1
0
mirror of https://github.com/gryf/pentadactyl-pm.git synced 2025-12-23 04:07:58 +01:00

added visualbellstyle (don't think it works on GTK at least)

This commit is contained in:
Martin Stubenschrott
2008-05-24 21:02:48 +00:00
parent b8dcad1d51
commit f7be4eccd0
3 changed files with 26 additions and 8 deletions

View File

@@ -100,6 +100,11 @@ const liberator = (function () //{{{
{
setter: function (value) { liberator.options.setPref("accessibility.typeaheadfind.enablesound", !value); },
});
liberator.options.add(["visualbellstyle", "t_vb"],
"CSS specification of the visual bell",
"string", "border: none; background-color: black;"
);
}
function addMappings()
@@ -447,15 +452,20 @@ const liberator = (function () //{{{
{
if (liberator.options["visualbell"])
{
// flash the visual bell
var popup = document.getElementById("liberator-visualbell");
var win = getBrowser().mPanelContainer;
var box = document.getBoxObjectFor(win);
var vbs = liberator.options["visualbellstyle"];
if (vbs)
{
// flash the visual bell
var popup = document.getElementById("liberator-visualbell");
var win = getBrowser().mPanelContainer;
var box = document.getBoxObjectFor(win);
popup.height = box.height;
popup.width = box.width;
popup.openPopup(win, "overlap", 0, 0, false, false);
setTimeout(function () { popup.hidePopup(); }, 50);
popup.style.cssText = vbs;
popup.height = box.height;
popup.width = box.width;
popup.openPopup(win, "overlap", 0, 0, false, false);
setTimeout(function () { popup.hidePopup(); }, 50);
}
}
else
{