Fix build with Xcode.

This commit is contained in:
John Preston 2023-11-29 21:07:12 +04:00
parent 2611899448
commit fa63a220fa
2 changed files with 8 additions and 7 deletions

View File

@ -499,12 +499,13 @@ TextWithEntities ThemeDocumentBox::subtitle() {
} }
rpl::producer<QString> ThemeDocumentBox::button() { rpl::producer<QString> ThemeDocumentBox::button() {
return _parent->data()->out() if (_parent->data()->out()) {
? nullptr return {};
: rpl::conditional( }
WallPaperRevertableValue(_parent->data()), return rpl::conditional(
tr::lng_action_set_wallpaper_remove(), WallPaperRevertableValue(_parent->data()),
tr::lng_action_set_wallpaper_button()); tr::lng_action_set_wallpaper_remove(),
tr::lng_action_set_wallpaper_button());
} }
ClickHandlerPtr ThemeDocumentBox::createViewLink() { ClickHandlerPtr ThemeDocumentBox::createViewLink() {

View File

@ -92,7 +92,7 @@ CaptionFullView::CaptionFullView(not_null<Controller*> controller)
} else if (type == QEvent::MouseButtonRelease) { } else if (type == QEvent::MouseButtonRelease) {
if (const auto activated = ClickHandler::unpressed()) { if (const auto activated = ClickHandler::unpressed()) {
ActivateClickHandler(_wrap.get(), activated, { ActivateClickHandler(_wrap.get(), activated, {
mouse()->button(), mouse()->button(), QVariant(),
}); });
} }
} }