diff options
author | Mike LeBeau <mlebeau@android.com> | 2009-07-30 16:07:50 -0700 |
---|---|---|
committer | Android Git Automerger <android-git-automerger@android.com> | 2009-07-30 16:07:50 -0700 |
commit | 0185fc570b8ce162e8a4d8576ca94960bf5b7e92 (patch) | |
tree | f77f9a2fe543fadf2b31a1d171a463769c3a12cb /core/java/android/app | |
parent | 2801ac1a77f41224edf1b68965f4bc7d467d1d70 (diff) | |
parent | c2e06072051e319bc609df66f4c72b77716f4fa4 (diff) | |
download | frameworks_base-0185fc570b8ce162e8a4d8576ca94960bf5b7e92.zip frameworks_base-0185fc570b8ce162e8a4d8576ca94960bf5b7e92.tar.gz frameworks_base-0185fc570b8ce162e8a4d8576ca94960bf5b7e92.tar.bz2 |
am c2e06072: Tell the SearchManager to stopSearch before starting an in-app voice search. Without this, because of the recent changes to how the search dialog hides and resumes, we end up re-showing the search dialog after returning to the app from voice search, obscu
Merge commit 'c2e06072051e319bc609df66f4c72b77716f4fa4'
* commit 'c2e06072051e319bc609df66f4c72b77716f4fa4':
Tell the SearchManager to stopSearch before starting an in-app voice
Diffstat (limited to 'core/java/android/app')
-rw-r--r-- | core/java/android/app/SearchDialog.java | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/core/java/android/app/SearchDialog.java b/core/java/android/app/SearchDialog.java index ea3d762..18e4a52 100644 --- a/core/java/android/app/SearchDialog.java +++ b/core/java/android/app/SearchDialog.java @@ -903,6 +903,12 @@ public class SearchDialog extends Dialog implements OnItemClickListener, OnItemS getContext().startActivity(mVoiceWebSearchIntent); } else if (mSearchable.getVoiceSearchLaunchRecognizer()) { Intent appSearchIntent = createVoiceAppSearchIntent(mVoiceAppSearchIntent); + + // Stop the existing search before starting voice search, or else we'll end + // up showing the search dialog again once we return to the app. + ((SearchManager) getContext().getSystemService(Context.SEARCH_SERVICE)). + stopSearch(); + getContext().startActivity(appSearchIntent); } } catch (ActivityNotFoundException e) { |