From 20c38ea9fd4024cc076c825f46cdfb34ffc090de Mon Sep 17 00:00:00 2001 From: Jan Bjernler Date: Fri, 18 May 2012 10:01:18 +0200 Subject: Musicplayer application can not display DRM files of internal storage. Make DRM-protected files transferred over MTP be detected. Previously it was inserted into the database as MEDIA_TYPE_NONE, the result of this was that the file was not detected properly. With this fix the file is scanned from the beginning. Change-Id: Idf17d39e3d529394cd4a03d71fb250e69b395533 --- media/java/android/media/MediaScanner.java | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'media') diff --git a/media/java/android/media/MediaScanner.java b/media/java/android/media/MediaScanner.java index 6f8b809..fd37bcf 100644 --- a/media/java/android/media/MediaScanner.java +++ b/media/java/android/media/MediaScanner.java @@ -1399,7 +1399,8 @@ public class MediaScanner long lastModifiedSeconds = file.lastModified() / 1000; if (!MediaFile.isAudioFileType(fileType) && !MediaFile.isVideoFileType(fileType) && - !MediaFile.isImageFileType(fileType) && !MediaFile.isPlayListFileType(fileType)) { + !MediaFile.isImageFileType(fileType) && !MediaFile.isPlayListFileType(fileType) && + !MediaFile.isDrmFileType(fileType)) { // no need to use the media scanner, but we need to update last modified and file size ContentValues values = new ContentValues(); -- cgit v1.1