summaryrefslogtreecommitdiff
path: root/prototypes/mdi
diff options
context:
space:
mode:
authorGraeme Geldenhuys <graeme@mastermaths.co.za>2011-11-21 10:59:25 +0200
committerGraeme Geldenhuys <graeme@mastermaths.co.za>2011-11-21 10:59:25 +0200
commit103708ec7ecee9b3710e845bfbebbc2018ff344d (patch)
tree5f64934249d3b7dc878479f9d139cc678913ea42 /prototypes/mdi
parent63098540b6e55412f3e62d7c23d649bac9406c4a (diff)
downloadfpGUI-103708ec7ecee9b3710e845bfbebbc2018ff344d.tar.xz
MDI: active windows are now brought to the front.
Diffstat (limited to 'prototypes/mdi')
-rw-r--r--prototypes/mdi/fpg_mdi.pas1
-rw-r--r--prototypes/mdi/project1.lpr1
2 files changed, 2 insertions, 0 deletions
diff --git a/prototypes/mdi/fpg_mdi.pas b/prototypes/mdi/fpg_mdi.pas
index 2de4b642..b5e769b6 100644
--- a/prototypes/mdi/fpg_mdi.pas
+++ b/prototypes/mdi/fpg_mdi.pas
@@ -374,6 +374,7 @@ begin
if FActiveWindow = AValue then
Exit;
FActiveWindow := AValue;
+ FActiveWindow.BringToFront;
ActiveWidget := FActiveWindow;
for i := 0 to FList.Count-1 do
begin
diff --git a/prototypes/mdi/project1.lpr b/prototypes/mdi/project1.lpr
index fa8a1850..fdde8f0d 100644
--- a/prototypes/mdi/project1.lpr
+++ b/prototypes/mdi/project1.lpr
@@ -1,6 +1,7 @@
program project1;
{$mode objfpc}{$H+}
+{$ifdef mswindows}{$apptype gui}{$endif}
uses
{$IFDEF UNIX}{$IFDEF UseCThreads}