Skip to content

Present Point and Mouse as scanning modes - #859

Merged
enaboapps merged 4 commits into
mainfrom
codex/858-point-mouse-modes
Sep 23, 2026
Merged

enaboapps merged 4 commits into
mainfrom
codex/858-point-mouse-modes

Conversation

@enaboapps

@enaboapps enaboapps commented Sep 23, 2026 •

Copy link
Copy Markdown
Contributor

Closes #858.

Present Point and Mouse as the two primary scanning modes. Select resumes the last explicitly used mode across app restarts, defaulting to Point for older settings. Add Open Point as an additive switch action; the Mouse panel now switches directly to Point. The Scanning page explains both paths before shared and advanced settings.

Validation:

  • Node 24: npm run lint, npm test, and npm run build passed (218 UI tests and 5 Node tests).
  • Rust 1.97.1: cargo fmt --manifest-path src-tauri/Cargo.toml --check, cargo clippy --manifest-path src-tauri/Cargo.toml --all-targets -- -D warnings, and cargo test --manifest-path src-tauri/Cargo.toml passed (512 unit tests, 1 ignored, 7 integration tests).
  • Windows 11 Parallels ARM64 VM: built the latest head 4cea753 with Node 24.19.0 and Rust 1.97.1 using npm run tauri -- build --debug --no-bundle --target aarch64-pc-windows-msvc. Tested native switch key press/release edges against ordinary Notepad windows: Select started Point, Open Mouse entered Mouse, Open Point returned to Point, and the Mouse panel's Switch to Point tile returned to Point. Escape stopped without changing the saved Mouse mode; after app restart, Select reopened Mouse. The pointer ring appeared in Mouse and cleared on Point/Stop. The native settings page displayed the two mode cards and the saved Select mode. Restored original VM configuration files byte-for-byte and left the corrected build running.
  • VM limits: Parallels-generated key events exercised Windows switch capture but were not a separate physical switch device. The VM has one monitor, and no Android Remote was connected; monitor navigation and remote disconnect rely on automated tests.
  • Independent review of 4cea753 found no actionable findings.
  • Required PR CI passed on 4cea753: frontend (rerun after an unrelated switch-practice focus timing failure), dependency audit, macOS native, Windows native/NSIS and UI Access, CodeQL, and JavaScript/TypeScript analysis.

Follow-up review fixes (ddbd3ad, d14d0e1):

  • Saving settings from the UI keeps the saved Point/Mouse mode, so an out-of-date UI config can no longer overwrite it. The config is merged and saved while holding the controller lock.
  • All scanning settings saves replace the file safely: the new contents are written to a temp file, flushed to disk and then renamed over the old file, and the temp file is removed if anything fails. Before this, a write interrupted by a crash could corrupt the settings file, and the app would then quietly reset all scanning settings to defaults.
  • If saving the mode fails, the switch action still runs. The mode is kept in memory and written with the next settings save.
  • Rust 1.97.1: cargo fmt --check, cargo clippy --all-targets -- -D warnings and cargo test pass (514 unit tests, 1 ignored, 7 integration tests). Node 24: npm run lint and npm test pass (218 UI tests, 5 Node tests). The frontend is unchanged, so the build was not re-run. The Windows VM test has not been repeated on these commits.
  • Independent review of latest head d14d0e1 found no actionable findings. Two points were accepted as-is: the mode is saved before its action runs, and the runtime paths that need an AppHandle have no tests.

🤖 Generated with Claude Code

@enaboapps enaboapps added this to the v1.0.0-rc.16 milestone Sep 23, 2026
@enaboapps
enaboapps marked this pull request as ready for review September 23, 2026 14:04
Owen McGirr and others added 2 commits September 23, 2026 16:08
Settings saves from the UI keep the runtime-owned control mode instead of
overwriting it with a stale value. All scanning settings writes now replace
the file atomically, and a failed mode save no longer cancels the switch
action.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
@enaboapps
enaboapps merged commit 32d89ba into main Sep 23, 2026
9 of 10 checks passed
@enaboapps
enaboapps deleted the codex/858-point-mouse-modes branch September 23, 2026 15:42
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.

Present Point and Mouse as two scanning modes

1 participant