mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-06-04 19:58:25 +02:00
lcl: newautosize: create parent handle before child handle
git-svn-id: trunk@23872 -
This commit is contained in:
parent
7c12e786fa
commit
4402426dd3
@ -1839,7 +1839,7 @@ type
|
||||
procedure FinalizeWnd; virtual; // gets called before the Handle is destroyed.
|
||||
procedure FixupTabList;
|
||||
procedure FontChanged(Sender: TObject); override;
|
||||
procedure InitializeWnd; virtual; // gets called after the Handle is created and before the child handles are created
|
||||
procedure InitializeWnd; virtual; // gets called after the Handle is created and before the missing child handles are created
|
||||
procedure Loaded; override;
|
||||
procedure FormEndUpdated; override;
|
||||
procedure MainWndProc(var Msg: TLMessage);
|
||||
|
@ -6994,12 +6994,14 @@ begin
|
||||
DisableAutoSizing;
|
||||
try
|
||||
{$IFDEF NewAutoSize}
|
||||
// create parent handle before child handles
|
||||
if Parent<>nil then
|
||||
if (Parent<>nil) and (not Parent.HandleAllocated) then
|
||||
begin
|
||||
// first create the parent handle
|
||||
Parent.HandleNeeded;
|
||||
if HandleAllocated then exit;
|
||||
end;
|
||||
{$ENDIF}
|
||||
|
||||
// Control is not visible at this moment. It will be showed in UpdateShowing
|
||||
// Control is not visible at this moment. It will be shown in UpdateShowing
|
||||
FShowing := False;
|
||||
Exclude(FWinControlFlags, wcfHandleVisible);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user