diff options
Diffstat (limited to 'content_scripts/vimium_frontend.coffee')
| -rw-r--r-- | content_scripts/vimium_frontend.coffee | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/content_scripts/vimium_frontend.coffee b/content_scripts/vimium_frontend.coffee index 4d081e90..7ff03ee5 100644 --- a/content_scripts/vimium_frontend.coffee +++ b/content_scripts/vimium_frontend.coffee @@ -143,7 +143,7 @@ initializeOnEnabledStateKnown = (isEnabledForUrl) -> if isEnabledForUrl # We only initialize (and activate) the Vomnibar in the top frame. Also, we do not initialize the # Vomnibar until we know that Vimium is enabled. Thereafter, there's no more initialization to do. - Vomnibar.init() if DomUtils.isTopFrame() + DomUtils.documentComplete Vomnibar.init.bind Vomnibar if DomUtils.isTopFrame() initializeOnEnabledStateKnown = -> # @@ -635,10 +635,11 @@ window.HelpDialog ?= abort: -> @helpUI.hide false if @isShowing() toggle: (request) -> - @helpUI ?= new UIComponent "pages/help_dialog.html", "vimiumHelpDialogFrame", -> - if @isShowing() + DomUtils.documentComplete => + @helpUI ?= new UIComponent "pages/help_dialog.html", "vimiumHelpDialogFrame", -> + if @helpUI? and @isShowing() @helpUI.hide() - else + else if @helpUI? @helpUI.activate extend request, name: "activate", focus: true |
