mirror of
https://github.com/AyuGram/AyuGramDesktop.git
synced 2026-07-25 06:54:43 +00:00
Moved ConfirmBox to Ui namespace.
This commit is contained in:
@@ -106,7 +106,8 @@ void AddParticipantsBoxController::rowClicked(not_null<PeerListRow*> row) {
|
||||
} else if (count >= serverConfig.chatSizeMax
|
||||
&& count < serverConfig.megagroupSizeMax) {
|
||||
Ui::show(
|
||||
Box<InformBox>(tr::lng_profile_add_more_after_create(tr::now)),
|
||||
Box<Ui::InformBox>(
|
||||
tr::lng_profile_add_more_after_create(tr::now)),
|
||||
Ui::LayerOption::KeepOther);
|
||||
}
|
||||
}
|
||||
@@ -566,20 +567,20 @@ void AddSpecialBoxController::showAdmin(
|
||||
if (canBanMembers) {
|
||||
if (!sure) {
|
||||
_editBox = Ui::show(
|
||||
Box<ConfirmBox>(
|
||||
Box<Ui::ConfirmBox>(
|
||||
tr::lng_sure_add_admin_unremove(tr::now),
|
||||
showAdminSure),
|
||||
Ui::LayerOption::KeepOther);
|
||||
return;
|
||||
}
|
||||
} else {
|
||||
Ui::show(Box<InformBox>(
|
||||
Ui::show(Box<Ui::InformBox>(
|
||||
tr::lng_error_cant_add_admin_unban(tr::now)),
|
||||
Ui::LayerOption::KeepOther);
|
||||
return;
|
||||
}
|
||||
} else {
|
||||
Ui::show(Box<InformBox>(
|
||||
Ui::show(Box<Ui::InformBox>(
|
||||
tr::lng_error_cant_add_admin_invite(tr::now)),
|
||||
Ui::LayerOption::KeepOther);
|
||||
return;
|
||||
@@ -589,14 +590,14 @@ void AddSpecialBoxController::showAdmin(
|
||||
if (canBanMembers) {
|
||||
if (!sure) {
|
||||
_editBox = Ui::show(
|
||||
Box<ConfirmBox>(
|
||||
Box<Ui::ConfirmBox>(
|
||||
tr::lng_sure_add_admin_unremove(tr::now),
|
||||
showAdminSure),
|
||||
Ui::LayerOption::KeepOther);
|
||||
return;
|
||||
}
|
||||
} else {
|
||||
Ui::show(Box<InformBox>(
|
||||
Ui::show(Box<Ui::InformBox>(
|
||||
tr::lng_error_cant_add_admin_unban(tr::now)),
|
||||
Ui::LayerOption::KeepOther);
|
||||
return;
|
||||
@@ -609,7 +610,7 @@ void AddSpecialBoxController::showAdmin(
|
||||
? tr::lng_sure_add_admin_invite
|
||||
: tr::lng_sure_add_admin_invite_channel)(tr::now);
|
||||
_editBox = Ui::show(
|
||||
Box<ConfirmBox>(
|
||||
Box<Ui::ConfirmBox>(
|
||||
text,
|
||||
showAdminSure),
|
||||
Ui::LayerOption::KeepOther);
|
||||
@@ -617,7 +618,8 @@ void AddSpecialBoxController::showAdmin(
|
||||
}
|
||||
} else {
|
||||
Ui::show(
|
||||
Box<InformBox>(tr::lng_error_cant_add_admin_invite(tr::now)),
|
||||
Box<Ui::InformBox>(
|
||||
tr::lng_error_cant_add_admin_invite(tr::now)),
|
||||
Ui::LayerOption::KeepOther);
|
||||
return;
|
||||
}
|
||||
@@ -717,7 +719,7 @@ void AddSpecialBoxController::showRestricted(
|
||||
if (!_additional.isCreator(user) && _additional.canEditAdmin(user)) {
|
||||
if (!sure) {
|
||||
_editBox = Ui::show(
|
||||
Box<ConfirmBox>(
|
||||
Box<Ui::ConfirmBox>(
|
||||
tr::lng_sure_ban_admin(tr::now),
|
||||
showRestrictedSure),
|
||||
Ui::LayerOption::KeepOther);
|
||||
@@ -725,7 +727,7 @@ void AddSpecialBoxController::showRestricted(
|
||||
}
|
||||
} else {
|
||||
Ui::show(
|
||||
Box<InformBox>(tr::lng_error_cant_ban_admin(tr::now)),
|
||||
Box<Ui::InformBox>(tr::lng_error_cant_ban_admin(tr::now)),
|
||||
Ui::LayerOption::KeepOther);
|
||||
return;
|
||||
}
|
||||
@@ -814,7 +816,7 @@ void AddSpecialBoxController::kickUser(
|
||||
if (!_additional.isCreator(user) && _additional.canEditAdmin(user)) {
|
||||
if (!sure) {
|
||||
_editBox = Ui::show(
|
||||
Box<ConfirmBox>(
|
||||
Box<Ui::ConfirmBox>(
|
||||
tr::lng_sure_ban_admin(tr::now),
|
||||
kickUserSure),
|
||||
Ui::LayerOption::KeepOther);
|
||||
@@ -822,7 +824,7 @@ void AddSpecialBoxController::kickUser(
|
||||
}
|
||||
} else {
|
||||
Ui::show(
|
||||
Box<InformBox>(tr::lng_error_cant_ban_admin(tr::now)),
|
||||
Box<Ui::InformBox>(tr::lng_error_cant_ban_admin(tr::now)),
|
||||
Ui::LayerOption::KeepOther);
|
||||
return;
|
||||
}
|
||||
@@ -837,7 +839,7 @@ void AddSpecialBoxController::kickUser(
|
||||
lt_user,
|
||||
participant->name);
|
||||
_editBox = Ui::show(
|
||||
Box<ConfirmBox>(text, kickUserSure),
|
||||
Box<Ui::ConfirmBox>(text, kickUserSure),
|
||||
Ui::LayerOption::KeepOther);
|
||||
return;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user