r103949 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r103948‎ | r103949 | r103950 >
Date:19:59, 22 November 2011
Author:inez
Status:deferred
Tags:
Comment:
Fix setInterval bug in IE (in IE setInterval doesn't take 3rd parameter)
Modified paths:
  • /trunk/extensions/VisualEditor/modules/es/views/es.SurfaceView.js (modified) (history)

Diff [purge]

Index: trunk/extensions/VisualEditor/modules/es/views/es.SurfaceView.js
@@ -427,7 +427,7 @@
428428 sourceSplitableNode = es.DocumentViewNode.getSplitableNode( sourceNode );
429429 targetSplitableNode = es.DocumentViewNode.getSplitableNode( targetNode );
430430 }
431 -
 431+
432432 this.selection.from = this.selection.to = targetOffset;
433433 this.showCursor();
434434
@@ -699,11 +699,13 @@
700700 if ( this.cursor.interval ) {
701701 clearInterval( this.cursor.interval );
702702 }
 703+
 704+ var _this = this;
703705 this.cursor.interval = setInterval( function( surface ) {
704 - surface.cursor.$.css( 'display', function( index, value ) {
 706+ _this.cursor.$.css( 'display', function( index, value ) {
705707 return value === 'block' ? 'none' : 'block';
706708 } );
707 - }, 500, this );
 709+ }, 500 );
708710 };
709711
710712 /**

Status & tagging log