MCPcopy Index your code
hub / github.com/microsoft/SandDance / runClearTimeout

Function runClearTimeout

docs/app/js/sanddance-app.js:52739–52760  ·  view source on GitHub ↗
(marker)

Source from the content-addressed store, hash-verified

52737 }
52738}
52739function runClearTimeout(marker) {
52740 if (cachedClearTimeout === clearTimeout) //normal enviroments in sane situations
52741 return clearTimeout(marker);
52742 // if clearTimeout wasn't available but was latter defined
52743 if ((cachedClearTimeout === defaultClearTimeout || !cachedClearTimeout) && clearTimeout) {
52744 cachedClearTimeout = clearTimeout;
52745 return clearTimeout(marker);
52746 }
52747 try {
52748 // when when somebody has screwed with setTimeout but no I.E. maddness
52749 return cachedClearTimeout(marker);
52750 } catch (e) {
52751 try {
52752 // When we are in I.E. but the script has been evaled so I.E. doesn't trust the global object when called normally
52753 return cachedClearTimeout.call(null, marker);
52754 } catch (e) {
52755 // same as above but when it's a version of I.E. that must have the global object for 'this', hopfully our context correct otherwise it will throw a global error.
52756 // Some versions of I.E. have different rules for clearTimeout vs setTimeout
52757 return cachedClearTimeout.call(this, marker);
52758 }
52759 }
52760}
52761var queue = [];
52762var draining = false;
52763var currentQueue;

Callers 1

drainQueueFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected