Removed Ui::show from Settings::SessionsContent.

This commit is contained in:
23rd 2022-02-23 07:43:33 +03:00 committed by John Preston
parent 78f7ea0c9d
commit ca7f4ffed9
1 changed files with 8 additions and 8 deletions

View File

@ -823,13 +823,13 @@ void SessionsContent::terminate(Fn<void()> terminateRequest, QString message) {
}
terminateRequest();
});
_terminateBox = Ui::show(
Box<Ui::ConfirmBox>(
message,
tr::lng_settings_reset_button(tr::now),
st::attentionBoxButton,
callback),
Ui::LayerOption::KeepOther);
auto box = Box<Ui::ConfirmBox>(
message,
tr::lng_settings_reset_button(tr::now),
st::attentionBoxButton,
callback);
_terminateBox = Ui::MakeWeak(box.data());
_controller->show(std::move(box), Ui::LayerOption::KeepOther);
}
void SessionsContent::terminateOne(uint64 hash) {
@ -911,7 +911,7 @@ void SessionsContent::Inner::setupContent() {
rename->moveToRight(x, y, outer.width());
}, rename->lifetime());
rename->setClickedCallback([=] {
Ui::show(Box(RenameBox), Ui::LayerOption::KeepOther);
_controller->show(Box(RenameBox), Ui::LayerOption::KeepOther);
});
const auto session = &_controller->session();