mirror of
https://github.com/Kvan7/Exiled-Exchange-2.git
synced 2026-09-27 07:05:46 +00:00
allow Alt
This commit is contained in:
@@ -147,8 +147,8 @@ export function setupShowHide () {
|
||||
shell.openExternal(link)
|
||||
})
|
||||
|
||||
ioHook.on('mousemove', (e: { x: number, y: number, ctrlKey?: boolean, shiftKey?: boolean }) => {
|
||||
const modifier = e.ctrlKey ? 'Ctrl' : e.shiftKey ? 'Shift' : undefined
|
||||
ioHook.on('mousemove', (e: { x: number, y: number, ctrlKey?: boolean, altKey?: boolean }) => {
|
||||
const modifier = e.ctrlKey ? 'Ctrl' : e.altKey ? 'Alt' : undefined
|
||||
if (!isPollingClipboard && checkPressPosition && isWindowShown && !isWindowLocked && modifier !== config.get('priceCheckKeyHold')) {
|
||||
const mousePos = mousePosFromEvent(e)
|
||||
const distance = Math.hypot(mousePos.x - checkPressPosition.x, mousePos.y - checkPressPosition.y)
|
||||
|
||||
@@ -39,9 +39,6 @@ function priceCheck (lockedMode: boolean) {
|
||||
robotjs.keyTap('C', ['Ctrl'])
|
||||
}
|
||||
} else {
|
||||
if (config.get('priceCheckLocked')!.includes('Alt')) {
|
||||
robotjs.keyToggle('Alt', 'up')
|
||||
}
|
||||
robotjs.keyTap('C', ['Ctrl'])
|
||||
}
|
||||
}
|
||||
|
||||
@@ -6,8 +6,8 @@
|
||||
<div class="flex">
|
||||
<span class="text-gray-500 mr-2">Auto-hide Mode</span>
|
||||
<button :class="{ border: config.priceCheckKeyHold === 'Ctrl' }" @click="config.priceCheckKeyHold = 'Ctrl'" class="rounded px-1 bg-gray-900 leading-none mr-1">Ctrl</button>
|
||||
<button :class="{ border: config.priceCheckKeyHold === 'Shift' }" @click="config.priceCheckKeyHold = 'Shift'" class="rounded px-1 bg-gray-900 leading-none">Shift</button>
|
||||
<span class="mx-3">+</span>
|
||||
<button :class="{ border: config.priceCheckKeyHold === 'Alt' }" @click="config.priceCheckKeyHold = 'Alt'" class="rounded px-1 bg-gray-900 leading-none">Alt</button>
|
||||
<span class="mx-4">+</span>
|
||||
<hotkey-input v-model="config.priceCheckKey" :forbidden="['Ctrl','Shift','Alt','C','V']" required class="w-20" />
|
||||
</div>
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user