diff options
author | Andrew Dolgov <[email protected]> | 2006-05-18 14:51:15 +0100 |
---|---|---|
committer | Andrew Dolgov <[email protected]> | 2006-05-18 14:51:15 +0100 |
commit | 292a8a12246dd386e36c20b24369d50bb60defa8 (patch) | |
tree | 2a9791b416dc57348c374072b9eda4e6ff656c0b /functions.js | |
parent | f9e621d06fde24fd6e753e274bcc2023d7b83631 (diff) |
opera fixes
Diffstat (limited to 'functions.js')
-rw-r--r-- | functions.js | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/functions.js b/functions.js index 8245c71a1..ef7910c71 100644 --- a/functions.js +++ b/functions.js @@ -1,5 +1,9 @@ var hotkeys_enabled = true; +function browser_has_opacity() { + return navigator.userAgent.match("Gecko") || navigator.userAgent.match("Opera"); +} + function exception_error(location, e) { var msg; @@ -78,14 +82,14 @@ var notify_last_doc = false; function hide_notify() { if (notify_last_doc) { var n = notify_last_doc.getElementById("notify"); - if (browser.isNS) { + if (browser_has_opacity()) { if (notify_opacity >= 0) { notify_opacity = notify_opacity - 0.2; n.style.opacity = notify_opacity; - notify_hide_timerid = window.setTimeout(hide_notify, 20); + notify_hide_timerid = window.setTimeout("hide_notify()", 20); } else { n.style.display = "none"; - n.style.opacity = 1; + n.style.opacity = 1; } } else { n.style.display = "none"; @@ -126,7 +130,7 @@ function notify_real(msg, doc, no_hide, is_err) { notify_opacity = 1; if (!no_hide) { - notify_hide_timerid = window.setTimeout(hide_notify, 3000); + notify_hide_timerid = window.setTimeout("hide_notify()", 3000); } } |