Adding Google Search API to Android App
您好,我想添加谷歌搜索API到我的应用程序和搜索结果应显示在列表视图中...任何一个可以给我一些例子或告诉我怎么做?
Here it is..
Intent intent = new Intent(Intent.ACTION_WEB_SEARCH);
String keyword= "your query here";
intent.putExtra(SearchManager.QUERY, keyword);
startActivity(intent);
What about a voice based search..
Intent sp=new Intent(RecognizerIntent.ACTION_WEB_SEARCH);
sp.putExtra(RecognizerIntent.EXTRA_LANGUAGE_MODEL, RecognizerIntent.LANGUAGE_MODEL_FREE_FORM);
sp.putExtra(RecognizerIntent.EXTRA_PROMPT, "Speak please");
startActivity(sp);
这是一个很好的例子,在你的android应用程序中实现谷歌搜索实施谷歌搜索。希望它有帮助。
链接地址: http://www.djcxy.com/p/75016.html