mirror of
https://github.com/atom/atom.git
synced 2026-02-17 01:51:54 -05:00
Merge pull request #8604 from lpommers/pressing-esc-on-multiple-cursors-returns-to-original-cursor-or-selection
Pressing esc on multiple cursors returns to original cursor or selection
This commit is contained in:
@@ -2241,11 +2241,11 @@ class TextEditor extends Model
|
||||
@consolidateSelections()
|
||||
@getLastSelection().clear(options)
|
||||
|
||||
# Reduce multiple selections to the most recently added selection.
|
||||
# Reduce multiple selections to the least recently added selection.
|
||||
consolidateSelections: ->
|
||||
selections = @getSelections()
|
||||
if selections.length > 1
|
||||
selection.destroy() for selection in selections[0...-1]
|
||||
selection.destroy() for selection in selections[1...(selections.length)]
|
||||
true
|
||||
else
|
||||
false
|
||||
|
||||
Reference in New Issue
Block a user