Show warning message before changing phone number.

This commit is contained in:
John Preston 2017-03-23 17:58:28 +03:00
parent be659e2611
commit 0ce6e8a33a
1 changed files with 4 additions and 2 deletions

View File

@ -304,8 +304,10 @@ bool ChangePhoneBox::EnterCode::sendCodeFail(const RPCError &error) {
void ChangePhoneBox::prepare() {
setTitle(lang(lng_change_phone_title));
addButton(lang(lng_change_phone_button), [this] {
Ui::show(Box<EnterPhone>());
addButton(lang(lng_change_phone_button), [] {
Ui::show(Box<ConfirmBox>(lang(lng_change_phone_warning), [] {
Ui::show(Box<EnterPhone>());
}));
});
addButton(lang(lng_cancel), [this] {
closeBox();