Android app not creating shortcut icon on home screen (downloaded from play store)

断了今生、忘了曾经 提交于 2019-12-11 01:47:40

问题


After downloading app from play store, its not creating shortcut icon on home screen(it creates icon in app drawer). While this thing working fine on most of devices. But for some devices. App is not creating shortcuts.

I have checked:

a) Play store settings and Auto-Add widgets is marked.

b) Launcher settings automatically add shortcut to screen is market.

Is there anything at programmer end? Can we write some code which will result in shortcut when app downloaded from play store?


回答1:


I don't think this is a bug coming from the application, it's more of a bug may be device bug probably. I'd check the caches on your device, ROM settings, etc.




回答2:


There is nothing wrong with programmer ensure you have checked Add icon Home screen check box, In some cases programmer may have written this code

Intent shortcutIntent = new Intent(getApplicationContext(),MainActivity.class); shortcutIntent.setAction(Intent.ACTION_MAIN); Intent addIntent = new Intent(); addIntent.putExtra(Intent.EXTRA_SHORTCUT_INTENT, shortcutIntent); addIntent.putExtra(Intent.EXTRA_SHORTCUT_NAME, "AppName"); addIntent.setAction("com.android.launcher.action.UNINSTALL_SHORTCUT"); getApplicationContext().sendBroadcast(addIntent);

To remove short-cut which is going to be created by play store even after "Add icon to Home screen" checked. So this Solution can help you out.




回答3:


Try this:

Go the home screen, hit apps then options (three dots at top right).

It had 'DOWNLOADED APPS' go into that then hold desired icon to create shortcut onto ur main screens.

Hope it works.



来源:https://stackoverflow.com/questions/17951352/android-app-not-creating-shortcut-icon-on-home-screen-downloaded-from-play-stor

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!