mirror of
https://github.com/ppy/osu
synced 2025-02-17 19:07:07 +00:00
Allow placement deletion with middle mouse
This is in addition to Shift + Right-click. I thik middle mouse feels more natural and is a good permanent solution to this issue. Note that this also *allows triggering the context menu from placement mode*. Until now it's done nothing. This may be annoying to users with muscle memory but I want to make the change and harvest feedback. I think showing the context menu is more correct behaviour (although arguably it should return to placement mode on dismiss?).
This commit is contained in:
parent
136cdcfb29
commit
0557b9ab79
@ -209,9 +209,7 @@ namespace osu.Game.Rulesets.Edit
|
||||
|
||||
case MouseButtonEvent mouse:
|
||||
// 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;
|
||||
return mouse.Button == MouseButton.Left || PlacementActive == PlacementState.Active;
|
||||
|
||||
default:
|
||||
return false;
|
||||
|
@ -263,7 +263,7 @@ namespace osu.Game.Screens.Edit.Compose.Components
|
||||
/// <returns>Whether a selection was performed.</returns>
|
||||
internal virtual bool MouseDownSelectionRequested(SelectionBlueprint<T> blueprint, MouseButtonEvent e)
|
||||
{
|
||||
if (e.ShiftPressed && e.Button == MouseButton.Right)
|
||||
if (e.Button == MouseButton.Middle || (e.ShiftPressed && e.Button == MouseButton.Right))
|
||||
{
|
||||
handleQuickDeletion(blueprint);
|
||||
return true;
|
||||
|
Loading…
Reference in New Issue
Block a user