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

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: fix testcase 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
« no previous file with comments | « no previous file | Source/devtools/devtools.gypi » ('j') | Source/devtools/front_end/common/Throttler.js » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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..4dc8d194140b647866bd78bacbd85e243a1ef745 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 = window.setTimeout;
+ window.setTimeout = innerSetTimeout;
InspectorTest.addSniffer(WebInspector.CSSStyleModel.prototype, "_fireStyleSheetChanged", onStyleSheetChanged);
function onStyleSheetChanged()
{
- WebInspector.StyleFile.updateTimeout = oldUpdateTimeout;
+ window.setTimeout = originalSetTimeout;
reply();
}
+
+ function innerSetTimeout(operation, timeout)
+ {
+ originalSetTimeout.call(window, operation, 0);
+ }
}
}
« no previous file with comments | « no previous file | Source/devtools/devtools.gypi » ('j') | Source/devtools/front_end/common/Throttler.js » ('J')

Powered by Google App Engine
This is Rietveld 408576698