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

@ -48,10 +48,7 @@ namespace osu.Game.Graphics.UserInterface
public override Anchor Origin
{
get
{
return base.Origin;
}
get => base.Origin;
set
{
@ -155,18 +152,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);
@ -217,7 +208,7 @@ namespace osu.Game.Graphics.UserInterface
private readonly SpriteIcon icon;
public FontAwesome Icon { set { icon.Icon = value; } }
public FontAwesome Icon { set => icon.Icon = value; }
public BouncingIcon()
{