mirror of
https://github.com/osukey/osukey.git
synced 2025-05-29 17:37:23 +09:00
Tidy up variables a bit
This commit is contained in:
parent
160b988735
commit
f96f7e696d
@ -17,7 +17,7 @@ namespace osu.Game.Overlays.Profile.Sections.Beatmaps
|
|||||||
|
|
||||||
private readonly BeatmapSetType type;
|
private readonly BeatmapSetType type;
|
||||||
|
|
||||||
private DirectPanel playing;
|
private DirectPanel currentlyPlaying;
|
||||||
|
|
||||||
public PaginatedBeatmapContainer(BeatmapSetType type, Bindable<User> user, string header, string missing)
|
public PaginatedBeatmapContainer(BeatmapSetType type, Bindable<User> user, string header, string missing)
|
||||||
: base(user, header, missing)
|
: base(user, header, missing)
|
||||||
@ -55,14 +55,14 @@ namespace osu.Game.Overlays.Profile.Sections.Beatmaps
|
|||||||
var panel = new DirectGridPanel(s.ToBeatmapSet(Rulesets)) { Width = 400 };
|
var panel = new DirectGridPanel(s.ToBeatmapSet(Rulesets)) { Width = 400 };
|
||||||
ItemsContainer.Add(panel);
|
ItemsContainer.Add(panel);
|
||||||
|
|
||||||
panel.PreviewPlaying.ValueChanged += newValue =>
|
panel.PreviewPlaying.ValueChanged += isPlaying =>
|
||||||
{
|
{
|
||||||
if (newValue)
|
if (!isPlaying) return;
|
||||||
{
|
|
||||||
if (playing != null && playing != panel)
|
if (currentlyPlaying != null && currentlyPlaying != panel)
|
||||||
playing.PreviewPlaying.Value = false;
|
currentlyPlaying.PreviewPlaying.Value = false;
|
||||||
playing = panel;
|
|
||||||
}
|
currentlyPlaying = panel;
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
Loading…
x
Reference in New Issue
Block a user