Fix username disappearance in My Profile.

This commit is contained in:
John Preston 2024-12-19 17:14:21 +04:00
parent bcd1d8461f
commit 4569f93e70

View file

@ -1241,19 +1241,19 @@ object_ptr<Ui::RpWidget> DetailsFiller::setupInfo() {
int rightSkip) {
const auto parent = label->parentWidget();
rpl::combine(
result->widthValue(),
label->geometryValue(),
button->sizeValue()
) | rpl::start_with_next([=](const QRect&, const QSize &buttonSize) {
) | rpl::start_with_next([=](int width, QRect, QSize buttonSize) {
const auto s = parent->size();
button->moveToRight(
rightSkip,
(s.height() - buttonSize.height()) / 2);
label->resizeToWidth(
s.width()
- rightSkip
- label->geometry().left()
- st::lineWidth * 2
- buttonSize.width());
(parent->height() - buttonSize.height()) / 2);
label->resizeToWidth(width
- rightSkip
- label->geometry().left()
- st::lineWidth * 2
- buttonSize.width());
}, button->lifetime());
};
const auto controller = _controller->parentController();