diff options
author | Rohit Yengisetty <rohit@cyngn.com> | 2016-06-15 15:18:37 -0700 |
---|---|---|
committer | Rohit Yengisetty <rohit@cyngn.com> | 2016-06-15 15:18:37 -0700 |
commit | 7a3316a2bf0d6187cbc870be6ade5d1667d7e6b7 (patch) | |
tree | 8aa3b0e69f3fb766a551b1a2796831fdb68c545c | |
parent | 91468b06102614c4eff14bcb45fcbff90c3c79f6 (diff) | |
download | android_packages_apps_InCallUI-7a3316a2bf0d6187cbc870be6ade5d1667d7e6b7.tar.gz android_packages_apps_InCallUI-7a3316a2bf0d6187cbc870be6ade5d1667d7e6b7.tar.bz2 android_packages_apps_InCallUI-7a3316a2bf0d6187cbc870be6ade5d1667d7e6b7.zip |
Explicitly set the visibility of right_icon within call notification
The right icon within the notification at times had the wrong visibility
state. This led to the contact attribution badge not showing up at times.
This could be the result of a series of notification state updates due to
the state change callbacks via ContactInfoCache. Resorting to explicitly
updating the view's visibility.
Change-Id: I447a1a4dc08ee8b6bba5569c7a1bb91d7677bd15
Issue-Id: OPO-766
-rw-r--r-- | src/com/android/incallui/StatusBarNotifier.java | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/com/android/incallui/StatusBarNotifier.java b/src/com/android/incallui/StatusBarNotifier.java index 0595bf14..3b5ad7e1 100644 --- a/src/com/android/incallui/StatusBarNotifier.java +++ b/src/com/android/incallui/StatusBarNotifier.java @@ -41,6 +41,7 @@ import android.telephony.SubscriptionManager; import android.telephony.TelephonyManager; import android.text.TextUtils; +import android.view.View; import android.widget.RemoteViews; import com.android.contacts.common.util.BitmapUtil; import com.android.incallui.ContactInfoCache.ContactCacheEntry; @@ -316,7 +317,7 @@ public class StatusBarNotifier implements InCallPresenter.InCallStateListener, notification.headsUpContentView}; // add LookupProvider badge to Notification Drawable logo = contactInfo.lookupProviderBadge; - if (largeIcon != null && logo != null) { + if (logo != null) { Bitmap bitmap = null; if (logo instanceof BitmapDrawable) { bitmap = ((BitmapDrawable) logo).getBitmap(); @@ -330,6 +331,7 @@ public class StatusBarNotifier implements InCallPresenter.InCallStateListener, int spamColor = mContext.getResources().getColor(R.color.spam_contact_color); for (RemoteViews view : viewsToUpdate) { int rightIconId = getNotificationRightIconId(mContext); + view.setViewVisibility(rightIconId, View.VISIBLE); view.setImageViewBitmap(rightIconId, bitmap); view.setViewPadding(rightIconId, 0, 0, 0, 0); if (contactInfo.isSpam) { |