From 5646f7777e77bd6c7a5414debef4bfd9c7c769cd Mon Sep 17 00:00:00 2001 From: Dean Herbert Date: Thu, 23 Jan 2020 16:23:42 +0900 Subject: [PATCH] Add comment about custom SelectionHandler --- .../Components/Timeline/TimelineBlueprintContainer.cs | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/osu.Game/Screens/Edit/Compose/Components/Timeline/TimelineBlueprintContainer.cs b/osu.Game/Screens/Edit/Compose/Components/Timeline/TimelineBlueprintContainer.cs index c1458480a6..6bfd323c13 100644 --- a/osu.Game/Screens/Edit/Compose/Components/Timeline/TimelineBlueprintContainer.cs +++ b/osu.Game/Screens/Edit/Compose/Components/Timeline/TimelineBlueprintContainer.cs @@ -82,15 +82,16 @@ namespace osu.Game.Screens.Edit.Compose.Components.Timeline protected override SelectionHandler CreateSelectionHandler() => new TimelineSelectionHandler(); - internal class TimelineSelectionHandler : SelectionHandler - { - public override bool HandleMovement(MoveSelectionEvent moveEvent) => true; - } - protected override SelectionBlueprint CreateBlueprintFor(HitObject hitObject) => new TimelineHitObjectBlueprint(hitObject); protected override DragBox CreateDragBox(Action performSelect) => new TimelineDragBox(performSelect); + internal class TimelineSelectionHandler : SelectionHandler + { + // for now we always allow movement. snapping is provided by the Timeline's "distance" snap implementation + public override bool HandleMovement(MoveSelectionEvent moveEvent) => true; + } + private class TimelineDragBox : DragBox { private Vector2 lastMouseDown;