mirror of
https://github.com/osukey/osukey.git
synced 2025-08-05 07:33:55 +09:00
Fix most warnings.
This commit is contained in:
@ -10,7 +10,7 @@ using OpenTK.Graphics;
|
||||
|
||||
namespace osu.Game.Screens.Play
|
||||
{
|
||||
class FailDialog : OsuScreen
|
||||
internal class FailDialog : OsuScreen
|
||||
{
|
||||
protected override BackgroundScreen CreateBackground() => new BackgroundScreenBeatmap(Beatmap);
|
||||
|
||||
|
@ -49,7 +49,7 @@ namespace osu.Game.Screens.Play
|
||||
}
|
||||
}
|
||||
|
||||
private int fadeTime = 0;
|
||||
private int fadeTime;
|
||||
public int FadeTime
|
||||
{
|
||||
get { return fadeTime; }
|
||||
|
@ -58,7 +58,7 @@ namespace osu.Game.Screens.Play
|
||||
},
|
||||
new OsuSpriteText
|
||||
{
|
||||
Text = $" time{((value == 1) ? "" : "s")} in this session",
|
||||
Text = $" time{(value == 1 ? "" : "s")} in this session",
|
||||
Shadow = true,
|
||||
ShadowColour = new Color4(0, 0, 0, 0.25f),
|
||||
TextSize = 18
|
||||
|
@ -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;
|
||||
}
|
||||
}
|
@ -10,11 +10,11 @@ using System.Linq;
|
||||
|
||||
namespace osu.Game.Screens.Play
|
||||
{
|
||||
class PlayerInputManager : UserInputManager
|
||||
internal class PlayerInputManager : UserInputManager
|
||||
{
|
||||
bool leftViaKeyboard;
|
||||
bool rightViaKeyboard;
|
||||
Bindable<bool> mouseDisabled;
|
||||
private bool leftViaKeyboard;
|
||||
private bool rightViaKeyboard;
|
||||
private Bindable<bool> mouseDisabled;
|
||||
|
||||
[BackgroundDependencyLoader]
|
||||
private void load(OsuConfigManager config)
|
||||
|
@ -95,9 +95,9 @@ namespace osu.Game.Screens.Play
|
||||
return base.OnExiting(next);
|
||||
}
|
||||
|
||||
class BeatmapMetadataDisplay : Container
|
||||
private class BeatmapMetadataDisplay : Container
|
||||
{
|
||||
class MetadataLine : Container
|
||||
private class MetadataLine : Container
|
||||
{
|
||||
public MetadataLine(string left, string right)
|
||||
{
|
||||
@ -131,7 +131,7 @@ namespace osu.Game.Screens.Play
|
||||
AutoSizeAxes = Axes.Both;
|
||||
Children = new Drawable[]
|
||||
{
|
||||
new FillFlowContainer()
|
||||
new FillFlowContainer
|
||||
{
|
||||
AutoSizeAxes = Axes.Both,
|
||||
Origin = Anchor.TopCentre,
|
||||
|
Reference in New Issue
Block a user