Example #1
0
 context.clearTimeout = function (to) {
     var res = clearTimeout.apply
         ? clearTimeout.apply(this, arguments)
         : apply(clearTimeout, this, arguments)
     ;
     var i = timeouts.indexOf(to);
     if (i >= 0) timeouts.splice(i, 1);
     compiled.checkStopped()
     return res;
 };
Example #2
0
 context.clearInterval = function (iv) {
     var res = clearInterval.apply
         ? clearInterval.apply(this, arguments)
         : apply(clearInterval, this, arguments)
     ;
     var i = intervals.indexOf(iv);
     if (i >= 0) intervals.splice(i, 1);
     compiled.checkStopped();
     return res;
 };
Example #3
0
 function wrappedCallback () {
   var res = callback()
   context.clearTimeout(to);
   compiled.checkStopped();
   return res;
 }
Example #4
0
 compiled.removeCallback = function unregister (wrappedCallback) {
   var i = callbacks.indexOf(wrappedCallback);
   if (i >= 0) callbacks.splice(i, 1);
   compiled.checkStopped();
 }