Boon
Boon

Reputation: 41500

What does it mean to have android.intent.action.MAIN in Android manifest without LAUNCHER category?

I have a project with an Android manifest that has two activities with android.intent.action.MAIN for its intent filters, one with LAUNCHER and one without. In fact, the second activity has no category set at all. How does one launch the activity without LAUNCHER category?

Upvotes: 1

Views: 424

Answers (1)

CommonsWare
CommonsWare

Reputation: 1006964

Typically, the first activity would have to call startActivity() to start up the second activity.

There may be other scenarios (e.g., Android 7.0 app shortcuts, notifications), but none of those would require the MAIN action. Similarly, MAIN can be tied with other categories (e.g., LEANBACK_LAUNCHER for Android TV), though I assume that's not the case here, since you did not mention it.

Upvotes: 1

Related Questions