From e45ba22d0350a0ba7ab382bde1f0dbd72ec70675 Mon Sep 17 00:00:00 2001 From: Paramananda Date: Tue, 24 Mar 2015 18:06:39 +0530 Subject: Gallery2 : Drm file can be set as wallpaper - Only DRM FL file can be set as device wallpaper. Other licenseable files like CD and SD can not be allow for wallpaper because after license expaired we can not revert wallpaper to default. CRs-Fixed: 804190 Change-Id: I42f501b6a06a057765f80a6a124970bec6619e85 --- src/com/android/gallery3d/data/LocalImage.java | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/com/android/gallery3d/data/LocalImage.java b/src/com/android/gallery3d/data/LocalImage.java index c4524854d..67e8071d3 100644 --- a/src/com/android/gallery3d/data/LocalImage.java +++ b/src/com/android/gallery3d/data/LocalImage.java @@ -257,6 +257,10 @@ public class LocalImage extends LocalMediaItem { public int getSupportedOperations() { int operation = SUPPORT_DELETE | SUPPORT_INFO; if (DrmHelper.isDrmFile(getFilePath())) { + if (DrmHelper.isDrmFLBlocking(mApplication.getAndroidContext(), + getFilePath())) { + operation |= SUPPORT_SETAS; + } operation |= SUPPORT_DRM_INFO | SUPPORT_FULL_IMAGE; if (DrmHelper.isShareableDrmFile(getFilePath())) { operation |= SUPPORT_SHARE; -- cgit v1.2.3