mirror of
https://github.com/ppy/osu.git
synced 2024-12-15 09:02:55 +08:00
Fix potential of toggle between load and LoadComplete
This commit is contained in:
parent
039b5ec958
commit
be66c0e912
@ -41,6 +41,12 @@ namespace osu.Game.Graphics.Containers
|
|||||||
|
|
||||||
[BackgroundDependencyLoader(true)]
|
[BackgroundDependencyLoader(true)]
|
||||||
private void load(AudioManager audio)
|
private void load(AudioManager audio)
|
||||||
|
{
|
||||||
|
samplePopIn = audio.Samples.Get(@"UI/overlay-pop-in");
|
||||||
|
samplePopOut = audio.Samples.Get(@"UI/overlay-pop-out");
|
||||||
|
}
|
||||||
|
|
||||||
|
protected override void LoadComplete()
|
||||||
{
|
{
|
||||||
OverlayActivationMode.ValueChanged += mode =>
|
OverlayActivationMode.ValueChanged += mode =>
|
||||||
{
|
{
|
||||||
@ -51,8 +57,7 @@ namespace osu.Game.Graphics.Containers
|
|||||||
if (game != null)
|
if (game != null)
|
||||||
OverlayActivationMode.BindTo(game.OverlayActivationMode);
|
OverlayActivationMode.BindTo(game.OverlayActivationMode);
|
||||||
|
|
||||||
samplePopIn = audio.Samples.Get(@"UI/overlay-pop-in");
|
base.LoadComplete();
|
||||||
samplePopOut = audio.Samples.Get(@"UI/overlay-pop-out");
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
|
Loading…
Reference in New Issue
Block a user