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

Unified Diff: third_party/WebKit/Source/core/page/NetworkStateNotifier.h

Issue 1381613003: Defer media loading while on cellular networks. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase. Created 5 years, 2 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: third_party/WebKit/Source/core/page/NetworkStateNotifier.h
diff --git a/third_party/WebKit/Source/core/page/NetworkStateNotifier.h b/third_party/WebKit/Source/core/page/NetworkStateNotifier.h
index 1e0b7b12c70db50d29ff7d6b9d3c25ff24b337cf..16aac60bdbebc73dc15cca4f51033bd297944636 100644
--- a/third_party/WebKit/Source/core/page/NetworkStateNotifier.h
+++ b/third_party/WebKit/Source/core/page/NetworkStateNotifier.h
@@ -90,6 +90,10 @@ public:
// When true, setWebConnectionType calls are ignored and only setWebConnectionTypeForTest
// can update the connection type. This is used for layout tests (see crbug.com/377736).
+ //
+ // Since this class is a singleton, tests must call this with false when completed to
+ // avoid indeterminate state across the test harness. When switching in or out of test
+ // mode, all state will be reset to default values.
void setTestUpdatesOnly(bool);
// Tests should call this as it will change the type regardless of the value of m_testUpdatesOnly.
void setWebConnectionForTest(WebConnectionType, double maxBandwidthMbps);
« no previous file with comments | « third_party/WebKit/Source/core/html/HTMLMediaElement.cpp ('k') | third_party/WebKit/Source/core/page/NetworkStateNotifier.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698