Created an IndexValueStore class which can store any object and return
an integer index to its hash map.
Linear data is now stored in ve.dm.LinearData instances. Two subclasses
for element and meta data contain methods specific to those data types
(ElementLinearData and MetaLinearData).
The static methods in ve.dm.Document that inspected data at a given
offset are now instance methods of ve.dm.ElementLinearData.
AnnotationSets (which are no longer OrderedHashSets) have been moved
to /dm and also have to be instantiated with a pointer the store.
Bug: 46320
Change-Id: I249a5d48726093d1cb3e36351893f4bff85f52e2
The IndentationAction was created against a version of master which
didn't have the new Surface constructor signature. This commit resolves
that conflict.
Change-Id: Ifc17f95acfa6057963d503448405355831b1ff97
isolateAndUnwrap now unwraps to a level determined by a target type
i.e. the type you are going to convert to.
Also in this commit wrap/unwrap/rewrap have been refactored to use
getLengthDifference. unwrap now takes an inner/outer unwrap depth.
Change-Id: I3c6249de43232a9ef64f498a0aaf66b1c44973f2
Wrapper paragraphs should only be unwrapped if they are the first
element in their parent - or if there is a block level element separating
them from the previous unwrapped paragraph.
Empty paragraphs should only be unwrapped if they are empty and the
last element in their parent.
Also in this commit is a simple test for IndentationAction.decrease().
Bug: 45590
Change-Id: I1f47d12db6d57d984fd4607f667a3b62c53f3dd6
The ve.Surface constructor was recently changed, but the instantiation
in the FormatAction tests was not updated accordingly.
The constructor now requires a ve.init.Target object.
Bug: 39597
Change-Id: Ia4193fbab5c63007ed057009bf9a39f1f9d18fb7
I was seeing intermittent test failures caused by exceptions in
ce.SurfaceObserver (!!), seems to be caused by the FormatAction test
creating a surface but not destroying it.
Change-Id: I7ab070d3c8db934eb9781ac8a6466475144c214e