1
0
mirror of https://github.com/ppy/osu.git synced 2025-02-22 05:23:05 +08:00

Fix BlueprintContainer eating input from skin editor buttons

This commit is contained in:
Salman Ahmed 2022-06-18 18:28:36 +03:00
parent cbc218200a
commit a5e5172b91
4 changed files with 15 additions and 8 deletions

View File

@ -108,13 +108,6 @@ namespace osu.Game.Screens.Edit.Compose.Components
/// </summary> /// </summary>
protected virtual bool AllowDeselectionDuringDrag => true; protected virtual bool AllowDeselectionDuringDrag => true;
/// <remarks>
/// Positional input must be received outside the container's bounds,
/// in order to handle blueprints which are partially offscreen.
/// </remarks>
/// <seealso cref="SelectionHandler{T}.ReceivePositionalInputAt"/>
public override bool ReceivePositionalInputAt(Vector2 screenSpacePos) => true;
protected override bool OnMouseDown(MouseDownEvent e) protected override bool OnMouseDown(MouseDownEvent e)
{ {
bool selectionPerformed = performMouseDownActions(e); bool selectionPerformed = performMouseDownActions(e);

View File

@ -39,6 +39,12 @@ namespace osu.Game.Screens.Edit.Compose.Components
private PlacementBlueprint currentPlacement; private PlacementBlueprint currentPlacement;
private InputManager inputManager; private InputManager inputManager;
/// <remarks>
/// Positional input must be received outside the container's bounds,
/// in order to handle composer blueprints which are partially offscreen.
/// </remarks>
public override bool ReceivePositionalInputAt(Vector2 screenSpacePos) => true;
public ComposeBlueprintContainer(HitObjectComposer composer) public ComposeBlueprintContainer(HitObjectComposer composer)
: base(composer) : base(composer)
{ {

View File

@ -21,6 +21,7 @@ using osu.Game.Graphics.UserInterface;
using osu.Game.Input.Bindings; using osu.Game.Input.Bindings;
using osu.Game.Resources.Localisation.Web; using osu.Game.Resources.Localisation.Web;
using osu.Game.Rulesets.Edit; using osu.Game.Rulesets.Edit;
using osu.Game.Screens.Edit.Compose.Components.Timeline;
using osuTK; using osuTK;
using osuTK.Input; using osuTK.Input;
@ -103,7 +104,8 @@ namespace osu.Game.Screens.Edit.Compose.Components
/// Positional input must be received outside the container's bounds, /// Positional input must be received outside the container's bounds,
/// in order to handle blueprints which are partially offscreen. /// in order to handle blueprints which are partially offscreen.
/// </remarks> /// </remarks>
/// <seealso cref="BlueprintContainer{T}.ReceivePositionalInputAt"/> /// <seealso cref="ComposeBlueprintContainer.ReceivePositionalInputAt"/>
/// <seealso cref="TimelineBlueprintContainer.ReceivePositionalInputAt"/>
public override bool ReceivePositionalInputAt(Vector2 screenSpacePos) => true; public override bool ReceivePositionalInputAt(Vector2 screenSpacePos) => true;
/// <summary> /// <summary>

View File

@ -35,6 +35,12 @@ namespace osu.Game.Screens.Edit.Compose.Components.Timeline
private Bindable<HitObject> placement; private Bindable<HitObject> placement;
private SelectionBlueprint<HitObject> placementBlueprint; private SelectionBlueprint<HitObject> placementBlueprint;
/// <remarks>
/// Positional input must be received outside the container's bounds,
/// in order to handle timeline blueprints which are stacked offscreen.
/// </remarks>
public override bool ReceivePositionalInputAt(Vector2 screenSpacePos) => timeline.ReceivePositionalInputAt(screenSpacePos);
public TimelineBlueprintContainer(HitObjectComposer composer) public TimelineBlueprintContainer(HitObjectComposer composer)
: base(composer) : base(composer)
{ {