settings = require '../settings'
class SearchBase extends MotionWithInput
- operatesInclusively: false
-
constructor: (@editor, @vimState, options = {}) ->
super(@editor, @vimState)
@reverse = @initiallyReversed = false
atom.beep()
scan: (cursor) ->
+ return [] if @input.characters is ""
+
currentPosition = cursor.getBufferPosition()
[rangesBefore, rangesAfter] = [[], []]
constructor: (@editor, @vimState) ->
super(@editor, @vimState)
@viewModel = new SearchViewModel(this)
+ @updateViewModel()
+
+ reversed: =>
+ @initiallyReversed = @reverse = true
+ @updateCurrentSearch()
+ @updateViewModel()
+ this
+
+ updateViewModel: ->
+ @viewModel.update(@initiallyReversed)
class SearchCurrentWord extends SearchBase
@keywordRegex: null