diff options
author | Treehugger Robot <treehugger-gerrit@google.com> | 2017-08-31 16:17:04 +0000 |
---|---|---|
committer | Gerrit Code Review <noreply-gerritcodereview@google.com> | 2017-08-31 16:17:04 +0000 |
commit | c39ea3c55fac807c0b98aabdf56c70dc8a49036c (patch) | |
tree | e282668a9587cf6c1ec7b604dea860400c75c6c7 /java/com/android/dialer/callcomposer/GalleryCursorLoader.java | |
parent | 68038172793ee0e2ab3e2e56ddfbeb82879d1f58 (diff) | |
parent | 2ca4318cc1ee57dda907ba2069bd61d162b1baef (diff) |
Merge "Update Dialer source to latest internal Google revision."
Diffstat (limited to 'java/com/android/dialer/callcomposer/GalleryCursorLoader.java')
-rw-r--r-- | java/com/android/dialer/callcomposer/GalleryCursorLoader.java | 12 |
1 files changed, 5 insertions, 7 deletions
diff --git a/java/com/android/dialer/callcomposer/GalleryCursorLoader.java b/java/com/android/dialer/callcomposer/GalleryCursorLoader.java index f9990e167..d33bfb398 100644 --- a/java/com/android/dialer/callcomposer/GalleryCursorLoader.java +++ b/java/com/android/dialer/callcomposer/GalleryCursorLoader.java @@ -16,7 +16,6 @@ package com.android.dialer.callcomposer; -import android.annotation.SuppressLint; import android.content.Context; import android.net.Uri; import android.provider.MediaStore.Files; @@ -28,7 +27,7 @@ import android.support.v4.content.CursorLoader; public class GalleryCursorLoader extends CursorLoader { public static final String MEDIA_SCANNER_VOLUME_EXTERNAL = "external"; public static final String[] ACCEPTABLE_IMAGE_TYPES = - new String[] {"image/jpeg", "image/jpg", "image/png", "image/gif", "image/webp"}; + new String[] {"image/jpeg", "image/jpg", "image/png", "image/webp"}; private static final Uri STORAGE_URI = Files.getContentUri(MEDIA_SCANNER_VOLUME_EXTERNAL); private static final String SORT_ORDER = Media.DATE_MODIFIED + " DESC"; @@ -44,11 +43,10 @@ public class GalleryCursorLoader extends CursorLoader { SORT_ORDER); } - @SuppressLint("DefaultLocale") private static String createSelection() { - return String.format( - "mime_type IN ('image/jpeg', 'image/jpg', 'image/png', 'image/gif', 'image/webp')" - + " AND media_type in (%d)", - FileColumns.MEDIA_TYPE_IMAGE); + return "mime_type IN ('image/jpeg', 'image/jpg', 'image/png', 'image/webp')" + + " AND media_type in (" + + FileColumns.MEDIA_TYPE_IMAGE + + ")"; } } |