mirror of
https://github.com/osukey/osukey.git
synced 2025-08-03 06:36:31 +09:00
Merge branch 'master' into more-inspections
This commit is contained in:
@ -26,7 +26,7 @@ namespace osu.Game.Graphics.UserInterface
|
||||
/// </summary>
|
||||
public float Length
|
||||
{
|
||||
get { return length; }
|
||||
get => length;
|
||||
set
|
||||
{
|
||||
length = MathHelper.Clamp(value, 0, 1);
|
||||
@ -50,7 +50,7 @@ namespace osu.Game.Graphics.UserInterface
|
||||
|
||||
public BarDirection Direction
|
||||
{
|
||||
get { return direction; }
|
||||
get => direction;
|
||||
set
|
||||
{
|
||||
direction = value;
|
||||
|
@ -20,10 +20,7 @@ namespace osu.Game.Graphics.UserInterface
|
||||
|
||||
public new BarDirection Direction
|
||||
{
|
||||
get
|
||||
{
|
||||
return direction;
|
||||
}
|
||||
get => direction;
|
||||
set
|
||||
{
|
||||
direction = value;
|
||||
|
@ -57,7 +57,7 @@ namespace osu.Game.Graphics.UserInterface
|
||||
|
||||
public Visibility State
|
||||
{
|
||||
get { return state; }
|
||||
get => state;
|
||||
set
|
||||
{
|
||||
if (value == state) return;
|
||||
|
@ -157,7 +157,7 @@ namespace osu.Game.Graphics.UserInterface
|
||||
|
||||
public Color4 ButtonColour
|
||||
{
|
||||
get { return buttonColour; }
|
||||
get => buttonColour;
|
||||
set
|
||||
{
|
||||
buttonColour = value;
|
||||
@ -170,7 +170,7 @@ namespace osu.Game.Graphics.UserInterface
|
||||
|
||||
public Color4 BackgroundColour
|
||||
{
|
||||
get { return backgroundColour; }
|
||||
get => backgroundColour;
|
||||
set
|
||||
{
|
||||
backgroundColour = value;
|
||||
@ -182,7 +182,7 @@ namespace osu.Game.Graphics.UserInterface
|
||||
|
||||
public string Text
|
||||
{
|
||||
get { return text; }
|
||||
get => text;
|
||||
set
|
||||
{
|
||||
text = value;
|
||||
|
@ -19,7 +19,7 @@ namespace osu.Game.Graphics.UserInterface
|
||||
/// </summary>
|
||||
public Color4 IconColour
|
||||
{
|
||||
get { return iconColour ?? Color4.White; }
|
||||
get => iconColour ?? Color4.White;
|
||||
set
|
||||
{
|
||||
iconColour = value;
|
||||
@ -34,8 +34,8 @@ namespace osu.Game.Graphics.UserInterface
|
||||
/// </summary>
|
||||
public Color4 IconHoverColour
|
||||
{
|
||||
get { return iconHoverColour ?? IconColour; }
|
||||
set { iconHoverColour = value; }
|
||||
get => iconHoverColour ?? IconColour;
|
||||
set => iconHoverColour = value;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
@ -43,8 +43,8 @@ namespace osu.Game.Graphics.UserInterface
|
||||
/// </summary>
|
||||
public FontAwesome Icon
|
||||
{
|
||||
get { return icon.Icon; }
|
||||
set { icon.Icon = value; }
|
||||
get => icon.Icon;
|
||||
set => icon.Icon = value;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
@ -52,8 +52,8 @@ namespace osu.Game.Graphics.UserInterface
|
||||
/// </summary>
|
||||
public Vector2 IconScale
|
||||
{
|
||||
get { return icon.Scale; }
|
||||
set { icon.Scale = value; }
|
||||
get => icon.Scale;
|
||||
set => icon.Scale = value;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
|
@ -44,7 +44,7 @@ namespace osu.Game.Graphics.UserInterface
|
||||
/// </summary>
|
||||
public IEnumerable<float> Values
|
||||
{
|
||||
get { return values; }
|
||||
get => values;
|
||||
set
|
||||
{
|
||||
values = value.ToArray();
|
||||
|
@ -75,7 +75,7 @@ namespace osu.Game.Graphics.UserInterface
|
||||
|
||||
public bool Glowing
|
||||
{
|
||||
get { return glowing; }
|
||||
get => glowing;
|
||||
set
|
||||
{
|
||||
glowing = value;
|
||||
@ -95,7 +95,7 @@ namespace osu.Game.Graphics.UserInterface
|
||||
|
||||
public bool Expanded
|
||||
{
|
||||
set { this.ResizeTo(new Vector2(value ? EXPANDED_SIZE : COLLAPSED_SIZE, 12), 500, Easing.OutQuint); }
|
||||
set => this.ResizeTo(new Vector2(value ? EXPANDED_SIZE : COLLAPSED_SIZE, 12), 500, Easing.OutQuint);
|
||||
}
|
||||
|
||||
private readonly Bindable<bool> current = new Bindable<bool>();
|
||||
@ -117,7 +117,7 @@ namespace osu.Game.Graphics.UserInterface
|
||||
|
||||
public Color4 AccentColour
|
||||
{
|
||||
get { return accentColour; }
|
||||
get => accentColour;
|
||||
set
|
||||
{
|
||||
accentColour = value;
|
||||
@ -130,7 +130,7 @@ namespace osu.Game.Graphics.UserInterface
|
||||
|
||||
public Color4 GlowingAccentColour
|
||||
{
|
||||
get { return glowingAccentColour; }
|
||||
get => glowingAccentColour;
|
||||
set
|
||||
{
|
||||
glowingAccentColour = value;
|
||||
@ -143,7 +143,7 @@ namespace osu.Game.Graphics.UserInterface
|
||||
|
||||
public Color4 GlowColour
|
||||
{
|
||||
get { return glowColour; }
|
||||
get => glowColour;
|
||||
set
|
||||
{
|
||||
glowColour = value;
|
||||
|
@ -33,7 +33,7 @@ namespace osu.Game.Graphics.UserInterface
|
||||
|
||||
public string LabelText
|
||||
{
|
||||
get { return labelSpriteText?.Text; }
|
||||
get => labelSpriteText?.Text;
|
||||
set
|
||||
{
|
||||
if (labelSpriteText != null)
|
||||
@ -43,7 +43,7 @@ namespace osu.Game.Graphics.UserInterface
|
||||
|
||||
public MarginPadding LabelPadding
|
||||
{
|
||||
get { return labelSpriteText?.Padding ?? new MarginPadding(); }
|
||||
get => labelSpriteText?.Padding ?? new MarginPadding();
|
||||
set
|
||||
{
|
||||
if (labelSpriteText != null)
|
||||
|
@ -20,7 +20,7 @@ namespace osu.Game.Graphics.UserInterface
|
||||
|
||||
public Color4 AccentColour
|
||||
{
|
||||
get { return accentColour; }
|
||||
get => accentColour;
|
||||
set
|
||||
{
|
||||
accentColour = value;
|
||||
@ -88,7 +88,7 @@ namespace osu.Game.Graphics.UserInterface
|
||||
|
||||
public Color4 AccentColour
|
||||
{
|
||||
get { return accentColour; }
|
||||
get => accentColour;
|
||||
set
|
||||
{
|
||||
accentColour = value;
|
||||
@ -110,7 +110,7 @@ namespace osu.Game.Graphics.UserInterface
|
||||
|
||||
public Color4 AccentColour
|
||||
{
|
||||
get { return accentColour ?? nonAccentSelectedColour; }
|
||||
get => accentColour ?? nonAccentSelectedColour;
|
||||
set
|
||||
{
|
||||
accentColour = value;
|
||||
@ -164,8 +164,8 @@ namespace osu.Game.Graphics.UserInterface
|
||||
{
|
||||
public string Text
|
||||
{
|
||||
get { return Label.Text; }
|
||||
set { Label.Text = value; }
|
||||
get => Label.Text;
|
||||
set => Label.Text = value;
|
||||
}
|
||||
|
||||
public readonly OsuSpriteText Label;
|
||||
@ -211,8 +211,8 @@ namespace osu.Game.Graphics.UserInterface
|
||||
|
||||
protected override string Label
|
||||
{
|
||||
get { return Text.Text; }
|
||||
set { Text.Text = value; }
|
||||
get => Text.Text;
|
||||
set => Text.Text = value;
|
||||
}
|
||||
|
||||
protected readonly SpriteIcon Icon;
|
||||
@ -221,7 +221,7 @@ namespace osu.Game.Graphics.UserInterface
|
||||
|
||||
public virtual Color4 AccentColour
|
||||
{
|
||||
get { return accentColour; }
|
||||
get => accentColour;
|
||||
set
|
||||
{
|
||||
accentColour = value;
|
||||
|
@ -125,7 +125,7 @@ namespace osu.Game.Graphics.UserInterface
|
||||
{
|
||||
public string Text
|
||||
{
|
||||
get { return NormalText.Text; }
|
||||
get => NormalText.Text;
|
||||
set
|
||||
{
|
||||
NormalText.Text = value;
|
||||
|
@ -38,7 +38,7 @@ namespace osu.Game.Graphics.UserInterface
|
||||
|
||||
public Color4 AccentColour
|
||||
{
|
||||
get { return accentColour; }
|
||||
get => accentColour;
|
||||
set
|
||||
{
|
||||
accentColour = value;
|
||||
|
@ -61,7 +61,7 @@ namespace osu.Game.Graphics.UserInterface
|
||||
|
||||
public Color4 AccentColour
|
||||
{
|
||||
get { return accentColour; }
|
||||
get => accentColour;
|
||||
set
|
||||
{
|
||||
accentColour = value;
|
||||
@ -105,7 +105,7 @@ namespace osu.Game.Graphics.UserInterface
|
||||
|
||||
public Color4 AccentColour
|
||||
{
|
||||
get { return accentColour; }
|
||||
get => accentColour;
|
||||
set
|
||||
{
|
||||
accentColour = value;
|
||||
@ -227,8 +227,7 @@ namespace osu.Game.Graphics.UserInterface
|
||||
{
|
||||
public override Color4 AccentColour
|
||||
{
|
||||
get { return base.AccentColour; }
|
||||
|
||||
get => base.AccentColour;
|
||||
set
|
||||
{
|
||||
base.AccentColour = value;
|
||||
|
@ -27,7 +27,7 @@ namespace osu.Game.Graphics.UserInterface
|
||||
|
||||
public Color4 AccentColour
|
||||
{
|
||||
get { return accentColour.GetValueOrDefault(); }
|
||||
get => accentColour.GetValueOrDefault();
|
||||
set
|
||||
{
|
||||
accentColour = value;
|
||||
@ -42,8 +42,8 @@ namespace osu.Game.Graphics.UserInterface
|
||||
|
||||
public string Text
|
||||
{
|
||||
get { return text.Text; }
|
||||
set { text.Text = value; }
|
||||
get => text.Text;
|
||||
set => text.Text = value;
|
||||
}
|
||||
|
||||
private const float transition_length = 500;
|
||||
|
@ -18,7 +18,7 @@ namespace osu.Game.Graphics.UserInterface
|
||||
|
||||
public Color4 FillColour
|
||||
{
|
||||
set { fill.FadeColour(value, 150, Easing.OutQuint); }
|
||||
set => fill.FadeColour(value, 150, Easing.OutQuint);
|
||||
}
|
||||
|
||||
public Color4 BackgroundColour
|
||||
@ -32,12 +32,12 @@ namespace osu.Game.Graphics.UserInterface
|
||||
|
||||
public double EndTime
|
||||
{
|
||||
set { CurrentNumber.MaxValue = value; }
|
||||
set => CurrentNumber.MaxValue = value;
|
||||
}
|
||||
|
||||
public double CurrentTime
|
||||
{
|
||||
set { CurrentNumber.Value = value; }
|
||||
set => CurrentNumber.Value = value;
|
||||
}
|
||||
|
||||
public ProgressBar()
|
||||
|
@ -45,10 +45,7 @@ namespace osu.Game.Graphics.UserInterface
|
||||
/// </summary>
|
||||
public virtual T DisplayedCount
|
||||
{
|
||||
get
|
||||
{
|
||||
return displayedCount;
|
||||
}
|
||||
get => displayedCount;
|
||||
|
||||
set
|
||||
{
|
||||
@ -71,8 +68,8 @@ namespace osu.Game.Graphics.UserInterface
|
||||
|
||||
public Color4 AccentColour
|
||||
{
|
||||
get { return DisplayedCountSpriteText.Colour; }
|
||||
set { DisplayedCountSpriteText.Colour = value; }
|
||||
get => DisplayedCountSpriteText.Colour;
|
||||
set => DisplayedCountSpriteText.Colour = value;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
|
@ -41,10 +41,7 @@ namespace osu.Game.Graphics.UserInterface
|
||||
/// </summary>
|
||||
public float CountStars
|
||||
{
|
||||
get
|
||||
{
|
||||
return countStars;
|
||||
}
|
||||
get => countStars;
|
||||
|
||||
set
|
||||
{
|
||||
|
@ -31,10 +31,7 @@ namespace osu.Game.Graphics.UserInterface
|
||||
|
||||
public bool MatchingFilter
|
||||
{
|
||||
set
|
||||
{
|
||||
this.FadeTo(value ? 1 : 0);
|
||||
}
|
||||
set => this.FadeTo(value ? 1 : 0);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -48,8 +48,7 @@ namespace osu.Game.Graphics.UserInterface
|
||||
|
||||
public override Anchor Origin
|
||||
{
|
||||
get { return base.Origin; }
|
||||
|
||||
get => base.Origin;
|
||||
set
|
||||
{
|
||||
base.Origin = value;
|
||||
@ -152,12 +151,12 @@ namespace osu.Game.Graphics.UserInterface
|
||||
|
||||
public FontAwesome Icon
|
||||
{
|
||||
set { bouncingIcon.Icon = value; }
|
||||
set => bouncingIcon.Icon = value;
|
||||
}
|
||||
|
||||
public string Text
|
||||
{
|
||||
set { text.Text = value; }
|
||||
set => text.Text = value;
|
||||
}
|
||||
|
||||
public override bool ReceivePositionalInputAt(Vector2 screenSpacePos) => IconLayer.ReceivePositionalInputAt(screenSpacePos) || TextLayer.ReceivePositionalInputAt(screenSpacePos);
|
||||
|
Reference in New Issue
Block a user