mirror of
https://github.com/osukey/osukey.git
synced 2025-08-04 23:24:04 +09:00
Update with framework bindable changes
This commit is contained in:
@ -69,10 +69,10 @@ namespace osu.Game.Overlays.Volume
|
||||
}
|
||||
});
|
||||
|
||||
Current.ValueChanged += newValue =>
|
||||
Current.ValueChanged += e =>
|
||||
{
|
||||
icon.Icon = newValue ? FontAwesome.fa_volume_off : FontAwesome.fa_volume_up;
|
||||
icon.Margin = new MarginPadding { Left = newValue ? width / 2 - 15 : width / 2 - 10 }; //Magic numbers to line up both icons because they're different widths
|
||||
icon.Icon = e.NewValue ? FontAwesome.fa_volume_off : FontAwesome.fa_volume_up;
|
||||
icon.Margin = new MarginPadding { Left = e.NewValue ? width / 2 - 15 : width / 2 - 10 }; //Magic numbers to line up both icons because they're different widths
|
||||
};
|
||||
Current.TriggerChange();
|
||||
}
|
||||
|
@ -175,10 +175,10 @@ namespace osu.Game.Overlays.Volume
|
||||
}
|
||||
}
|
||||
};
|
||||
Bindable.ValueChanged += newVolume =>
|
||||
Bindable.ValueChanged += e =>
|
||||
{
|
||||
this.TransformTo("DisplayVolume",
|
||||
newVolume,
|
||||
e.NewValue,
|
||||
400,
|
||||
Easing.OutQuint);
|
||||
};
|
||||
@ -218,7 +218,7 @@ namespace osu.Game.Overlays.Volume
|
||||
|
||||
public double Volume
|
||||
{
|
||||
get => Bindable;
|
||||
get => Bindable.Value;
|
||||
private set => Bindable.Value = value;
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user