1
0
mirror of https://github.com/ppy/osu.git synced 2024-11-11 21:07:33 +08:00

Fix song select reverting to first difficulty of current group on entering

This commit is contained in:
Dean Herbert 2017-05-17 17:15:25 +09:00
parent cab12ee55a
commit 7bb38e927b

View File

@ -107,6 +107,8 @@ namespace osu.Game.Screens.Select
return;
}
if (beatmap == SelectedBeatmap) return;
foreach (BeatmapGroup group in groups)
{
var panel = group.BeatmapPanels.FirstOrDefault(p => p.Beatmap.Equals(beatmap));
@ -204,7 +206,7 @@ namespace osu.Game.Screens.Select
if (selectedGroup == null || selectedGroup.State == BeatmapGroupState.Hidden)
SelectNext();
else
selectGroup(selectedGroup);
selectGroup(selectedGroup, selectedPanel);
};
filterTask?.Cancel();
@ -339,6 +341,8 @@ namespace osu.Game.Screens.Select
selectedGroup.State = BeatmapGroupState.Collapsed;
group.State = BeatmapGroupState.Expanded;
group.SelectedPanel = panel;
panel.State = PanelSelectedState.Selected;
if (selectedPanel == panel) return;