Add media scan config

This commit is contained in:
seven332 committed 2016-04-08 20:28:05 +08:00
1 parent 97c28c04c5
commit a2a9dbcb02
9 files changed
+74 -9

No files matched your search

@@ -559,7 +559,18 @@ public class Settings {
putString(KEY_DOWNLOAD_SAVE_QUERY, uri.getEncodedQuery());
putString(KEY_DOWNLOAD_SAVE_FRAGMENT, uri.getEncodedFragment());
CommonOperations.ensureNoMediaFile(location);
if (getMediaScan()) {
CommonOperations.removeNoMediaFile(location);
} else {
CommonOperations.ensureNoMediaFile(location);
}
}
public static final String KEY_MEDIA_SCAN = "media_scan";
private static final boolean DEFAULT_MEDIA_SCAN = false;
public static boolean getMediaScan() {
return getBoolean(KEY_MEDIA_SCAN, DEFAULT_MEDIA_SCAN);
}
private static final String KEY_RECENT_DOWNLOAD_LABEL = "recent_download_label";