Use expression body for property get/set where possible

This commit is contained in:
Dean Herbert
2019-02-28 13:58:19 +09:00
parent 94a389319d
commit 42be7857d1
130 changed files with 297 additions and 403 deletions

View File

@ -19,7 +19,7 @@ namespace osu.Game.Graphics.UserInterface
private Color4 accentColour;
public Color4 AccentColour
{
get { return accentColour; }
get => accentColour;
set
{
accentColour = value;
@ -85,7 +85,7 @@ namespace osu.Game.Graphics.UserInterface
private Color4 accentColour;
public Color4 AccentColour
{
get { return accentColour; }
get => accentColour;
set
{
accentColour = value;
@ -105,7 +105,7 @@ namespace osu.Game.Graphics.UserInterface
private Color4? accentColour;
public Color4 AccentColour
{
get { return accentColour ?? nonAccentSelectedColour; }
get => accentColour ?? nonAccentSelectedColour;
set
{
accentColour = value;
@ -159,8 +159,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;
@ -203,8 +203,8 @@ namespace osu.Game.Graphics.UserInterface
protected readonly SpriteText Text;
protected override string Label
{
get { return Text.Text; }
set { Text.Text = value; }
get => Text.Text;
set => Text.Text = value;
}
protected readonly SpriteIcon Icon;
@ -212,7 +212,7 @@ namespace osu.Game.Graphics.UserInterface
private Color4 accentColour;
public virtual Color4 AccentColour
{
get { return accentColour; }
get => accentColour;
set
{
accentColour = value;