summaryrefslogtreecommitdiff
path: root/src/com/android/dialer/service
diff options
context:
space:
mode:
authorGilles Franck Mevaa <gillesd@google.com>2016-03-02 12:08:03 -0800
committerGilles Franck Mevaa <gillesd@google.com>2016-03-02 15:48:50 -0800
commit9228d4a260961807329cc9187d21ab35ae2c097e (patch)
tree6f3c265b108a32c206a16b299d4d06b2aa20af6e /src/com/android/dialer/service
parent24c02ee4ecee7607ce014022b9a3950350c7cad9 (diff)
CallLogListItemViewHolder distinguishes block/spam numbers
A new method is added to show the appropriate photo and label if the number is either blocked or spam. This occurs after the normal photo and labels are rendered. Because of that, there is a flickering if the photo and labels should be changed. b/27295728 will help track the fix of the flickering bug. Change-Id: I639c0c0d4167b48956892f2b955d4e1f0cc8e8eb
Diffstat (limited to 'src/com/android/dialer/service')
-rw-r--r--src/com/android/dialer/service/ExtendedBlockingButtonRenderer.java13
1 files changed, 13 insertions, 0 deletions
diff --git a/src/com/android/dialer/service/ExtendedBlockingButtonRenderer.java b/src/com/android/dialer/service/ExtendedBlockingButtonRenderer.java
index 5ff373288..f8d5ea048 100644
--- a/src/com/android/dialer/service/ExtendedBlockingButtonRenderer.java
+++ b/src/com/android/dialer/service/ExtendedBlockingButtonRenderer.java
@@ -19,6 +19,8 @@ package com.android.dialer.service;
import android.support.annotation.Nullable;
import android.view.View;
import android.view.ViewStub;
+import android.widget.QuickContactBadge;
+import android.widget.TextView;
import java.util.List;
@@ -70,4 +72,15 @@ public interface ExtendedBlockingButtonRenderer {
void render(ViewStub viewStub);
void setViewHolderInfo(ViewHolderInfo info);
+
+ /**
+ * Updates the photo and label for the given phone number and country iso.
+ *
+ * @param number Phone number for which the rendering occurs.
+ * @param countryIso Two-letter country code.
+ * @param badge {@link QuickContactBadge} in which the photo should be rendered.
+ * @param view Textview that will hold the new label.
+ */
+ void updatePhotoAndLabelIfNecessary(
+ String number, String countryIso, QuickContactBadge badge, TextView view);
}