summaryrefslogtreecommitdiffstats
path: root/core/java/android/appwidget
diff options
context:
space:
mode:
authorMichael Jurka <mikejurka@google.com>2012-11-16 15:34:20 -0800
committerAndroid Git Automerger <android-git-automerger@android.com>2012-11-16 15:34:20 -0800
commit3366a5d54eccbbe861bcc765653664d80eae5398 (patch)
tree1a31d1f7e0c0856bff8ebe725e16ba7ddde80f37 /core/java/android/appwidget
parente9019d90a3eed0dae98d5502e386212e56a92267 (diff)
parentcf474b1a10a1349d0d6d6f7cbb5d48489bacfb09 (diff)
downloadframeworks_base-3366a5d54eccbbe861bcc765653664d80eae5398.zip
frameworks_base-3366a5d54eccbbe861bcc765653664d80eae5398.tar.gz
frameworks_base-3366a5d54eccbbe861bcc765653664d80eae5398.tar.bz2
am cf474b1a: am 7b0c8779: Merge "Delete appWidgetId when removing lockscreen widgets" into jb-mr1.1-dev
* commit 'cf474b1a10a1349d0d6d6f7cbb5d48489bacfb09': Delete appWidgetId when removing lockscreen widgets
Diffstat (limited to 'core/java/android/appwidget')
-rw-r--r--core/java/android/appwidget/AppWidgetHost.java16
1 files changed, 16 insertions, 0 deletions
diff --git a/core/java/android/appwidget/AppWidgetHost.java b/core/java/android/appwidget/AppWidgetHost.java
index cb61a71..24fd2e4 100644
--- a/core/java/android/appwidget/AppWidgetHost.java
+++ b/core/java/android/appwidget/AppWidgetHost.java
@@ -224,6 +224,22 @@ public class AppWidgetHost {
}
}
+ /**
+ * Gets a list of all the appWidgetIds that are bound to the current host
+ *
+ * @hide
+ */
+ public int[] getAppWidgetIds() {
+ try {
+ if (sService == null) {
+ bindService();
+ }
+ return sService.getAppWidgetIdsForHost(mHostId);
+ } catch (RemoteException e) {
+ throw new RuntimeException("system server dead?", e);
+ }
+ }
+
private static void checkCallerIsSystem() {
int uid = Process.myUid();
if (UserHandle.getAppId(uid) == Process.SYSTEM_UID || uid == 0) {