I would advise strongly against the use of SwitchToThisWindow API
function in Lazarus. Mainly because it states in the docs: /This
function is not intended for general use. It may be altered or
unavailable in subsequent versions of Windows./
Read more in Raymond Chen's blog - The life story of the
SwitchToThisWindow function:
https://blogs.msdn.microsoft.com/oldnewthing/20111107-00/?p=9183
Denis
On 23/05/2017 18:38, Alexey via Lazarus wrote:
What do you think about using this rare API [beginning from WinXP] in
LCLIntf fnction? It will make LCL function work more stable: window
will always go to foreground. I used it in CudaText. It works.
https://github.com/Alexey-T/CudaText/blob/master/app/fix_focus_window.pas
--
_______________________________________________
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
http://lists.lazarus-ide.org/listinfo/lazarus