am 6d9ac11a: am b99d53b9: am 53e9490f: am 64fd7253: Merge "Fix wrong color in ContactDrawable" into ub-gmail-ur14-dev
* commit '6d9ac11a9a5df6c8ee922f0eae3c244181c93fb9':
Fix wrong color in ContactDrawable
diff --git a/src/com/android/mail/bitmap/ContactDrawable.java b/src/com/android/mail/bitmap/ContactDrawable.java
index badcc12..0102b5e 100644
--- a/src/com/android/mail/bitmap/ContactDrawable.java
+++ b/src/com/android/mail/bitmap/ContactDrawable.java
@@ -31,11 +31,12 @@
*/
public class ContactDrawable extends AbstractAvatarDrawable {
/** Letter tile */
- private static ColorPicker sTileColorPicker;
+ private ColorPicker mTileColorPicker;
+
+ /** Reusable components to avoid new allocations */
private static int sTileLetterFontSize;
private static int sTileFontColor;
private static Bitmap DEFAULT_AVATAR;
- /** Reusable components to avoid new allocations */
private static final Paint sPaint = new Paint();
private static final Rect sRect = new Rect();
private static final char[] sFirstChar = new char[1];
@@ -58,8 +59,8 @@
* Sets the {@link ColorPicker} for the background tile used in letter avatars.
* @param colorPicker
*/
- public static void setTileColorPicker(ColorPicker colorPicker) {
- sTileColorPicker = colorPicker;
+ public void setTileColorPicker(ColorPicker colorPicker) {
+ mTileColorPicker = colorPicker;
}
/**
@@ -68,10 +69,10 @@
* @return non-null color picker.
*/
public ColorPicker getTileColorPicker() {
- if (sTileColorPicker == null) {
- sTileColorPicker = new ColorPicker.PaletteColorPicker(mResources);
+ if (mTileColorPicker == null) {
+ mTileColorPicker = new ColorPicker.PaletteColorPicker(mResources);
}
- return sTileColorPicker;
+ return mTileColorPicker;
}
@Override