I'm implementing an app widget and I'd like to be able to change the property of a single view in the widget layout, without rebuilding all the RemoteViews
from scratch, which involves loading XML etc and which is not necessary in some circumstances.. Is there a way to say "update property X on view identified by a specific ID in the current widget layout"? I've seen that there is a partiallyUpdateAppWidget
method in the AppWidgetManager
class but I can't understand nor if it is meant for this purpose neither how it must be used.. Can you help me or point me to a useful link or example?
相关问题
- How can I create this custom Bottom Navigation on
- Bottom Navigation View gets Shrink Down
- How to make that the snackbar action button be sho
- Listening to outgoing sms not working android
- How to create Circular view on android wear?
相关文章
- android开发 怎么把图片放入drawable的文件夹下
- android上如何获取/storage/emulated/下的文件列表
- androidStudio有个箭头不认识
- SQLite不能创建表
- Windows - Android SDK manager not listing any plat
- Animate Recycler View grid when number of columns
- Why is the app closing suddenly without showing an
- Android OverlayItem.setMarker(): Change the marker
Yes, you can use
partiallyUpdateAppWidge
t method in theAppWidgetManager
class. As an example, if you want to update a text view inside a widget:Ref: Just update a widget RemoteViews instead of completly creating a new one?