[PR #417] [MERGED] Macos menubar app #409

Closed
opened 2026-05-05 22:18:32 -06:00 by gitea-mirror · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/feschber/lan-mouse/pull/417
Author: @jondkinney
Created: 4/24/2026
Status: Merged
Merged: 4/29/2026
Merged by: @feschber

Base: mainHead: macos-menubar-app


📝 Commits (10+)

  • 2122750 bundle Adwaita symbolic icons in gresource
  • f095fb5 makeicns.sh: produce Big Sur+ style macOS app icon
  • 546d133 fix: create ~/.config/lan-mouse/ on first launch
  • 24062d7 macos: run as LSUIElement menubar app with NSStatusItem
  • 36f27c2 macos: per-pane TCC navigation and Sequoia-tolerant permission flow
  • d3d0804 fix: write a default config.toml on every Config::new()
  • a45e00e macos: prompt to relaunch after live Accessibility grant
  • 06e0c96 macos: drop the CapturePane / EmulationPane enums
  • a9cccd9 macos: hide Reenable warning row once Accessibility is granted
  • d1e963e macos: fold relaunch prompt into the warning row instead of a toast

📊 Changes

34 files changed (+1423 additions, -93 deletions)

View changed files

📝 Cargo.lock (+2 -0)
📝 Cargo.toml (+2 -0)
📝 README.md (+2 -1)
build-aux/macos-lsui-element.plist (+8 -0)
📝 input-capture/src/error.rs (+4 -0)
📝 input-capture/src/lib.rs (+13 -0)
📝 input-capture/src/macos.rs (+254 -66)
📝 input-emulation/Cargo.toml (+2 -0)
📝 input-emulation/src/error.rs (+4 -0)
📝 input-emulation/src/macos.rs (+38 -0)
lan-mouse-gtk/resources/icons/scalable/actions/edit-copy-symbolic.svg (+4 -0)
lan-mouse-gtk/resources/icons/scalable/actions/edit-delete-symbolic.svg (+4 -0)
lan-mouse-gtk/resources/icons/scalable/actions/emblem-ok-symbolic.svg (+4 -0)
lan-mouse-gtk/resources/icons/scalable/actions/list-add-symbolic.svg (+4 -0)
lan-mouse-gtk/resources/icons/scalable/actions/object-rotate-right-symbolic.svg (+4 -0)
lan-mouse-gtk/resources/icons/scalable/actions/object-select-symbolic.svg (+4 -0)
lan-mouse-gtk/resources/icons/scalable/actions/open-menu-symbolic.svg (+8 -0)
lan-mouse-gtk/resources/icons/scalable/actions/process-stop-symbolic.svg (+4 -0)
lan-mouse-gtk/resources/icons/scalable/devices/auth-fingerprint-symbolic.svg (+4 -0)
lan-mouse-gtk/resources/icons/scalable/devices/network-wired-symbolic.svg (+4 -0)

...and 14 more files

📄 Description

This includes commits from #416 as well so we can likely close that other PR.

The app will now properly prompt for accessibility permissions, and monitor for them being granted. Once granted the app will prompt to be restarted for the new permissions to take effect. That auto-relaunch flow and manual launches open the GUI window automatically, but closing that window leaves the app running in the menubar. And if it's set to auto-launch, then the GUI doesn't show on a reboot, etc.

If you revoke the accessibility permissions, the app quits itself since not quitting would leave the input system in a broken state where the cursor still moves but clicking doesn't work, nor do keypresses. Once revoked, a re-launch will re-prompt for accessibility permissions.

Menubar

CleanShot 2026-04-24 at 10 58 46@2x

Dock

CleanShot 2026-04-23 at 14 04 58@2x

Granting permissions

CleanShot 2026-04-24 at 11 03 43@2x

Restart required

CleanShot 2026-04-24 at 11 05 22@2x

Restarted

CleanShot 2026-04-24 at 11 06 44@2x

Download this PR's build for macOS for testing

Lan Mouse.zip

Because this is an ad-hoc signed bundle, you will need to remove quarantine before it will open

xattr -rd com.apple.quarantine "/Applications/Lan Mouse.app"

🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/feschber/lan-mouse/pull/417 **Author:** [@jondkinney](https://github.com/jondkinney) **Created:** 4/24/2026 **Status:** ✅ Merged **Merged:** 4/29/2026 **Merged by:** [@feschber](https://github.com/feschber) **Base:** `main` ← **Head:** `macos-menubar-app` --- ### 📝 Commits (10+) - [`2122750`](https://github.com/feschber/lan-mouse/commit/212275031b175d341a002c9832c35c0ae953d530) bundle Adwaita symbolic icons in gresource - [`f095fb5`](https://github.com/feschber/lan-mouse/commit/f095fb54446c9e74466101ce0f6f1e6299570241) makeicns.sh: produce Big Sur+ style macOS app icon - [`546d133`](https://github.com/feschber/lan-mouse/commit/546d133aeb42f546e0a854762b166caf4c4e9eef) fix: create ~/.config/lan-mouse/ on first launch - [`24062d7`](https://github.com/feschber/lan-mouse/commit/24062d7681218803dcec8c0a4440d9915d9851b6) macos: run as LSUIElement menubar app with NSStatusItem - [`36f27c2`](https://github.com/feschber/lan-mouse/commit/36f27c28acc1590e5c3cdf4bfb1efce6ea4623eb) macos: per-pane TCC navigation and Sequoia-tolerant permission flow - [`d3d0804`](https://github.com/feschber/lan-mouse/commit/d3d0804feed509533ad71149537e2750f853fd75) fix: write a default config.toml on every Config::new() - [`a45e00e`](https://github.com/feschber/lan-mouse/commit/a45e00e03aa2fd98d48398ed2bc0ec996b5587ee) macos: prompt to relaunch after live Accessibility grant - [`06e0c96`](https://github.com/feschber/lan-mouse/commit/06e0c96d679bafe7d96cd1fe84a9c57ac73cfcfd) macos: drop the CapturePane / EmulationPane enums - [`a9cccd9`](https://github.com/feschber/lan-mouse/commit/a9cccd95ece5412bcaa03cef02fb6a5f8715f685) macos: hide Reenable warning row once Accessibility is granted - [`d1e963e`](https://github.com/feschber/lan-mouse/commit/d1e963e90a94efc2a2873571239b1f1c1017f3a2) macos: fold relaunch prompt into the warning row instead of a toast ### 📊 Changes **34 files changed** (+1423 additions, -93 deletions) <details> <summary>View changed files</summary> 📝 `Cargo.lock` (+2 -0) 📝 `Cargo.toml` (+2 -0) 📝 `README.md` (+2 -1) ➕ `build-aux/macos-lsui-element.plist` (+8 -0) 📝 `input-capture/src/error.rs` (+4 -0) 📝 `input-capture/src/lib.rs` (+13 -0) 📝 `input-capture/src/macos.rs` (+254 -66) 📝 `input-emulation/Cargo.toml` (+2 -0) 📝 `input-emulation/src/error.rs` (+4 -0) 📝 `input-emulation/src/macos.rs` (+38 -0) ➕ `lan-mouse-gtk/resources/icons/scalable/actions/edit-copy-symbolic.svg` (+4 -0) ➕ `lan-mouse-gtk/resources/icons/scalable/actions/edit-delete-symbolic.svg` (+4 -0) ➕ `lan-mouse-gtk/resources/icons/scalable/actions/emblem-ok-symbolic.svg` (+4 -0) ➕ `lan-mouse-gtk/resources/icons/scalable/actions/list-add-symbolic.svg` (+4 -0) ➕ `lan-mouse-gtk/resources/icons/scalable/actions/object-rotate-right-symbolic.svg` (+4 -0) ➕ `lan-mouse-gtk/resources/icons/scalable/actions/object-select-symbolic.svg` (+4 -0) ➕ `lan-mouse-gtk/resources/icons/scalable/actions/open-menu-symbolic.svg` (+8 -0) ➕ `lan-mouse-gtk/resources/icons/scalable/actions/process-stop-symbolic.svg` (+4 -0) ➕ `lan-mouse-gtk/resources/icons/scalable/devices/auth-fingerprint-symbolic.svg` (+4 -0) ➕ `lan-mouse-gtk/resources/icons/scalable/devices/network-wired-symbolic.svg` (+4 -0) _...and 14 more files_ </details> ### 📄 Description This includes commits from #416 as well so we can likely close that other PR. The app will now properly prompt for accessibility permissions, and monitor for them being granted. Once granted the app will prompt to be restarted for the new permissions to take effect. That auto-relaunch flow and manual launches open the GUI window automatically, but closing that window leaves the app running in the menubar. And if it's set to auto-launch, then the GUI doesn't show on a reboot, etc. If you revoke the accessibility permissions, the app quits itself since not quitting would leave the input system in a broken state where the cursor still moves but clicking doesn't work, nor do keypresses. Once revoked, a re-launch will re-prompt for accessibility permissions. # Menubar <img width="398" height="136" alt="CleanShot 2026-04-24 at 10 58 46@2x" src="https://github.com/user-attachments/assets/b322a141-6d25-4f61-8169-60b71d22c819" /> # Dock <img width="702" height="572" alt="CleanShot 2026-04-23 at 14 04 58@2x" src="https://github.com/user-attachments/assets/f9c95def-838f-4b71-a759-4fe79daada41" /> # Granting permissions <img width="2798" height="2026" alt="CleanShot 2026-04-24 at 11 03 43@2x" src="https://github.com/user-attachments/assets/8116dff5-3448-4cdd-8e2b-3005811e9389" /> ## Restart required <img width="2752" height="1970" alt="CleanShot 2026-04-24 at 11 05 22@2x" src="https://github.com/user-attachments/assets/7b900505-1ba0-41a8-a73c-8a9159c47251" /> ## Restarted <img width="2808" height="2000" alt="CleanShot 2026-04-24 at 11 06 44@2x" src="https://github.com/user-attachments/assets/a9adaad5-9f6e-47fd-84aa-c466b625d212" /> ## Download this PR's build for macOS for testing [Lan Mouse.zip](https://github.com/user-attachments/files/27183767/Lan.Mouse.zip) Because this is an ad-hoc signed bundle, you will need to remove quarantine before it will open ``` xattr -rd com.apple.quarantine "/Applications/Lan Mouse.app" ``` --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
gitea-mirror 2026-05-05 22:18:32 -06:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference: github-starred/lan-mouse#409
No description provided.