Fix build with MSVC.

This commit is contained in:
John Preston 2024-08-30 17:58:07 +04:00
parent 7ed92ec402
commit 437d8ea890
3 changed files with 6 additions and 5 deletions

View File

@ -2141,6 +2141,7 @@ QByteArray HtmlWriter::Wrap::pushGiveaway(
return SerializeString(
"All winners received gift links in private messages.");
}
return QByteArray();
}();
result.append(prize);
result.append(popTag());

View File

@ -455,7 +455,7 @@ void CreateGiveawayBox(
return;
}
constexpr auto kColorIndexCredits = int(1);
constexpr auto kOutdated = 1735689600;
static constexpr auto kOutdated = 1735689600;
auto badge = [&] {
if (base::unixtime::now() > kOutdated) {
@ -531,9 +531,9 @@ void CreateGiveawayBox(
const auto &stStatus = st::defaultTextStyle;
const auto buttonInnerSkip = st.height - stButton.height;
const auto options = state->apiCreditsOptions.options();
const auto singleStarWidth = Ui::GenerateStars(
st.nameStyle.font->height,
1).width() / style::DevicePixelRatio();
//const auto singleStarWidth = Ui::GenerateStars(
// st.nameStyle.font->height,
// 1).width() / style::DevicePixelRatio();
const auto content = randomCreditsWrap->entity();
const auto title = Ui::AddSubsectionTitle(
content,

View File

@ -483,7 +483,7 @@ Fn<void(QPainter &)> PaintOutlinedColoredCreditsIconCallback(
constexpr auto kPoints = uint(16);
constexpr auto kAngleStep = 2. * M_PI / kPoints;
constexpr auto kOutlineWidth = 1.6;
constexpr auto kStarShift = 3.8;
// constexpr auto kStarShift = 3.8;
constexpr auto kStrokeWidth = 3;
const auto starSize = Size(size);