mirror of
https://github.com/AyuGram/AyuGramDesktop.git
synced 2025-04-16 14:17:12 +02:00
Fix userpics in "Who Read" menu.
This commit is contained in:
parent
37ab65d952
commit
5dc35bc75f
1 changed files with 7 additions and 4 deletions
|
@ -165,8 +165,9 @@ Action::Action(
|
|||
+ _st.itemStyle.font->height
|
||||
+ st::defaultWhoRead.itemPadding.bottom()) {
|
||||
const auto parent = parentMenu->menu();
|
||||
const auto checkAppeared = [=, now = crl::now()] {
|
||||
_appeared = (crl::now() - now) >= parentMenu->st().duration;
|
||||
const auto delay = anim::Disabled() ? 0 : parentMenu->st().duration;
|
||||
const auto checkAppeared = [=, now = crl::now()](bool force = false) {
|
||||
_appeared = force || ((crl::now() - now) >= delay);
|
||||
};
|
||||
|
||||
setAcceptBoth(true);
|
||||
|
@ -224,8 +225,10 @@ Action::Action(
|
|||
enableMouseSelecting();
|
||||
|
||||
base::call_delayed(parentMenu->st().duration, this, [=] {
|
||||
checkAppeared();
|
||||
updateUserpicsFromContent();
|
||||
if (!_appeared) {
|
||||
checkAppeared(true);
|
||||
updateUserpicsFromContent();
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue