diff options
author | mdooley <mdooley@google.com> | 2017-10-04 10:16:46 -0700 |
---|---|---|
committer | Eric Erfanian <erfanian@google.com> | 2017-10-04 16:00:35 -0700 |
commit | cb52c4c1358add154fc7532f368893166247da9b (patch) | |
tree | 431922dcf2a0672fb82e033f39c32a59aa50bf89 /java/com/android/dialer/app/voicemail/error/VoicemailTosMessageCreator.java | |
parent | bc07ed7f31845b0565990999e90510c90e8dad9b (diff) |
Remove 'learn more' link from verizon voicemail TOS text
and using non-breaking space in dialer TOS 'learn more' link.
screen shots:
https://drive.google.com/open?id=0B9o_KvtLkcuIV3BWWmxSTTlJQ2dBTnR2UHRGWjZJRlFQUGo0
https://drive.google.com/open?id=0B9o_KvtLkcuIOEJjanVhMXlfck81aU02Y0I2MkVtWFNOVGp3
Bug: 67379747
Test: manual and updated unit tests
PiperOrigin-RevId: 171025914
Change-Id: I9c4bfd899805681492a5063ee1bc674bbb98f630
Diffstat (limited to 'java/com/android/dialer/app/voicemail/error/VoicemailTosMessageCreator.java')
-rw-r--r-- | java/com/android/dialer/app/voicemail/error/VoicemailTosMessageCreator.java | 22 |
1 files changed, 12 insertions, 10 deletions
diff --git a/java/com/android/dialer/app/voicemail/error/VoicemailTosMessageCreator.java b/java/com/android/dialer/app/voicemail/error/VoicemailTosMessageCreator.java index a2b82c0fc..63ebd1959 100644 --- a/java/com/android/dialer/app/voicemail/error/VoicemailTosMessageCreator.java +++ b/java/com/android/dialer/app/voicemail/error/VoicemailTosMessageCreator.java @@ -304,10 +304,12 @@ public class VoicemailTosMessageCreator { return ""; } - String learnMoreText = context.getString(R.string.dialer_terms_and_conditions_learn_more); - return isVvm3() - ? context.getString(R.string.dialer_terms_and_conditions_for_verizon_1_0, learnMoreText) - : context.getString(R.string.dialer_terms_and_conditions_1_0, learnMoreText); + if (isVvm3()) { + return context.getString(R.string.dialer_terms_and_conditions_for_verizon_1_0); + } else { + String learnMoreText = context.getString(R.string.dialer_terms_and_conditions_learn_more); + return context.getString(R.string.dialer_terms_and_conditions_1_0, learnMoreText); + } } private CharSequence getAcceptText() { @@ -359,7 +361,7 @@ public class VoicemailTosMessageCreator { Spanned.SPAN_EXCLUSIVE_EXCLUSIVE); // Add verizon policy link String linkUrl = context.getString(R.string.verizon_terms_and_conditions_policy_url); - addLink(spannableTos, linkUrl, linkUrl); + return addLink(spannableTos, linkUrl, linkUrl); } else { // The TOS for everyone else, there are no details, but change to center alignment. CharSequence tos = @@ -370,12 +372,12 @@ public class VoicemailTosMessageCreator { 0, tos.length(), Spanned.SPAN_EXCLUSIVE_EXCLUSIVE); - } - // Add 'Learn more' link for dialer TOS - String learnMore = context.getString(R.string.dialer_terms_and_conditions_learn_more); - String linkUrl = context.getString(R.string.dialer_terms_and_conditions_learn_more_url); - return addLink(spannableTos, learnMore, linkUrl); + // Add 'Learn more' link for dialer TOS + String learnMore = context.getString(R.string.dialer_terms_and_conditions_learn_more); + String linkUrl = context.getString(R.string.dialer_terms_and_conditions_learn_more_url); + return addLink(spannableTos, learnMore, linkUrl); + } } private SpannableString addLink(SpannableString spannable, String linkText, String linkUrl) { |