Created
March 23, 2015 14:54
-
-
Save pedrovgs/c424fe754a74f326e997 to your computer and use it in GitHub Desktop.
Configure your Activity to be opened when the user taps home button with a long press action.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<activity android:name="AwesomeActivity"> | |
<intent-filter> | |
<action android:name="android.intent.action.ASSIST"/> | |
<category android:name="android.intent.category.DEFAULT"/> | |
</intent-filter> | |
<meta-data | |
android:name="com.android.systemui.action_assist_icon" | |
android:resource="@drawable/app_icon"/> | |
</activity> |
The use case is if you want to create your own "assistant", like Gemini or Google Assistant. This allows your application to be configured as the default assistant so that it is opened when the user long presses the power button.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
What's the usecase for this?