简体   繁体   中英

How to add widget configuration activity to launcher?

I have a widget with a configuration activity.

Currently the configuration launches when you click on the widget.

I want to add the configuration as an app icon to the launcher.

The problem is that when the configuration launches on click, I get a specific widget id , so each widget instance can have a different configuration.

What will happen if I start the activity from the launcher?

I wont be able to show multiple configurations on the same activity.

Thanks.

What will happen if I start the activity from the launcher? I wont be able to show multiple configurations on the same activity.

Correct. Your choices appear to be:

  1. Display a list of app widgets -- perhaps you have a database table matching up app widget instance ID to some sort of display name
  2. You don't have the activity in the launcher. For example, put a configuration icon in the app widget itself.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM