mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-08-12 08:36:04 +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 FinalizeWnd; virtual; // gets called before the Handle is destroyed.
|
||||||
procedure FixupTabList;
|
procedure FixupTabList;
|
||||||
procedure FontChanged(Sender: TObject); override;
|
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 Loaded; override;
|
||||||
procedure FormEndUpdated; override;
|
procedure FormEndUpdated; override;
|
||||||
procedure MainWndProc(var Msg: TLMessage);
|
procedure MainWndProc(var Msg: TLMessage);
|
||||||
|
@ -6994,12 +6994,14 @@ begin
|
|||||||
DisableAutoSizing;
|
DisableAutoSizing;
|
||||||
try
|
try
|
||||||
{$IFDEF NewAutoSize}
|
{$IFDEF NewAutoSize}
|
||||||
// create parent handle before child handles
|
if (Parent<>nil) and (not Parent.HandleAllocated) then
|
||||||
if Parent<>nil then
|
begin
|
||||||
|
// first create the parent handle
|
||||||
Parent.HandleNeeded;
|
Parent.HandleNeeded;
|
||||||
|
if HandleAllocated then exit;
|
||||||
|
end;
|
||||||
{$ENDIF}
|
{$ENDIF}
|
||||||
|
// Control is not visible at this moment. It will be shown in UpdateShowing
|
||||||
// Control is not visible at this moment. It will be showed in UpdateShowing
|
|
||||||
FShowing := False;
|
FShowing := False;
|
||||||
Exclude(FWinControlFlags, wcfHandleVisible);
|
Exclude(FWinControlFlags, wcfHandleVisible);
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user