diff options
| author | 2016-06-01 19:41:46 +0000 | |
|---|---|---|
| committer | 2016-06-01 19:41:50 +0000 | |
| commit | 6510bdeada8b670b1c9863fdb7b518e161105c09 (patch) | |
| tree | dab2436578e1bb5db5217c2dfb5bfcbdc231f099 | |
| parent | 65f1973ba9f91c6727a7131b31b6c563cd880ee0 (diff) | |
| parent | 0789ee09080f8db98349a4a5dd9e0a43da8c675f (diff) | |
Merge "Fix DirectReply bug when reapply fails" into nyc-dev
| -rw-r--r-- | packages/SystemUI/src/com/android/systemui/statusbar/NotificationContentView.java | 20 | ||||
| -rw-r--r-- | packages/SystemUI/src/com/android/systemui/statusbar/policy/RemoteInputView.java | 2 |
2 files changed, 16 insertions, 6 deletions
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/NotificationContentView.java b/packages/SystemUI/src/com/android/systemui/statusbar/NotificationContentView.java index bdbeb2b13498..21fed3c47689 100644 --- a/packages/SystemUI/src/com/android/systemui/statusbar/NotificationContentView.java +++ b/packages/SystemUI/src/com/android/systemui/statusbar/NotificationContentView.java @@ -277,15 +277,25 @@ public class NotificationContentView extends FrameLayout { mContractedChild.animate().cancel(); removeView(mContractedChild); } - mPreviousExpandedRemoteInputIntent = - mExpandedRemoteInput != null ? mExpandedRemoteInput.getPendingIntent() : null; + mPreviousExpandedRemoteInputIntent = null; + if (mExpandedRemoteInput != null) { + mExpandedRemoteInput.onNotificationUpdateOrReset(); + if (mExpandedRemoteInput.isActive()) { + mPreviousExpandedRemoteInputIntent = mExpandedRemoteInput.getPendingIntent(); + } + } if (mExpandedChild != null) { mExpandedChild.animate().cancel(); removeView(mExpandedChild); mExpandedRemoteInput = null; } - mPreviousHeadsUpRemoteInputIntent = - mHeadsUpRemoteInput != null ? mHeadsUpRemoteInput.getPendingIntent() : null; + mPreviousHeadsUpRemoteInputIntent = null; + if (mHeadsUpRemoteInput != null) { + mHeadsUpRemoteInput.onNotificationUpdateOrReset(); + if (mHeadsUpRemoteInput.isActive()) { + mPreviousHeadsUpRemoteInputIntent = mHeadsUpRemoteInput.getPendingIntent(); + } + } if (mHeadsUpChild != null) { mHeadsUpChild.animate().cancel(); removeView(mHeadsUpChild); @@ -910,7 +920,7 @@ public class NotificationContentView extends FrameLayout { view.findViewWithTag(RemoteInputView.VIEW_TAG); if (existing != null) { - existing.onNotificationUpdate(); + existing.onNotificationUpdateOrReset(); } if (existing == null && hasRemoteInput) { diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/policy/RemoteInputView.java b/packages/SystemUI/src/com/android/systemui/statusbar/policy/RemoteInputView.java index 40ff05124644..7704a07449ac 100644 --- a/packages/SystemUI/src/com/android/systemui/statusbar/policy/RemoteInputView.java +++ b/packages/SystemUI/src/com/android/systemui/statusbar/policy/RemoteInputView.java @@ -227,7 +227,7 @@ public class RemoteInputView extends LinearLayout implements View.OnClickListene updateSendButton(); } - public void onNotificationUpdate() { + public void onNotificationUpdateOrReset() { boolean sending = mProgressBar.getVisibility() == VISIBLE; if (sending) { |