Mercurial > p > roundup > code
diff templates/classic/html/help_controls.js @ 1971:75fe2131b6d9
fixed check for JS pop()/push() to make more general [SF#877504]
| author | Richard Jones <richard@users.sourceforge.net> |
|---|---|
| date | Sat, 17 Jan 2004 01:49:18 +0000 |
| parents | d6c039c5b52b |
| children | 37bf760544f3 |
line wrap: on
line diff
--- a/templates/classic/html/help_controls.js Thu Jan 15 04:12:03 2004 +0000 +++ b/templates/classic/html/help_controls.js Sat Jan 17 01:49:18 2004 +0000 @@ -35,10 +35,11 @@ } } -// add the pop() and push() method to Array prototype for old IE browser -if (bName() == 1 && bVer() >= 5.5); -else { +// add the pop() and push() method to Array if they're not there +if (!Array.prototype.pop) { Array.prototype.pop = pop; +} +if (!Array.prototype.push) { Array.prototype.push = push; }
