LCL: don't call OnHide/OnShow after minimizing/restoring (bug #7255)

git-svn-id: trunk@10506 -
This commit is contained in:
vincents 2007-01-26 10:18:27 +00:00
parent b6299f483a
commit 5fef15b66b
2 changed files with 9 additions and 3 deletions

View File

@ -423,6 +423,7 @@ type
protected protected
FFormBorderStyle: TFormBorderStyle; FFormBorderStyle: TFormBorderStyle;
FActionLists: TList; FActionLists: TList;
procedure CMShowingChanged(var Message: TLMessage); message CM_SHOWINGCHANGED;
procedure Activate; dynamic; procedure Activate; dynamic;
procedure ActiveChanged; dynamic; procedure ActiveChanged; dynamic;
procedure BeginFormUpdate; procedure BeginFormUpdate;

View File

@ -428,9 +428,6 @@ begin
{$ENDIF} {$ENDIF}
LCLIntf.SetFocus(FActiveControl.Handle); LCLIntf.SetFocus(FActiveControl.Handle);
end; end;
DoShow;
end else begin
DoHide;
end; end;
end; end;
finally finally
@ -471,6 +468,14 @@ begin
Deactivate; Deactivate;
end; end;
procedure TCustomForm.CMShowingChanged(var Message: TLMessage);
begin
inherited;
if Showing then
DoShow
else
DoHide;
end;
{------------------------------------------------------------------------------ {------------------------------------------------------------------------------
Method: TCustomForm.Activate Method: TCustomForm.Activate
Params: none Params: none