mirror of
https://github.com/osukey/osukey.git
synced 2025-08-02 22:26:41 +09:00
Fix cursor being displayed on intro/disclaimer
This commit is contained in:
@ -14,6 +14,11 @@ namespace osu.Game.Graphics.Cursor
|
||||
protected override Container<Drawable> Content => content;
|
||||
private readonly Container content;
|
||||
|
||||
/// <summary>
|
||||
/// Whether any cursors can be displayed.
|
||||
/// </summary>
|
||||
public bool CanShowCursor;
|
||||
|
||||
public CursorContainer LocalCursor { get; }
|
||||
public bool ProvidesUserCursor => true;
|
||||
|
||||
@ -39,6 +44,12 @@ namespace osu.Game.Graphics.Cursor
|
||||
{
|
||||
base.Update();
|
||||
|
||||
if (!CanShowCursor)
|
||||
{
|
||||
currentTarget?.LocalCursor?.Hide();
|
||||
return;
|
||||
}
|
||||
|
||||
var newTarget = inputManager.HoveredDrawables.OfType<IProvideLocalCursor>().FirstOrDefault(t => t.ProvidesUserCursor) ?? this;
|
||||
|
||||
if (currentTarget == newTarget)
|
||||
|
Reference in New Issue
Block a user