Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bug: Stuck at ClipWait During QuickEnter() with Empty Clipboard #8

Open
jacob70293 opened this issue Sep 10, 2023 · 0 comments
Open

Comments

@jacob70293
Copy link

jacob70293 commented Sep 10, 2023

When using QuickEnter(), if the clipboard is empty, it results in getting stuck at ClipWait, which in turn prevents the release of BlockInput.

Please see the relevant code in functions.ahk on line 93.

QuickEnter(channel){
    if channel {
        BlockInput On
        temp := Clipboard
        Clipboard := channel
        ClipWait 
        Send {Enter}
        Send ^v
        Send {Enter}
        Sleep 100
        Clipboard := temp     -> This was empty.
        ClipWait              -> Will wait indefinitely.
        BlockInput Off
    }
    return
}

當使用 QuickEnter 功能時,如果當下剪貼簿沒有內容,會導致後續將 Temp 塞回 Clipboard 時 ClipWait 卡住,
而由於當中有包含 BlockInput,因此在卡住當下僅能透過 Ctrl + Alt + Delete 來解卡。

由於此處不再需要使用剪貼簿內容,建議將 ClipWait 移除或是新增 Timeout,避免此情形。

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant