diff options
10 files changed, 16 insertions, 16 deletions
diff --git a/api/current.txt b/api/current.txt index be011123e549..b70f5d7ed392 100644 --- a/api/current.txt +++ b/api/current.txt @@ -1188,7 +1188,7 @@ package android { field public static final int summaryColumn = 16843426; // 0x10102a2 field public static final int summaryOff = 16843248; // 0x10101f0 field public static final int summaryOn = 16843247; // 0x10101ef - field public static final int supportsAssistGesture = 16844011; // 0x10104eb + field public static final int supportsAssist = 16844011; // 0x10104eb field public static final int supportsRtl = 16843695; // 0x10103af field public static final int supportsSwitchingToNextInputMethod = 16843755; // 0x10103eb field public static final int supportsUploading = 16843419; // 0x101029b diff --git a/api/system-current.txt b/api/system-current.txt index c4f96afed355..f3935fc8cc40 100644 --- a/api/system-current.txt +++ b/api/system-current.txt @@ -1263,7 +1263,7 @@ package android { field public static final int summaryColumn = 16843426; // 0x10102a2 field public static final int summaryOff = 16843248; // 0x10101f0 field public static final int summaryOn = 16843247; // 0x10101ef - field public static final int supportsAssistGesture = 16844011; // 0x10104eb + field public static final int supportsAssist = 16844011; // 0x10104eb field public static final int supportsRtl = 16843695; // 0x10103af field public static final int supportsSwitchingToNextInputMethod = 16843755; // 0x10103eb field public static final int supportsUploading = 16843419; // 0x101029b diff --git a/core/java/android/service/voice/VoiceInteractionServiceInfo.java b/core/java/android/service/voice/VoiceInteractionServiceInfo.java index 4bc97c9cbcb5..997d58673da3 100644 --- a/core/java/android/service/voice/VoiceInteractionServiceInfo.java +++ b/core/java/android/service/voice/VoiceInteractionServiceInfo.java @@ -43,7 +43,7 @@ public class VoiceInteractionServiceInfo { private String mSessionService; private String mRecognitionService; private String mSettingsActivity; - private boolean mSupportsAssistGesture; + private boolean mSupportsAssist; public VoiceInteractionServiceInfo(PackageManager pm, ComponentName comp) throws PackageManager.NameNotFoundException { @@ -95,8 +95,8 @@ public class VoiceInteractionServiceInfo { com.android.internal.R.styleable.VoiceInteractionService_recognitionService); mSettingsActivity = array.getString( com.android.internal.R.styleable.VoiceInteractionService_settingsActivity); - mSupportsAssistGesture = array.getBoolean( - com.android.internal.R.styleable.VoiceInteractionService_supportsAssistGesture, + mSupportsAssist = array.getBoolean( + com.android.internal.R.styleable.VoiceInteractionService_supportsAssist, false); array.recycle(); if (mSessionService == null) { @@ -145,7 +145,7 @@ public class VoiceInteractionServiceInfo { return mSettingsActivity; } - public boolean getSupportsAssistGesture() { - return mSupportsAssistGesture; + public boolean getSupportsAssist() { + return mSupportsAssist; } } diff --git a/core/java/com/android/internal/app/IVoiceInteractionManagerService.aidl b/core/java/com/android/internal/app/IVoiceInteractionManagerService.aidl index d149c5b9d497..4c6db24e4043 100644 --- a/core/java/com/android/internal/app/IVoiceInteractionManagerService.aidl +++ b/core/java/com/android/internal/app/IVoiceInteractionManagerService.aidl @@ -105,5 +105,5 @@ interface IVoiceInteractionManagerService { * Indicates whether the currently active voice interaction service is capable of handling the * assist gesture. */ - boolean activeServiceSupportsAssistGesture(); + boolean activeServiceSupportsAssist(); } diff --git a/core/res/res/values/attrs.xml b/core/res/res/values/attrs.xml index 702f7201acc3..8bcbca10d089 100644 --- a/core/res/res/values/attrs.xml +++ b/core/res/res/values/attrs.xml @@ -7305,8 +7305,8 @@ <attr name="recognitionService" format="string" /> <attr name="settingsActivity" /> <!-- Flag indicating whether this voice interaction service is capable of handling the - assist gesture. --> - <attr name="supportsAssistGesture" format="boolean" /> + assist action. --> + <attr name="supportsAssist" format="boolean" /> </declare-styleable> <!-- Use <code>voice-enrollment-application</code> diff --git a/core/res/res/values/public.xml b/core/res/res/values/public.xml index cf21a1c50cb1..79b81a797057 100644 --- a/core/res/res/values/public.xml +++ b/core/res/res/values/public.xml @@ -2663,7 +2663,7 @@ <public type="attr" name="autoVerify" /> <public type="attr" name="breakStrategy" /> - <public type="attr" name="supportsAssistGesture" /> + <public type="attr" name="supportsAssist" /> <public type="attr" name="thumbPosition" /> <!-- Placeholder for a removed attribute. Remove this before M release. --> diff --git a/packages/SystemUI/src/com/android/systemui/assist/AssistGestureManager.java b/packages/SystemUI/src/com/android/systemui/assist/AssistGestureManager.java index 36be3555e486..d9f2324b8e81 100644 --- a/packages/SystemUI/src/com/android/systemui/assist/AssistGestureManager.java +++ b/packages/SystemUI/src/com/android/systemui/assist/AssistGestureManager.java @@ -196,7 +196,7 @@ public class AssistGestureManager { private boolean getVoiceInteractorSupportsAssistGesture() { try { - return mVoiceInteractionManagerService.activeServiceSupportsAssistGesture(); + return mVoiceInteractionManagerService.activeServiceSupportsAssist(); } catch (RemoteException e) { Log.w(TAG, "Failed to call activeServiceSupportsAssistGesture", e); return false; diff --git a/services/voiceinteraction/java/com/android/server/voiceinteraction/VoiceInteractionManagerService.java b/services/voiceinteraction/java/com/android/server/voiceinteraction/VoiceInteractionManagerService.java index 81c5e6afbea5..56b2fa53d37b 100644 --- a/services/voiceinteraction/java/com/android/server/voiceinteraction/VoiceInteractionManagerService.java +++ b/services/voiceinteraction/java/com/android/server/voiceinteraction/VoiceInteractionManagerService.java @@ -734,10 +734,10 @@ public class VoiceInteractionManagerService extends SystemService { } @Override - public boolean activeServiceSupportsAssistGesture() { + public boolean activeServiceSupportsAssist() { enforceCallingPermission(Manifest.permission.ACCESS_VOICE_INTERACTION_SERVICE); synchronized (this) { - return mImpl != null && mImpl.mInfo.getSupportsAssistGesture(); + return mImpl != null && mImpl.mInfo.getSupportsAssist(); } } diff --git a/tests/Assist/res/xml/interaction_service.xml b/tests/Assist/res/xml/interaction_service.xml index 2fd50aae105f..f56156e53fb2 100644 --- a/tests/Assist/res/xml/interaction_service.xml +++ b/tests/Assist/res/xml/interaction_service.xml @@ -18,4 +18,4 @@ <voice-interaction-service xmlns:android="http://schemas.android.com/apk/res/android" android:sessionService="com.android.test.assist.AssistInteractionSessionService" android:recognitionService="com.android.test.assist.AssistRecognitionService" - android:supportsAssistGesture="true"/> + android:supportsAssist="true"/> diff --git a/tests/VoiceInteraction/res/xml/interaction_service.xml b/tests/VoiceInteraction/res/xml/interaction_service.xml index 789493a7f22c..c015ad232fae 100644 --- a/tests/VoiceInteraction/res/xml/interaction_service.xml +++ b/tests/VoiceInteraction/res/xml/interaction_service.xml @@ -21,4 +21,4 @@ android:sessionService="com.android.test.voiceinteraction.MainInteractionSessionService" android:recognitionService="com.android.test.voiceinteraction.MainRecognitionService" android:settingsActivity="com.android.test.voiceinteraction.SettingsActivity" - android:supportsAssistGesture="true" /> + android:supportsAssist="true" /> |