mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-09-06 14:00:14 +02:00
lcl: TWinControl.InsertControl fixed position in Controls, widgetsets do not support that yet, issue #25405
git-svn-id: branches/fixes_1_4@47376 -
This commit is contained in:
parent
616bd7e127
commit
ee2dd46d22
@ -6035,11 +6035,13 @@ end;
|
||||
procedure TWinControl.Insert(AControl: TControl; Index: integer);
|
||||
begin
|
||||
if AControl = nil then exit;
|
||||
if AControl.FParent<>nil then
|
||||
raise EInvalidOperation.Create('control has already a parent');
|
||||
|
||||
if AControl = Self then
|
||||
raise EInvalidOperation.Create(rsAControlCanNotHaveItselfAsParent);
|
||||
|
||||
ListAdd(FControls, AControl);
|
||||
ListInsert(FControls, Index, AControl);
|
||||
if AControl is TWinControl then
|
||||
begin
|
||||
ListAdd(FTabList, AControl);
|
||||
|
Loading…
Reference in New Issue
Block a user