MCPcopy Index your code
hub / github.com/angular-ui/ui-router / $$AnimateAsyncRunFactoryProvider

Function $$AnimateAsyncRunFactoryProvider

test/angular/1.6/angular.js:6131–6160  ·  view source on GitHub ↗

@this

()

Source from the content-addressed store, hash-verified

6129}];
6130
6131var $$AnimateAsyncRunFactoryProvider = /** @this */ function() {
6132 this.$get = ['$$rAF', function($$rAF) {
6133 var waitQueue = [];
6134
6135 function waitForTick(fn) {
6136 waitQueue.push(fn);
6137 if (waitQueue.length > 1) return;
6138 $$rAF(function() {
6139 for (var i = 0; i < waitQueue.length; i++) {
6140 waitQueue[i]();
6141 }
6142 waitQueue = [];
6143 });
6144 }
6145
6146 return function() {
6147 var passed = false;
6148 waitForTick(function() {
6149 passed = true;
6150 });
6151 return function(callback) {
6152 if (passed) {
6153 callback();
6154 } else {
6155 waitForTick(callback);
6156 }
6157 };
6158 };
6159 }];
6160};
6161
6162var $$AnimateRunnerFactoryProvider = /** @this */ function() {
6163 this.$get = ['$q', '$sniffer', '$$animateAsyncRun', '$$isDocumentHidden', '$timeout',

Callers

nothing calls this directly

Calls 2

waitForTickFunction · 0.70
callbackFunction · 0.70

Tested by

no test coverage detected