       cursor.getBufferPosition()
 
   getCursorPositionForSelection: (selection) ->
+    swrap ?= require './selection-wrapper'
     swrap(selection).getBufferPositionFor('head', from: ['property', 'selection'])
 
   toString: ->

  @registerCommandFromSpec: (name, spec) ->
    {commandScope, commandPrefix, commandName, getClass} = spec
    commandScope ?= 'atom-text-editor'
    commandName = (commandPrefix ? 'vim-mode-plus') + ':' + _.dasherize(name)
    atom.commands.add commandScope, commandName, (event) ->
      vimState = getEditorState(@getModel()) ? getEditorState(atom.workspace.getActiveTextEditor())
      if vimState? # Possibly undefined See #85

  getIndentLevelForBufferRow
  scanEditorInDirection
} = require './utils'
swrap = null

settings = require './settings'

[
