diff options
| -rw-r--r-- | content_scripts/link_hints.coffee | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/content_scripts/link_hints.coffee b/content_scripts/link_hints.coffee index 7165b885..a975ff60 100644 --- a/content_scripts/link_hints.coffee +++ b/content_scripts/link_hints.coffee @@ -9,7 +9,7 @@ # typing the text of the link itself. # OPEN_IN_CURRENT_TAB = {} -OPEN_IN_NEW_TAB = {} +OPEN_IN_NEW_BG_TAB = {} OPEN_IN_NEW_FG_TAB = {} OPEN_WITH_QUEUE = {} COPY_LINK_URL = {} @@ -47,7 +47,7 @@ LinkHints = "@contenteditable='' or translate(@contenteditable, 'TRUE', 'true')='true']"]) # We need this as a top-level function because our command system doesn't yet support arguments. - activateModeToOpenInNewTab: -> @activateMode(OPEN_IN_NEW_TAB) + activateModeToOpenInNewTab: -> @activateMode(OPEN_IN_NEW_BG_TAB) activateModeToOpenInNewForegroundTab: -> @activateMode(OPEN_IN_NEW_FG_TAB) activateModeToCopyLinkUrl: -> @activateMode(COPY_LINK_URL) activateModeWithQueue: -> @activateMode(OPEN_WITH_QUEUE) @@ -79,11 +79,11 @@ LinkHints = }) setOpenLinkMode: (@mode) -> - if @mode is OPEN_IN_NEW_TAB or @mode is OPEN_IN_NEW_FG_TAB or @mode is OPEN_WITH_QUEUE - if @mode is OPEN_IN_NEW_TAB + if @mode is OPEN_IN_NEW_BG_TAB or @mode is OPEN_IN_NEW_FG_TAB or @mode is OPEN_WITH_QUEUE + if @mode is OPEN_IN_NEW_BG_TAB HUD.show("Open link in new tab") else if @mode is OPEN_IN_NEW_FG_TAB - HUD.show("Open link in new foreground tab") + HUD.show("Open link in new tab and switch to it") else HUD.show("Open multiple links in a new tab") @linkActivator = (link) -> @@ -173,16 +173,16 @@ LinkHints = if ((event.keyCode == keyCodes.shiftKey or event.keyCode == keyCodes.ctrlKey) and (@mode == OPEN_IN_CURRENT_TAB or - @mode == OPEN_IN_NEW_TAB or + @mode == OPEN_IN_NEW_BG_TAB or @mode == OPEN_IN_NEW_FG_TAB)) # Toggle whether to open link in a new or current tab. prev_mode = @mode if event.keyCode == keyCodes.shiftKey - @setOpenLinkMode(if @mode is OPEN_IN_CURRENT_TAB then OPEN_IN_NEW_TAB else OPEN_IN_CURRENT_TAB) + @setOpenLinkMode(if @mode is OPEN_IN_CURRENT_TAB then OPEN_IN_NEW_BG_TAB else OPEN_IN_CURRENT_TAB) else # event.keyCode == keyCodes.ctrlKey - @setOpenLinkMode(if @mode is OPEN_IN_NEW_FG_TAB then OPEN_IN_NEW_TAB else OPEN_IN_NEW_FG_TAB) + @setOpenLinkMode(if @mode is OPEN_IN_NEW_FG_TAB then OPEN_IN_NEW_BG_TAB else OPEN_IN_NEW_FG_TAB) # TODO(philc): Ignore keys that have modifiers. if (KeyboardUtils.isEscape(event)) |
