From 8b57d179a1655dbce081b321445f34a4aad696f4 Mon Sep 17 00:00:00 2001 From: Stephen Blott Date: Tue, 26 May 2015 06:03:07 +0100 Subject: Add comment noting why we need AsyncDataFetcher. --- content_scripts/ui_component.coffee | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'content_scripts') diff --git a/content_scripts/ui_component.coffee b/content_scripts/ui_component.coffee index 31274c3e..24982fa7 100644 --- a/content_scripts/ui_component.coffee +++ b/content_scripts/ui_component.coffee @@ -27,7 +27,9 @@ class UIComponent # Hide the iframe, but don't interfere with the focus. @hide false - # Open a port and pass it to the iframe via window.postMessage. + # Open a port and pass it to the iframe via window.postMessage. We use an AsyncDataFetcher to handle + # requests which arrive before the frame (and its message handlers) have completed initialization. See + # #1679. @iframePort = new AsyncDataFetcher (setIframePort) => @iframeElement.addEventListener "load", => # Get vimiumSecret so the iframe can determine that our message isn't the page impersonating us. -- cgit v1.2.3