1 { getCommand, maybeCommand } = require 'commands'
2 { getWindowId } = require 'utils'
8 constructor: (@window) ->
12 keypress: (keyInfo) ->
14 if command = getCommand @keys
18 else if maybeCommand @keys
24 @activeElement = element
25 console.log 'focus', @activeElement
28 console.log 'blur', @activeElement
29 delete @activeElement if @activeElement == element
39 id = getWindowId window
40 @vims[id] or @vims[id] = new Vim window
43 id = getWindowId window
44 delete @vims[id] if id
46 exports.VimBucket = VimBucket