From fdcbb9c8ffb641fb9100a653e57d741800c88cf6 Mon Sep 17 00:00:00 2001 From: Antonio Scandurra Date: Wed, 25 Feb 2015 18:44:08 +0100 Subject: [PATCH] Don't change mergeIntersectingSelections behavior for now --- src/text-editor.coffee | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/src/text-editor.coffee b/src/text-editor.coffee index 35519c431..a25f98496 100644 --- a/src/text-editor.coffee +++ b/src/text-editor.coffee @@ -92,7 +92,7 @@ class TextEditor extends Model @updateInvisibles() - @batch => @mergeIntersectingSelections => + @batch => for marker in @findMarkers(@getSelectionMarkerAttributes()) marker.setProperties(preserveFolds: true) @addSelection(marker) @@ -835,8 +835,7 @@ class TextEditor extends Model # argument will be a {Selection} and the second argument will be the # {Number} index of that selection. mutateSelectedText: (fn) -> - @mergeIntersectingSelections => @transact => - fn(selection, index) for selection, index in @getSelections() + @transact => fn(selection, index) for selection, index in @getSelections() # Move lines intersection the most recent selection up by one row in screen # coordinates. @@ -995,7 +994,7 @@ class TextEditor extends Model # selections to create multiple single-line selections that cumulatively cover # the same original area. splitSelectionsIntoLines: -> - @batch => @mergeIntersectingSelections => + @batch => for selection in @getSelections() range = selection.getBufferRange() continue if range.isSingleLine() @@ -1803,7 +1802,7 @@ class TextEditor extends Model @emitter.emit 'did-remove-cursor', cursor moveCursors: (fn) -> - @batch => @mergeIntersectingSelections => + @batch => fn(cursor) for cursor in @getCursors() @mergeCursors()