Commit ecb5ce9e authored by rsadam's avatar rsadam Committed by Commit bot

Merge gesture deletion and selection.

BUG=

Review URL: https://codereview.chromium.org/1130833005

Cr-Commit-Position: refs/heads/master@{#329416}
parent b3557d52
...@@ -14506,17 +14506,11 @@ After you create a new supervised user, you can manage their settings at any tim ...@@ -14506,17 +14506,11 @@ After you create a new supervised user, you can manage their settings at any tim
<message name="IDS_FLAGS_GESTURE_TYPING_DESCRIPTION" desc="Description of about::flags option to toggle gesture typing for the virtual keyboard"> <message name="IDS_FLAGS_GESTURE_TYPING_DESCRIPTION" desc="Description of about::flags option to toggle gesture typing for the virtual keyboard">
Enable/Disable gesture typing for the virtual keyboard. Enable/Disable gesture typing for the virtual keyboard.
</message> </message>
<message name="IDS_FLAGS_GESTURE_SELECTION_NAME" desc="Name of about::flags option to enable gesture selection for the virtual keyboard"> <message name="IDS_FLAGS_GESTURE_EDITING_NAME" desc="Name of about::flags option to toggle gesture editing for the virtual keyboard">
Gesture selection for the virtual keyboard. Gesture editing for the virtual keyboard.
</message> </message>
<message name="IDS_FLAGS_GESTURE_SELECTION_DESCRIPTION" desc="Description of about::flags option to toggle gesture selection in the settings page for the virtual keyboard"> <message name="IDS_FLAGS_GESTURE_EDITING_DESCRIPTION" desc="Description of about::flags option to toggle gesture editing in the settings page for the virtual keyboard">
Enable/Disable gesture selection option in the settings page for the virtual keyboard. Enable/Disable gesture editing option in the settings page for the virtual keyboard.
</message>
<message name="IDS_FLAGS_GESTURE_DELETION_NAME" desc="Name of about::flags option to toggle gesture deletion for the virtual keyboard">
Gesture deletion for the virtual keyboard.
</message>
<message name="IDS_FLAGS_GESTURE_DELETION_DESCRIPTION" desc="Description of about::flags option to toggle gesture deletion in the settings page for the virtual keyboard">
Enable/Disable gesture deletion option in the settings page for the virtual keyboard.
</message> </message>
<message name="IDS_FLAGS_DISABLE_CAPTIVE_PORTAL_BYPASS_PROXY_NAME" desc="Name of about::flags option to disable bypass proxy for captive portal authorization on Chrome OS."> <message name="IDS_FLAGS_DISABLE_CAPTIVE_PORTAL_BYPASS_PROXY_NAME" desc="Name of about::flags option to disable bypass proxy for captive portal authorization on Chrome OS.">
Disable bypass proxy for Captive Portal Authorization Disable bypass proxy for Captive Portal Authorization
...@@ -487,24 +487,14 @@ const Experiment::Choice kGestureTypingChoices[] = { ...@@ -487,24 +487,14 @@ const Experiment::Choice kGestureTypingChoices[] = {
keyboard::switches::kGestureTypingEnabled}, keyboard::switches::kGestureTypingEnabled},
}; };
const Experiment::Choice kGestureSelectionChoices[] = { const Experiment::Choice kGestureEditingChoices[] = {
{ IDS_GENERIC_EXPERIMENT_CHOICE_DEFAULT, "", "" }, { IDS_GENERIC_EXPERIMENT_CHOICE_DEFAULT, "", "" },
{ IDS_GENERIC_EXPERIMENT_CHOICE_DISABLED, { IDS_GENERIC_EXPERIMENT_CHOICE_DISABLED,
keyboard::switches::kGestureSelection, keyboard::switches::kGestureEditing,
keyboard::switches::kGestureSelectionDisabled}, keyboard::switches::kGestureEditingDisabled},
{ IDS_GENERIC_EXPERIMENT_CHOICE_ENABLED, { IDS_GENERIC_EXPERIMENT_CHOICE_ENABLED,
keyboard::switches::kGestureSelection, keyboard::switches::kGestureEditing,
keyboard::switches::kGestureSelectionEnabled}, keyboard::switches::kGestureEditingEnabled},
};
const Experiment::Choice kGestureDeletionChoices[] = {
{ IDS_GENERIC_EXPERIMENT_CHOICE_DEFAULT, "", "" },
{ IDS_GENERIC_EXPERIMENT_CHOICE_DISABLED,
keyboard::switches::kGestureDeletion,
keyboard::switches::kGestureDeletionDisabled},
{ IDS_GENERIC_EXPERIMENT_CHOICE_ENABLED,
keyboard::switches::kGestureDeletion,
keyboard::switches::kGestureDeletionEnabled},
}; };
#endif #endif
...@@ -1481,18 +1471,11 @@ const Experiment kExperiments[] = { ...@@ -1481,18 +1471,11 @@ const Experiment kExperiments[] = {
MULTI_VALUE_TYPE(kGestureTypingChoices) MULTI_VALUE_TYPE(kGestureTypingChoices)
}, },
{ {
"gesture-selection", "gesture-editing",
IDS_FLAGS_GESTURE_SELECTION_NAME, IDS_FLAGS_GESTURE_EDITING_NAME,
IDS_FLAGS_GESTURE_SELECTION_DESCRIPTION, IDS_FLAGS_GESTURE_EDITING_DESCRIPTION,
kOsCrOS,
MULTI_VALUE_TYPE(kGestureSelectionChoices)
},
{
"gesture-deletion",
IDS_FLAGS_GESTURE_DELETION_NAME,
IDS_FLAGS_GESTURE_DELETION_DESCRIPTION,
kOsCrOS, kOsCrOS,
MULTI_VALUE_TYPE(kGestureDeletionChoices) MULTI_VALUE_TYPE(kGestureEditingChoices)
}, },
{ {
"disable-smart-virtual-keyboard", "disable-smart-virtual-keyboard",
......
...@@ -64,9 +64,7 @@ bool ChromeVirtualKeyboardDelegate::GetKeyboardConfig( ...@@ -64,9 +64,7 @@ bool ChromeVirtualKeyboardDelegate::GetKeyboardConfig(
features->AppendString( features->AppendString(
GenerateFeatureFlag("gesturetyping", keyboard::IsGestureTypingEnabled())); GenerateFeatureFlag("gesturetyping", keyboard::IsGestureTypingEnabled()));
features->AppendString(GenerateFeatureFlag( features->AppendString(GenerateFeatureFlag(
"gestureselection", keyboard::IsGestureSelectionEnabled())); "gestureediting", keyboard::IsGestureEditingEnabled()));
features->AppendString(GenerateFeatureFlag(
"gesturedeletion", keyboard::IsGestureDeletionEnabled()));
features->AppendString(GenerateFeatureFlag( features->AppendString(GenerateFeatureFlag(
"materialdesign", keyboard::IsMaterialDesignEnabled())); "materialdesign", keyboard::IsMaterialDesignEnabled()));
features->AppendString( features->AppendString(
......
...@@ -56196,6 +56196,7 @@ To add a new entry, add it with any value and run test to compute valid value. ...@@ -56196,6 +56196,7 @@ To add a new entry, add it with any value and run test to compute valid value.
<int value="-996673716" label="enable-web-app-frame"/> <int value="-996673716" label="enable-web-app-frame"/>
<int value="-979057409" label="enable-seccomp-filter-sandbox"/> <int value="-979057409" label="enable-seccomp-filter-sandbox"/>
<int value="-979034258" label="disable-ntp-other-sessions-menu"/> <int value="-979034258" label="disable-ntp-other-sessions-menu"/>
<int value="-972425050" label="gesture-editing"/>
<int value="-949178861" label="enable-new-avatar-menu"/> <int value="-949178861" label="enable-new-avatar-menu"/>
<int value="-926422468" label="disable-embedded-shared-worker"/> <int value="-926422468" label="disable-embedded-shared-worker"/>
<int value="-918618075" label="enable-service-worker"/> <int value="-918618075" label="enable-service-worker"/>
...@@ -20,13 +20,9 @@ const char kGestureTyping[] = "gesture-typing"; ...@@ -20,13 +20,9 @@ const char kGestureTyping[] = "gesture-typing";
const char kGestureTypingEnabled[] = "enabled"; const char kGestureTypingEnabled[] = "enabled";
const char kGestureTypingDisabled[] = "disabled"; const char kGestureTypingDisabled[] = "disabled";
const char kGestureSelection[] = "gesture-selection"; const char kGestureEditing[] = "gesture-editing";
const char kGestureSelectionEnabled[] = "enabled"; const char kGestureEditingEnabled[] = "enabled";
const char kGestureSelectionDisabled[] = "disabled"; const char kGestureEditingDisabled[] = "disabled";
const char kGestureDeletion[] = "gesture-deletion";
const char kGestureDeletionEnabled[] = "enabled";
const char kGestureDeletionDisabled[] = "disabled";
const char kEnableVirtualKeyboard[] = "enable-virtual-keyboard"; const char kEnableVirtualKeyboard[] = "enable-virtual-keyboard";
const char kFloatingVirtualKeyboard[] = "floating-virtual-keyboard"; const char kFloatingVirtualKeyboard[] = "floating-virtual-keyboard";
......
...@@ -39,23 +39,15 @@ KEYBOARD_EXPORT extern const char kGestureTypingEnabled[]; ...@@ -39,23 +39,15 @@ KEYBOARD_EXPORT extern const char kGestureTypingEnabled[];
// Disables gesture typing for the virtual keyboard. // Disables gesture typing for the virtual keyboard.
KEYBOARD_EXPORT extern const char kGestureTypingDisabled[]; KEYBOARD_EXPORT extern const char kGestureTypingDisabled[];
// Gesture selection for the virtual keyboard. // Controls the appearance of the settings option to enable gesture editing
KEYBOARD_EXPORT extern const char kGestureSelection[]; // for the virtual keyboard.
KEYBOARD_EXPORT extern const char kGestureEditing[];
// Enables gesture selection for the virtual keyboard. // Enables gesture editing for the virtual keyboard.
KEYBOARD_EXPORT extern const char kGestureSelectionEnabled[]; KEYBOARD_EXPORT extern const char kGestureEditingEnabled[];
// Disables gesture selection for the virtual keyboard. // Disables gesture editing for the virtual keyboard.
KEYBOARD_EXPORT extern const char kGestureSelectionDisabled[]; KEYBOARD_EXPORT extern const char kGestureEditingDisabled[];
// Gesture deletion for the virtual keyboard.
KEYBOARD_EXPORT extern const char kGestureDeletion[];
// Enables gesture deletion for the virtual keyboard.
KEYBOARD_EXPORT extern const char kGestureDeletionEnabled[];
// Disables gesture deletion for the virtual keyboard.
KEYBOARD_EXPORT extern const char kGestureDeletionDisabled[];
// Enables the virtual keyboard. // Enables the virtual keyboard.
KEYBOARD_EXPORT extern const char kEnableVirtualKeyboard[]; KEYBOARD_EXPORT extern const char kEnableVirtualKeyboard[];
......
...@@ -170,18 +170,11 @@ bool IsGestureTypingEnabled() { ...@@ -170,18 +170,11 @@ bool IsGestureTypingEnabled() {
return keyboard_switch == switches::kGestureTypingEnabled; return keyboard_switch == switches::kGestureTypingEnabled;
} }
bool IsGestureSelectionEnabled() { bool IsGestureEditingEnabled() {
std::string keyboard_switch = std::string keyboard_switch =
base::CommandLine::ForCurrentProcess()->GetSwitchValueASCII( base::CommandLine::ForCurrentProcess()->GetSwitchValueASCII(
switches::kGestureSelection); switches::kGestureEditing);
return keyboard_switch != switches::kGestureSelectionDisabled; return keyboard_switch == switches::kGestureEditingEnabled;
}
bool IsGestureDeletionEnabled() {
std::string keyboard_switch =
base::CommandLine::ForCurrentProcess()->GetSwitchValueASCII(
switches::kGestureDeletion);
return keyboard_switch != switches::kGestureDeletionDisabled;
} }
bool IsMaterialDesignEnabled() { bool IsMaterialDesignEnabled() {
......
...@@ -99,11 +99,8 @@ KEYBOARD_EXPORT bool IsFloatingVirtualKeyboardEnabled(); ...@@ -99,11 +99,8 @@ KEYBOARD_EXPORT bool IsFloatingVirtualKeyboardEnabled();
// Returns true if gesture typing is enabled for virtual keyboard. // Returns true if gesture typing is enabled for virtual keyboard.
KEYBOARD_EXPORT bool IsGestureTypingEnabled(); KEYBOARD_EXPORT bool IsGestureTypingEnabled();
// Returns true if gesture deletion is enabled for virtual keyboard. // Returns true if gesture editing option is enabled for virtual keyboard.
KEYBOARD_EXPORT bool IsGestureDeletionEnabled(); KEYBOARD_EXPORT bool IsGestureEditingEnabled();
// Returns true if gesture selection is enabled for virtual keyboard.
KEYBOARD_EXPORT bool IsGestureSelectionEnabled();
// Returns true if material design is enabled for the keyboard. // Returns true if material design is enabled for the keyboard.
KEYBOARD_EXPORT bool IsMaterialDesignEnabled(); KEYBOARD_EXPORT bool IsMaterialDesignEnabled();
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment