Skip to content

Commit

Permalink
Show RCS library in F_Main StatusBar too.
Browse files Browse the repository at this point in the history
  • Loading branch information
horacekj committed Dec 19, 2021
1 parent 36b1711 commit 7f16ce0
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 8 deletions.
11 changes: 6 additions & 5 deletions src/forms/fMain.dfm
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
object F_Main: TF_Main
Left = 264
Top = 316
Caption = 'hJOPserver'
Caption = ','
ClientHeight = 695
ClientWidth = 1297
Color = clWhite
Expand Down Expand Up @@ -3466,7 +3466,7 @@ object F_Main: TF_Main
BiDiMode = bdLeftToRight
ParentBiDiMode = False
Text = 'log'
Width = 700
Width = 550
end
item
Alignment = taCenter
Expand All @@ -3483,11 +3483,12 @@ object F_Main: TF_Main
item
Alignment = taCenter
Text = '-'
Width = 100
Width = 200
end
item
Text = 'Prim'#225'rn'#237' smy'#269'ka: x ms'
Width = 150
Alignment = taCenter
Text = '-'
Width = 200
end
item
Text = 'CPU'
Expand Down
9 changes: 8 additions & 1 deletion src/forms/fMain.pas
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ interface
_SB_RCS = 1;
_SB_TRAKCE_STAV = 2;
_SB_TRAKCE_LIB = 3;
_SB_SBERNICE = 4;
_SB_RCS_LIB = 4;
_SB_PROC = 5;

_INIDATA_FN = 'inidata.ini';
Expand Down Expand Up @@ -503,9 +503,11 @@ procedure TF_Main.MI_RCS_libClick(Sender: TObject);

Screen.Cursor := crHourGlass;
Log('RCS -> ' + fn, ltRCS);
Self.SB1.Panels.Items[_SB_RCS_LIB].Text := '-';
try
RCSi.LoadLib(RCSi.libDir + '\' + fn);
Self.LogStatus('RCS: načteno ' + fn);
Self.SB1.Panels.Items[_SB_RCS_LIB].Text := ExtractFileName(RCSi.Lib);
except
on E: Exception do
begin
Expand Down Expand Up @@ -2707,6 +2709,11 @@ procedure TF_Main.OnStart();
else
F_Main.SB1.Panels.Items[_SB_TRAKCE_LIB].Text := ExtractFileName(TrakceI.Lib);

if (RCSi.Lib = '') then
F_Main.SB1.Panels.Items[_SB_RCS_LIB].Text := '-'
else
F_Main.SB1.Panels.Items[_SB_RCS_LIB].Text := ExtractFileName(RCSi.Lib);

try
if ((RCSi.ready) and (diag.simInputs) and (RCSi.Simulation)) then
RCSi.InputSim();
Expand Down
2 changes: 0 additions & 2 deletions src/forms/fSettings.pas
Original file line number Diff line number Diff line change
Expand Up @@ -392,8 +392,6 @@ procedure TF_Options.B_SS_SaveClick(Sender: TObject);
procedure TF_Options.LB_TimerClick(Sender: TObject);
begin
F_Main.T_Main.Interval := StrToInt(LB_Timer.Items.Strings[LB_Timer.ItemIndex]);
F_Main.SB1.Panels.Items[_SB_SBERNICE].Text := 'Primární smyčka : ' + LB_Timer.Items.Strings
[LB_Timer.ItemIndex] + ' ms';
Log('Primární smyčka nastavena na ' + LB_Timer.Items.Strings[LB_Timer.ItemIndex] + ' ms', ltMessage);
end;

Expand Down

0 comments on commit 7f16ce0

Please sign in to comment.