2
0
mirror of https://github.com/telegramdesktop/tdesktop synced 2025-08-31 06:26:18 +00:00

Remove some MainWindow::sessionController() calls.

This commit is contained in:
John Preston
2020-06-23 21:21:58 +04:00
parent 4d65df6ca2
commit 30c82bb2e0
35 changed files with 275 additions and 182 deletions

View File

@@ -827,12 +827,12 @@ void MainMenu::refreshMenu() {
}, &st::mainMenuContacts, &st::mainMenuContactsOver);
if (_controller->session().serverConfig().phoneCallsEnabled.current()) {
_menu->addAction(tr::lng_menu_calls(tr::now), [=] {
Ui::show(Box<PeerListBox>(std::make_unique<Calls::BoxController>(controller), [](not_null<PeerListBox*> box) {
Ui::show(Box<PeerListBox>(std::make_unique<Calls::BoxController>(controller), [=](not_null<PeerListBox*> box) {
box->addButton(tr::lng_close(), [=] {
box->closeBox();
});
box->addTopButton(st::callSettingsButton, [=] {
App::wnd()->sessionController()->showSettings(
controller->showSettings(
Settings::Type::Calls,
Window::SectionShow(anim::type::instant));
});