       HintCoordinator.sendMessage "activateActiveHintMarker" if @markerMatcher.activeHintMarker
 
     else if event.key == "Tab"
-      @tabCount = previousTabCount + (if event.shiftKey then -1 else 1)
+      if event.shiftKey then @tabCount-- else @tabCount++
       @updateVisibleMarkers @tabCount
 
     else if event.key == " " and @markerMatcher.shouldRotateHints event
-      @tabCount = previousTabCount
       HintCoordinator.sendMessage "rotateHints"
 
     else
-      @tabCount = previousTabCount if event.ctrlKey or event.metaKey or event.altKey
+      @tabCount = 0 unless event.ctrlKey or event.metaKey or event.altKey
       unless event.repeat
         keyChar =
           if Settings.get "filterLinkHints"


    else if KeyboardUtils.isBackspace event
      if @markerMatcher.popKeyChar()
        @updateVisibleMarkers()
      else
        # Exit via @hintMode.exit(), so that the LinkHints.activate() "onExit" callback sees the key event and

  onKeyDownInMode: (event) ->
    return if event.repeat

    # NOTE(smblott) The modifier behaviour here applies only to alphabet hints.
    if event.key in ["Control", "Shift"] and not Settings.get("filterLinkHints") and
      @mode in [ OPEN_IN_CURRENT_TAB, OPEN_WITH_QUEUE, OPEN_IN_NEW_BG_TAB, OPEN_IN_NEW_FG_TAB ]
        # Toggle whether to open the link in a new or current tab.
        previousMode = @mode
        key = event.key
