aboutsummaryrefslogtreecommitdiffstats
path: root/main
diff options
context:
space:
mode:
authorSamuel Tardieu <sam@rfc1149.net>2011-09-26 18:18:21 +0200
committerSamuel Tardieu <sam@rfc1149.net>2011-09-26 18:18:21 +0200
commit739ee51692607bdbbe2514eb49cf14fe49bb3268 (patch)
tree7b133eba3b55c1e30fb5bdab58be34187d878240 /main
parent73f98cce3ea4358873b997b7cc91613351dc6a66 (diff)
downloadcgeo-739ee51692607bdbbe2514eb49cf14fe49bb3268.zip
cgeo-739ee51692607bdbbe2514eb49cf14fe49bb3268.tar.gz
cgeo-739ee51692607bdbbe2514eb49cf14fe49bb3268.tar.bz2
Initialize field in constructor
This lets the field initialization be near its customization.
Diffstat (limited to 'main')
-rw-r--r--main/src/cgeo/geocaching/cgHtmlImg.java3
1 files changed, 2 insertions, 1 deletions
diff --git a/main/src/cgeo/geocaching/cgHtmlImg.java b/main/src/cgeo/geocaching/cgHtmlImg.java
index 9952481..880d5b4 100644
--- a/main/src/cgeo/geocaching/cgHtmlImg.java
+++ b/main/src/cgeo/geocaching/cgHtmlImg.java
@@ -36,7 +36,7 @@ public class cgHtmlImg implements Html.ImageGetter {
final private int reason;
final private boolean onlySave;
final private boolean save;
- final private BitmapFactory.Options bfOptions = new BitmapFactory.Options();
+ final private BitmapFactory.Options bfOptions;
final private Display display;
final private int maxWidth;
final private int maxHeight;
@@ -53,6 +53,7 @@ public class cgHtmlImg implements Html.ImageGetter {
onlySave = onlySaveIn;
save = saveIn;
+ bfOptions = new BitmapFactory.Options();
bfOptions.inTempStorage = new byte[16 * 1024];
display = ((WindowManager) activity.getSystemService(Context.WINDOW_SERVICE)).getDefaultDisplay();