merge from froyo-plus-aosp
Change-Id: Ibaa84571e3b5a7ea29e55d41f773aa5f301086de
This commit is contained in:
@@ -1215,8 +1215,12 @@ public class MediaScanner
|
|||||||
prescan(path);
|
prescan(path);
|
||||||
|
|
||||||
File file = new File(path);
|
File file = new File(path);
|
||||||
|
|
||||||
|
// lastModified is in milliseconds on Files.
|
||||||
|
long lastModifiedSeconds = file.lastModified() / 1000;
|
||||||
|
|
||||||
// always scan the file, so we can return the content://media Uri for existing files
|
// always scan the file, so we can return the content://media Uri for existing files
|
||||||
return mClient.doScanFile(path, mimeType, file.lastModified(), file.length(), true);
|
return mClient.doScanFile(path, mimeType, lastModifiedSeconds, file.length(), true);
|
||||||
} catch (RemoteException e) {
|
} catch (RemoteException e) {
|
||||||
Log.e(TAG, "RemoteException in MediaScanner.scanFile()", e);
|
Log.e(TAG, "RemoteException in MediaScanner.scanFile()", e);
|
||||||
return null;
|
return null;
|
||||||
|
|||||||
Reference in New Issue
Block a user