aboutsummaryrefslogtreecommitdiffstats
path: root/content_scripts/vimium_frontend.coffee
diff options
context:
space:
mode:
authorStephen Blott2016-04-17 16:51:55 +0100
committerStephen Blott2016-04-17 16:51:55 +0100
commitc01d7eea8675f9a7d84999777e8de72244d687b6 (patch)
tree5a76f087567dd05aca4fe2adf69090398e62e9a0 /content_scripts/vimium_frontend.coffee
parent44ddab1e1eca01ae6c958756d149be2d4128b290 (diff)
downloadvimium-c01d7eea8675f9a7d84999777e8de72244d687b6.tar.bz2
UI-compnent commands must wait for the document to be ready.
Diffstat (limited to 'content_scripts/vimium_frontend.coffee')
-rw-r--r--content_scripts/vimium_frontend.coffee5
1 files changed, 3 insertions, 2 deletions
diff --git a/content_scripts/vimium_frontend.coffee b/content_scripts/vimium_frontend.coffee
index a80093f9..d1ff874e 100644
--- a/content_scripts/vimium_frontend.coffee
+++ b/content_scripts/vimium_frontend.coffee
@@ -616,8 +616,9 @@ enterFindMode = ->
new FindMode()
window.showHelp = (sourceFrameId) ->
- chrome.runtime.sendMessage handler: "getHelpDialogHtml", (response) ->
- HelpDialog.toggle {sourceFrameId, html: response}
+ DomUtils.ifDocumentIsReady ->
+ chrome.runtime.sendMessage handler: "getHelpDialogHtml", (response) ->
+ HelpDialog.toggle {sourceFrameId, html: response}
# If we are in the help dialog iframe, then HelpDialog is already defined with the necessary functions.
window.HelpDialog ?=