Although LowLevelHooksTimeout is set to 1000 on start up, if computer lags when it's triggered, it's still possible that the hook process takes longer than 1 second, causing the hook being removed by Windows. For example, I set Ctrl + Windows + Right Click to open the context menu, now it's removed, leaving only keyboard hook available.
Is it possible to check if mouse and keyboard hooks are still available, and reapply hooks if necessary? Or make the hook processing function async, so it can take less time to process.
Although
LowLevelHooksTimeoutis set to1000on start up, if computer lags when it's triggered, it's still possible that the hook process takes longer than 1 second, causing the hook being removed by Windows. For example, I set Ctrl + Windows + Right Click to open the context menu, now it's removed, leaving only keyboard hook available.Is it possible to check if mouse and keyboard hooks are still available, and reapply hooks if necessary? Or make the hook processing function async, so it can take less time to process.