From 27732cc0db32239feac8cbb0be4ff19a6440e8c7 Mon Sep 17 00:00:00 2001 From: Selim Cinek Date: Tue, 29 May 2018 17:01:05 -0700 Subject: [PATCH] Fixed an issue where the reply icon was disabled Because it was disabled by an earlier update, a subsequent update needs to enable the reply icon again, as the pending intent might be valid again. Change-Id: Ic562b399184e37c3870e1da7dc5d15baca43dc54 Fixes: 80250615 Test: add multiple messages where each one cancels the previous pendinging intent, observe clickable reply icon --- .../notification/NotificationTemplateViewWrapper.java | 3 +++ 1 file changed, 3 insertions(+) diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/notification/NotificationTemplateViewWrapper.java b/packages/SystemUI/src/com/android/systemui/statusbar/notification/NotificationTemplateViewWrapper.java index 03791c7f91ea3..91a4dda5a2817 100644 --- a/packages/SystemUI/src/com/android/systemui/statusbar/notification/NotificationTemplateViewWrapper.java +++ b/packages/SystemUI/src/com/android/systemui/statusbar/notification/NotificationTemplateViewWrapper.java @@ -182,6 +182,9 @@ public class NotificationTemplateViewWrapper extends NotificationHeaderViewWrapp } } if (mReplyAction != null) { + // Let's reset the view on update, assuming the new pending intent isn't cancelled + // anymore. The color filter automatically resets when it's updated. + mReplyAction.setEnabled(true); performOnPendingIntentCancellation(mReplyAction, () -> { if (mReplyAction != null && mReplyAction.isEnabled()) { mReplyAction.setEnabled(false);