mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-08-22 10:39:31 +02:00
LCL: TCustomForm DoCreate moved to AfterConstruction to be fully delphi compatibile. fixes #14120
git-svn-id: trunk@24525 -
This commit is contained in:
parent
21d5eda8e4
commit
724575d244
@ -558,6 +558,7 @@ type
|
|||||||
constructor Create(AOwner: TComponent); override;
|
constructor Create(AOwner: TComponent); override;
|
||||||
constructor CreateNew(AOwner: TComponent; Num: Integer = 0); virtual;
|
constructor CreateNew(AOwner: TComponent; Num: Integer = 0); virtual;
|
||||||
destructor Destroy; override;
|
destructor Destroy; override;
|
||||||
|
procedure AfterConstruction; override;
|
||||||
procedure BeforeDestruction; override;
|
procedure BeforeDestruction; override;
|
||||||
|
|
||||||
class function GetControlClassDefaultSize: TPoint; override;
|
class function GetControlClassDefaultSize: TPoint; override;
|
||||||
|
@ -66,6 +66,19 @@ begin
|
|||||||
end;
|
end;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
{------------------------------------------------------------------------------
|
||||||
|
Method: TCustomForm.AfterConstruction
|
||||||
|
Params: None
|
||||||
|
Returns: Nothing
|
||||||
|
|
||||||
|
Gets called after the construction of the object
|
||||||
|
------------------------------------------------------------------------------}
|
||||||
|
procedure TCustomForm.AfterConstruction;
|
||||||
|
begin
|
||||||
|
DoCreate;
|
||||||
|
inherited AfterConstruction;
|
||||||
|
end;
|
||||||
|
|
||||||
{------------------------------------------------------------------------------
|
{------------------------------------------------------------------------------
|
||||||
Method: TCustomForm.BeforeDestruction
|
Method: TCustomForm.BeforeDestruction
|
||||||
Params: None
|
Params: None
|
||||||
@ -1772,7 +1785,6 @@ begin
|
|||||||
// MG: Ignoring is best at the moment. (Delphi raises an exception.)
|
// MG: Ignoring is best at the moment. (Delphi raises an exception.)
|
||||||
end;
|
end;
|
||||||
//DebugLn('[TCustomForm.Create] D Class=',Classname);
|
//DebugLn('[TCustomForm.Create] D Class=',Classname);
|
||||||
DoCreate;
|
|
||||||
//DebugLn('[TCustomForm.Create] E Class=',Classname);
|
//DebugLn('[TCustomForm.Create] E Class=',Classname);
|
||||||
finally
|
finally
|
||||||
Exclude(FFormState, fsCreating);
|
Exclude(FFormState, fsCreating);
|
||||||
|
Loading…
Reference in New Issue
Block a user