summaryrefslogtreecommitdiffstats
path: root/docs/html/guide/topics/search/search-dialog.jd
diff options
context:
space:
mode:
Diffstat (limited to 'docs/html/guide/topics/search/search-dialog.jd')
-rw-r--r--docs/html/guide/topics/search/search-dialog.jd1
1 files changed, 1 insertions, 0 deletions
diff --git a/docs/html/guide/topics/search/search-dialog.jd b/docs/html/guide/topics/search/search-dialog.jd
index b9a26d6..e24681a 100644
--- a/docs/html/guide/topics/search/search-dialog.jd
+++ b/docs/html/guide/topics/search/search-dialog.jd
@@ -722,6 +722,7 @@ public boolean onCreateOptionsMenu(Menu menu) {
// Get the SearchView and set the searchable configuration
SearchManager searchManager = (SearchManager) {@link android.app.Activity#getSystemService getSystemService}(Context.SEARCH_SERVICE);
SearchView searchView = (SearchView) menu.findItem(R.id.menu_search).getActionView();
+ // Assumes current activity is the searchable activity
searchView.setSearchableInfo(searchManager.getSearchableInfo({@link android.app.Activity#getComponentName()}));
searchView.setIconifiedByDefault(false); // Do not iconify the widget; expand it by default