Commit ae809092 authored by shuchen's avatar shuchen Committed by Commit bot

Turn off physical keyboard autocorrect feature by default.

And make the flag --enable-physical-keyboard-autocorrect as
ENABLE_DISABLE_VALUE_TYPE.

TBR=stevet@chromium.org
BUG=422869
TEST=Verified on linux_chromeos.

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

Cr-Commit-Position: refs/heads/master@{#316407}
parent 0ecf5952
......@@ -14287,11 +14287,11 @@ Do you accept?
Enable new Korean IME, which is based on Google Input Tools' HMM engine.
</message>
<message name="IDS_FLAGS_DISABLE_PHYSICAL_KEYBOARD_AUTOCORRECT_NAME" desc="Name of about::flags option to disable physical keyboard autocorrect for US keyboard">
Disable physical keyboard autocorrect.
<message name="IDS_FLAGS_ENABLE_PHYSICAL_KEYBOARD_AUTOCORRECT_NAME" desc="Name of about::flags option to enable physical keyboard autocorrect for US keyboard">
Enable physical keyboard autocorrect.
</message>
<message name="IDS_FLAGS_DISABLE_PHYSICAL_KEYBOARD_AUTOCORRECT_DESCRIPTION" desc="Description of about::flags option to disable physical keyboard autocorrect for US keyboard">
Disable physical keyboard autocorrect for US keyboard, which can provide suggestions as typing on physical keyboard.
<message name="IDS_FLAGS_ENABLE_PHYSICAL_KEYBOARD_AUTOCORRECT_DESCRIPTION" desc="Description of about::flags option to enable physical keyboard autocorrect for US keyboard">
Enable physical keyboard autocorrect for US keyboard, which can provide suggestions as typing on physical keyboard.
</message>
<message name="IDS_FLAGS_DISABLE_VOICE_INPUT_NAME" desc="Name of about::flags option to disable voice input on virtual keyboard">
......
......@@ -1287,11 +1287,13 @@ const Experiment kExperiments[] = {
SINGLE_VALUE_TYPE(chromeos::switches::kEnableNewMDInputView)
},
{
"disable-physical-keyboard-autocorrect",
IDS_FLAGS_DISABLE_PHYSICAL_KEYBOARD_AUTOCORRECT_NAME,
IDS_FLAGS_DISABLE_PHYSICAL_KEYBOARD_AUTOCORRECT_DESCRIPTION,
"enable-physical-keyboard-autocorrect",
IDS_FLAGS_ENABLE_PHYSICAL_KEYBOARD_AUTOCORRECT_NAME,
IDS_FLAGS_ENABLE_PHYSICAL_KEYBOARD_AUTOCORRECT_DESCRIPTION,
kOsCrOS,
SINGLE_VALUE_TYPE(chromeos::switches::kDisablePhysicalKeyboardAutocorrect)
ENABLE_DISABLE_VALUE_TYPE(
chromeos::switches::kEnablePhysicalKeyboardAutocorrect,
chromeos::switches::kDisablePhysicalKeyboardAutocorrect)
},
{
"disable-voice-input",
......
......@@ -34,8 +34,8 @@ ExtensionFunction::ResponseAction GetInputMethodConfigFunction::Run() {
base::DictionaryValue* output = new base::DictionaryValue();
output->SetBoolean(
"isPhysicalKeyboardAutocorrectEnabled",
!base::CommandLine::ForCurrentProcess()->HasSwitch(
chromeos::switches::kDisablePhysicalKeyboardAutocorrect));
base::CommandLine::ForCurrentProcess()->HasSwitch(
chromeos::switches::kEnablePhysicalKeyboardAutocorrect));
output->SetBoolean("isVoiceInputEnabled",
!base::CommandLine::ForCurrentProcess()->HasSwitch(
chromeos::switches::kDisableVoiceInput));
......
......@@ -119,6 +119,11 @@ const char kEnableNewKoreanIme[] = "enable-new-korean-ime";
// If this switch is set, the input view keyboard will be in materia design.
const char kEnableNewMDInputView[] = "enable-new-md-input-view";
// If this switch is set, the options for suggestions as typing on physical
// keyboard will be enabled.
const char kEnablePhysicalKeyboardAutocorrect[] =
"enable-physical-keyboard-autocorrect";
// If this switch is set, the options for suggestions as typing on physical
// keyboard will be disabled.
const char kDisablePhysicalKeyboardAutocorrect[] =
......
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