2
0
mirror of https://github.com/kotatogram/kotatogram-desktop synced 2025-09-03 16:15:13 +00:00

Disable avatar cropping in Windows notifications with non-circle avatars

This commit is contained in:
RadRussianRus
2022-01-10 03:11:27 +03:00
parent 98f2683e5e
commit 3bb8b52b4c

View File

@@ -56,6 +56,7 @@ namespace {
[[nodiscard]] std::wstring NotificationTemplate( [[nodiscard]] std::wstring NotificationTemplate(
QString id, QString id,
Window::Notifications::Manager::DisplayOptions options) { Window::Notifications::Manager::DisplayOptions options) {
const auto crop = (cUserpicCornersType() == 3) ? L"circle" : L"none";
const auto wid = id.replace('&', "&").toStdWString(); const auto wid = id.replace('&', "&").toStdWString();
const auto fastReply = LR"( const auto fastReply = LR"(
<input id="fastReply" type="text" placeHolderContent=""/> <input id="fastReply" type="text" placeHolderContent=""/>
@@ -78,7 +79,7 @@ namespace {
<toast launch="action=open&amp;)" + wid + LR"("> <toast launch="action=open&amp;)" + wid + LR"(">
<visual> <visual>
<binding template="ToastGeneric"> <binding template="ToastGeneric">
<image placement="appLogoOverride" hint-crop="circle" src=""/> <image placement="appLogoOverride" hint-crop=")" + crop + LR"( src=""/>
<text hint-maxLines="1"></text> <text hint-maxLines="1"></text>
<text></text> <text></text>
<text></text> <text></text>