summaryrefslogtreecommitdiff
path: root/java/com/android/dialer/app
diff options
context:
space:
mode:
authoruabdullah <uabdullah@google.com>2018-03-29 17:19:55 -0700
committerCopybara-Service <copybara-piper@google.com>2018-03-29 18:04:33 -0700
commit0afd6bab1c6d1111a23802ff7381e3b4694c92e3 (patch)
tree2b38c47cb45202e672c20fb4855c2421f3eede42 /java/com/android/dialer/app
parent26bc51ec4b3cbf88c334f1ed8e23ccf458b8b933 (diff)
Update what happens when donation is rejected & use correct donation availability check
Checking donation is not a simple config check, but everything that donation availability is dependent on via the isVoicemailDonationAvailable() helper method. We update the code accordingly. When the user declines the promo for donation, we should also update the toggle accordingly. Bug: 74033229 Test: N/A PiperOrigin-RevId: 191011808 Change-Id: I6e4ff9914355deed72175179fc7b9009f2395ef5
Diffstat (limited to 'java/com/android/dialer/app')
-rw-r--r--java/com/android/dialer/app/calllog/PhoneCallDetailsHelper.java3
1 files changed, 3 insertions, 0 deletions
diff --git a/java/com/android/dialer/app/calllog/PhoneCallDetailsHelper.java b/java/com/android/dialer/app/calllog/PhoneCallDetailsHelper.java
index 096488a39..680424a78 100644
--- a/java/com/android/dialer/app/calllog/PhoneCallDetailsHelper.java
+++ b/java/com/android/dialer/app/calllog/PhoneCallDetailsHelper.java
@@ -356,6 +356,9 @@ public class PhoneCallDetailsHelper
new DialogInterface.OnClickListener() {
@Override
public void onClick(final DialogInterface dialog, final int button) {
+ VoicemailComponent.get(context)
+ .getVoicemailClient()
+ .setVoicemailDonationEnabled(context, details.accountHandle, false);
dialog.cancel();
recordPromoShown(context);
ratingView.setVisibility(View.GONE);