mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-08-17 05:09:10 +02:00
fixed TArrow streaming
git-svn-id: trunk@4153 -
This commit is contained in:
parent
68208c499e
commit
9cddc2792a
@ -2252,7 +2252,6 @@ begin
|
|||||||
//,' ',FPropertyEditorHook<>nil,' ',FPropertyEditorHook.LookupRoot<>nil);
|
//,' ',FPropertyEditorHook<>nil,' ',FPropertyEditorHook.LookupRoot<>nil);
|
||||||
if FUpdatingAvailComboBox then exit;
|
if FUpdatingAvailComboBox then exit;
|
||||||
FUpdatingAvailComboBox:=true;
|
FUpdatingAvailComboBox:=true;
|
||||||
|
|
||||||
NewList:=TStringList.Create;
|
NewList:=TStringList.Create;
|
||||||
try
|
try
|
||||||
if (FPropertyEditorHook<>nil)
|
if (FPropertyEditorHook<>nil)
|
||||||
@ -2264,6 +2263,8 @@ begin
|
|||||||
AddComponentToList(Root.Components[a],NewList);
|
AddComponentToList(Root.Components[a],NewList);
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
if AvailCompsComboBox.Items.Equals(NewList) then exit;
|
||||||
|
|
||||||
AvailCompsComboBox.Items.BeginUpdate;
|
AvailCompsComboBox.Items.BeginUpdate;
|
||||||
if AvailCompsComboBox.Items.Count=1 then
|
if AvailCompsComboBox.Items.Count=1 then
|
||||||
OldText:=AvailCompsComboBox.Text
|
OldText:=AvailCompsComboBox.Text
|
||||||
@ -2271,7 +2272,6 @@ begin
|
|||||||
OldText:='';
|
OldText:='';
|
||||||
AvailCompsComboBox.Items.Assign(NewList);
|
AvailCompsComboBox.Items.Assign(NewList);
|
||||||
AvailCompsComboBox.Items.EndUpdate;
|
AvailCompsComboBox.Items.EndUpdate;
|
||||||
FUpdatingAvailComboBox:=false;
|
|
||||||
a:=AvailCompsComboBox.Items.IndexOf(OldText);
|
a:=AvailCompsComboBox.Items.IndexOf(OldText);
|
||||||
if (OldText='') or (a<0) then
|
if (OldText='') or (a<0) then
|
||||||
SetAvailComboBoxText
|
SetAvailComboBoxText
|
||||||
@ -2280,6 +2280,7 @@ begin
|
|||||||
|
|
||||||
finally
|
finally
|
||||||
NewList.Free;
|
NewList.Free;
|
||||||
|
FUpdatingAvailComboBox:=false;
|
||||||
end;
|
end;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
18
lcl/arrow.pp
18
lcl/arrow.pp
@ -60,7 +60,8 @@ Type
|
|||||||
public
|
public
|
||||||
constructor Create(AOwner: TComponent); override;
|
constructor Create(AOwner: TComponent); override;
|
||||||
destructor Destroy; override;
|
destructor Destroy; override;
|
||||||
|
procedure Loaded; override;
|
||||||
|
procedure InitializeWnd; override;
|
||||||
published
|
published
|
||||||
Property ArrowType : TArrowType read GetArrowType write SetArrowType;
|
Property ArrowType : TArrowType read GetArrowType write SetArrowType;
|
||||||
property ShadowType : TShadowType read fShadowType write SetShadowType;
|
property ShadowType : TShadowType read fShadowType write SetShadowType;
|
||||||
@ -97,6 +98,18 @@ begin
|
|||||||
inherited;
|
inherited;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
procedure TArrow.Loaded;
|
||||||
|
begin
|
||||||
|
inherited Loaded;
|
||||||
|
SetProps;
|
||||||
|
end;
|
||||||
|
|
||||||
|
procedure TArrow.InitializeWnd;
|
||||||
|
begin
|
||||||
|
inherited InitializeWnd;
|
||||||
|
SetProps;
|
||||||
|
end;
|
||||||
|
|
||||||
function TArrow.GetArrowType: TArrowType;
|
function TArrow.GetArrowType: TArrowType;
|
||||||
begin
|
begin
|
||||||
Result := FArrowType;
|
Result := FArrowType;
|
||||||
@ -117,8 +130,7 @@ procedure TArrow.SetProps;
|
|||||||
var
|
var
|
||||||
Temp : TLMArrow;
|
Temp : TLMArrow;
|
||||||
begin
|
begin
|
||||||
|
if HandleAllocated and (not (csLoading in ComponentState)) then
|
||||||
if HandleAllocated then
|
|
||||||
begin
|
begin
|
||||||
Temp.ArrowType := FArrowType;
|
Temp.ArrowType := FArrowType;
|
||||||
Temp.ShadowType := FShadowType;
|
Temp.ShadowType := FShadowType;
|
||||||
|
Loading…
Reference in New Issue
Block a user