r105599 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r105598‎ | r105599 | r105600 >
Date:22:16, 8 December 2011
Author:inez
Status:deferred
Tags:
Comment:
Fix bug in ListButtilTool - cursor position was adjusted when it shouldn't be
Modified paths:
  • /trunk/extensions/VisualEditor/modules/es/tools/es.ListButtonTool.js (modified) (history)

Diff [purge]

Index: trunk/extensions/VisualEditor/modules/es/tools/es.ListButtonTool.js
@@ -57,12 +57,12 @@
5858 if( stack.length > 0 ) {
5959 stacks.push( stack );
6060 }
61 -
62 - if ( selection.from === selection.to ) {
63 - selection.from += 2;
64 - selection.to += 2;
65 - } else {
66 - if ( stacks.length > 0 ) {
 61+
 62+ if ( stacks.length > 0 ) {
 63+ if ( selection.from === selection.to ) {
 64+ selection.from += 2;
 65+ selection.to += 2;
 66+ } else {
6767 if ( nodes[0].getParent().getElementType() != 'listItem' ) {
6868 if ( selection.from < selection.to ) {
6969 selection.from += 2;

Status & tagging log