Fix most warnings.

This commit is contained in:
Dean Herbert
2017-03-07 10:59:19 +09:00
parent 9106c45858
commit 0cad5d7d41
168 changed files with 504 additions and 473 deletions

View File

@ -39,21 +39,14 @@ namespace osu.Game.Screens.Play
public PlayMode PreferredPlayMode;
private bool isPaused;
public bool IsPaused
{
get
{
return isPaused;
}
}
public bool IsPaused { get; private set; }
public int RestartCount;
private double pauseCooldown = 1000;
private double lastPauseActionTime = 0;
private double lastPauseActionTime;
private bool canPause => Time.Current >= (lastPauseActionTime + pauseCooldown);
private bool canPause => Time.Current >= lastPauseActionTime + pauseCooldown;
private IAdjustableClock sourceClock;
@ -198,11 +191,11 @@ namespace osu.Game.Screens.Play
pauseOverlay.Retries = RestartCount;
pauseOverlay.Show();
sourceClock.Stop();
isPaused = true;
IsPaused = true;
}
else
{
isPaused = false;
IsPaused = false;
}
}
@ -212,12 +205,12 @@ namespace osu.Game.Screens.Play
scoreOverlay.KeyCounter.IsCounting = true;
pauseOverlay.Hide();
sourceClock.Start();
isPaused = false;
IsPaused = false;
}
public void TogglePaused()
{
isPaused = !IsPaused;
IsPaused = !IsPaused;
if (IsPaused) Pause(); else Resume();
}
@ -327,6 +320,6 @@ namespace osu.Game.Screens.Play
private Bindable<bool> mouseWheelDisabled;
protected override bool OnWheel(InputState state) => mouseWheelDisabled.Value && !isPaused;
protected override bool OnWheel(InputState state) => mouseWheelDisabled.Value && !IsPaused;
}
}