From af854e41c0f98acec4be31efe1d6690cefa60554 Mon Sep 17 00:00:00 2001 From: graemeg Date: Thu, 12 Jun 2008 14:40:49 +0000 Subject: * Minor fixes to csUpdating ComponentState in Grids. * fpgApplication now closes all forms created via fpgApplication.CreateForm() before the main form when the application terminates. * Minor documentation update for fpgfx.pas unit. --- src/corelib/gfxbase.pas | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'src/corelib') diff --git a/src/corelib/gfxbase.pas b/src/corelib/gfxbase.pas index 03aae37d..6e419d72 100644 --- a/src/corelib/gfxbase.pas +++ b/src/corelib/gfxbase.pas @@ -1938,7 +1938,13 @@ begin end; procedure TfpgApplicationBase.Terminate; +var + i: integer; begin + // make sure all forms are closed before main form + for i := FormCount - 1 downto 0 do + if Forms[i] <> MainForm then + fpgSendMessage(Self, Forms[i], FPGM_CLOSE); // SendMessage waits for it to complete. Post doesn't. Terminated := True; end; -- cgit v1.2.3-70-g09d2