Android Widget implementation

房东的猫 提交于 2019-12-20 05:38:31

问题


Hi I apologise in advance if this question is daft. I am fairly new to Android programming and I learn fast.

Any ways I have just created a Task Reminder application and I would like to turn/implement that application into a widget that you can view on the home screen?

Is this possible?

Thanks.


回答1:


Without more information about what your app does all I can really do is point you to the documentation on widgets which would be a good place to start anyway. One thing I can tell you though is to make sure that your application is a good fit for a widget. Widgets were purposefully designed to be very limited in Android. There are only a handful of views that can be used and you can't update them very frequently without it being a major headache. You may just want to make a part of your app into a widget. Widgets aren't just apps on the launcher. Best of luck.




回答2:


Yes, it's probably possible. Take a look at http://programmerbruce.blogspot.com/2011/04/simple-complete-app-widget-part-1.html for a decent example.




回答3:


I think you like to create an "App Widget". A manual about doing so is here.



来源:https://stackoverflow.com/questions/5873816/android-widget-implementation

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