Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Rename timer_update → timer, add AdaptEventCx, pass only ConfigCx to Widget::_nav_next #421

Merged
merged 11 commits into from
Dec 4, 2023

Conversation

dhardy
Copy link
Collaborator

@dhardy dhardy commented Nov 30, 2023

This is a series of fixes and tweaks used while updating 7GUIs.

  • Remove parameter first of EventState::request_timer_update since it is reasonable to always use true
  • Rename timer_updatetimer for brevity
  • Add AdaptConfigCx and AdaptEventCx. These are essentially ConfigCx / EventCx plus an Id, allowing some methods to be called without specifying an id (for use from methods like Adapt::on_configure). This is very much a half-baked addition; likely more methods should be supported, possibly these should be moved to kas-core, possibly even integrated with ConfigCx and EventCx (the latter is not ideal since various methods such as _send impls would need to update the id both before and after recursing to children).
  • Remove MatrixData::ColKey: DataKey and RowKey: DataKey bound (not needed)
  • Pass only ConfigCx (instead of EventCx) into Widget::_nav_next. This fixes a slightly obscure bug where ListView::_nav_next would set EventCx::scroll, nothing would handle or clear this, and later a debug_assert! on EventCx::send_event would fail.
  • Fix infinite loop in ListView::_nav_next and MatrixView::_nav_next
  • Fix handling of (Lost)KeyFocus with mouse input

@dhardy dhardy merged commit 90b19d6 into master Dec 4, 2023
5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant