mirror of
https://github.com/ppy/osu.git
synced 2024-11-11 21:07:33 +08:00
Fix double confirmation
This commit is contained in:
parent
3e3f12f277
commit
f7a570d67a
@ -144,10 +144,15 @@ namespace osu.Game.Screens.Play.HUD
|
||||
|
||||
bind();
|
||||
|
||||
gameActive.BindValueChanged(_ => updateActive());
|
||||
gameActive.BindTo(game.IsActive);
|
||||
}
|
||||
|
||||
protected override void LoadComplete()
|
||||
{
|
||||
base.LoadComplete();
|
||||
gameActive.BindValueChanged(_ => updateActive(), true);
|
||||
}
|
||||
|
||||
private void bind()
|
||||
{
|
||||
circularProgress.Current.BindTo(Progress);
|
||||
@ -195,7 +200,7 @@ namespace osu.Game.Screens.Play.HUD
|
||||
base.OnHoverLost(e);
|
||||
}
|
||||
|
||||
private bool pauseOnFocusLost;
|
||||
private bool pauseOnFocusLost = true;
|
||||
|
||||
public bool PauseOnFocusLost
|
||||
{
|
||||
@ -205,7 +210,8 @@ namespace osu.Game.Screens.Play.HUD
|
||||
return;
|
||||
|
||||
pauseOnFocusLost = value;
|
||||
updateActive();
|
||||
if (IsLoaded)
|
||||
updateActive();
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user