Fixed position of show more button in translate box.

This commit is contained in:
23rd 2022-11-16 12:42:47 +03:00 committed by John Preston
parent 2de76cb75b
commit 32cebc0d9b

View file

@ -173,10 +173,12 @@ void TranslateBox(
container.get(),
object_ptr<ShowButton>(container));
show->hide(anim::type::instant);
original->geometryValue(
) | rpl::start_with_next([=](const QRect &rect) {
rpl::combine(
container->widthValue(),
original->geometryValue()
) | rpl::start_with_next([=](int width, const QRect &rect) {
show->moveToLeft(
rect.x() + rect.width() - show->width(),
width - show->width() - st::boxRowPadding.right(),
rect.y() + std::abs(lineHeight - show->height()) / 2);
}, show->lifetime());
original->entity()->heightValue(