MCPcopy Create free account
hub / github.com/Bistutu/FluentRead / getConfiguredHotkeyParts

Function getConfiguredHotkeyParts

entrypoints/content.ts:448–465  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

446
447 // 获取当前配置的快捷键
448 const getConfiguredHotkeyParts = () => {
449 // 如果选择了自定义快捷键,使用自定义的
450 const hotkeyString = config.floatingBallHotkey === 'custom'
451 ? config.customFloatingBallHotkey
452 : config.floatingBallHotkey;
453
454 if (!hotkeyString || hotkeyString === 'none') {
455 return [];
456 }
457
458 return hotkeyString.split('+').map(key => {
459 const k = key.toLowerCase();
460 // 标准化修饰键名称
461 if (k === 'ctrl') return 'control';
462 if (k === 'option') return 'alt';
463 return k;
464 });
465 };
466
467 if (isDev) {
468 console.log(`[FluentRead] 设置悬浮球快捷键: ${config.floatingBallHotkey}, 系统: ${isMac ? 'macOS' : '其他'}`);

Callers 1

setupFloatingBallHotkeyFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected