mirror of
https://github.com/telegramdesktop/tdesktop
synced 2025-08-31 14:38:15 +00:00
Filter out allowed gift types.
This commit is contained in:
@@ -15,12 +15,18 @@ https://github.com/telegramdesktop/tdesktop/blob/master/LEGAL
|
||||
#include "data/data_lastseen_status.h"
|
||||
#include "data/data_user_names.h"
|
||||
#include "dialogs/dialogs_key.h"
|
||||
#include "base/flags.h"
|
||||
|
||||
namespace Data {
|
||||
struct BotCommand;
|
||||
struct BusinessDetails;
|
||||
} // namespace Data
|
||||
|
||||
namespace Api {
|
||||
enum class DisallowedGiftType;
|
||||
using DisallowedGiftTypes = base::flags<DisallowedGiftType>;
|
||||
} // namespace Api
|
||||
|
||||
struct StarRefProgram {
|
||||
StarsAmount revenuePerUser;
|
||||
TimeId endDate = 0;
|
||||
@@ -262,6 +268,11 @@ public:
|
||||
|
||||
std::unique_ptr<BotInfo> botInfo;
|
||||
|
||||
[[nodiscard]] Api::DisallowedGiftTypes disallowedGiftTypes() const {
|
||||
return _disallowedGiftTypes;
|
||||
}
|
||||
void setDisallowedGiftTypes(Api::DisallowedGiftTypes types);
|
||||
|
||||
private:
|
||||
auto unavailableReasons() const
|
||||
-> const std::vector<Data::UnavailableReason> & override;
|
||||
@@ -293,6 +304,8 @@ private:
|
||||
static constexpr auto kInaccessibleAccessHashOld
|
||||
= 0xFFFFFFFFFFFFFFFFULL;
|
||||
|
||||
Api::DisallowedGiftTypes _disallowedGiftTypes;
|
||||
|
||||
};
|
||||
|
||||
namespace Data {
|
||||
|
Reference in New Issue
Block a user