Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Dynamically creating Widgets on Android

Is it possible to create multiple widgets in runtime? Application (Activity) should generate in some cases new widget(or edit exist) with new name and label and do some primitive action on click, which should be available in desktop widgets menu.

like image 789
user311076 Avatar asked Feb 02 '26 09:02

user311076


1 Answers

Is it possible to create multiple widgets in runtime?

No.

Application (Activity) should generate in some cases new widget(or edit exist) with new name and label and do some primitive action on click, which should be available in desktop widgets menu.

That is not possible. App widgets must be declared in the manifest, which cannot be modified at runtime.

Sorry!

like image 144
CommonsWare Avatar answered Feb 04 '26 22:02

CommonsWare