       do @view.save
 
   buildBindingsDiv: () ->
+    if not (localStorage? and localStorage['showKeyBindings'])
+      return
+
+    modeKeymap = @keyMaps[@mode] || {}
+
     table = $('<table>')
 
     buildTableContents = (definitions, onto) =>

        bindings[key] = v
    return bindings

  constructor: (view, divs = {}) ->
    @view = view

    @keyMaps = _.clone defaultVimKeyBindings

    @bindings = {}
    @bindings[MODES.NORMAL] = getBindings keyDefinitions, @keyMaps.NORMAL
    @bindings[MODES.INSERT] = getBindings keyDefinitions, @keyMaps.INSERT
    @bindings[MODES.MENU]   = getBindings keyDefinitions, @keyMaps.MENU

    if divs.keyBindingsDiv
      @keybindingsDiv = divs.keyBindingsDiv
      do @buildBindingsDiv

    if divs.menuDiv
      @menuDiv = divs.menuDiv

    if divs.modeDiv
      @modeDiv = divs.modeDiv

    @mode = ''
    @setMode MODES.NORMAL

    @macros = {}

      @keybindingsDiv.toggleClass 'active'
      if localStorage?
        localStorage['showKeyBindings'] = @keybindingsDiv.hasClass 'active'
      do @buildBindingsDiv

  ZOOM_IN:
    display: 'Zoom in by one level'
