| 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 "ash/ash_switches.h" | 5 #include "ash/ash_switches.h" |
| 6 | 6 |
| 7 #include "base/command_line.h" | 7 #include "base/command_line.h" |
| 8 | 8 |
| 9 namespace ash { | 9 namespace ash { |
| 10 namespace switches { | 10 namespace switches { |
| (...skipping 50 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 61 // Disable ability to dock windows at the desktop edge. | 61 // Disable ability to dock windows at the desktop edge. |
| 62 const char kAshDisableDockedWindows[] = "ash-disable-docked-windows"; | 62 const char kAshDisableDockedWindows[] = "ash-disable-docked-windows"; |
| 63 | 63 |
| 64 // Disallow items to be dragged from the app launcher list into the launcher. | 64 // Disallow items to be dragged from the app launcher list into the launcher. |
| 65 const char kAshDisableDragAndDropAppListToLauncher[] = | 65 const char kAshDisableDragAndDropAppListToLauncher[] = |
| 66 "ash-disable-drag-and-drop-applist-to-launcher"; | 66 "ash-disable-drag-and-drop-applist-to-launcher"; |
| 67 | 67 |
| 68 // Disable dragging items off the shelf to unpin them. | 68 // Disable dragging items off the shelf to unpin them. |
| 69 const char kAshDisableDragOffShelf[] = "ash-disable-drag-off-shelf"; | 69 const char kAshDisableDragOffShelf[] = "ash-disable-drag-off-shelf"; |
| 70 | 70 |
| 71 // Disables overview mode for window switching. | |
| 72 const char kAshDisableOverviewMode[] = "ash-disable-overview-mode"; | |
| 73 | |
| 74 #if defined(OS_CHROMEOS) | 71 #if defined(OS_CHROMEOS) |
| 75 // Disable the notification when a low-power USB charger is connected. | 72 // Disable the notification when a low-power USB charger is connected. |
| 76 const char kAshDisableUsbChargerNotification[] = | 73 const char kAshDisableUsbChargerNotification[] = |
| 77 "ash-disable-usb-charger-notification"; | 74 "ash-disable-usb-charger-notification"; |
| 78 | 75 |
| 79 // TODO(jamescook): Remove this unused flag. It exists only to allow the | 76 // TODO(jamescook): Remove this unused flag. It exists only to allow the |
| 80 // "Enable audio device menu" about:flags item to have the tri-state | 77 // "Enable audio device menu" about:flags item to have the tri-state |
| 81 // default/enabled/disabled UI. | 78 // default/enabled/disabled UI. |
| 82 const char kAshEnableAudioDeviceMenu[] = "ash-enable-audio-device-menu"; | 79 const char kAshEnableAudioDeviceMenu[] = "ash-enable-audio-device-menu"; |
| 83 #endif // defined(OS_CHROMEOS) | 80 #endif // defined(OS_CHROMEOS) |
| (...skipping 122 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 206 bool UseMultiUserTray() { | 203 bool UseMultiUserTray() { |
| 207 #if defined(OS_CHROMEOS) | 204 #if defined(OS_CHROMEOS) |
| 208 // TODO(skuhne): If this gets removed for good, remove also | 205 // TODO(skuhne): If this gets removed for good, remove also |
| 209 // |SystemTray::user_items_| and the use of it. | 206 // |SystemTray::user_items_| and the use of it. |
| 210 return CommandLine::ForCurrentProcess()->HasSwitch(kAshEnableMultiUserTray); | 207 return CommandLine::ForCurrentProcess()->HasSwitch(kAshEnableMultiUserTray); |
| 211 #else | 208 #else |
| 212 return false; | 209 return false; |
| 213 #endif | 210 #endif |
| 214 } | 211 } |
| 215 | 212 |
| 216 bool UseOverviewMode() { | |
| 217 return !CommandLine::ForCurrentProcess()->HasSwitch(kAshDisableOverviewMode); | |
| 218 } | |
| 219 | |
| 220 bool UseDockedWindows() { | 213 bool UseDockedWindows() { |
| 221 return !CommandLine::ForCurrentProcess()->HasSwitch(kAshDisableDockedWindows); | 214 return !CommandLine::ForCurrentProcess()->HasSwitch(kAshDisableDockedWindows); |
| 222 } | 215 } |
| 223 | 216 |
| 224 bool ShowAudioDeviceMenu() { | 217 bool ShowAudioDeviceMenu() { |
| 225 #if defined(OS_CHROMEOS) | 218 #if defined(OS_CHROMEOS) |
| 226 return !CommandLine::ForCurrentProcess()-> | 219 return !CommandLine::ForCurrentProcess()-> |
| 227 HasSwitch(kAshDisableAudioDeviceMenu); | 220 HasSwitch(kAshDisableAudioDeviceMenu); |
| 228 #else | 221 #else |
| 229 return false; | 222 return false; |
| 230 #endif | 223 #endif |
| 231 } | 224 } |
| 232 | 225 |
| 233 #if defined(OS_CHROMEOS) | 226 #if defined(OS_CHROMEOS) |
| 234 bool UseUsbChargerNotification() { | 227 bool UseUsbChargerNotification() { |
| 235 return !CommandLine::ForCurrentProcess()-> | 228 return !CommandLine::ForCurrentProcess()-> |
| 236 HasSwitch(kAshDisableUsbChargerNotification); | 229 HasSwitch(kAshDisableUsbChargerNotification); |
| 237 } | 230 } |
| 238 #endif | 231 #endif |
| 239 | 232 |
| 240 } // namespace switches | 233 } // namespace switches |
| 241 } // namespace ash | 234 } // namespace ash |
| OLD | NEW |