Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(129)

Unified Diff: LayoutTests/inspector/extensions/extensions-resources.html

Issue 319143002: DevTools: introduce WebInspector.Throttler (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: address @vsevik & @aandrey comments Created 6 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: LayoutTests/inspector/extensions/extensions-resources.html
diff --git a/LayoutTests/inspector/extensions/extensions-resources.html b/LayoutTests/inspector/extensions/extensions-resources.html
index ab1cb30328e48d18ed6b6c0d467391acf6878efa..5b37a90089462932163511259fe22e8a78e76a8a 100644
--- a/LayoutTests/inspector/extensions/extensions-resources.html
+++ b/LayoutTests/inspector/extensions/extensions-resources.html
@@ -27,15 +27,20 @@ InspectorTest.clickOnURL = function()
InspectorTest.waitForStyleSheetChangedEvent = function(reply)
{
- var oldUpdateTimeout = WebInspector.StyleFile.updateTimeout;
- WebInspector.StyleFile.updateTimeout = 0;
+ var originalSetTimeout = WebInspector.Throttler.prototype._setTimeout;
+ WebInspector.Throttler.prototype._setTimeout = innerSetTimeout;
InspectorTest.addSniffer(WebInspector.CSSStyleModel.prototype, "_fireStyleSheetChanged", onStyleSheetChanged);
function onStyleSheetChanged()
{
- WebInspector.StyleFile.updateTimeout = oldUpdateTimeout;
+ WebInspector.Throttler.prototype._setTimeout = originalSetTimeout;
reply();
}
+
+ function innerSetTimeout(operation, timeout)
+ {
+ return originalSetTimeout.call(this, operation, 0);
+ }
}
}

Powered by Google App Engine
This is Rietveld 408576698