Browse Source

* fixes setImmediate

setimmediate
Lebedev Konstantin 9 years ago
parent
commit
7b8af01c1e
  1. 6
      Sortable.js

6
Sortable.js

@ -1249,7 +1249,10 @@
var postMessageIsAsynchronous = true; var postMessageIsAsynchronous = true;
var oldOnMessage = win.onmessage; var oldOnMessage = win.onmessage;
win.onmessage = function () { postMessageIsAsynchronous = false; }; win.onmessage = function () {
postMessageIsAsynchronous = false;
};
win.postMessage('', '*'); win.postMessage('', '*');
win.onmessage = oldOnMessage; win.onmessage = oldOnMessage;
@ -1273,7 +1276,6 @@
setImmediate = function (callback) { setImmediate = function (callback) {
postMessageQueue.push(callback); postMessageQueue.push(callback);
win.postMessage(postMessageEventName, '*'); win.postMessage(postMessageEventName, '*');
return handle;
}; };
} }
} }

Loading…
Cancel
Save