According to the documentation on onAppWidgetOptionsChanged in AppWidgetProvider: "This is called when the widget is first placed and any time the widget is resized."
However, when I place my widget on the stock launcher in Android 4.2 and 4.3, this method is not being called immediately (only after I resize the widget). I tried it on my own app, as well as CommonsWare's https://github.com/commonsguy/cw-omnibus/tree/master/AppWidget/Resize
Is there something I am missing?
EDIT: The only launcher I have found that makes this method work correctly as described by the Google documentation is Action Launcher Pro; nice job and thanks, Chris Lacy! Why does the stock launcher not work? Anyone else have this issue?
thanks for calling attention to this issue. I will be updating the Android documentation to reflect this.
However, instead of forcing a call to onAppWidgetOptionsChanged() in onUpdate(), we would recommend an approach such as the following: