Support 'FT' "country" flag emoji.

This commit is contained in:
John Preston 2025-03-10 11:52:42 +04:00
parent 4b2c5b3321
commit b843f91b3c
3 changed files with 5 additions and 0 deletions

View file

@ -322,6 +322,9 @@ QString CountriesInstance::flagEmojiByISO2(const QString &iso) const {
|| iso.back() < 'A'
|| iso.back() > 'Z') {
return QString();
} else if (iso == u"FT"_q) {
return QString::fromUtf8(
"\xF0\x9F\x8F\xB4\xE2\x80\x8D\xE2\x98\xA0\xEF\xB8\x8F");
}
auto result = QString(4, QChar(0xD83C));
result[1] = QChar(iso.front().unicode() - 'A' + 0xDDE6);

View file

@ -748,6 +748,7 @@ AdminLog::OwnedItem AboutView::makeNewPeerInfo(not_null<UserData*> user) {
owned.get(),
GenerateNewPeerInfo(owned.get(), _item.get(), user, _commonGroups),
HistoryView::MediaGenericDescriptor{
.maxWidth = st::newPeerWidth,
.service = true,
.hideServiceText = true,
}));

View file

@ -1244,3 +1244,4 @@ newPeerUserpics: GroupCallUserpics {
align: align(left);
}
newPeerUserpicsPadding: margins(0px, 3px, 0px, 0px);
newPeerWidth: 320px;