Unify voice interactor and recognizer settings.

There is now one settings UI to select both the new
voice interactor and old voice recognizer.

There are still a few wonky things about this that won't
be resolved until we start requiring that all interactors
specify an associated recognizer service.

Change-Id: Ib702ff717fb28bcb244cb30e49577066ddc9f197
This commit is contained in:
Dianne Hackborn
2014-07-18 19:20:11 -07:00
parent f6f1e2ba13
commit ff795ffba8
7 changed files with 670 additions and 373 deletions

View File

@@ -4061,24 +4061,28 @@
<string name="keyboard_settings_title">Android keyboard</string>
<!-- Title for the 'voice input' category of voice input/output settings -->
<string name="voice_category">Speech</string>
<!-- Title for the voice interactor setting in voice input/output settings -->
<string name="voice_interactor_title">Voice input</string>
<!-- Title for the link to settings for the chosen voice interactor in voice input/output
settings -->
<string name="voice_interactor_settings_title">Voice input</string>
<!-- Summary for the link to settings for the chosen voice interactor in voice input/output
settings. Would say something like, e.g., "Settings for 'Google'". -->
<string name="voice_interactor_settings_summary">Settings for
\'<xliff:g id="interactor_name">%s</xliff:g>\'</string>
<!-- Label to show for no voice interactor selector -->
<string name="no_voice_interactor">None</string>
<!-- Title for the voice recognizer setting in voice input/output settings -->
<string name="recognizer_title">Voice recognizer</string>
<!-- Title for the link to settings for the chosen voice recognizer in voice input/output settings -->
<string name="recognizer_settings_title">Voice Search</string>
<!-- Summary for the link to settings for the chosen voice recognizer in voice input/output settings.
Would say something like, e.g., "Settings for 'Google'". -->
<string name="recognizer_settings_summary">Settings for \'<xliff:g id="recognizer_name">%s</xliff:g>\'</string>
<!-- Voice input settings --><skip />
<!-- [CHAR_LIMIT=NONE] Name of the settings item to open the voice input settings. -->
<string name="voice_input_settings">Voice input settings</string>
<!-- [CHAR_LIMIT=NONE] Title of the screen of the voice input settings -->
<string name="voice_input_settings_title">Voice input</string>
<!-- [CHAR LIMIT=50] The text for the settings section in which users select
a voice interaction or recognition service to use. -->
<string name="voice_service_preference_section_title">Voice input services</string>
<!-- [CHAR LIMIT=NONE] The summary text for the voice service preference that is
a full voice interaction service. -->
<string name="voice_interactor_preference_summary">Full voice interaction</string>
<!-- [CHAR LIMIT=NONE] The summary text for the voice service preference that is
a simple voice recognition service. -->
<string name="voice_recognizer_preference_summary">Simple voice recognition</string>
<!-- [CHAR_LIMIT=NONE] Warning message about security implications of enabling a
voice interaction service, displayed as a dialog
message when the user selects to enable a service. -->
<string name="voice_interaction_security_warning">This voice input service will be able to
control all voice enabled applications on your behalf.
It comes from the <xliff:g id="voice_input_service_app_name">%s</xliff:g> application.
Enable the use of this service?</string>
<!-- Text-To-Speech (TTS) settings --><skip />
<!-- Name of the TTS package as listed by the package manager. -->
@@ -5462,6 +5466,7 @@
<string name="keywords_storage">space disk hard drive</string>
<string name="keywords_battery">power</string>
<string name="keywords_spell_checker">spelling</string>
<string name="keywords_voice_input">recognizer input speech speak language hands-free hand free recognition offensive word audio history bluetooth headset</string>
<string name="keywords_text_to_speech_output">rate language default speak speaking</string>
<string name="keywords_date_and_time">clock</string>
<string name="keywords_factory_data_reset">wipe delete</string>
@@ -5474,7 +5479,6 @@
<string name="keywords_accounts">account</string>
<string name="keywords_users">restriction restrict restricted</string>
<string name="keywords_keyboard_and_ime">text correction correct sound vibrate auto language gesture suggest suggestion theme offensive word type emoji</string>
<string name="keywords_search_voice">language hands-free hand free recognition offensive word audio history bluetooth headset</string>
<!-- NFC Wi-Fi pairing/setup strings-->

View File

@@ -99,31 +99,11 @@
android:key="voice_category"
android:title="@string/voice_category" >
<!-- entries, entryValues, and defaultValue will be populated programmatically. -->
<ListPreference
android:key="voice_interactor"
android:title="@string/voice_interactor_title"
android:dialogTitle="@string/voice_interactor_title"
/>
<!-- An intent for this preference will be populated programmatically. -->
<PreferenceScreen
android:key="voice_interactor_settings"
android:title="@string/voice_interactor_settings_title"
/>
<!-- entries, entryValues, and defaultValue will be populated programmatically. -->
<ListPreference
android:key="recognizer"
android:title="@string/recognizer_title"
android:dialogTitle="@string/recognizer_title"
/>
<!-- An intent for this preference will be populated programmatically. -->
<PreferenceScreen
android:key="recognizer_settings"
android:title="@string/recognizer_settings_title"
settings:keywords="@string/keywords_search_voice"
android:key="voice_input_settings"
android:title="@string/voice_input_settings_title"
settings:keywords="@string/keywords_voice_input"
android:fragment="com.android.settings.voice.VoiceInputSettings"
/>
<PreferenceScreen

View File

@@ -0,0 +1,25 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- Copyright (C) 2014 The Android Open Source Project
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
-->
<PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android"
android:title="@string/voice_input_settings_title">
<!-- The contents of this category are filled in by the Java code
based on the list of available voice interaction and recognition services. -->
<PreferenceCategory android:key="voice_service_preference_section"
android:title="@string/voice_service_preference_section_title" />
</PreferenceScreen>