From 070bc8302e00f766076b4aaabfd2de4a0f2da66f Mon Sep 17 00:00:00 2001 From: alecpl <alec@alec.pl> Date: Wed, 20 Jul 2011 15:09:12 -0400 Subject: [PATCH] - Add check for inArray() input to prevent error in Firefox 5 --- program/js/common.js | 31 ++++++++++++++++--------------- 1 files changed, 16 insertions(+), 15 deletions(-) diff --git a/program/js/common.js b/program/js/common.js index 79832be..cacf0ff 100644 --- a/program/js/common.js +++ b/program/js/common.js @@ -347,9 +347,14 @@ break; } } + + if (ret) + delete ret.event; } this._event_exec = false; + delete e.event; + return ret; } @@ -378,21 +383,17 @@ parent = arg.parent, obj = document.createElement('DIV'); - with (obj) { - id = this.name; - with (style) { - position = 'absolute'; - visibility = (vis) ? (vis==2) ? 'inherit' : 'visible' : 'hidden'; - left = l+'px'; - top = t+'px'; - if (w) - width = w.toString().match(/\%$/) ? w : w+'px'; - if (h) - height = h.toString().match(/\%$/) ? h : h+'px'; - if (z) - zIndex = z; - } - } + obj.id = this.name; + obj.style.position = 'absolute'; + obj.style.visibility = (vis) ? (vis==2) ? 'inherit' : 'visible' : 'hidden'; + obj.style.left = l+'px'; + obj.style.top = t+'px'; + if (w) + obj.style.width = w.toString().match(/\%$/) ? w : w+'px'; + if (h) + obj.style.height = h.toString().match(/\%$/) ? h : h+'px'; + if (z) + obj.style.zIndex = z; if (parent) parent.appendChild(obj); -- Gitblit v1.9.1