Which function to close the search dialog in Android?

Using the super.onSearchRequested () function, I can open the search dialog in my Android application, what is the equivalent function to close it?

+4
source share
4 answers

The search dialog closes with setOnDismissListener() and / or setOnCancelListener() .

+2
source

That should do it ...

 import android.app.SearchManager; ((SearchManager)this.getSystemService(Context.SEARCH_SERVICE)).stopSearch(); 
0
source

Can't hide this line using ICS using this method?

0
source

All Articles