mirror of
https://github.com/ppy/osu.git
synced 2024-11-06 11:27:24 +08:00
Fix potentially triggering new requests too early
This commit is contained in:
parent
a4a4c87612
commit
17018ffa8b
@ -190,8 +190,9 @@ namespace osu.Game.Screens.Ranking
|
|||||||
|
|
||||||
if (nextPageRequest != null)
|
if (nextPageRequest != null)
|
||||||
{
|
{
|
||||||
nextPageRequest.Success += () => nextPageRequest = null;
|
// Scheduled after children to give the list a chance to update its scroll position and not potentially trigger a second request too early.
|
||||||
nextPageRequest.Failure += _ => nextPageRequest = null;
|
nextPageRequest.Success += () => ScheduleAfterChildren(() => nextPageRequest = null);
|
||||||
|
nextPageRequest.Failure += _ => ScheduleAfterChildren(() => nextPageRequest = null);
|
||||||
|
|
||||||
api.Queue(nextPageRequest);
|
api.Queue(nextPageRequest);
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user