tdesktop/Telegram/SourceFiles/window/window_session_controller_link_info.h

62 lines
1.4 KiB
C
Raw Normal View History

/*
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
namespace InlineBots {
struct WebViewContext;
} // namespace InlineBots
namespace Window {
enum class ResolveType {
Default,
BotApp,
BotStart,
AddToGroup,
AddToChannel,
ShareGame,
Mention,
Boost,
2024-07-26 11:45:02 +00:00
Profile,
};
struct CommentId {
MsgId id = 0;
};
struct ThreadId {
MsgId id = 0;
};
using RepliesByLinkInfo = std::variant<v::null_t, CommentId, ThreadId>;
struct PeerByLinkInfo {
std::variant<QString, ChannelId> usernameOrId;
QString phone;
2024-03-26 15:13:26 +00:00
QString chatLinkSlug;
MsgId messageId = ShowAtUnreadMsgId;
StoryId storyId = 0;
2024-04-09 10:00:48 +00:00
QString text;
RepliesByLinkInfo repliesInfo;
ResolveType resolveType = ResolveType::Default;
QString startToken;
ChatAdminRights startAdminRights;
bool startAutoSubmit = false;
2023-12-04 19:06:44 +00:00
bool joinChannel = false;
QString botAppName;
bool botAppForceConfirmation = false;
QString attachBotUsername;
std::optional<QString> attachBotToggleCommand;
bool attachBotMainOpen = false;
bool attachBotMainCompact = false;
InlineBots::PeerTypes attachBotChooseTypes;
std::optional<QString> voicechatHash;
FullMsgId clickFromMessageId;
std::shared_ptr<InlineBots::WebViewContext> clickFromBotWebviewContext;
};
} // namespace Window