Skip to content

Expose two-way editor focus - #175

Open
yvos wants to merge 1 commit into
nodes-app:mainfrom
yvos:nofray/focus-binding
Open

Expose two-way editor focus#175
yvos wants to merge 1 commit into
nodes-app:mainfrom
yvos:nofray/focus-binding

Conversation

@yvos

@yvos yvos commented Sep 3, 2026

Copy link
Copy Markdown

Summary

  • Add an optional two-way isFocused binding to NativeTextViewWrapper.
  • Fulfill host focus requests immediately or after window attachment.
  • Report actual first-responder transitions without disturbing another control.
  • Preserve AppKit-owned focus when the binding is omitted.

This is the focus half of #173.

Validation

  • FocusBindingTests: 7 tests passed.
  • Full suite: 477 tests in 69 suites passed.
  • Demo call site includes a programmatic focus button.

Embedders need to request and observe first-responder state without introspecting the wrapped AppKit view. Keep the binding optional so existing focus behavior is unchanged.
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