Trevor Parscal has uploaded a new change for review. Change subject: (bug 42401) Cursor movement fixes ......................................................................
(bug 42401) Cursor movement fixes ve.ce.Surface * Added ve.ce.Surface.adjustCursor, which replaces repetitive and buggy code that was handling left and right arrow key presses * New method only affects the selection target, so it won't collapse the selection on you - this was what caused bug 42401 ve.dm.Document * Fixed turn-around issue in ve.dm.Document.getRelativeOffset - if the offset is already valid and we can't move in the direction we want, we should just leave it be, not turn around * Since this method was being used by ve.ce.Surface to correct the cursor position on arrow key presses, it was causing the strange cursor jumping when you pressed an arrow key while at the edge of a document ve.dm.SurfaceFragment * Fixed typo where getAnnotationRangeFromSelection was preserving selection direction, but checking the wrong properties ve.dm.Document.test * Added tests that verify turn-around issue is fixed Change-Id: Iba55cfc3d531e7d1333b78c94912ff22179aace8 --- M modules/ve/ce/ve.ce.Surface.js M modules/ve/dm/ve.dm.Document.js M modules/ve/dm/ve.dm.SurfaceFragment.js M modules/ve/test/dm/ve.dm.Document.test.js 4 files changed, 79 insertions(+), 54 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/VisualEditor refs/changes/90/35590/1 -- To view, visit https://gerrit.wikimedia.org/r/35590 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: Iba55cfc3d531e7d1333b78c94912ff22179aace8 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/VisualEditor Gerrit-Branch: master Gerrit-Owner: Trevor Parscal <[email protected]> _______________________________________________ MediaWiki-commits mailing list [email protected] https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
