mirror of https://gitlab.com/basile.b/dexed.git
about box, status was only auto refresh on create
This commit is contained in:
parent
be20059d6b
commit
e72f558ff1
|
@ -25,12 +25,12 @@ inherited CEInfoWidget: TCEInfoWidget
|
|||
Align = alTop
|
||||
BorderSpacing.Around = 4
|
||||
Caption = 'about'
|
||||
ClientHeight = 75
|
||||
ClientHeight = 85
|
||||
ClientWidth = 366
|
||||
TabOrder = 0
|
||||
object Label1: TLabel
|
||||
Left = 0
|
||||
Height = 75
|
||||
Height = 85
|
||||
Top = 0
|
||||
Width = 366
|
||||
Align = alClient
|
||||
|
@ -52,12 +52,12 @@ inherited CEInfoWidget: TCEInfoWidget
|
|||
Align = alClient
|
||||
BorderSpacing.Around = 4
|
||||
Caption = 'tools status'
|
||||
ClientHeight = 159
|
||||
ClientHeight = 169
|
||||
ClientWidth = 366
|
||||
TabOrder = 1
|
||||
object boxTools: TScrollBox
|
||||
Left = 4
|
||||
Height = 151
|
||||
Height = 161
|
||||
Top = 4
|
||||
Width = 358
|
||||
HorzScrollBar.Page = 1
|
||||
|
|
|
@ -37,6 +37,9 @@ type
|
|||
GroupBox2: TGroupBox;
|
||||
Label1: TLabel;
|
||||
private
|
||||
procedure RefreshAllStatus;
|
||||
protected
|
||||
procedure SetVisible(Value: Boolean); override;
|
||||
public
|
||||
constructor create(aOwner: TComponent); override;
|
||||
end;
|
||||
|
@ -147,6 +150,8 @@ begin
|
|||
fIco.Glyph.Assign(png);
|
||||
png.Free;
|
||||
end;
|
||||
ReAlign;
|
||||
Invalidate;
|
||||
end;
|
||||
|
||||
constructor TCEInfoWidget.create(aOwner: TComponent);
|
||||
|
@ -176,5 +181,24 @@ begin
|
|||
Realign;
|
||||
end;
|
||||
|
||||
procedure TCEInfoWidget.RefreshAllStatus;
|
||||
var
|
||||
i: integer;
|
||||
begin
|
||||
for i := 0 to boxTools.ControlCount -1 do
|
||||
begin
|
||||
if not (boxTools.Controls[i] is TToolInfo) then
|
||||
continue;
|
||||
TToolInfo(boxTools.Controls[i]).refreshStatus;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TCEInfoWidget.SetVisible(Value: Boolean);
|
||||
begin
|
||||
inherited;
|
||||
if Visible then
|
||||
RefreshAllStatus;
|
||||
end;
|
||||
|
||||
end.
|
||||
|
||||
|
|
Loading…
Reference in New Issue