summaryrefslogtreecommitdiffstats
path: root/services
diff options
context:
space:
mode:
authorMichael Jurka <mikejurka@google.com>2012-11-01 18:26:01 -0700
committerMichael Jurka <mikejurka@google.com>2012-11-01 18:50:21 -0700
commit67a871d85732e582c70a2a1d85ef4419eb658a12 (patch)
treeeffd9037568ce6a2fd73afa3150ce5646881f9a3 /services
parent9767597a74bd9a5a265ff72aa5f77dd7efb93b53 (diff)
downloadframeworks_base-67a871d85732e582c70a2a1d85ef4419eb658a12.zip
frameworks_base-67a871d85732e582c70a2a1d85ef4419eb658a12.tar.gz
frameworks_base-67a871d85732e582c70a2a1d85ef4419eb658a12.tar.bz2
Use clock's widget as the default keyguard widget
Also, if we have no widgets in lockscreen, reinflate the default widget. If that fails, inflate the built-in clock (KeyguardStatusView) Change-Id: I2e90ab0893c993a755700e075e4a8ac5a685e0f2
Diffstat (limited to 'services')
-rw-r--r--services/java/com/android/server/AppWidgetServiceImpl.java4
1 files changed, 2 insertions, 2 deletions
diff --git a/services/java/com/android/server/AppWidgetServiceImpl.java b/services/java/com/android/server/AppWidgetServiceImpl.java
index d0dd9cf..daa82f2 100644
--- a/services/java/com/android/server/AppWidgetServiceImpl.java
+++ b/services/java/com/android/server/AppWidgetServiceImpl.java
@@ -599,7 +599,7 @@ class AppWidgetServiceImpl {
}
public void bindAppWidgetId(int appWidgetId, ComponentName provider, Bundle options) {
- mContext.enforceCallingPermission(android.Manifest.permission.BIND_APPWIDGET,
+ mContext.enforceCallingOrSelfPermission(android.Manifest.permission.BIND_APPWIDGET,
"bindAppWidgetId appWidgetId=" + appWidgetId + " provider=" + provider);
bindAppWidgetIdImpl(appWidgetId, provider, options);
}
@@ -607,7 +607,7 @@ class AppWidgetServiceImpl {
public boolean bindAppWidgetIdIfAllowed(
String packageName, int appWidgetId, ComponentName provider, Bundle options) {
try {
- mContext.enforceCallingPermission(android.Manifest.permission.BIND_APPWIDGET, null);
+ mContext.enforceCallingOrSelfPermission(android.Manifest.permission.BIND_APPWIDGET, null);
} catch (SecurityException se) {
if (!callerHasBindAppWidgetPermission(packageName)) {
return false;