[email protected] | 7dfb6960 | 2012-02-17 00:29:01 | [diff] [blame] | 1 | // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
[email protected] | 3d2c6fb | 2011-07-06 22:26:45 | [diff] [blame] | 2 | // Use of this source code is governed by a BSD-style license that can be |
3 | // found in the LICENSE file. | ||||
[email protected] | 42ce29d | 2011-01-20 23:19:46 | [diff] [blame] | 4 | |
5 | #include "ui/base/ui_base_switches.h" | ||||
6 | |||||
7 | namespace switches { | ||||
8 | |||||
[email protected] | 1995d80d | 2012-08-23 02:58:47 | [diff] [blame^] | 9 | // Disable support for bezel touch. |
10 | const char kDisableBezelTouch[] = "disable-bezel-touch"; | ||||
11 | |||||
[email protected] | 831d9ba | 2012-07-10 22:53:09 | [diff] [blame] | 12 | // Whether or not ImageSkiaOperations methods can scale one of images |
13 | // if they don't have the same scale factor. | ||||
14 | const char kDisableScalingInImageSkiaOperations[] = | ||||
15 | "disable-scaling-in-image-skia-operations"; | ||||
16 | |||||
[email protected] | f463cd4 | 2012-05-09 16:05:15 | [diff] [blame] | 17 | // Let text glyphs have X-positions that aren't snapped to the pixel grid. |
18 | const char kEnableTextSubpixelPositioning[] = | ||||
19 | "enable-text-subpixel-positioning"; | ||||
[email protected] | 8b3b3615 | 2012-05-01 04:55:07 | [diff] [blame] | 20 | |
[email protected] | 74a02d7 | 2012-05-14 21:19:24 | [diff] [blame] | 21 | // Enable touch screen calibration. |
22 | const char kEnableTouchCalibration[] = "enable-touch-calibration"; | ||||
23 | |||||
[email protected] | 8a6aaa7 | 2012-04-20 20:53:58 | [diff] [blame] | 24 | // Enable support for touch events. |
[email protected] | f463cd4 | 2012-05-09 16:05:15 | [diff] [blame] | 25 | const char kEnableTouchEvents[] = "enable-touch-events"; |
[email protected] | 8a6aaa7 | 2012-04-20 20:53:58 | [diff] [blame] | 26 | |
[email protected] | fc7a93c | 2012-06-08 20:25:39 | [diff] [blame] | 27 | // Enables the Views textfield on Windows. |
28 | const char kEnableViewsTextfield[] = "enable-views-textfield"; | ||||
29 | |||||
[email protected] | 4bd2020 | 2012-06-14 17:35:01 | [diff] [blame] | 30 | // Overrides the device scale factor for the browser UI and the |
31 | // contents. | ||||
32 | const char kForceDeviceScaleFactor[] = "force-device-scale-factor"; | ||||
33 | |||||
[email protected] | e5c641c | 2012-06-08 17:24:51 | [diff] [blame] | 34 | // Generates a 2x version of resources for which no 2x version is available or |
35 | // the 2x version is of an incorrect size and applies a red mask to the | ||||
36 | // resource. Resources for which hidpi is not supported because of software | ||||
37 | // reasons will show up pixelated. | ||||
38 | const char kHighlightMissing2xResources[] = | ||||
39 | "highlight-missing-2x-resources"; | ||||
40 | |||||
[email protected] | 3455af4e | 2012-03-12 15:35:12 | [diff] [blame] | 41 | // The language file that we want to try to open. Of the form |
[email protected] | 42ce29d | 2011-01-20 23:19:46 | [diff] [blame] | 42 | // language[-country] where language is the 2 letter code from ISO-639. |
[email protected] | f463cd4 | 2012-05-09 16:05:15 | [diff] [blame] | 43 | const char kLang[] = "lang"; |
[email protected] | 42ce29d | 2011-01-20 23:19:46 | [diff] [blame] | 44 | |
[email protected] | 3d2c6fb | 2011-07-06 22:26:45 | [diff] [blame] | 45 | // Load the locale resources from the given path. When running on Mac/Unix the |
46 | // path should point to a locale.pak file. | ||||
[email protected] | f463cd4 | 2012-05-09 16:05:15 | [diff] [blame] | 47 | const char kLocalePak[] = "locale_pak"; |
[email protected] | 3d2c6fb | 2011-07-06 22:26:45 | [diff] [blame] | 48 | |
[email protected] | ef41b7ee | 2012-07-24 19:10:41 | [diff] [blame] | 49 | // Disables the new appearance for checkboxes and radio buttons. |
50 | const char kOldCheckboxStyle[] = "old-checkbox-style"; | ||||
[email protected] | bd0cd3bb | 2012-06-14 03:03:38 | [diff] [blame] | 51 | |
[email protected] | 3455af4e | 2012-03-12 15:35:12 | [diff] [blame] | 52 | // Disable ui::MessageBox. This is useful when running as part of scripts that |
53 | // do not have a user interface. | ||||
[email protected] | f463cd4 | 2012-05-09 16:05:15 | [diff] [blame] | 54 | const char kNoMessageBox[] = "no-message-box"; |
[email protected] | 3455af4e | 2012-03-12 15:35:12 | [diff] [blame] | 55 | |
[email protected] | 7dfb6960 | 2012-02-17 00:29:01 | [diff] [blame] | 56 | // Enables UI changes that make it easier to use with a touchscreen. |
[email protected] | 347a0c7 | 2012-05-14 20:28:06 | [diff] [blame] | 57 | // WARNING: Do not check this flag directly when deciding what UI to draw, |
58 | // instead you must call ui::GetDisplayLayout | ||||
59 | const char kTouchOptimizedUI[] = "touch-optimized-ui"; | ||||
[email protected] | 7dfb6960 | 2012-02-17 00:29:01 | [diff] [blame] | 60 | |
[email protected] | 347a0c7 | 2012-05-14 20:28:06 | [diff] [blame] | 61 | // The values the kTouchOptimizedUI switch may have, as in |
62 | // "--touch-optimized-ui=disabled". | ||||
63 | // auto: Enabled on monitors which have touchscreen support (default). | ||||
64 | const char kTouchOptimizedUIAuto[] = "auto"; | ||||
65 | // enabled: always optimized for touch (even if no touch support). | ||||
66 | const char kTouchOptimizedUIEnabled[] = "enabled"; | ||||
67 | // disabled: never optimized for touch. | ||||
68 | const char kTouchOptimizedUIDisabled[] = "disabled"; | ||||
[email protected] | 9b75ac5 | 2012-05-07 22:44:58 | [diff] [blame] | 69 | |
[email protected] | dc51d1c | 2011-11-30 04:42:21 | [diff] [blame] | 70 | #if defined(OS_MACOSX) |
71 | const char kDisableCompositedCoreAnimationPlugins[] = | ||||
72 | "disable-composited-core-animation-plugins"; | ||||
[email protected] | 89ac531b | 2012-06-28 05:35:16 | [diff] [blame] | 73 | // Disables using core animation in plugins. This is triggered when accelerated |
74 | // compositing is disabled. See http://crbug.com/122430 | ||||
75 | const char kDisableCoreAnimationPlugins[] = | ||||
76 | "disable-core-animation-plugins"; | ||||
[email protected] | dc51d1c | 2011-11-30 04:42:21 | [diff] [blame] | 77 | #endif |
78 | |||||
[email protected] | bcb93db | 2012-05-25 20:03:04 | [diff] [blame] | 79 | #if defined(TOOLKIT_VIEWS) && defined(OS_LINUX) |
80 | // Tells chrome to interpret events from these devices as touch events. Only | ||||
81 | // available with XInput 2 (i.e. X server 1.8 or above). The id's of the | ||||
82 | // devices can be retrieved from 'xinput list'. | ||||
83 | const char kTouchDevices[] = "touch-devices"; | ||||
84 | #endif | ||||
85 | |||||
[email protected] | 42ce29d | 2011-01-20 23:19:46 | [diff] [blame] | 86 | } // namespace switches |