Widget Limitations and Extensions

Android home widgets appear simple when you look at them. However, they have nuances when you start writing widgets.

If your widget doesn't require any state management and doesn't need to be invoked more than a few times a day, you have a widget that is very simple to write.

The next level of widget is one where you will need to manage the state, but the widget is invoked infrequently, like the one we have shown here. These types of widget can benefit from a state management framework. We have shown in this chapter a bare-bones state management framework. We assume that more sophisticated ones will be available or that you could write one that is more robust and flexible.

The next level of widgets must be invoked ...

Get Pro Android 4 now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.