summaryrefslogtreecommitdiff
path: root/src/com/android/bitmap/drawable/BasicBitmapDrawable.java
diff options
context:
space:
mode:
authorSam Blitzstein <sblitz@google.com>2013-10-16 12:12:54 -0700
committerSam Blitzstein <sblitz@google.com>2013-10-16 15:16:43 -0700
commit40662f4b39e795d9c64502b13036e7c37fa2d373 (patch)
tree9caf8aa9e550d9d03e167a6fd519bcf5b6b5a138 /src/com/android/bitmap/drawable/BasicBitmapDrawable.java
parent93a35b93dc582e38ff8ee5979754a16b4bf4da0c (diff)
downloadbitmap-40662f4b39e795d9c64502b13036e7c37fa2d373.tar.gz
Change BitmapRequestKey to be more cleanly implementable.
Change-Id: I831586688605e6c6c2f2f7a879c6be23175f71de
Diffstat (limited to 'src/com/android/bitmap/drawable/BasicBitmapDrawable.java')
-rw-r--r--src/com/android/bitmap/drawable/BasicBitmapDrawable.java16
1 files changed, 8 insertions, 8 deletions
diff --git a/src/com/android/bitmap/drawable/BasicBitmapDrawable.java b/src/com/android/bitmap/drawable/BasicBitmapDrawable.java
index b16618b..2aa6011 100644
--- a/src/com/android/bitmap/drawable/BasicBitmapDrawable.java
+++ b/src/com/android/bitmap/drawable/BasicBitmapDrawable.java
@@ -27,7 +27,7 @@ import android.util.Log;
import com.android.bitmap.BitmapCache;
import com.android.bitmap.DecodeTask;
-import com.android.bitmap.DecodeTask.Request;
+import com.android.bitmap.RequestKey;
import com.android.bitmap.ReusableBitmap;
import com.android.bitmap.util.BitmapUtils;
import com.android.bitmap.util.RectUtils;
@@ -47,7 +47,7 @@ import java.util.concurrent.TimeUnit;
public class BasicBitmapDrawable extends Drawable implements DecodeTask.DecodeCallback,
Drawable.Callback {
- private BitmapRequestKey mCurrKey;
+ private RequestKey mCurrKey;
private ReusableBitmap mBitmap;
private final BitmapCache mCache;
private DecodeTask mTask;
@@ -81,7 +81,7 @@ public class BasicBitmapDrawable extends Drawable implements DecodeTask.DecodeCa
mPaint.setFilterBitmap(true);
}
- public DecodeTask.Request getKey() {
+ public RequestKey getKey() {
return mCurrKey;
}
@@ -98,11 +98,11 @@ public class BasicBitmapDrawable extends Drawable implements DecodeTask.DecodeCa
setImage(null);
}
- public void bind(BitmapRequestKey key) {
+ public void bind(RequestKey key) {
setImage(key);
}
- private void setImage(final BitmapRequestKey key) {
+ private void setImage(final RequestKey key) {
if (mCurrKey != null && mCurrKey.equals(key)) {
return;
}
@@ -201,10 +201,10 @@ public class BasicBitmapDrawable extends Drawable implements DecodeTask.DecodeCa
}
@Override
- public void onDecodeBegin(final Request key) { }
+ public void onDecodeBegin(final RequestKey key) { }
@Override
- public void onDecodeComplete(final Request key, final ReusableBitmap result) {
+ public void onDecodeComplete(final RequestKey key, final ReusableBitmap result) {
if (key.equals(mCurrKey)) {
setBitmap(result);
} else {
@@ -217,7 +217,7 @@ public class BasicBitmapDrawable extends Drawable implements DecodeTask.DecodeCa
}
@Override
- public void onDecodeCancel(final Request key) { }
+ public void onDecodeCancel(final RequestKey key) { }
private void setBitmap(ReusableBitmap bmp) {
if (mBitmap != null && mBitmap != bmp) {