diff options
author | Alex Yatskov <alex@foosoft.net> | 2016-05-05 20:06:13 -0700 |
---|---|---|
committer | Alex Yatskov <alex@foosoft.net> | 2016-05-05 20:06:13 -0700 |
commit | 9cb099e5f6aad33c70d986bd6a48668e54ee211c (patch) | |
tree | d46de3d97388764f15f8f319d8455e60d3c2d9f4 /ext/fg/js/popup.js | |
parent | dd4b2f73656d652bc56be784a27e7378ab969ac6 (diff) |
Optimization
Diffstat (limited to 'ext/fg/js/popup.js')
-rw-r--r-- | ext/fg/js/popup.js | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/ext/fg/js/popup.js b/ext/fg/js/popup.js index 16a62b1c..53359cf3 100644 --- a/ext/fg/js/popup.js +++ b/ext/fg/js/popup.js @@ -68,6 +68,12 @@ class Popup { doc.close(); } + sendMessage(action, params, callback) { + if (this.popup !== null) { + this.popup.contentWindow.postMessage({action: action, params: params}, '*'); + } + } + inject() { if (this.popup !== null) { return; |