Trevor Parscal
cbb868577e
Whitespace and syntax fixes
...
Change-Id: I5a553272c1faf1e83a5e8be8ecf7911a11ec27a8
2012-05-07 13:40:09 -07:00
Catrope
93d6adb5f2
Add an isWrapped property and make getOuterLength use it
...
This gets rid of the length == outerLength-2 hack in getDataFromNode()
and will make it easier to implement similar logic in selectNodes()
Change-Id: I1294350b67ca3eefde2b7fe9fea0bc6d8b90f772
2012-05-07 12:00:07 -07:00
Trevor Parscal
e34ec4b479
Added canHaveChildren and canHaveGrandchildren to all nodes
...
Change-Id: Ibe53292f7269736750e03da49e5bb5913c0124ab
2012-05-04 17:50:54 -07:00
Trevor Parscal
dc27d8acb4
Refactored dom wrapper functionality in ce nodes
...
* Moved implementation of getting and updating a DOM wrapper to ve.ce.BranchNode
* Updated ve.ce.BranchNode tests
* Renamed ve.NodeFactory.createNode to ve.NodeFactory.create
* Added ve.NodeFactory.lookup which gets the constructor of a type
* Added attribute pass-through to ve.dm.BranchNodeStub
Change-Id: I8f5b7d3d3ae616cc5f39828b24b655163d782ae5
2012-05-04 13:31:14 -07:00
Trevor Parscal
a9b26c8b55
Removed recursive rendering calls in favor of 100% event driven updates
...
Change-Id: I636222518e4cbeddb1c02901b79a9dcb09eeb952
2012-05-03 17:19:01 -07:00
Trevor Parscal
458ba0b7d5
Added tests for getModel, getParent, attach and detach on ve.ce.Node
...
Change-Id: I064b2a13cbfe7a7ebc11af83fb7744ebbad39da1
2012-05-03 17:06:23 -07:00
Inez Korczynski
a3b32b6615
Big refactoring to TextNode to make it work with new format of storing
...
annotations.
Change-Id: If84fcfdd04ff42e9b2449e1c8186d64fec4fb1ac
2012-05-02 22:28:57 -07:00
Inez Korczynski
9f11f437d2
Merge branch 'dmrewrite' of ssh://review/mediawiki/extensions/VisualEditor into dmrewrite
2012-05-02 19:29:49 -07:00
Inez Korczynski
d81b972cdf
Very dirty but working version of getHtml method for TextNode (with bunch
...
of tests that are passing now).
Change-Id: Ie76bd59bc0a5e10e2a3b3e014b2d0e4701fcc368
2012-05-02 19:29:03 -07:00
Trevor Parscal
6a60c1f60b
Removed console.log
...
Change-Id: I7cd2e1cf5e1cf7a2e9864090cfab391faba10997
2012-05-02 16:46:36 -07:00
Trevor Parscal
b7b2fc1179
Made render for ce leaf nodes abstract and added a test for it
...
Change-Id: Iee228d5f1a18a5c9618680fa81ab132a85472fa6
2012-05-02 15:59:43 -07:00
Trevor Parscal
6792762285
Added insertion and removal tests to ve.ce.BranchNode.onSplice
...
Change-Id: Ic4fc51f3f8f869b03e9ae0fced88c74d2ddf4388
2012-05-02 14:59:07 -07:00
Trevor Parscal
d97864a92e
Added removal test for ve.ce.BranchNode.onSplice
...
Change-Id: I54b622fa05ce02965a2ae48fc78958b6408bca4d
2012-05-02 14:50:28 -07:00
Trevor Parscal
fd28fff50f
Added test for replaceDomWrapper and onSplice in ve.ce.BranchNode
...
* Also fixed calls to addListenerMethod
* Also routed adding children in the constructor of ve.dm.BranchNode to the splice method
* Renamed types of ve.dm stub nodes to avoid collisions (since we have to register ce nodes by the same names for them to be generated by onSplice)
Change-Id: Ia2e75cf0a62186cc0e214683feb25c619590318a
2012-05-02 13:58:50 -07:00
Trevor Parscal
8bd0d385eb
Added test for whitespacePattern, getDomText and getDomHash in ce
...
* Also fixed some naming typos in the units under test
Change-Id: I17f753a122f94dd16f7783f60b5c0eb1c6d3e480
2012-05-02 12:54:42 -07:00
Trevor Parscal
de0debb866
Added skeleton tests for ce nodes
...
Change-Id: I1f5988b31fdef1bf5c5f9266d0bfa8da91d97c3a
2012-04-30 17:04:58 -07:00
Trevor Parscal
aaa322642b
Added ve.ce.NodeFactory and tests
...
Also added tests for initialization of factories at ve.ce.factory and ve.dm.factory
Change-Id: Ic6ac74aab86ecdfd4f094d9bb1fa16de930387b7
2012-04-30 16:36:02 -07:00