Wrapper script for isolating telemetry_gpu_unittests.
[chromium-blink-merge.git] / ui / views / views_switches.cc
blob41d2ce5089c7935ca49828830a915215e4e29d20
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
3 // found in the LICENSE file.
5 #include "ui/views/views_switches.h"
7 #include "base/command_line.h"
9 namespace views {
10 namespace switches {
12 // Please keep alphabetized.
14 // Specifies if a heuristic should be used to determine the most probable
15 // target of a gesture, where the touch region is represented by a rectangle.
16 const char kDisableViewsRectBasedTargeting[] =
17 "disable-views-rect-based-targeting";
19 #if defined(USE_X11) && !defined(OS_CHROMEOS)
20 // When enabled, tries to get a transparent X11 visual so that we can have
21 // per-pixel alpha in windows.
23 // TODO(erg): Remove this switch once we've stabilized the code
24 // path. http://crbug.com/369209
25 const char kEnableTransparentVisuals[] = "enable-transparent-visuals";
26 #endif
28 bool IsRectBasedTargetingEnabled() {
29 #if defined(OS_CHROMEOS) || defined(OS_WIN) || defined(OS_LINUX)
30 return !base::CommandLine::ForCurrentProcess()->HasSwitch(
31 kDisableViewsRectBasedTargeting);
32 #else
33 return false;
34 #endif
37 } // namespace switches
38 } // namespace views