2
0
mirror of https://github.com/telegramdesktop/tdesktop synced 2025-08-24 19:27:17 +00:00
tdesktop/Telegram/SourceFiles/settings/settings_information.h

53 lines
1.1 KiB
C
Raw Normal View History

2018-09-05 22:05:49 +03:00
/*
This file is part of Telegram Desktop,
the official desktop application for the Telegram messaging service.
For license and copyright information please follow this link:
https://github.com/telegramdesktop/tdesktop/blob/master/LEGAL
*/
#pragma once
#include "settings/settings_common.h"
2022-03-15 15:12:49 +04:00
namespace Dialogs::Ui {
struct UnreadBadgeStyle;
} // namespace Dialogs::Ui
namespace Main {
class Account;
} // namespace Main
2018-09-05 22:05:49 +03:00
namespace Settings {
class Information : public Section<Information> {
2018-09-05 22:05:49 +03:00
public:
2018-09-13 23:09:26 +03:00
Information(
QWidget *parent,
2019-07-24 16:00:30 +02:00
not_null<Window::SessionController*> controller);
2018-09-05 22:05:49 +03:00
[[nodiscard]] rpl::producer<QString> title() override;
2018-09-05 22:05:49 +03:00
private:
void setupContent(not_null<Window::SessionController*> controller);
2018-09-05 22:05:49 +03:00
};
2022-03-15 15:12:49 +04:00
struct AccountsEvents {
rpl::producer<> currentAccountActivations;
};
AccountsEvents SetupAccounts(
not_null<Ui::VerticalLayout*> container,
not_null<Window::SessionController*> controller);
[[nodiscard]] Dialogs::Ui::UnreadBadgeStyle BadgeStyle();
struct UnreadBadge {
int count = 0;
bool muted = false;
};
void AddUnreadBadge(
not_null<Ui::SettingsButton*> button,
rpl::producer<UnreadBadge> value);
2018-09-05 22:05:49 +03:00
} // namespace Settings