From c49e5bfef983da748a8a140e537a7f03a7bfee9c Mon Sep 17 00:00:00 2001 From: nightwing Date: Sun, 7 Dec 2014 01:26:44 +0400 Subject: [PATCH] disable warning --- lib/ace/mouse/multi_select_handler.js | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/lib/ace/mouse/multi_select_handler.js b/lib/ace/mouse/multi_select_handler.js index 8d6af6b5..9b52e237 100644 --- a/lib/ace/mouse/multi_select_handler.js +++ b/lib/ace/mouse/multi_select_handler.js @@ -150,7 +150,8 @@ function onMouseDown(e) { if (isSamePoint(screenCursor, newCursor) && isSamePoint(cursor, selection.lead)) return; screenCursor = newCursor; - + + editor.$blockScrolling++; editor.selection.moveToPosition(cursor); editor.renderer.scrollCursorIntoView(); @@ -160,8 +161,9 @@ function onMouseDown(e) { rectSel[0] = editor.$mouseHandler.$clickSelection.clone(); rectSel.forEach(editor.addSelectionMarker, editor); editor.updateSelectionMarkers(); + editor.$blockScrolling--; }; - + editor.$blockScrolling++; if (isMultiSelect && !accel) { selection.toSingleRange(); } else if (!isMultiSelect && accel) { @@ -173,6 +175,7 @@ function onMouseDown(e) { screenAnchor = session.documentToScreenPosition(selection.lead); else selection.moveToPosition(pos); + editor.$blockScrolling--; screenCursor = {row: -1, column: -1};