diff options
-rw-r--r-- | core/java/android/speech/RecognitionManager.java | 2 | ||||
-rw-r--r-- | packages/SettingsProvider/src/com/android/providers/settings/DatabaseHelper.java | 3 |
2 files changed, 3 insertions, 2 deletions
diff --git a/core/java/android/speech/RecognitionManager.java b/core/java/android/speech/RecognitionManager.java index edb7067..74b9fce 100644 --- a/core/java/android/speech/RecognitionManager.java +++ b/core/java/android/speech/RecognitionManager.java @@ -221,7 +221,7 @@ public class RecognitionManager { if (mConnection == null) { // first time connection mConnection = new Connection(); - Intent serviceIntent = new Intent(RecognizerIntent.ACTION_RECOGNIZE_SPEECH); + Intent serviceIntent = new Intent(RecognitionService.SERVICE_INTERFACE); String serviceComponent = Settings.Secure.getString(mContext.getContentResolver(), Settings.Secure.VOICE_RECOGNITION_SERVICE); diff --git a/packages/SettingsProvider/src/com/android/providers/settings/DatabaseHelper.java b/packages/SettingsProvider/src/com/android/providers/settings/DatabaseHelper.java index 4e1e0a2..b26607f 100644 --- a/packages/SettingsProvider/src/com/android/providers/settings/DatabaseHelper.java +++ b/packages/SettingsProvider/src/com/android/providers/settings/DatabaseHelper.java @@ -38,6 +38,7 @@ import android.net.ConnectivityManager; import android.os.Environment; import android.os.SystemProperties; import android.provider.Settings; +import android.speech.RecognitionService; import android.speech.RecognizerIntent; import android.text.TextUtils; import android.util.Config; @@ -996,7 +997,7 @@ public class DatabaseHelper extends SQLiteOpenHelper { String selectedService = null; List<ResolveInfo> availableRecognitionServices = mContext.getPackageManager().queryIntentServices( - new Intent(RecognizerIntent.ACTION_RECOGNIZE_SPEECH), 0); + new Intent(RecognitionService.SERVICE_INTERFACE), 0); int numAvailable = availableRecognitionServices.size(); if (numAvailable == 0) { |