Loading src/com/android/gallery3d/app/AbstractGalleryActivity.java +2 −2 Original line number Diff line number Diff line Loading @@ -67,7 +67,7 @@ public abstract class AbstractGalleryActivity extends AbstractPermissionActivity private BroadcastReceiver mMountReceiver = new BroadcastReceiver() { @Override public void onReceive(Context context, Intent intent) { if (getExternalCacheDir() != null) onStorageReady(); if (getCacheDir() != null) onStorageReady(); } }; private IntentFilter mMountFilter = new IntentFilter(Intent.ACTION_MEDIA_MOUNTED); Loading Loading @@ -156,7 +156,7 @@ public abstract class AbstractGalleryActivity extends AbstractPermissionActivity @Override protected void onStart() { super.onStart(); if (getExternalCacheDir() == null) { if (getCacheDir() == null) { OnCancelListener onCancel = new OnCancelListener() { @Override public void onCancel(DialogInterface dialog) { Loading src/com/android/gallery3d/app/GalleryAppImpl.java +1 −1 Original line number Diff line number Diff line Loading @@ -96,7 +96,7 @@ public class GalleryAppImpl extends Application implements GalleryApp { @Override public synchronized DownloadCache getDownloadCache() { if (mDownloadCache == null) { File cacheDir = new File(getExternalCacheDir(), DOWNLOAD_FOLDER); File cacheDir = new File(getCacheDir(), DOWNLOAD_FOLDER); if (!cacheDir.isDirectory()) cacheDir.mkdirs(); Loading src/com/android/gallery3d/ui/CacheStorageUsageInfo.java +1 −1 Original line number Diff line number Diff line Loading @@ -54,7 +54,7 @@ public class CacheStorageUsageInfo { } public void loadStorageInfo(JobContext jc) { File cacheDir = mContext.getExternalCacheDir(); File cacheDir = mContext.getCacheDir(); if (cacheDir == null) { cacheDir = mContext.getCacheDir(); } Loading src/com/android/gallery3d/util/CacheManager.java +2 −2 Original line number Diff line number Diff line Loading @@ -45,7 +45,7 @@ public class CacheManager { } BlobCache cache = sCacheMap.get(filename); if (cache == null) { File cacheDir = context.getExternalCacheDir(); File cacheDir = context.getCacheDir(); String path = cacheDir.getAbsolutePath() + "/" + filename; try { cache = new BlobCache(path, maxEntries, maxBytes, false, Loading @@ -72,7 +72,7 @@ public class CacheManager { if (n != 0) return; pref.edit().putInt(KEY_CACHE_UP_TO_DATE, 1).commit(); File cacheDir = context.getExternalCacheDir(); File cacheDir = context.getCacheDir(); String prefix = cacheDir.getAbsolutePath() + "/"; BlobCache.deleteFiles(prefix + "imgcache"); Loading Loading
src/com/android/gallery3d/app/AbstractGalleryActivity.java +2 −2 Original line number Diff line number Diff line Loading @@ -67,7 +67,7 @@ public abstract class AbstractGalleryActivity extends AbstractPermissionActivity private BroadcastReceiver mMountReceiver = new BroadcastReceiver() { @Override public void onReceive(Context context, Intent intent) { if (getExternalCacheDir() != null) onStorageReady(); if (getCacheDir() != null) onStorageReady(); } }; private IntentFilter mMountFilter = new IntentFilter(Intent.ACTION_MEDIA_MOUNTED); Loading Loading @@ -156,7 +156,7 @@ public abstract class AbstractGalleryActivity extends AbstractPermissionActivity @Override protected void onStart() { super.onStart(); if (getExternalCacheDir() == null) { if (getCacheDir() == null) { OnCancelListener onCancel = new OnCancelListener() { @Override public void onCancel(DialogInterface dialog) { Loading
src/com/android/gallery3d/app/GalleryAppImpl.java +1 −1 Original line number Diff line number Diff line Loading @@ -96,7 +96,7 @@ public class GalleryAppImpl extends Application implements GalleryApp { @Override public synchronized DownloadCache getDownloadCache() { if (mDownloadCache == null) { File cacheDir = new File(getExternalCacheDir(), DOWNLOAD_FOLDER); File cacheDir = new File(getCacheDir(), DOWNLOAD_FOLDER); if (!cacheDir.isDirectory()) cacheDir.mkdirs(); Loading
src/com/android/gallery3d/ui/CacheStorageUsageInfo.java +1 −1 Original line number Diff line number Diff line Loading @@ -54,7 +54,7 @@ public class CacheStorageUsageInfo { } public void loadStorageInfo(JobContext jc) { File cacheDir = mContext.getExternalCacheDir(); File cacheDir = mContext.getCacheDir(); if (cacheDir == null) { cacheDir = mContext.getCacheDir(); } Loading
src/com/android/gallery3d/util/CacheManager.java +2 −2 Original line number Diff line number Diff line Loading @@ -45,7 +45,7 @@ public class CacheManager { } BlobCache cache = sCacheMap.get(filename); if (cache == null) { File cacheDir = context.getExternalCacheDir(); File cacheDir = context.getCacheDir(); String path = cacheDir.getAbsolutePath() + "/" + filename; try { cache = new BlobCache(path, maxEntries, maxBytes, false, Loading @@ -72,7 +72,7 @@ public class CacheManager { if (n != 0) return; pref.edit().putInt(KEY_CACHE_UP_TO_DATE, 1).commit(); File cacheDir = context.getExternalCacheDir(); File cacheDir = context.getCacheDir(); String prefix = cacheDir.getAbsolutePath() + "/"; BlobCache.deleteFiles(prefix + "imgcache"); Loading