mirror of
https://github.com/commons-app/apps-android-commons.git
synced 2025-10-27 04:43:54 +01:00
Final touch-ups to improved image loading.
This commit is contained in:
parent
7a4062a377
commit
38e7cad345
9 changed files with 44 additions and 33 deletions
|
|
@ -11,6 +11,7 @@ import android.content.pm.PackageManager;
|
|||
import android.os.Build;
|
||||
import android.database.sqlite.SQLiteDatabase;
|
||||
import android.preference.PreferenceManager;
|
||||
import android.support.v4.util.LruCache;
|
||||
|
||||
import com.facebook.drawee.backends.pipeline.Fresco;
|
||||
import com.facebook.stetho.Stetho;
|
||||
|
|
@ -84,6 +85,7 @@ public class CommonsApplication extends Application {
|
|||
private static CommonsApplication instance = null;
|
||||
private AbstractHttpClient httpClient = null;
|
||||
private MWApi api = null;
|
||||
LruCache<String, String> thumbnailUrlCache = new LruCache<>(1024);
|
||||
private CacheController cacheData = null;
|
||||
private DBOpenHelper dbOpenHelper = null;
|
||||
private NearbyPlaces nearbyPlaces = null;
|
||||
|
|
@ -139,6 +141,10 @@ public class CommonsApplication extends Application {
|
|||
return cacheData;
|
||||
}
|
||||
|
||||
public LruCache<String, String> getThumbnailUrlCache() {
|
||||
return thumbnailUrlCache;
|
||||
}
|
||||
|
||||
public synchronized DBOpenHelper getDBOpenHelper() {
|
||||
if (dbOpenHelper == null) {
|
||||
dbOpenHelper = new DBOpenHelper(this);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue