开发者

show spinner before adding widget android

开发者 https://www.devze.com 2022-12-10 18:42 出处:网络
For a widget I am creating for the Android OS, I want the user to first select a certain option from a Spinner. Just like when you add a shortcut to the homescreen.

For a widget I am creating for the Android OS, I want the user to first select a certain option from a Spinner. Just like when you add a shortcut to the homescreen.

Is that possible or do you have to start an Activity? If it is possible, can anyone expla开发者_如何学运维in how to do it?


Spinner widgets do not exist on their own -- you have to have them in an Activity. Android's app widget framework supports the notion of a configuration activity that is automatically launched when somebody chooses your widget. Just put your Spinner in there.

0

精彩评论

暂无评论...
验证码 换一张
取 消