mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-04-09 20:28:19 +02:00
IDE: Cleanup ComponentList code.
git-svn-id: trunk@52436 -
This commit is contained in:
parent
44ae5e635a
commit
21b3356fc3
@ -288,10 +288,11 @@ begin
|
||||
else
|
||||
begin
|
||||
Node := InheritanceTree.Items.AddChildObject(Node, ClssName, Comp);
|
||||
CurIcon := nil;
|
||||
if (Comp is TPkgComponent) then
|
||||
CurIcon := TPkgComponent(Comp).Icon;
|
||||
if CurIcon <> nil then
|
||||
if Comp is TPkgComponent then
|
||||
CurIcon := TPkgComponent(Comp).Icon
|
||||
else
|
||||
CurIcon := nil;
|
||||
if Assigned(CurIcon) then
|
||||
begin
|
||||
Node.ImageIndex := imInheritance.Add(CurIcon, nil);
|
||||
Node.SelectedIndex := Node.ImageIndex;
|
||||
@ -346,10 +347,11 @@ begin
|
||||
AListNode := ListTree.Items.AddChildObject(Nil, Comps[j], Comp);
|
||||
// Palette layout item
|
||||
APaletteNode := PalletteTree.Items.AddChildObject(ParentNode, Comps[j], Comp);
|
||||
CurIcon := nil;
|
||||
if (Comp is TPkgComponent) then
|
||||
CurIcon := TPkgComponent(Comp).Icon;
|
||||
if CurIcon <> nil then
|
||||
if Comp is TPkgComponent then
|
||||
CurIcon := TPkgComponent(Comp).Icon
|
||||
else
|
||||
CurIcon := nil;
|
||||
if Assigned(CurIcon) then
|
||||
begin
|
||||
AListNode.ImageIndex := imListPalette.Add(CurIcon, nil);
|
||||
AListNode.SelectedIndex := AListNode.ImageIndex;
|
||||
@ -455,7 +457,6 @@ begin
|
||||
FPageControlChange := False;
|
||||
end;
|
||||
|
||||
|
||||
procedure TComponentListForm.FormClose(Sender: TObject; var CloseAction: TCloseAction);
|
||||
begin
|
||||
if Parent=nil then begin
|
||||
|
Loading…
Reference in New Issue
Block a user