| 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 276 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
|  287  |  287  | 
|  288   WebRuntimeFeatures::enableFeatureFromString( |  288   WebRuntimeFeatures::enableFeatureFromString( | 
|  289       "FontCacheScaling", |  289       "FontCacheScaling", | 
|  290       base::FeatureList::IsEnabled(features::kFontCacheScaling)); |  290       base::FeatureList::IsEnabled(features::kFontCacheScaling)); | 
|  291  |  291  | 
|  292   WebRuntimeFeatures::enableFeatureFromString( |  292   WebRuntimeFeatures::enableFeatureFromString( | 
|  293       "FramebustingNeedsSameOriginOrUserGesture", |  293       "FramebustingNeedsSameOriginOrUserGesture", | 
|  294       base::FeatureList::IsEnabled( |  294       base::FeatureList::IsEnabled( | 
|  295           features::kFramebustingNeedsSameOriginOrUserGesture)); |  295           features::kFramebustingNeedsSameOriginOrUserGesture)); | 
|  296  |  296  | 
 |  297   WebRuntimeFeatures::enableFeatureFromString( | 
 |  298       "VibrateRequiresUserGesture", | 
 |  299       base::FeatureList::IsEnabled(features::kVibrateRequiresUserGesture)); | 
 |  300  | 
|  297   if (command_line.HasSwitch(switches::kDisableBackgroundTimerThrottling)) |  301   if (command_line.HasSwitch(switches::kDisableBackgroundTimerThrottling)) | 
|  298     WebRuntimeFeatures::enableTimerThrottlingForBackgroundTabs(false); |  302     WebRuntimeFeatures::enableTimerThrottlingForBackgroundTabs(false); | 
|  299  |  303  | 
|  300   WebRuntimeFeatures::enableExpensiveBackgroundTimerThrottling( |  304   WebRuntimeFeatures::enableExpensiveBackgroundTimerThrottling( | 
|  301       base::FeatureList::IsEnabled( |  305       base::FeatureList::IsEnabled( | 
|  302           features::kExpensiveBackgroundTimerThrottling)); |  306           features::kExpensiveBackgroundTimerThrottling)); | 
|  303  |  307  | 
|  304   if (base::FeatureList::IsEnabled(features::kHeapCompaction)) |  308   if (base::FeatureList::IsEnabled(features::kHeapCompaction)) | 
|  305     WebRuntimeFeatures::enableHeapCompaction(true); |  309     WebRuntimeFeatures::enableHeapCompaction(true); | 
|  306  |  310  | 
| (...skipping 76 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
|  383   if (command_line.HasSwitch(switches::kDisableBlinkFeatures)) { |  387   if (command_line.HasSwitch(switches::kDisableBlinkFeatures)) { | 
|  384     std::vector<std::string> disabled_features = base::SplitString( |  388     std::vector<std::string> disabled_features = base::SplitString( | 
|  385         command_line.GetSwitchValueASCII(switches::kDisableBlinkFeatures), |  389         command_line.GetSwitchValueASCII(switches::kDisableBlinkFeatures), | 
|  386         ",", base::TRIM_WHITESPACE, base::SPLIT_WANT_ALL); |  390         ",", base::TRIM_WHITESPACE, base::SPLIT_WANT_ALL); | 
|  387     for (const std::string& feature : disabled_features) |  391     for (const std::string& feature : disabled_features) | 
|  388       WebRuntimeFeatures::enableFeatureFromString(feature, false); |  392       WebRuntimeFeatures::enableFeatureFromString(feature, false); | 
|  389   } |  393   } | 
|  390 } |  394 } | 
|  391  |  395  | 
|  392 }  // namespace content |  396 }  // namespace content | 
| OLD | NEW |