feat(linux): evdev input for side combos and mouse dictation (split from #724)#728
feat(linux): evdev input for side combos and mouse dictation (split from #724)#728HKLHaoBin wants to merge 21 commits into
Conversation
PR Reviewer Guide 🔍(Review updated until commit c98c801)Here are some key observations to aid the review process:
|
|
稍等,我处理一下ci问题。 |
|
Linux evdev 这层本身写得不错(见下),但这个 PR 现在还不能合,需要先 rebase 瘦身 🙏 现状问题:diff 累计回到了整个 #724本 PR 的分支叠在 正确路径
对 Linux evdev 增量的审查(rebase 后即可落地)
先留开着,按上面顺序 rebase 后再推进。 |
|
Persistent review updated to latest commit 0bac973 |
0bac973 to
23a4f69
Compare
|
@Felix201209 已按 review 处理 rebase 瘦身 🙏 分支结构
相对 合并顺序(与 review 一致):#726 → #727 → 本 PR。待前两 PR 进 beta 后,对 beta 的 diff 会自然瘦到 evdev-only。 本次未做(review 标注不阻断):epoll/EventStream 空闲 CPU、udev 提示常量统一。 请 re-review。 |
|
Persistent review updated to latest commit 23a4f69 |
|
Persistent review updated to latest commit 6ea63bb |
|
Persistent review updated to latest commit ebc9fe7 |
|
Persistent review updated to latest commit 5cf792d |
|
Persistent review updated to latest commit a997cd1 |
|
Persistent review updated to latest commit a5871ee |
|
Persistent review updated to latest commit d22ded2 |
…d source On update_config disable or Drop, swap held flags and send Released events so HoldSourceTracker does not retain stale mouse sources after prefs refresh. Co-authored-by: Cursor <cursoragent@cursor.com>
…inux Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
Rebase dropped leftCommand/leftShift/rightShift from beta while hotkey.ts still references them; sync Cargo.lock for futures dep. Co-authored-by: Cursor <cursoragent@cursor.com>
578f6d1 to
9fb62f3
Compare
|
Persistent review updated to latest commit 9fb62f3 |
Rebase dropped LeftCommand/LeftShift/RightShift from beta while shortcut_binding still references them. Co-authored-by: Cursor <cursoragent@cursor.com>
|
Persistent review updated to latest commit 0331833 |
Co-authored-by: Cursor <cursoragent@cursor.com>
|
Persistent review updated to latest commit 4fa244f |
Co-authored-by: Cursor <cursoragent@cursor.com>
|
Persistent review updated to latest commit 5ac029d |
Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
|
Persistent review updated to latest commit c98c801 |
|
请你说清楚,你为什么写了 1,000 多行出来?又不是什么大的改变,也不是什么严重的改变,你写一千多行出来要把我看死。我也不敢直接给你合并,你等我一下,我 @ 一下 Claude。 |
|
@claude Review. |
|
感谢实现鼠标键听写 + Linux evdev 输入,这块工作量不小。经维护者审阅 + 两轮独立代码审查,此 PR 暂打回搁置,主要两个原因: ① 架构方向 —— 往 god-file 增量过多 本 PR 约 458 行加进了 ② 运行时 2 个 CRITICAL 缺陷(CI 的 cargo check + 单测覆盖不到,两轮独立审查一致确认):
需要说明:核心逻辑本身是干净的 —— |
|
@jiangmuran 这个 PR 我之前想 @claude 审但没响应(自动审核已移除),我自己看完先打回搁置了。如果你对 Linux evdev 这块有不同看法,麻烦也过目一下。(PR 目前已关闭) |
User description
摘要
Completes #718(Linux 路径)。
由已关闭的 #724 拆分而来(第 3/3 部分):
linux_evdev_input+evdev依赖;Linux 侧向组合与鼠标输入;prefs 变更时refresh_linux_evdev_monitor;monitor 停止时清除status_message。堆叠 PR:含 #726 + #727 全部变更,用于 Linux 端到端验收。建议 #726/#727 合并后 rebase,或作为完整验收 PR 审查。
关联:#718、#724。
修复 / 新增 / 改进
兼容
测试计划
Linux 实机验证(请维护者复测,回应 @jiangmuran):
cmd-left+D/shift-left+D→ evdev monitor 启动、听写触发/dev/input/event*读权限时出现 input 组提示;monitor 停止后清除本地已验证:
npm run build、npm run check:hotkey-side-modifiersPR Type
Enhancement, Tests
Description
Support left/right modifier keys in dictation hotkeys
Add independent mouse middle/side button dictation triggers
Implement Linux evdev input for side combos and mouse events
Track multiple hold sources for Hold mode with refcount
Diagram Walkthrough
File Walkthrough
3 files
Add mouse_dictation_refreshes test counterAdd mock data for new dictation prefsInclude new prefs fields in test data12 files
Add refresh_mouse_dictation to settings persistenceIntegrate mouse/evdev/hold components and update hotkey bindingAdd TriggerSource parameter to edge handlers for hold modeAdd mouse dictation and linux evdev supervision loopsNew HoldSourceTracker for refcounting multiple trigger sourcesAdd macOS mouse button dispatch for side and mouse dictationRegister new modules and start mouse dictation listenerNew Linux evdev monitor for side combos and mouse eventsNew mouse dictation monitor with platform hooks and update configAdd mouse_middle_button_dictation and mouse_side_button_dictationprefsUpdate ShortcutBinding comments and add mouse dictation fieldsAdd mouse dictation toggle UI components1 files
Provide stub implementations for mobile platforms1 files
Add i18n strings for mouse dictation settings1 files
Add futures and evdev dependencies7 files