Skip to content

access_kit_winit Adapter::on_event is confusingly named and undocumented #300

@alice-i-cecile

Description

@alice-i-cecile

This call seems to propagate winit events into access_kit in order to be handled correctly.

The boolean returned seems to reflect whether or not the event should be filtered and absorbed, per bevyengine/bevy#10239 (comment), but currently always returns true across platforms. This is particularly confusing because the wrapping struct (of the same name)'s method is marked #[must_use].

I'm new to accesskit's codebase, but a few requests to ease integration:

  1. Rename on_event to something that clearly indicates that there will be side-effects, like process_winit_event
  2. Add documentation for these methods.
  3. Change the returned bool to a more meaningful enum, either a Result or a custom ShouldFilter enum to better communicate intended use.

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions