Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

indexOf support added for IE8 and below; Known Issue (still buggy in …

…IE) added to Readme.
  • Loading branch information...
commit 24b460d6036c01f137d2de07af15e5bade52de78 1 parent df67b98
@KuraFire authored
Showing with 24 additions and 0 deletions.
  1. +5 −0 README.md
  2. +19 −0 jquery.runloop.0.9.js
View
5 README.md
@@ -14,5 +14,10 @@ to avoid timing conflicts in the case of doing many multiple .animate() calls.
Full usage documentation will be prepared for the 1.0 release.
+### Known issues
+
+* Currently there is a bug in IE8 and below. It seems to have something to do with
+ the jQuery library, but we're still investigating it.
+
Runloop is Copyright © 2011 Faruk Ates; dual licensed under the MIT or BSD licenses.
View
19 jquery.runloop.0.9.js
@@ -65,6 +65,25 @@
var val = parseInt(at.toString().match(/[0-9]+/g));
return (isNaN(val)) ? false : "at" + val;
};
+
+ // Add indexOf support if needed:
+ if (!Array.prototype.indexOf) {
+ Array.prototype.indexOf = function(elt)
+ {
+ var len = this.length >>> 0;
+ var from = Number(arguments[1]) || 0;
+ from = (from < 0) ? Math.ceil(from) : Math.floor(from);
+ if (from < 0) {
+ from += len;
+ }
+ for (; from < len; from++) {
+ if (from in this && this[from] === elt) {
+ return from;
+ }
+ }
+ return -1;
+ };
+ }
// Public methods:
return {
Please sign in to comment.
Something went wrong with that request. Please try again.