mirror of
https://github.com/osukey/osukey.git
synced 2025-06-14 07:47:59 +09:00
Allow certain mouse input to pass through PlacementBlueprints
to the selection logic
This commit is contained in:
parent
cf1e3ea988
commit
9a7bf8109f
@ -14,6 +14,7 @@ using osu.Game.Rulesets.Objects;
|
|||||||
using osu.Game.Screens.Edit;
|
using osu.Game.Screens.Edit;
|
||||||
using osu.Game.Screens.Edit.Compose;
|
using osu.Game.Screens.Edit.Compose;
|
||||||
using osuTK;
|
using osuTK;
|
||||||
|
using osuTK.Input;
|
||||||
|
|
||||||
namespace osu.Game.Rulesets.Edit
|
namespace osu.Game.Rulesets.Edit
|
||||||
{
|
{
|
||||||
@ -128,8 +129,11 @@ namespace osu.Game.Rulesets.Edit
|
|||||||
case DoubleClickEvent _:
|
case DoubleClickEvent _:
|
||||||
return false;
|
return false;
|
||||||
|
|
||||||
case MouseButtonEvent _:
|
case MouseButtonEvent mouse:
|
||||||
return true;
|
// placement blueprints should generally block mouse from reaching underlying components (ie. performing clicks on interface buttons).
|
||||||
|
// for now, the one exception we want to allow is when using a non-main mouse button when shift is pressed, which is used to trigger object deletion
|
||||||
|
// while in placement mode.
|
||||||
|
return mouse.Button == MouseButton.Left || !mouse.ShiftPressed;
|
||||||
|
|
||||||
default:
|
default:
|
||||||
return false;
|
return false;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user