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 "ui/views/corewm/corewm_switches.h" | 5 #include "ui/views/corewm/corewm_switches.h" |
6 | 6 |
7 #include "base/command_line.h" | 7 #include "base/command_line.h" |
8 | 8 |
9 namespace views { | 9 namespace views { |
10 namespace corewm { | 10 namespace corewm { |
11 namespace switches { | 11 namespace switches { |
12 | 12 |
13 // When set uses the old ActivationController/FocusManager instead of the new | 13 // When set uses the old ActivationController/FocusManager instead of the new |
14 // CoreWM FocusController. | 14 // CoreWM FocusController. |
15 const char kDisableFocusController[] = "disable-focus-controller"; | 15 const char kDisableFocusController[] = "disable-focus-controller"; |
16 | 16 |
| 17 // When set uses the FocusController in desktop mode. |
| 18 const char kEnableFocusControllerOnDesktop[] = |
| 19 "enable-focus-controller-on-desktop"; |
| 20 |
17 // If present animations are disabled. | 21 // If present animations are disabled. |
18 const char kWindowAnimationsDisabled[] = | 22 const char kWindowAnimationsDisabled[] = |
19 "views-corewm-window-animations-disabled"; | 23 "views-corewm-window-animations-disabled"; |
20 | 24 |
21 } // namespace switches | 25 } // namespace switches |
22 | 26 |
23 bool UseFocusController() { | 27 bool UseFocusController() { |
24 return !CommandLine::ForCurrentProcess()->HasSwitch( | 28 return !CommandLine::ForCurrentProcess()->HasSwitch( |
25 switches::kDisableFocusController); | 29 switches::kDisableFocusController); |
26 } | 30 } |
27 | 31 |
| 32 bool UseFocusControllerOnDesktop() { |
| 33 return CommandLine::ForCurrentProcess()->HasSwitch( |
| 34 switches::kEnableFocusControllerOnDesktop); |
| 35 } |
| 36 |
28 } // namespace corewm | 37 } // namespace corewm |
29 } // namespace views | 38 } // namespace views |
OLD | NEW |