Commit graph

6 commits

Author SHA1 Message Date
Trevor Parscal 3be13a7cbc Consistent use of mw in HTML classes, and data element and annotation types
MWfooBar or MWfoobar should be mwFooBar

Change-Id: I30f0ef05960c9df218ef6f1cb161ff6ccd529bc7
2013-05-28 13:49:56 +01:00
Catrope cba55b9330 Don't do evil shadowing of mw
Having local variable called mw that shadows the global variable mw
is evil. Rename it to mwAttr.

Change-Id: I87bd3698c73608076424c10fdb0559dfdc3e3045
2013-05-26 14:34:47 +02:00
Catrope c36df77e3f Make reference editing work
The only reason it doesn't save correctly right now is because Parsoid
doesn't serialize reference edits correctly.

Change-Id: Ia0f272c07cc28ee829372eb848f23aec99eb92f0
2013-05-25 18:06:57 +02:00
Catrope 238d68eb74 Merging and remapping of IVStores and InternalLists
Add merge() methods to IndexValueStore and InternalList, which merge
another store/list in to the current one and return a mapping
translating old indexes to new ones.

Also add functions that, given such a mapping, traverse a linear
model data array and remap store/list indexes using simple logic for
annotations and node type-specific functions for node attributes.

Change-Id: I1e90755ced1a87c190947c037cf151c4d17cf8b7
2013-05-25 11:33:35 +00:00
Trevor Parscal cce80e63c0 Fix for crashing on save
converter.documentData contains the full data with metadata interleaved,
but it was being sliced using offsets relevant to the element data.

Change-Id: Iddbef23212da818a2a399b4abdc223aad130eb4e
See: I6daff5c5969e5fdc871f8f346cf790b4302ae080
2013-05-14 21:34:06 +00:00
Ed Sanders 6ad61d4ddb Add data model support for MediaWiki references
So far just read-only.

Bug: 39599
Change-Id: I6daff5c5969e5fdc871f8f346cf790b4302ae080
2013-04-23 10:17:42 +01:00