mirror of
https://github.com/telegramdesktop/tdesktop
synced 2025-08-30 22:16:14 +00:00
Add chat name / account name / unread count title settings.
This commit is contained in:
@@ -170,6 +170,12 @@ Application::Application(not_null<Launcher*> launcher)
|
||||
passcodeLockChanges(
|
||||
) | rpl::start_with_next([=] {
|
||||
_notifications->updateAll();
|
||||
updateWindowTitles();
|
||||
}, _lifetime);
|
||||
|
||||
settings().windowTitleContentChanges(
|
||||
) | rpl::start_with_next([=] {
|
||||
updateWindowTitles();
|
||||
}, _lifetime);
|
||||
|
||||
_domain->activeSessionChanges(
|
||||
@@ -1067,6 +1073,12 @@ void Application::preventOrInvoke(Fn<void()> &&callback) {
|
||||
_lastActivePrimaryWindow->preventOrInvoke(std::move(callback));
|
||||
}
|
||||
|
||||
void Application::updateWindowTitles() {
|
||||
enumerateWindows([](not_null<Window::Controller*> window) {
|
||||
window->widget()->updateTitle();
|
||||
});
|
||||
}
|
||||
|
||||
void Application::lockByPasscode() {
|
||||
enumerateWindows([&](not_null<Window::Controller*> w) {
|
||||
_passcodeLock = true;
|
||||
|
Reference in New Issue
Block a user