diff --git a/Telegram/SourceFiles/info/info_top_bar.cpp b/Telegram/SourceFiles/info/info_top_bar.cpp index 71bac1b3c8..af7006b382 100644 --- a/Telegram/SourceFiles/info/info_top_bar.cpp +++ b/Telegram/SourceFiles/info/info_top_bar.cpp @@ -669,6 +669,7 @@ void TopBar::createSelectionControls() { ) | rpl::start_to_stream( _selectionActionRequests, _cancelSelection->lifetime()); + _selectionText = wrap(Ui::CreateChild>( this, object_ptr( @@ -679,6 +680,11 @@ void TopBar::createSelectionControls() { st::infoTopBarScale)); _selectionText->setDuration(st::infoTopBarDuration); _selectionText->entity()->resize(0, _st.height); + _selectionText->naturalWidthValue( + ) | rpl::skip(1) | rpl::start_with_next([=] { + updateSelectionControlsGeometry(width()); + }, _selectionText->lifetime()); + _forward = wrap(Ui::CreateChild>( this, object_ptr(this, _st.mediaForward),