OLD | NEW |
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 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 "ui/base/ui_base_switches_util.h" | 5 #include "ui/base/ui_base_switches_util.h" |
6 | 6 |
7 #include "base/command_line.h" | 7 #include "base/command_line.h" |
8 #include "build/build_config.h" | 8 #include "build/build_config.h" |
9 #include "ui/base/ui_base_switches.h" | 9 #include "ui/base/ui_base_switches.h" |
10 | 10 |
11 namespace switches { | 11 namespace switches { |
12 | 12 |
13 bool IsTouchDragDropEnabled() { | 13 bool IsTouchDragDropEnabled() { |
14 #if defined(OS_CHROMEOS) | 14 #if defined(OS_CHROMEOS) || defined(OS_ANDROID) |
15 return !base::CommandLine::ForCurrentProcess()->HasSwitch( | 15 return !base::CommandLine::ForCurrentProcess()->HasSwitch( |
16 switches::kDisableTouchDragDrop); | 16 switches::kDisableTouchDragDrop); |
17 #else | 17 #else |
18 return base::CommandLine::ForCurrentProcess()->HasSwitch( | 18 return base::CommandLine::ForCurrentProcess()->HasSwitch( |
19 switches::kEnableTouchDragDrop); | 19 switches::kEnableTouchDragDrop); |
20 #endif | 20 #endif |
21 } | 21 } |
22 | 22 |
23 bool IsTouchFeedbackEnabled() { | 23 bool IsTouchFeedbackEnabled() { |
24 static bool touch_feedback_enabled = | 24 static bool touch_feedback_enabled = |
25 !base::CommandLine::ForCurrentProcess()->HasSwitch( | 25 !base::CommandLine::ForCurrentProcess()->HasSwitch( |
26 switches::kDisableTouchFeedback); | 26 switches::kDisableTouchFeedback); |
27 return touch_feedback_enabled; | 27 return touch_feedback_enabled; |
28 } | 28 } |
29 | 29 |
30 } // namespace switches | 30 } // namespace switches |
OLD | NEW |