mirror of
https://github.com/telegramdesktop/tdesktop
synced 2025-03-25 04:38:23 +00:00
parent
4d84781a65
commit
296e009808
@ -205,10 +205,9 @@ base::unique_qptr<ConnectingWidget> ConnectingWidget::CreateDefaultWidget(
|
||||
const auto weak = result.get();
|
||||
rpl::combine(
|
||||
result->visibility(),
|
||||
parent->heightValue(),
|
||||
std::move(shown)
|
||||
) | rpl::start_with_next([=](float64 visible, int height, bool shown) {
|
||||
const auto hidden = (visible == 0.) || !shown;
|
||||
parent->heightValue()
|
||||
) | rpl::start_with_next([=](float64 visible, int height) {
|
||||
const auto hidden = (visible == 0.);
|
||||
if (weak->isHidden() != hidden) {
|
||||
weak->setVisible(!hidden);
|
||||
}
|
||||
@ -218,6 +217,11 @@ base::unique_qptr<ConnectingWidget> ConnectingWidget::CreateDefaultWidget(
|
||||
height - weak->height(),
|
||||
visible));
|
||||
}, weak->lifetime());
|
||||
std::move(
|
||||
shown
|
||||
) | rpl::start_with_next([=](bool shown) {
|
||||
weak->setForceHidden(!shown);
|
||||
}, weak->lifetime());
|
||||
result->finishAnimating();
|
||||
return result;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user