android - Add / Remove App Drawer Shortcuts -


i trying programmatically add , remove application shortcuts app drawer. understand app drawer knows applications should presented using intent filter launcher category.

i able add/remove shortcuts specific activities in application, according dynamic conditions, why can't have them in manifest file.

thank you.

as far know, not possible. unfortunately, current android api level there no way add intentfilters activity objects through code. check out this doc on intent filters. relevant quote:

an intent filter instance of intentfilter class. however, since android system must know capabilities of component before can launch component, intent filters not set in java code, in application's manifest file (androidmanifest.xml) elements. (the 1 exception filters broadcast receivers registered dynamically calling context.registerreceiver(); directly created intentfilter objects.)


Comments

Popular posts from this blog

linux - Mailx and Gmail nss config dir -

c# - Is it possible to remove an existing registration from Autofac container builder? -

php - Mysql PK and FK char(36) vs int(10) -