mirror of
https://github.com/ppy/osu.git
synced 2025-01-14 20:03:21 +08:00
Fix button alignment and animation
This commit is contained in:
parent
86f5c9d6f1
commit
93ffa1f8a2
@ -15,7 +15,7 @@ namespace osu.Game.Graphics.UserInterface
|
||||
{
|
||||
public class IconButton : OsuClickableContainer
|
||||
{
|
||||
private const float button_size = 30;
|
||||
public const float BUTTON_SIZE = 30;
|
||||
|
||||
private Color4? flashColour;
|
||||
/// <summary>
|
||||
@ -106,7 +106,7 @@ namespace osu.Game.Graphics.UserInterface
|
||||
{
|
||||
Origin = Anchor.Centre,
|
||||
Anchor = Anchor.Centre,
|
||||
Size = new Vector2(button_size),
|
||||
Size = new Vector2(BUTTON_SIZE),
|
||||
CornerRadius = 5,
|
||||
Masking = true,
|
||||
EdgeEffect = new EdgeEffectParameters
|
||||
|
@ -36,11 +36,16 @@ namespace osu.Game.Graphics.UserInterface.Volume
|
||||
Spacing = new Vector2(15, 0),
|
||||
Children = new Drawable[]
|
||||
{
|
||||
muteIcon = new IconButton
|
||||
new Container
|
||||
{
|
||||
Icon = FontAwesome.fa_volume_up,
|
||||
Scale = new Vector2(2.0f),
|
||||
Action = () => Adjust(GlobalAction.ToggleMute),
|
||||
Size = new Vector2(IconButton.BUTTON_SIZE),
|
||||
Child = muteIcon = new IconButton
|
||||
{
|
||||
Anchor = Anchor.Centre,
|
||||
Origin = Anchor.Centre,
|
||||
Icon = FontAwesome.fa_volume_up,
|
||||
Action = () => Adjust(GlobalAction.ToggleMute),
|
||||
}
|
||||
},
|
||||
volumeMeterMaster = new VolumeMeter("Master"),
|
||||
volumeMeterEffect = new VolumeMeter("Effects"),
|
||||
|
Loading…
Reference in New Issue
Block a user