summaryrefslogtreecommitdiff
path: root/gui
diff options
context:
space:
mode:
Diffstat (limited to 'gui')
-rw-r--r--gui/form.inc6
1 files changed, 4 insertions, 2 deletions
diff --git a/gui/form.inc b/gui/form.inc
index f87b4f99..4cbd1b2e 100644
--- a/gui/form.inc
+++ b/gui/form.inc
@@ -140,15 +140,17 @@ procedure TCustomForm.Show;
begin
LAYOUTTRACE('TCustomForm.Show for %s:%s', [Name, ClassName]);
- if Assigned(Wnd) then ; // this makes sure that wnd is created
+// if Assigned(Wnd) then ; // this makes sure that wnd is created
FVisible := True;
- FWnd.Show;
+ GFApplication.AddWindow(Wnd);
+ Wnd.Show;
end;
procedure TCustomForm.Close;
begin
+ GFApplication.RemoveWindow(FWnd);
FVisible := False;
FWnd.Free;
FWnd := nil;