Questions tagged [android-appwidget]

Android App Widgets are custom views that can be placed on the home screen of an Android device.

Android App Widgets are custom views that can be placed on the homescreen of an Android device.

Useful links

992 questions
5
votes
2 answers

How to include edittext in appwidget like Google search widget

I was trying to include an editText in appwidget..later I came to know that it is not possible to include edittext But if I check Google search appwiget I can see they are using a view similar to edittext.. How can I create a view like edittext…
Eby
  • 2,769
  • 4
  • 23
  • 30
5
votes
2 answers

AppWidget PendingIntent not working after Launcher restart

I have an AppWidget with 2 pending intents. They work most of the time, but after a while they stop responding. Only thing I have been able to pinpoint is that they are crippled after a Launcher restart, i.e. I use Launcher Pro, and sometimes fiddle…
5
votes
1 answer

What the difference to update Android App Widget between two approach?

I read some example in internet/book about the App Widget, a normal example to update the widget is in onUpdate(Context context, AppWidgetManager appWidgetManager,int[] appWidgetIds) method of AppWidgetProvider like this: final int N =…
chow
  • 769
  • 2
  • 8
  • 10
5
votes
2 answers

Binding AppWidgets to AppWidgetHost - Android

When you normally want to add an AppWidget in Android there is a list where you need to pick one widget and it binds it to the home screen. I'm trying to build an app which has its own appWidgetHost and specific App Widgets that I built for it. I…
shaimagz
  • 1,265
  • 4
  • 17
  • 39
5
votes
2 answers

Listening to gestures on an App widget

I have created an app widget in Android and want to add some gesture-based functionality to it. For e.g: when user swipes up new set of data be displayed. AFAIK, gestures are not supported in AppWidgets and yet I have seen widgets which have similar…
Samuh
  • 36,316
  • 26
  • 109
  • 116
5
votes
1 answer

Android 6.0 - App Standby and AppWidgets

What is Google's definition of a user "actively using" an app, in the context of app widgets? If an app hasn't been opened for a long period of time but has a widget on the home screen, does anybody know if Android will put that app in standby…
dennisdrew
  • 4,399
  • 1
  • 25
  • 25
5
votes
1 answer

Updating widget width - height programmatically on device rotation

I am working over widget where I need to control the width and height of widget programmatically when device rotates from portrait to landscape and landscape to protrait. For this when configuration change I call the below code to update the widget…
Vineet Shukla
  • 23,865
  • 10
  • 55
  • 63
5
votes
1 answer

Android Lollipop: Launcher crashes when adding app widget to Home Screen

The Launcher crashes on Android Lollipop when adding a Widget giving the following message (It works fine on previous Android versions): Edit: This only happens in landscape orientation. 12-16 12:35:10.208: E/AndroidRuntime(960):…
Christopher Masser
  • 809
  • 13
  • 25
5
votes
2 answers

How to launch activity from android home screen widget

I am desperately trying to get my head wrapped around how to implement home screen widgets. Right now, I (finally) was able to get a button on my widget respond to a button press setting up an intent filter in the manifest. However, I cannot for…
5
votes
4 answers

Updating android app widget manually using a button on the widget

I have a Android App widget and a button on the widget. I have set the update time period to 30mins but I also want to update the widget whenever I touch the button. here's my code: RemoteViews remoteV = new…
iitum studant
  • 856
  • 2
  • 8
  • 24
5
votes
2 answers

Android Widget with ListView displaying Loading views only

I am trying to implement an Android App Widget with a ListView. I started by following the Google documentation but I got stuck with a list of loading views being displayed instead of the normal list items. Does anybody have experiences with list…
sschmid
  • 1,341
  • 1
  • 16
  • 22
5
votes
3 answers

AppWidgetHostView can't handle onClick/onLongClick properly

I am developing a launcher, now I am working with app widgets, I follow the tutorial from here: AppWigetHost tutrial - Leonardo Fischer Everything goes well until I tried adding onLongCick listener on the AppWidgetHostView private void…
hungson175
  • 4,373
  • 6
  • 22
  • 21
5
votes
0 answers

App Widget in Android with network connection

I am trying to develop an AppWidget with network data. So far I have an application (up and running) with a custom AsyncTaskLoader (gets URL gives parsed data) to loaders inside my fragments. There is no cache or db to save that data. My best…
madlymad
  • 6,367
  • 6
  • 37
  • 68
5
votes
1 answer

Android AppWidget onUpdate on boot

Does an onUpdate AppWidget called on boot? I'm setting an alarm in the onUpdate and I wanted to know if the onUpdate will get called on boot or should I use the BOOT_COMPLETED intent. Thanks.
Ran
  • 4,117
  • 4
  • 44
  • 70
5
votes
3 answers

How to get ids of all the widgets installed?

I need to find any AppWidget id to test some features. The code to do this: List infos = mAppWidgetManager.getInstalledProviders(); for (int i = 0; i < infos.size(); i++) { int ids[] =…
artem
  • 16,382
  • 34
  • 113
  • 189