summaryrefslogtreecommitdiff
path: root/src/com/android
diff options
context:
space:
mode:
authorSailesh Nepal <sail@google.com>2016-06-01 23:06:50 +0000
committerandroid-build-merger <android-build-merger@google.com>2016-06-01 23:06:50 +0000
commitbef81166d9a65469aff4b116e20d2c59777de95c (patch)
tree79aa06b7707b898d6136342840c1467a1d773a48 /src/com/android
parent77458db0b98fa3f1f21aa7cda594c8e5f34fe06d (diff)
parent30371b9022d0b3740c74523208a9126b9890dab4 (diff)
Fix missed call notification dialing wrong number
am: 30371b9022 * commit '30371b9022d0b3740c74523208a9126b9890dab4': Fix missed call notification dialing wrong number Change-Id: Ic234f26998193e848c80f9763f585f7de36050e3
Diffstat (limited to 'src/com/android')
-rw-r--r--src/com/android/dialer/calllog/MissedCallNotifier.java10
1 files changed, 6 insertions, 4 deletions
diff --git a/src/com/android/dialer/calllog/MissedCallNotifier.java b/src/com/android/dialer/calllog/MissedCallNotifier.java
index 20fc5d551..f6830168b 100644
--- a/src/com/android/dialer/calllog/MissedCallNotifier.java
+++ b/src/com/android/dialer/calllog/MissedCallNotifier.java
@@ -254,8 +254,9 @@ public class MissedCallNotifier {
intent.setAction(
CallLogNotificationsService.ACTION_CALL_BACK_FROM_MISSED_CALL_NOTIFICATION);
intent.putExtra(CallLogNotificationsService.EXTRA_MISSED_CALL_NUMBER, number);
- // Use FLAG_ONE_SHOT to avoid reusing previous PendingIntent with different number.
- return PendingIntent.getService(mContext, 0, intent, PendingIntent.FLAG_ONE_SHOT);
+ // Use FLAG_UPDATE_CURRENT to make sure any previous pending intent is updated with the new
+ // extra.
+ return PendingIntent.getService(mContext, 0, intent, PendingIntent.FLAG_UPDATE_CURRENT);
}
private PendingIntent createSendSmsFromNotificationPendingIntent(String number) {
@@ -263,8 +264,9 @@ public class MissedCallNotifier {
intent.setAction(
CallLogNotificationsService.ACTION_SEND_SMS_FROM_MISSED_CALL_NOTIFICATION);
intent.putExtra(CallLogNotificationsService.EXTRA_MISSED_CALL_NUMBER, number);
- // Use FLAG_ONE_SHOT to avoid reusing previous PendingIntent with different number.
- return PendingIntent.getService(mContext, 0, intent, PendingIntent.FLAG_ONE_SHOT);
+ // Use FLAG_UPDATE_CURRENT to make sure any previous pending intent is updated with the new
+ // extra.
+ return PendingIntent.getService(mContext, 0, intent, PendingIntent.FLAG_UPDATE_CURRENT);
}
/**