Skip to content

Consistent mouse and key event handling #1822

@eruvanos

Description

@eruvanos

From Discord

There are established patterns from other UI libraries and the web which can be copied unless we have good reason to deviate.

Mouse events go to the widget when overlapping the widget's bounds, keyboard events go to the widget when it has "focus"

Revisit the event logic and check if these changes are applicable.

  • widgets drop mouse events and do not pass them further, if they are out of bounce
  • only focused widget receives text events
  • one widget can be focused per UIManager

Metadata

Metadata

Assignees

Labels

guiRelated to arcade GUI (sub module arcade.gui)

Type

No type

Projects

Status

Done

Relationships

None yet

Development

No branches or pull requests

Issue actions