feat(keybinding): several shortcuts per action, mouse buttons, searchable picker
Shortcuts were defined in four places that drifted apart: per-action IPC channel pairs, a hand-written VK table in the service, a second one in the renderer, and three copies of the keycap styling. Adding an action meant editing all of them, so two shortcuts stayed hardcoded in bootstrap and one had no settings entry at all. packages/core/src/keybinding.ts is now the single source for the binding type, the selectable key catalog, the action catalog, normalization, validation, conflict detection, display labels, search and deserialization. Main, preload and renderer all read from it; nothing redefines keys or rules locally. - Each action holds a list of bindings instead of one. AppConfig's four *Shortcut fields collapse into a single keyBindings map, migrated on launch. - Mouse buttons can be bound. Left click is refused, right/middle need a modifier, side buttons are free. uiohook cannot swallow events, so the original click still fires and the UI says so. - Keys can be picked from a grouped dropdown with a search box, not only by recording a keypress. - HOTKEY's 14 channels become KEYBINDING's 9, taking the action as a parameter, so actions no longer multiply channels. The history and command popups moved out of bootstrap into ordinary actions. - displayLabel is gone; labels derive from the binding and follow the app language and platform. Fixes found on the way: - Double-press hands-free was unreachable: lookup returned only the first matching action, and dictation shares its default binding. - Reserved-combination checks compared joined key names, so a different modifier order let Ctrl+C through. - Disabling shortcuts released every global registration in the process, including the popup ones, and never restored them. - Enabling shortcuts after starting disabled left nothing registered. - The dashboard stored the caption event payload instead of the state in it.
This commit is contained in:
parent
0ca9e242fa
commit
4ad1ae6ed4
49 changed files with 5901 additions and 1792 deletions
|
|
@ -1659,5 +1659,60 @@
|
|||
"mobile.works.section.data": "데이터 · 알림",
|
||||
"mobile.works.historyDescription": "녹음과 가져오기의 전사 기록을 검색하고 관리합니다.",
|
||||
"mobile.meetings.templateNone": "템플릿 없이 시작",
|
||||
"mobile.meetings.templateNoneDesc": "문서 생성 시점에 템플릿을 선택합니다"
|
||||
"mobile.meetings.templateNoneDesc": "문서 생성 시점에 템플릿을 선택합니다",
|
||||
"keybinding.mouse.left": "마우스 왼쪽 버튼",
|
||||
"keybinding.mouse.right": "마우스 오른쪽 버튼",
|
||||
"keybinding.mouse.middle": "마우스 가운데 버튼",
|
||||
"keybinding.mouse.back": "마우스 뒤로 버튼",
|
||||
"keybinding.mouse.forward": "마우스 앞으로 버튼",
|
||||
"keybinding.group.mouse": "마우스",
|
||||
"keybinding.group.modifier": "조합키",
|
||||
"keybinding.group.function": "기능키",
|
||||
"keybinding.group.letter": "문자",
|
||||
"keybinding.group.digit": "숫자",
|
||||
"keybinding.group.numpad": "숫자패드",
|
||||
"keybinding.group.navigation": "탐색",
|
||||
"keybinding.group.editing": "편집",
|
||||
"keybinding.group.punctuation": "기호",
|
||||
"keybinding.group.system": "시스템",
|
||||
"keybinding.action.dictation": "받아쓰기",
|
||||
"keybinding.action.dictation.desc": "누르고 있는 동안 녹음합니다.",
|
||||
"keybinding.action.handsFree": "원터치 모드",
|
||||
"keybinding.action.handsFree.desc": "두 번 눌러 토글합니다.",
|
||||
"keybinding.action.command": "음성 명령어",
|
||||
"keybinding.action.command.desc": "음성으로 명령을 실행합니다.",
|
||||
"keybinding.action.caption": "실시간 자막",
|
||||
"keybinding.action.caption.desc": "실시간 자막을 켜고 끕니다.",
|
||||
"keybinding.action.historyPopup": "기록 팝업",
|
||||
"keybinding.action.historyPopup.desc": "기록 팝업을 엽니다.",
|
||||
"keybinding.action.commandPopup": "명령어 팝업",
|
||||
"keybinding.action.commandPopup.desc": "명령어 팝업을 엽니다.",
|
||||
"keybinding.reject.unknownKey": "지원하지 않는 키입니다",
|
||||
"keybinding.reject.systemReserved": "시스템 예약 단축키입니다",
|
||||
"keybinding.reject.modifierRequired": "조합키(Ctrl/Alt/Shift)와 함께 사용해야 합니다",
|
||||
"keybinding.disabled.mouseLeft": "왼쪽 클릭은 모든 화면 조작에 쓰이므로 바인딩할 수 없습니다",
|
||||
"keybinding.warning.mousePassthrough": "마우스 버튼은 원래 동작도 함께 실행됩니다",
|
||||
"keybinding.ui.add": "추가",
|
||||
"keybinding.ui.remove": "삭제",
|
||||
"keybinding.ui.reset": "기본값으로",
|
||||
"keybinding.ui.tabRecord": "직접 입력",
|
||||
"keybinding.ui.tabList": "목록에서 선택",
|
||||
"keybinding.ui.search": "키 검색",
|
||||
"keybinding.ui.searchEmpty": "검색 결과가 없습니다",
|
||||
"keybinding.ui.pressKeys": "원하는 키 또는 마우스 버튼을 누르세요",
|
||||
"keybinding.ui.noBindings": "설정된 단축키 없음",
|
||||
"keybinding.ui.conflictWith": "{{action}}와(과) 중복됩니다",
|
||||
"keybinding.ui.modifiers": "조합키",
|
||||
"keybinding.ui.selectedKey": "선택한 키",
|
||||
"keybinding.ui.sectionVoice": "음성",
|
||||
"keybinding.ui.sectionWindow": "창 / 팝업",
|
||||
"keybinding.ui.duplicate": "이미 추가된 단축키입니다",
|
||||
"keybinding.ui.holdMode": "누름 유지",
|
||||
"keybinding.ui.doublePress": "두 번 누름",
|
||||
"keybinding.ui.pickerTitle": "단축키 설정",
|
||||
"keybinding.ui.pressToRecord": "눌러 녹음 시작",
|
||||
"keybinding.ui.recordHint": "조합키(예: Ctrl+Shift+Q) 또는 단일키(예: F5)를 입력하세요",
|
||||
"keybinding.ui.recordAgain": "다시 입력",
|
||||
"keybinding.ui.saveFailed": "단축키를 저장하지 못했습니다",
|
||||
"keybinding.ui.globalEnabled": "전역 단축키 사용"
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue