Index: safari/ext/background.js |
diff --git a/safari/ext/background.js b/safari/ext/background.js |
index 38870c0564b31fca093a5cb0c36419a0063014a7..152ff2e1b467e0505b566ff8255051cc50d982ab 100644 |
--- a/safari/ext/background.js |
+++ b/safari/ext/background.js |
@@ -384,6 +384,7 @@ |
/* Message processing */ |
+ var dispatchedLegacyAPISupportMessage = false; |
safari.application.addEventListener("message", function(event) |
{ |
var tab = event.target; |
@@ -503,6 +504,15 @@ |
} |
tab._documentLookup[documentId] = {pageId: pageId, frameId: frameId}; |
+ |
+ if (!dispatchedLegacyAPISupportMessage) |
+ { |
+ ext.onMessage._dispatch({ |
+ type: "safari.legacyAPISupported", |
+ legacyAPISupported: message.legacyAPISupported |
+ }); |
+ dispatchedLegacyAPISupportMessage = true; |
+ } |
break; |
case "documentId": |
tab._documentLookup[message.documentId] = { |