Fix mouse button disable not disabling touch input mappings

This commit is contained in:
Dean Herbert 2022-01-05 18:29:32 +09:00
parent df6a755c36
commit 88602ec1b4
1 changed files with 11 additions and 0 deletions

View File

@ -127,6 +127,17 @@ protected override bool Handle(UIEvent e)
return base.Handle(e); return base.Handle(e);
} }
protected override bool HandleMouseTouchStateChange(TouchStateChangeEvent e)
{
if (mouseDisabled.Value)
{
// Only propagate positional data when mouse buttons are disabled.
e = new TouchStateChangeEvent(e.State, e.Input, e.Touch, false, e.LastPosition);
}
return base.HandleMouseTouchStateChange(e);
}
#endregion #endregion
#region Key Counter Attachment #region Key Counter Attachment