1
0
mirror of https://github.com/gryf/pentadactyl-pm.git synced 2025-12-22 03:38:00 +01:00

add a visual bell and replace 'beep' with 'visualbell'

This commit is contained in:
Doug Kearns
2007-09-05 18:49:26 +00:00
parent 517dea72e1
commit 908124ce22
7 changed files with 38 additions and 13 deletions

View File

@@ -280,8 +280,22 @@ const vimperator = (function() //{{{
beep: function()
{
if (vimperator.options["beep"])
if (!vimperator.options["visualbell"])
{
sound_service.beep();
return;
}
// flash the visual bell
var popup = document.getElementById("vimperator-visualbell");
var win = document.getElementById("main-window");
var box = document.getBoxObjectFor(win);
popup.height = box.height;
popup.width = box.width;
popup.showPopup(win, box.screenX, box.screenY, "popup");
setTimeout(function() { popup.hidePopup(); }, 375);
},
copyToClipboard: function(str)