From f86f2dcee5735076ccf00a604c188d9a3fdb8991 Mon Sep 17 00:00:00 2001 From: Doug Kearns Date: Wed, 29 Oct 2008 10:13:40 +0000 Subject: [PATCH] replace use of deprecated getBoxObjectFor in liberator.beep --- content/liberator.js | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/content/liberator.js b/content/liberator.js index 27e53065..62358a97 100644 --- a/content/liberator.js +++ b/content/liberator.js @@ -625,11 +625,13 @@ const liberator = (function () //{{{ // flash the visual bell let popup = document.getElementById("liberator-visualbell"); let win = config.visualbellWindow; - let box = document.getBoxObjectFor(win); + let rect = win.getBoundingClientRect(); + let width = rect.right - rect.left; + let height = rect.bottom - rect.top; // NOTE: this doesn't seem to work in FF3 with full box dimensions popup.openPopup(win, "overlap", 1, 1, false, false); - popup.sizeTo(box.width - 2, box.height - 2); + popup.sizeTo(width - 2, height - 2); setTimeout(function () { popup.hidePopup(); }, 20); } else