SearchView Voice Listener

I would like to know if it is possible to install a voice listener in my searchView, for example, a sentence listener: http://developer.android.com/reference/android/support/v7/widget/SearchView.OnSuggestionListener.html

I want to overwrite the default behavior. I do not want to start another activity. I just want to record the recorded voice as a string and use it.

+5
source share
2 answers

I read what you ask, but why do not you want to use any activity? Just in case this can help you, you should take a look at them if you are still not:

Andriod Developers: http://developer.android.com/guide/topics/search/search-dialog.html#VoiceSearch

Examples:

http://www.codeproject.com/Articles/821839/A-Beginners-Guide-to-Working-With-Speech-and-Audio http://www.truiton.com/2014/06/android-speech-recognition -without-dialog-custom-activity /

Hope this helps, yakobom

+1
source

To show the microphone icon, you need to add a search configuration and set it to SearchView. See this question and my answer here fooobar.com/questions/1219506 / ...

0
source

All Articles