SelectionBoxDragHandleDisplay -> SelectionBoxDragHandleContainer

This commit is contained in:
Salman Ahmed
2021-04-25 19:59:08 +03:00
parent c58ef4230d
commit 7390a12e4b
2 changed files with 5 additions and 5 deletions

View File

@ -92,7 +92,7 @@ namespace osu.Game.Screens.Edit.Compose.Components
} }
} }
private SelectionBoxDragHandleDisplay dragHandles; private SelectionBoxDragHandleContainer dragHandles;
private FillFlowContainer buttons; private FillFlowContainer buttons;
public const float BORDER_RADIUS = 3; public const float BORDER_RADIUS = 3;
@ -161,7 +161,7 @@ namespace osu.Game.Screens.Edit.Compose.Components
}, },
} }
}, },
dragHandles = new SelectionBoxDragHandleDisplay dragHandles = new SelectionBoxDragHandleContainer
{ {
RelativeSizeAxes = Axes.Both, RelativeSizeAxes = Axes.Both,
// ensures that the centres of all drag handles line up with the middle of the selection box border. // ensures that the centres of all drag handles line up with the middle of the selection box border.

View File

@ -13,7 +13,7 @@ namespace osu.Game.Screens.Edit.Compose.Components
/// <summary> /// <summary>
/// Represents a display composite containing and managing the visibility state of the selection box's drag handles. /// Represents a display composite containing and managing the visibility state of the selection box's drag handles.
/// </summary> /// </summary>
public class SelectionBoxDragHandleDisplay : CompositeDrawable public class SelectionBoxDragHandleContainer : CompositeDrawable
{ {
private Container<SelectionBoxScaleHandle> scaleHandles; private Container<SelectionBoxScaleHandle> scaleHandles;
private Container<SelectionBoxRotationHandle> rotationHandles; private Container<SelectionBoxRotationHandle> rotationHandles;
@ -75,7 +75,7 @@ namespace osu.Game.Screens.Edit.Compose.Components
if (activeHandle?.InOperation == true || activeHandle?.IsHovered == true) if (activeHandle?.InOperation == true || activeHandle?.IsHovered == true)
return; return;
displayedRotationHandle?.FadeOut(SelectionBoxControl.TRANSFORM_DURATION, Easing.OutQuint); displayedRotationHandle?.Hide();
displayedRotationHandle = null; displayedRotationHandle = null;
activeHandle = allDragHandles.SingleOrDefault(h => h.InOperation); activeHandle = allDragHandles.SingleOrDefault(h => h.InOperation);
@ -84,7 +84,7 @@ namespace osu.Game.Screens.Edit.Compose.Components
if (activeHandle != null) if (activeHandle != null)
{ {
displayedRotationHandle = getCorrespondingRotationHandle(activeHandle, rotationHandles); displayedRotationHandle = getCorrespondingRotationHandle(activeHandle, rotationHandles);
displayedRotationHandle?.FadeIn(SelectionBoxControl.TRANSFORM_DURATION, Easing.OutQuint); displayedRotationHandle?.Show();
} }
} }