mirror of
https://github.com/kotatogram/kotatogram-desktop
synced 2025-08-31 06:35:14 +00:00
Correctly show premium promo for custom reactions.
This commit is contained in:
@@ -996,7 +996,7 @@ void ReactionPreview::paintEffect(QPainter &p) {
|
||||
Data::Reactions::Type::Active);
|
||||
const auto count = ranges::count(list, true, &Data::Reaction::premium);
|
||||
const auto rows = (count + kReactionsPerRow - 1) / kReactionsPerRow;
|
||||
const auto inrowmax = (count + rows - 1) / rows;
|
||||
const auto inrowmax = rows ? ((count + rows - 1) / rows) : 1;
|
||||
const auto inrowless = (inrowmax * rows - count);
|
||||
const auto inrowmore = rows - inrowless;
|
||||
const auto inmaxrows = inrowmore * inrowmax;
|
||||
|
@@ -455,9 +455,7 @@ void ReactionsSettingsBox(
|
||||
|
||||
button->setClickedCallback([=, id = r.id] {
|
||||
if (premium && !controller->session().premium()) {
|
||||
ShowPremiumPreviewBox(
|
||||
controller,
|
||||
PremiumPreview::Reactions);
|
||||
ShowPremiumPreviewBox(controller, PremiumPreview::Reactions);
|
||||
return;
|
||||
}
|
||||
checkButton(button);
|
||||
|
Reference in New Issue
Block a user