 
   deactivateMode: ->
     @removeHintMarkers()
-    @markerMatcher = null
-    @isActive = false
     @hintMode?.exit()
-    @hintMode = null
     @onExit?()
-    @onExit = null
-    @tabCount = 0
 
   removeHintMarkers: ->
     DomUtils.removeElement @hintMarkerContainingDiv if @hintMarkerContainingDiv

      keypress: @onKeyPressInMode.bind this, hintMarkers

    @hintMode.onExit =>
      @deactivateMode() if @isActive
    @hintMode.onExit onExit

    @setOpenLinkMode mode

          keyup: (event) =>
            if event.keyCode == keyCode
              handlerStack.remove()
              @setOpenLinkMode previousMode
            true # Continue bubbling the event.

        # For some (unknown) reason, we don't always receive the keyup event needed to remove this handler.
