From b74b9e8451081eba5877aded54f2986979cbafcc Mon Sep 17 00:00:00 2001 From: Graeme Geldenhuys Date: Wed, 23 May 2012 12:20:23 +0200 Subject: Windows GDI BringToFront() behaviour is now consistent with Linux X11 The window is brought to the front, but not activated. --- src/corelib/gdi/fpg_gdi.pas | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'src/corelib/gdi') diff --git a/src/corelib/gdi/fpg_gdi.pas b/src/corelib/gdi/fpg_gdi.pas index 59c9731c..2bbdd389 100644 --- a/src/corelib/gdi/fpg_gdi.pas +++ b/src/corelib/gdi/fpg_gdi.pas @@ -2058,7 +2058,10 @@ end; procedure TfpgGDIWindow.BringToFront; begin if HasHandle then - BringWindowToTop(FWinHandle); + Windows.SetWindowPos( + WinHandle, HWND_TOP, + FLeft, FTop, FWidth, FHeight, + SWP_NOACTIVATE or SWP_NOSIZE); end; function TfpgGDIWindow.HandleIsValid: boolean; -- cgit v1.2.3-70-g09d2