Skip to content

Commit 8651c55

Browse files
committed
cannot create alert dialog in wallpapers
1 parent 9de4f45 commit 8651c55

File tree

1 file changed

+8
-8
lines changed

1 file changed

+8
-8
lines changed

templates/WallpaperService.java.tmpl

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -70,14 +70,14 @@ public class MainService extends PWallpaper {
7070
boolean granted = true;
7171
for (int i = 0; i < grantResults.length; i++) {
7272
if (grantResults[i] != PackageManager.PERMISSION_GRANTED) {
73-
AlertDialog.Builder builder = new AlertDialog.Builder(this);
74-
builder.setMessage("Some permissions needed by the wallpaper were not granted, so it might not work as intended.")
75-
.setCancelable(false)
76-
.setPositiveButton("OK", new DialogInterface.OnClickListener() {
77-
public void onClick(DialogInterface dialog, int id) { }
78-
});
79-
AlertDialog alert = builder.create();
80-
alert.show();
73+
// AlertDialog.Builder builder = new AlertDialog.Builder(this);
74+
// builder.setMessage("Some permissions needed by the wallpaper were not granted, so it might not work as intended.")
75+
// .setCancelable(false)
76+
// .setPositiveButton("OK", new DialogInterface.OnClickListener() {
77+
// public void onClick(DialogInterface dialog, int id) { }
78+
// });
79+
// AlertDialog alert = builder.create();
80+
// alert.show();
8181
granted = false;
8282
break;
8383
}

0 commit comments

Comments
 (0)