diff options
| -rw-r--r-- | content_scripts/hud.coffee | 8 | 
1 files changed, 6 insertions, 2 deletions
| diff --git a/content_scripts/hud.coffee b/content_scripts/hud.coffee index 928ae5fd..d4c38447 100644 --- a/content_scripts/hud.coffee +++ b/content_scripts/hud.coffee @@ -90,10 +90,14 @@ HUD =    # * we don't want to disrupt the focus in the page, in case the page is listening for focus/blur events.    # * the HUD shouldn't be active for this frame while any of the copy/paste commands are running.    copyToClipboard: (text) -> -    @hudUI.postMessage {name: "copyToClipboard", data: text} +    DomUtils.documentComplete => +      @init() +      @hudUI?.postMessage {name: "copyToClipboard", data: text}    pasteFromClipboard: (@pasteListener) -> -    @hudUI.postMessage {name: "pasteFromClipboard"} +    DomUtils.documentComplete => +      @init() +      @hudUI?.postMessage {name: "pasteFromClipboard"}    pasteResponse: ({data}) ->      @pasteListener data | 
