Can a live wallpaper also be an application? (With a separate Activity for the Application)
I have a Live Wallpaper which I would like to also make available as an Activity which can be accessed as a normal Phone App.
Can this be achieved?
开发者_C百科Thanks in advance, Mark
Just append an acitivity with
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
in the manifest. You can have as many as you want.
You certainly can you just need to setup the activities you want to expose through proper intent filters in your Android manifest under the application node..
<activity ...> <!-- this being the activity you want to expose -->
<intent-filter>
<action android:name="android.intent.action.MAIN"/>
<category android:name="android.intent.category.LAUNCHER"/>
</intent-filter>
</activity>
精彩评论