OLD | NEW |
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 214 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
225 WebRuntimeFeatures::enableScrollAnchoring(true); | 225 WebRuntimeFeatures::enableScrollAnchoring(true); |
226 | 226 |
227 if (command_line.HasSwitch(switches::kEnableSlimmingPaintV2)) | 227 if (command_line.HasSwitch(switches::kEnableSlimmingPaintV2)) |
228 WebRuntimeFeatures::enableSlimmingPaintV2(true); | 228 WebRuntimeFeatures::enableSlimmingPaintV2(true); |
229 | 229 |
230 // Note that it might already by true for OS_ANDROID, above. This is for | 230 // Note that it might already by true for OS_ANDROID, above. This is for |
231 // non-android versions. | 231 // non-android versions. |
232 if (base::FeatureList::IsEnabled(features::kNewMediaPlaybackUi)) | 232 if (base::FeatureList::IsEnabled(features::kNewMediaPlaybackUi)) |
233 WebRuntimeFeatures::enableNewMediaPlaybackUi(true); | 233 WebRuntimeFeatures::enableNewMediaPlaybackUi(true); |
234 | 234 |
| 235 if (base::FeatureList::IsEnabled( |
| 236 features::kNonValidatingReloadOnNormalReload)) { |
| 237 WebRuntimeFeatures::enableNonValidatingReload(true); |
| 238 } |
| 239 |
235 if (base::FeatureList::IsEnabled(features::kDocumentWriteEvaluator)) | 240 if (base::FeatureList::IsEnabled(features::kDocumentWriteEvaluator)) |
236 WebRuntimeFeatures::enableDocumentWriteEvaluator(true); | 241 WebRuntimeFeatures::enableDocumentWriteEvaluator(true); |
237 | 242 |
238 WebRuntimeFeatures::enableMediaDocumentDownloadButton( | 243 WebRuntimeFeatures::enableMediaDocumentDownloadButton( |
239 base::FeatureList::IsEnabled(features::kMediaDocumentDownloadButton)); | 244 base::FeatureList::IsEnabled(features::kMediaDocumentDownloadButton)); |
240 | 245 |
241 if (base::FeatureList::IsEnabled(features::kPointerEvents)) | 246 if (base::FeatureList::IsEnabled(features::kPointerEvents)) |
242 WebRuntimeFeatures::enablePointerEvent(true); | 247 WebRuntimeFeatures::enablePointerEvent(true); |
243 | 248 |
244 if (base::FeatureList::IsEnabled(features::kPassiveDocumentEventListeners)) | 249 if (base::FeatureList::IsEnabled(features::kPassiveDocumentEventListeners)) |
(...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
287 if (command_line.HasSwitch(switches::kDisableBlinkFeatures)) { | 292 if (command_line.HasSwitch(switches::kDisableBlinkFeatures)) { |
288 std::vector<std::string> disabled_features = base::SplitString( | 293 std::vector<std::string> disabled_features = base::SplitString( |
289 command_line.GetSwitchValueASCII(switches::kDisableBlinkFeatures), | 294 command_line.GetSwitchValueASCII(switches::kDisableBlinkFeatures), |
290 ",", base::TRIM_WHITESPACE, base::SPLIT_WANT_ALL); | 295 ",", base::TRIM_WHITESPACE, base::SPLIT_WANT_ALL); |
291 for (const std::string& feature : disabled_features) | 296 for (const std::string& feature : disabled_features) |
292 WebRuntimeFeatures::enableFeatureFromString(feature, false); | 297 WebRuntimeFeatures::enableFeatureFromString(feature, false); |
293 } | 298 } |
294 } | 299 } |
295 | 300 |
296 } // namespace content | 301 } // namespace content |
OLD | NEW |