1
0
mirror of https://github.com/ppy/osu.git synced 2024-12-14 20:22:55 +08:00

Merge pull request #15670 from Joehuu/fix-score-panel-animation

Fix score panels sometimes jumping when toggling statistics fast
This commit is contained in:
Dan Balasescu 2021-11-19 01:18:22 +09:00 committed by GitHub
commit 2a5ecad771
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -311,10 +311,10 @@ namespace osu.Game.Screens.Ranking
ScorePanelList.Attach(detachedPanel);
// Move into its original location in the attached container first, then to the final location.
var origLocation = detachedPanel.Parent.ToLocalSpace(screenSpacePos);
detachedPanel.MoveTo(origLocation)
float origLocation = detachedPanel.Parent.ToLocalSpace(screenSpacePos).X;
detachedPanel.MoveToX(origLocation)
.Then()
.MoveTo(new Vector2(0, origLocation.Y), 150, Easing.OutQuint);
.MoveToX(0, 150, Easing.OutQuint);
// Show contracted panels.
foreach (var contracted in ScorePanelList.GetScorePanels().Where(p => p.State == PanelState.Contracted))