| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 "chromeos/chromeos_switches.h" | 5 #include "chromeos/chromeos_switches.h" |
| 6 | 6 |
| 7 #include "base/command_line.h" | 7 #include "base/command_line.h" |
| 8 #include "base/metrics/field_trial.h" | 8 #include "base/metrics/field_trial.h" |
| 9 | 9 |
| 10 // TODO(rsorokin): alphabetize all of these switches so they | 10 // TODO(rsorokin): alphabetize all of these switches so they |
| (...skipping 314 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 325 const char kEnableCaptivePortalBypassProxyOption[] = | 325 const char kEnableCaptivePortalBypassProxyOption[] = |
| 326 "enable-captive-portal-bypass-proxy-option"; | 326 "enable-captive-portal-bypass-proxy-option"; |
| 327 | 327 |
| 328 // Disable automatic timezone update. | 328 // Disable automatic timezone update. |
| 329 const char kDisableTimeZoneTrackingOption[] = | 329 const char kDisableTimeZoneTrackingOption[] = |
| 330 "disable-timezone-tracking-option"; | 330 "disable-timezone-tracking-option"; |
| 331 | 331 |
| 332 // Disable new GAIA sign-in flow. | 332 // Disable new GAIA sign-in flow. |
| 333 const char kDisableWebviewSigninFlow[] = "disable-webview-signin-flow"; | 333 const char kDisableWebviewSigninFlow[] = "disable-webview-signin-flow"; |
| 334 | 334 |
| 335 // Enable Chrome OS firewall hole-punching for Chrome Apps. |
| 336 const char kEnableFirewallHolePunching[] = "enable-firewall-hole-punching"; |
| 337 |
| 335 bool WakeOnWifiEnabled() { | 338 bool WakeOnWifiEnabled() { |
| 336 return !base::CommandLine::ForCurrentProcess()->HasSwitch(kDisableWakeOnWifi); | 339 return !base::CommandLine::ForCurrentProcess()->HasSwitch(kDisableWakeOnWifi); |
| 337 } | 340 } |
| 338 | 341 |
| 339 bool MemoryPressureHandlingEnabled() { | 342 bool MemoryPressureHandlingEnabled() { |
| 340 if ((base::CommandLine::ForCurrentProcess()->HasSwitch( | 343 if ((base::CommandLine::ForCurrentProcess()->HasSwitch( |
| 341 chromeos::switches::kDisableMemoryPressureSystemChromeOS)) || | 344 chromeos::switches::kDisableMemoryPressureSystemChromeOS)) || |
| 342 (base::FieldTrialList::FindFullName(kMemoryPressureExperimentName) == | 345 (base::FieldTrialList::FindFullName(kMemoryPressureExperimentName) == |
| 343 kMemoryPressureHandlingOff)) | 346 kMemoryPressureHandlingOff)) |
| 344 return false; | 347 return false; |
| (...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 376 return base::MemoryPressureObserverChromeOS:: | 379 return base::MemoryPressureObserverChromeOS:: |
| 377 THRESHOLD_AGGRESSIVE_TAB_DISCARD; | 380 THRESHOLD_AGGRESSIVE_TAB_DISCARD; |
| 378 if (option == kAggressiveThreshold) | 381 if (option == kAggressiveThreshold) |
| 379 return base::MemoryPressureObserverChromeOS::THRESHOLD_AGGRESSIVE; | 382 return base::MemoryPressureObserverChromeOS::THRESHOLD_AGGRESSIVE; |
| 380 | 383 |
| 381 return base::MemoryPressureObserverChromeOS::THRESHOLD_DEFAULT; | 384 return base::MemoryPressureObserverChromeOS::THRESHOLD_DEFAULT; |
| 382 } | 385 } |
| 383 | 386 |
| 384 } // namespace switches | 387 } // namespace switches |
| 385 } // namespace chromeos | 388 } // namespace chromeos |
| OLD | NEW |