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

Side by Side Diff: content/child/runtime_features.cc

Issue 2475983002: Add FeatureList plumbing for the LazyParseCSS experiment (Closed)
Patch Set: Created 4 years, 1 month 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 unified diff | Download patch
« no previous file with comments | « no previous file | content/public/common/content_features.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "content/child/runtime_features.h" 5 #include "content/child/runtime_features.h"
6 6
7 #include <vector> 7 #include <vector>
8 8
9 #include "base/command_line.h" 9 #include "base/command_line.h"
10 #include "base/feature_list.h" 10 #include "base/feature_list.h"
(...skipping 230 matching lines...) Expand 10 before | Expand all | Expand 10 after
241 WebRuntimeFeatures::enableSlimmingPaintV2(true); 241 WebRuntimeFeatures::enableSlimmingPaintV2(true);
242 242
243 if (base::FeatureList::IsEnabled( 243 if (base::FeatureList::IsEnabled(
244 features::kNonValidatingReloadOnNormalReload)) { 244 features::kNonValidatingReloadOnNormalReload)) {
245 WebRuntimeFeatures::enableReloadwithoutSubResourceCacheRevalidation(true); 245 WebRuntimeFeatures::enableReloadwithoutSubResourceCacheRevalidation(true);
246 } 246 }
247 247
248 if (base::FeatureList::IsEnabled(features::kDocumentWriteEvaluator)) 248 if (base::FeatureList::IsEnabled(features::kDocumentWriteEvaluator))
249 WebRuntimeFeatures::enableDocumentWriteEvaluator(true); 249 WebRuntimeFeatures::enableDocumentWriteEvaluator(true);
250 250
251 if (base::FeatureList::IsEnabled(features::kLazyParseCSS))
252 WebRuntimeFeatures::enableLazyParseCSS(true);
253
251 WebRuntimeFeatures::enableMediaDocumentDownloadButton( 254 WebRuntimeFeatures::enableMediaDocumentDownloadButton(
252 base::FeatureList::IsEnabled(features::kMediaDocumentDownloadButton)); 255 base::FeatureList::IsEnabled(features::kMediaDocumentDownloadButton));
253 256
254 WebRuntimeFeatures::enablePointerEvent( 257 WebRuntimeFeatures::enablePointerEvent(
255 base::FeatureList::IsEnabled(features::kPointerEvents)); 258 base::FeatureList::IsEnabled(features::kPointerEvents));
256 259
257 if (base::FeatureList::IsEnabled(features::kPointerEventV1SpecCapturing)) 260 if (base::FeatureList::IsEnabled(features::kPointerEventV1SpecCapturing))
258 WebRuntimeFeatures::enablePointerEventV1SpecCapturing(true); 261 WebRuntimeFeatures::enablePointerEventV1SpecCapturing(true);
259 262
260 if (base::FeatureList::IsEnabled(features::kPassiveDocumentEventListeners)) 263 if (base::FeatureList::IsEnabled(features::kPassiveDocumentEventListeners))
(...skipping 64 matching lines...) Expand 10 before | Expand all | Expand 10 after
325 if (command_line.HasSwitch(switches::kDisableBlinkFeatures)) { 328 if (command_line.HasSwitch(switches::kDisableBlinkFeatures)) {
326 std::vector<std::string> disabled_features = base::SplitString( 329 std::vector<std::string> disabled_features = base::SplitString(
327 command_line.GetSwitchValueASCII(switches::kDisableBlinkFeatures), 330 command_line.GetSwitchValueASCII(switches::kDisableBlinkFeatures),
328 ",", base::TRIM_WHITESPACE, base::SPLIT_WANT_ALL); 331 ",", base::TRIM_WHITESPACE, base::SPLIT_WANT_ALL);
329 for (const std::string& feature : disabled_features) 332 for (const std::string& feature : disabled_features)
330 WebRuntimeFeatures::enableFeatureFromString(feature, false); 333 WebRuntimeFeatures::enableFeatureFromString(feature, false);
331 } 334 }
332 } 335 }
333 336
334 } // namespace content 337 } // namespace content
OLDNEW
« no previous file with comments | « no previous file | content/public/common/content_features.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698