Index: content/common/content_switches_internal.cc |
diff --git a/content/common/content_switches_internal.cc b/content/common/content_switches_internal.cc |
index eeb18a7603b40c6987a33bbfe248b5fe2591a163..a2a6674fd7c75bd639d928ea5cfca2c6518ac47c 100644 |
--- a/content/common/content_switches_internal.cc |
+++ b/content/common/content_switches_internal.cc |
@@ -36,6 +36,12 @@ bool IsUseZoomForDSFEnabledByDefault() { |
#endif |
} |
+#if defined(ANDROID) |
+const base::Feature kProgressBarCompletionResourcesBeforeDOMContentLoaded{ |
Charlie Reis
2016/10/21 22:07:20
nit: Is there room for a space before the brace, a
Nate Chapin
2016/10/21 22:09:22
Yep, will fix before landing.
|
+ "progress-bar-completion-resources-before-domContentLoaded", |
+ base::FEATURE_DISABLED_BY_DEFAULT}; |
+#endif |
+ |
} // namespace |
bool IsPinchToZoomEnabled() { |
@@ -106,6 +112,12 @@ ProgressBarCompletion GetProgressBarCompletionPolicy() { |
"resourcesBeforeDOMContentLoadedAndSameOriginIframes") { |
return ProgressBarCompletion::RESOURCES_BEFORE_DCL_AND_SAME_ORIGIN_IFRAMES; |
} |
+ // The command line, which is set by the user, takes priority. Otherwise, |
+ // fall back to the feature flag. |
+ if (base::FeatureList::IsEnabled( |
+ kProgressBarCompletionResourcesBeforeDOMContentLoaded)) { |
+ return ProgressBarCompletion::RESOURCES_BEFORE_DCL; |
+ } |
#endif |
return ProgressBarCompletion::LOAD_EVENT; |
} |