From f1f7d978ec92be92183755cd9a1fa646e1d3e1b3 Mon Sep 17 00:00:00 2001 From: smoogipoo Date: Fri, 30 Mar 2018 16:28:59 +0900 Subject: [PATCH] Add some comments --- osu.Game/Screens/Edit/Screens/Compose/Layers/Selection.cs | 2 ++ 1 file changed, 2 insertions(+) diff --git a/osu.Game/Screens/Edit/Screens/Compose/Layers/Selection.cs b/osu.Game/Screens/Edit/Screens/Compose/Layers/Selection.cs index 4ff1284f8a..427acbef5a 100644 --- a/osu.Game/Screens/Edit/Screens/Compose/Layers/Selection.cs +++ b/osu.Game/Screens/Edit/Screens/Compose/Layers/Selection.cs @@ -68,6 +68,7 @@ namespace osu.Game.Screens.Edit.Screens.Compose.Layers protected override bool OnMouseDown(InputState state, MouseDownEventArgs args) { + // If masks are overlapping, make sure we don't change the selection if the overlapped portion is pressed if (selectedMasks.Any(m => m.ReceiveMouseInputAt(state.Mouse.NativeState.Position))) return true; @@ -80,6 +81,7 @@ namespace osu.Game.Screens.Edit.Screens.Compose.Layers protected override bool OnClick(InputState state) { + // If there's only mask, this isn't going to change anything, so we can save on doing some processing here if (selectedMasks.Count == 1) return true;