mirror of
https://github.com/telegramdesktop/tdesktop
synced 2025-08-29 13:39:06 +00:00
Fix top bar selection label resizing.
This commit is contained in:
parent
e656cb8118
commit
ec8a475a2c
@ -669,6 +669,7 @@ void TopBar::createSelectionControls() {
|
|||||||
) | rpl::start_to_stream(
|
) | rpl::start_to_stream(
|
||||||
_selectionActionRequests,
|
_selectionActionRequests,
|
||||||
_cancelSelection->lifetime());
|
_cancelSelection->lifetime());
|
||||||
|
|
||||||
_selectionText = wrap(Ui::CreateChild<Ui::FadeWrap<Ui::LabelWithNumbers>>(
|
_selectionText = wrap(Ui::CreateChild<Ui::FadeWrap<Ui::LabelWithNumbers>>(
|
||||||
this,
|
this,
|
||||||
object_ptr<Ui::LabelWithNumbers>(
|
object_ptr<Ui::LabelWithNumbers>(
|
||||||
@ -679,6 +680,11 @@ void TopBar::createSelectionControls() {
|
|||||||
st::infoTopBarScale));
|
st::infoTopBarScale));
|
||||||
_selectionText->setDuration(st::infoTopBarDuration);
|
_selectionText->setDuration(st::infoTopBarDuration);
|
||||||
_selectionText->entity()->resize(0, _st.height);
|
_selectionText->entity()->resize(0, _st.height);
|
||||||
|
_selectionText->naturalWidthValue(
|
||||||
|
) | rpl::skip(1) | rpl::start_with_next([=] {
|
||||||
|
updateSelectionControlsGeometry(width());
|
||||||
|
}, _selectionText->lifetime());
|
||||||
|
|
||||||
_forward = wrap(Ui::CreateChild<Ui::FadeWrap<Ui::IconButton>>(
|
_forward = wrap(Ui::CreateChild<Ui::FadeWrap<Ui::IconButton>>(
|
||||||
this,
|
this,
|
||||||
object_ptr<Ui::IconButton>(this, _st.mediaForward),
|
object_ptr<Ui::IconButton>(this, _st.mediaForward),
|
||||||
|
Loading…
x
Reference in New Issue
Block a user