mirror of
https://github.com/AyuGram/AyuGramDesktop.git
synced 2025-06-05 22:54:01 +02:00
Add "Join Call" button to confcall link previews.
This commit is contained in:
parent
346f7aadd6
commit
41c0a5ee3b
4 changed files with 7 additions and 0 deletions
|
@ -5856,6 +5856,7 @@ https://github.com/telegramdesktop/tdesktop/blob/master/LEGAL
|
||||||
"lng_view_button_stickerset" = "View stickers";
|
"lng_view_button_stickerset" = "View stickers";
|
||||||
"lng_view_button_emojipack" = "View emoji";
|
"lng_view_button_emojipack" = "View emoji";
|
||||||
"lng_view_button_collectible" = "View collectible";
|
"lng_view_button_collectible" = "View collectible";
|
||||||
|
"lng_view_button_call" = "Join call";
|
||||||
|
|
||||||
"lng_sponsored_hide_ads" = "Hide";
|
"lng_sponsored_hide_ads" = "Hide";
|
||||||
"lng_sponsored_title" = "What are sponsored messages?";
|
"lng_sponsored_title" = "What are sponsored messages?";
|
||||||
|
|
|
@ -159,6 +159,8 @@ WebPageType ParseWebPageType(
|
||||||
return WebPageType::VoiceChat;
|
return WebPageType::VoiceChat;
|
||||||
} else if (type == u"telegram_livestream"_q) {
|
} else if (type == u"telegram_livestream"_q) {
|
||||||
return WebPageType::Livestream;
|
return WebPageType::Livestream;
|
||||||
|
} else if (type == u"telegram_call"_q) {
|
||||||
|
return WebPageType::ConferenceCall;
|
||||||
} else if (type == u"telegram_user"_q) {
|
} else if (type == u"telegram_user"_q) {
|
||||||
return WebPageType::User;
|
return WebPageType::User;
|
||||||
} else if (type == u"telegram_botapp"_q) {
|
} else if (type == u"telegram_botapp"_q) {
|
||||||
|
|
|
@ -55,6 +55,7 @@ enum class WebPageType : uint8 {
|
||||||
|
|
||||||
VoiceChat,
|
VoiceChat,
|
||||||
Livestream,
|
Livestream,
|
||||||
|
ConferenceCall,
|
||||||
|
|
||||||
Factcheck,
|
Factcheck,
|
||||||
};
|
};
|
||||||
|
|
|
@ -220,6 +220,8 @@ constexpr auto kSponsoredUserpicLines = 2;
|
||||||
? tr::lng_view_button_voice_chat(tr::now)
|
? tr::lng_view_button_voice_chat(tr::now)
|
||||||
: (type == WebPageType::Livestream)
|
: (type == WebPageType::Livestream)
|
||||||
? tr::lng_view_button_voice_chat_channel(tr::now)
|
? tr::lng_view_button_voice_chat_channel(tr::now)
|
||||||
|
: (type == WebPageType::ConferenceCall)
|
||||||
|
? tr::lng_view_button_call(tr::now)
|
||||||
: (type == WebPageType::Bot)
|
: (type == WebPageType::Bot)
|
||||||
? tr::lng_view_button_bot(tr::now)
|
? tr::lng_view_button_bot(tr::now)
|
||||||
: (type == WebPageType::User)
|
: (type == WebPageType::User)
|
||||||
|
@ -258,6 +260,7 @@ constexpr auto kSponsoredUserpicLines = 2;
|
||||||
|| (type == WebPageType::User)
|
|| (type == WebPageType::User)
|
||||||
|| (type == WebPageType::VoiceChat)
|
|| (type == WebPageType::VoiceChat)
|
||||||
|| (type == WebPageType::Livestream)
|
|| (type == WebPageType::Livestream)
|
||||||
|
|| (type == WebPageType::ConferenceCall)
|
||||||
|| (type == WebPageType::BotApp)
|
|| (type == WebPageType::BotApp)
|
||||||
|| ((type == WebPageType::Theme)
|
|| ((type == WebPageType::Theme)
|
||||||
&& webpage->document
|
&& webpage->document
|
||||||
|
|
Loading…
Add table
Reference in a new issue