Fixed crash on dismiss of birthday suggestion.

This commit is contained in:
23rd 2025-05-07 12:14:43 +03:00
parent 4560a83441
commit 584e55a89c
2 changed files with 2 additions and 1 deletions

View file

@ -359,7 +359,7 @@ rpl::producer<Ui::SlideWrap<Ui::RpWidget>*> TopBarSuggestionValue(
fake->moveToLeft(
leftPadding,
(s.height() - fake->height()) / 2);
}, content->lifetime());
}, fake->lifetime());
content->setLeftPadding(fake->width() + leftPadding);
}

View file

@ -194,6 +194,7 @@ rpl::producer<int> TopBarSuggestionContent::desiredHeightValue() const {
}
void TopBarSuggestionContent::setHideCallback(Fn<void()> hideCallback) {
Expects(_rightHide != nullptr);
_rightHide->setClickedCallback(std::move(hideCallback));
}