aboutsummaryrefslogtreecommitdiff
path: root/ext/fg/js/popup-proxy.js
diff options
context:
space:
mode:
Diffstat (limited to 'ext/fg/js/popup-proxy.js')
-rw-r--r--ext/fg/js/popup-proxy.js17
1 files changed, 10 insertions, 7 deletions
diff --git a/ext/fg/js/popup-proxy.js b/ext/fg/js/popup-proxy.js
index 09c184db..d910d30c 100644
--- a/ext/fg/js/popup-proxy.js
+++ b/ext/fg/js/popup-proxy.js
@@ -88,14 +88,17 @@ class PopupProxy extends EventDispatcher {
return await this._invoke('containsPoint', {id: this._id, x, y});
}
- async showContent(elementRect, writingMode, type, details, context) {
- let {x, y, width, height} = elementRect;
- if (this._frameOffsetForwarder !== null) {
- await this._updateFrameOffset();
- [x, y] = this._applyFrameOffset(x, y);
+ async showContent(details, displayDetails) {
+ const {elementRect} = details;
+ if (typeof elementRect !== 'undefined') {
+ let {x, y, width, height} = elementRect;
+ if (this._frameOffsetForwarder !== null) {
+ await this._updateFrameOffset();
+ [x, y] = this._applyFrameOffset(x, y);
+ }
+ details.elementRect = {x, y, width, height};
}
- elementRect = {x, y, width, height};
- return await this._invoke('showContent', {id: this._id, elementRect, writingMode, type, details, context});
+ return await this._invoke('showContent', {id: this._id, details, displayDetails});
}
setCustomCss(css) {