mirror of
https://github.com/osukey/osukey.git
synced 2025-07-03 01:09:57 +09:00
.NET Standard 2.1 implements Math.Clamp , use it instead of MathHelper.Clamp from osuTK.
This commit is contained in:
@ -84,7 +84,7 @@ namespace osu.Game.Screens.Edit.Compose.Components.Timeline
|
||||
get => zoomTarget;
|
||||
set
|
||||
{
|
||||
value = MathHelper.Clamp(value, MinZoom, MaxZoom);
|
||||
value = Math.Clamp(value, MinZoom, MaxZoom);
|
||||
|
||||
if (IsLoaded)
|
||||
setZoomTarget(value, ToSpaceOfOtherDrawable(new Vector2(DrawWidth / 2, 0), zoomedContent).X);
|
||||
@ -117,7 +117,7 @@ namespace osu.Game.Screens.Edit.Compose.Components.Timeline
|
||||
|
||||
private void setZoomTarget(float newZoom, float focusPoint)
|
||||
{
|
||||
zoomTarget = MathHelper.Clamp(newZoom, MinZoom, MaxZoom);
|
||||
zoomTarget = Math.Clamp(newZoom, MinZoom, MaxZoom);
|
||||
transformZoomTo(zoomTarget, focusPoint, ZoomDuration, ZoomEasing);
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user