Index: LayoutTests/http/tests/inspector/inspector-test.js |
diff --git a/LayoutTests/http/tests/inspector/inspector-test.js b/LayoutTests/http/tests/inspector/inspector-test.js |
index dfa60dfc460bbc53244b852f4eb1534e80a0745a..dedbb144ecef5c39e1887c019e54ba5933e7f570 100644 |
--- a/LayoutTests/http/tests/inspector/inspector-test.js |
+++ b/LayoutTests/http/tests/inspector/inspector-test.js |
@@ -445,7 +445,7 @@ InspectorTest.TempFileMock = function(dirPath, name, callback) |
{ |
this._chunks = []; |
this._name = name; |
- setTimeout(callback.bind(this, this), 0); |
+ requestAnimationFrame(callback.bind(this, this)); |
} |
InspectorTest.TempFileMock.prototype = { |
@@ -456,7 +456,7 @@ InspectorTest.TempFileMock.prototype = { |
write: function(strings, callback) |
{ |
this._chunks.push.apply(this._chunks, strings); |
- setTimeout(callback.bind(this, true), 0); |
+ requestAnimationFrame(callback.bind(this, true)); |
}, |
finishWriting: function() { }, |
@@ -600,17 +600,17 @@ function closeFrontend(callback) |
{ |
// Do this asynchronously to allow InspectorBackendDispatcher to send response |
// back to the frontend before it's destroyed. |
- setTimeout(function() { |
+ requestAnimationFrame(function() { |
testRunner.closeWebInspector(); |
callback(); |
- }, 0); |
+ }); |
} |
function openFrontendAndIncrement() |
{ |
frontendReopeningCount++; |
testRunner.showWebInspector(); |
- setTimeout(runTest, 0); |
+ requestAnimationFrame(runTest); |
} |
function runAfterIframeIsLoaded() |
@@ -763,9 +763,9 @@ function closeInspectorAndNotifyDone() |
clearTimeout(window._watchDogTimer); |
testRunner.closeWebInspector(); |
- setTimeout(function() { |
+ requestAnimationFrame(function() { |
testRunner.notifyDone(); |
- }, 0); |
+ }); |
} |
var outputElement; |