Question

Is there a way to automatically start Google Now on Music Recognition? I'd need it to create a DashClock extension that start Music Recognizing...

As far as I speak, I can start package com.google.android.googlequicksearchbox successfully but I cannot start voice input... I would not use startActivity for result since I would not need a result, I would really just start Google Now voice recognition feature, is there a way to do it programmatically?

Était-ce utile?

La solution

Otherwise, to simply launch Google Now Song Recognition service (without having to tap on "Listen to Music", to be clear), you can create an Intent with the string

"com.google.android.googlequicksearchbox.MUSIC_SEARCH";

that would launch directly the proper interface.

Autres conseils

I just found a way to achieve my goal:

Intent intent = new Intent();
intent.setClassName("com.google.android.googlequicksearchbox","com.google.android.googlequicksearchbox.VoiceSearchActivity");

starting this intent will bring up voice search window.

Licencié sous: CC-BY-SA avec attribution
Non affilié à StackOverflow
scroll top