Skip to content

Fix Linux compose input and speed up local recipient suggestions - #29

Merged
mrinc merged 1 commit into
masterfrom
fix/linux-compose-and-local-recipients
Sep 28, 2026
Merged

mrinc merged 1 commit into
masterfrom
fix/linux-compose-and-local-recipients

Conversation

@bcbetterninja

Copy link
Copy Markdown
Collaborator

Linux compose bodies can render while keyboard input stays outside the embedded GTK window. Recipient autocomplete on all platforms can also stall after sync invalidates the directory, because it waits for saved contacts and the full local mail-history aggregate to finish.

This change explicitly transfers X11 keyboard focus into the GTK editor and returns it to the compose window when leaving the body. It keeps native keyboard handling and ignores focus transfers from other windows. Identical HTML binding updates no longer replace the DOM and disturb selection/undo state.

Recipient autocomplete now searches an in-memory snapshot while local refreshes run in the background. Saved contacts become available before mail-history aggregation finishes; the focused recipient field updates when more results arrive. Refresh failures retain existing results, concurrent refreshes coalesce, and account-scope changes discard the previous directory. No remote recipient searches are introduced.

Validation:

  • Solution and offline UI preview builds passed with no warnings or errors; all 546 unit tests passed.
  • Real X11 input regression fails against the prior app build when returning from To to the editor through Avalonia focus, and passes with this change. Tested typing, Shift, Backspace, Enter, toolbar undo/redo, focus transitions, draft capture, and read-only behavior, including under Openbox. The check now runs in Linux PR CI.
  • Synthetic benchmark: 100 searches over 25,000 cached recipients while refresh was blocked; median 1.57 ms, p95 5.26 ms, max 11.19 ms on the development host. This measures warm-cache filtering, not cold database loading.
  • Reproduction host is Ubuntu 24.04 with WebKitGTK 2.52.6. The reported Ubuntu 26 desktop still needs confirmation; no real mail or personal screenshots were used.

@coderabbitai

coderabbitai Bot commented Sep 28, 2026 •

Copy link
Copy Markdown

Important

  • 🔍 Trigger review

This repository does not receive automatic reviews because it has fewer than 10 stars.

⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Advanced

Run ID: 5515076c-32c6-4648-92e6-9db7b432cd5c


Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@bcbetterninja
bcbetterninja marked this pull request as ready for review September 28, 2026 16:23
@mrinc
mrinc merged commit db55608 into master Sep 28, 2026
9 checks passed
@mrinc
mrinc deleted the fix/linux-compose-and-local-recipients branch September 28, 2026 16:40
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.

2 participants