mirror of
https://github.com/ppy/osu
synced 2024-12-10 17:12:57 +00:00
Use BindValueChanged
This commit is contained in:
parent
be66c0e912
commit
55a071e8ba
@ -48,14 +48,14 @@ namespace osu.Game.Graphics.Containers
|
||||
|
||||
protected override void LoadComplete()
|
||||
{
|
||||
OverlayActivationMode.ValueChanged += mode =>
|
||||
if (game != null)
|
||||
OverlayActivationMode.BindTo(game.OverlayActivationMode);
|
||||
|
||||
OverlayActivationMode.BindValueChanged(mode =>
|
||||
{
|
||||
if (mode.NewValue == OverlayActivation.Disabled)
|
||||
State.Value = Visibility.Hidden;
|
||||
};
|
||||
|
||||
if (game != null)
|
||||
OverlayActivationMode.BindTo(game.OverlayActivationMode);
|
||||
}, true);
|
||||
|
||||
base.LoadComplete();
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user