billiegoose / lock-screen

An invisible screensaver / lock screen for Windows 7+
MIT License
88 stars 28 forks source link

Take focus on launch #8

Open Webbeh opened 2 years ago

Webbeh commented 2 years ago

Hey there,

Using this as an alternative to Win + L key combination.

I have the lockscreen sent through a shortcut in my taskbar (Windows 11) like so

image

When using Win + 2, the shortcut is launched (because it's in the second position of the taskbar items).

However, if I click on any window between the launch of the Lockscreen shortcut and the moment it acutally launches, it loses focus and I can't Ctrl + L to exit it, the only workaround is to quit Lock.scr from the task manager.

Is it possible to force the focus on launch ?

EDIT: ignore the last "A" in the launcher path, typed it in by mistake when doing the screenshot