format phone number with narrow non-breaking space
This commit is contained in:
parent
6ecf6f1149
commit
91db13b01b
|
@ -151,7 +151,7 @@ public class EnterPhoneNumberActivity extends XmppActivity implements QuickConve
|
|||
this.binding.countryCode.setText(String.valueOf(phoneNumber.getCountryCode()));
|
||||
number.clear();
|
||||
number.append(String.valueOf(phoneNumber.getNationalNumber()));
|
||||
final String formattedPhoneNumber = PhoneNumberUtilWrapper.getInstance(this).format(phoneNumber, PhoneNumberUtil.PhoneNumberFormat.INTERNATIONAL);
|
||||
final String formattedPhoneNumber = PhoneNumberUtilWrapper.getInstance(this).format(phoneNumber, PhoneNumberUtil.PhoneNumberFormat.INTERNATIONAL).replace(' ','\u202F');
|
||||
|
||||
if (PhoneNumberUtilWrapper.getInstance(this).isValidNumber(phoneNumber)) {
|
||||
builder.setMessage(Html.fromHtml(getString(R.string.we_will_be_verifying, formattedPhoneNumber)));
|
||||
|
|
|
@ -24,7 +24,7 @@ public class PhoneNumberUtilWrapper {
|
|||
|
||||
public static String toFormattedPhoneNumber(Context context, Jid jid) {
|
||||
try {
|
||||
return getInstance(context).format(toPhoneNumber(context, jid), PhoneNumberUtil.PhoneNumberFormat.INTERNATIONAL);
|
||||
return getInstance(context).format(toPhoneNumber(context, jid), PhoneNumberUtil.PhoneNumberFormat.INTERNATIONAL).replace(' ','\u202F');
|
||||
} catch (Exception e) {
|
||||
return jid.getEscapedLocal();
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue