Chromium Code Reviews| Index: chrome/android/java/src/org/chromium/chrome/browser/payments/AddressEditor.java |
| diff --git a/chrome/android/java/src/org/chromium/chrome/browser/payments/AddressEditor.java b/chrome/android/java/src/org/chromium/chrome/browser/payments/AddressEditor.java |
| index 804186b826fa310271e1c379236ff673cd97a597..792c7968c051e0c0ba4cd70d24790404a04d00f7 100644 |
| --- a/chrome/android/java/src/org/chromium/chrome/browser/payments/AddressEditor.java |
| +++ b/chrome/android/java/src/org/chromium/chrome/browser/payments/AddressEditor.java |
| @@ -123,6 +123,7 @@ public class AddressEditor |
| mEditor.removeAllFields(); |
| showProgressDialog(); |
| mRecentlySelectedCountry = eventData.first; |
| + mEditorDialog.updateCountryOfPhoneFormatter(mRecentlySelectedCountry); |
| mCountryChangeCallback = eventData.second; |
| loadAdminAreasForCountry(mRecentlySelectedCountry); |
| } |
| @@ -395,7 +396,9 @@ public class AddressEditor |
| mPhoneValidator = new EditorFieldValidator() { |
| @Override |
| public boolean isValid(@Nullable CharSequence value) { |
| - return value != null && PhoneNumberUtil.isValidNumber(value.toString()); |
| + return value != null |
| + && PhoneNumberUtil.isValidNumber( |
| + value.toString(), mRecentlySelectedCountry); |
|
gogerald1
2017/06/08 16:20:43
mRecentlySelectedCountry is null if the user doesn
wuandy1
2017/06/08 20:34:58
Which is handled by isValidNumber..do you mean a @
gogerald1
2017/06/09 13:33:46
NO, the selected country is set according to profi
wuandy1
2017/06/12 14:15:25
ok i see. what is your suggestion then?
gogerald1
2017/06/12 17:02:11
What about using 'mCountryField.getValue().toStrin
wuandy1
2017/06/13 19:47:25
Done.
|
| } |
| @Override |