tdesktop/Telegram/SourceFiles/settings/settings_information.h

49 lines
1.1 KiB
C
Raw Normal View History

2018-09-05 19:05:49 +00: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 11:12:49 +00:00
namespace Dialogs::Ui {
struct UnreadBadgeStyle;
} // namespace Dialogs::Ui
2018-09-05 19:05:49 +00:00
namespace Settings {
class Information : public Section<Information> {
2018-09-05 19:05:49 +00:00
public:
2018-09-13 20:09:26 +00:00
Information(
QWidget *parent,
2019-07-24 14:00:30 +00:00
not_null<Window::SessionController*> controller);
2018-09-05 19:05:49 +00:00
[[nodiscard]] rpl::producer<QString> title() override;
2018-09-05 19:05:49 +00:00
private:
void setupContent(not_null<Window::SessionController*> controller);
2018-09-05 19:05:49 +00:00
};
2022-03-15 11:12:49 +00: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 19:05:49 +00:00
} // namespace Settings