mirror of https://github.com/procxx/kepka.git
Fixed dialogs up button when column of dialogs is small.
This commit is contained in:
parent
14de1fe485
commit
be89a0bf7e
|
@ -275,6 +275,8 @@ void DialogsWidget::updateScrollUpVisibility() {
|
||||||
}
|
}
|
||||||
|
|
||||||
void DialogsWidget::startScrollUpButtonAnimation(bool shown) {
|
void DialogsWidget::startScrollUpButtonAnimation(bool shown) {
|
||||||
|
const auto smallColumn = (width() < st::columnMinimalWidthLeft);
|
||||||
|
shown &= !smallColumn;
|
||||||
if (_scrollToTopIsShown == shown) {
|
if (_scrollToTopIsShown == shown) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
@ -283,7 +285,7 @@ void DialogsWidget::startScrollUpButtonAnimation(bool shown) {
|
||||||
[=] { updateScrollUpPosition(); },
|
[=] { updateScrollUpPosition(); },
|
||||||
_scrollToTopIsShown ? 0. : 1.,
|
_scrollToTopIsShown ? 0. : 1.,
|
||||||
_scrollToTopIsShown ? 1. : 0.,
|
_scrollToTopIsShown ? 1. : 0.,
|
||||||
st::historyToDownDuration);
|
smallColumn ? 0 : st::historyToDownDuration);
|
||||||
}
|
}
|
||||||
|
|
||||||
void DialogsWidget::updateScrollUpPosition() {
|
void DialogsWidget::updateScrollUpPosition() {
|
||||||
|
|
Loading…
Reference in New Issue