2017-12-02 11:07:27 +00:00
|
|
|
/*
|
|
|
|
This file is part of Telegram Desktop,
|
2018-01-03 10:23:14 +00:00
|
|
|
the official desktop application for the Telegram messaging service.
|
2017-12-02 11:07:27 +00:00
|
|
|
|
2018-01-03 10:23:14 +00:00
|
|
|
For license and copyright information please follow this link:
|
|
|
|
https://github.com/telegramdesktop/tdesktop/blob/master/LEGAL
|
2017-12-02 11:07:27 +00:00
|
|
|
*/
|
|
|
|
#pragma once
|
|
|
|
|
|
|
|
namespace Data {
|
|
|
|
|
|
|
|
class ChannelAdminChanges {
|
|
|
|
public:
|
|
|
|
ChannelAdminChanges(not_null<ChannelData*> channel);
|
|
|
|
|
2019-07-19 13:34:09 +00:00
|
|
|
void add(UserId userId, const QString &rank);
|
|
|
|
void remove(UserId userId);
|
2017-12-02 11:07:27 +00:00
|
|
|
|
|
|
|
~ChannelAdminChanges();
|
|
|
|
|
|
|
|
private:
|
|
|
|
not_null<ChannelData*> _channel;
|
2019-07-19 13:34:09 +00:00
|
|
|
base::flat_map<UserId, QString> &_admins;
|
|
|
|
base::flat_set<UserId> _changes;
|
2017-12-02 11:07:27 +00:00
|
|
|
|
|
|
|
};
|
|
|
|
|
|
|
|
} // namespace Data
|