This commit is contained in:
f1iwq2
2025-05-30 10:55:32 +02:00
parent 23143aa4db
commit 89a03216ca
10 changed files with 75 additions and 57 deletions
+1 -1
View File
@@ -769,7 +769,7 @@ begin
// imageC <-- FCBitMap (on écrit les vitesses) <- ImageCompteur (grande)
// créer un bitmap réduit qui sert de référence
Scompteur[i].FCBitMap.Free;
Scompteur[i].FCBitMap.Free; // zizi
Scompteur[i].fcBitMap:=tbitmap.Create;
with Scompteur[i].FCBitMap do
begin
+6 -6
View File
@@ -1393,7 +1393,7 @@ object FormConfig: TFormConfig
Left = 8
Top = 282
Width = 297
Height = 161
Height = 159
Caption = 'Au d'#233'marrage de signaux complexes en mode autonome'
TabOrder = 6
object Label32: TLabel
@@ -3232,8 +3232,8 @@ object FormConfig: TFormConfig
OnChange = LabeledEditTrainChange
end
object RadioGroupOP: TRadioGroup
Left = 256
Top = 24
Left = 208
Top = 16
Width = 89
Height = 57
Caption = 'Op'#233'rateur'
@@ -3657,7 +3657,7 @@ object FormConfig: TFormConfig
Top = 240
Width = 265
Height = 121
Caption = 'Actionneurs PN simples'
Caption = 'Actionneurs CDM PN simples'
TabOrder = 0
end
object GroupBoxPNZ: TGroupBox
@@ -3772,8 +3772,8 @@ object FormConfig: TFormConfig
Top = 174
Width = 113
Height = 17
Hint = 'PN command'#233' par actionneurs'
Caption = 'Actionneurs simples'
Hint = 'PN command'#233' par actionneurs CDM'
Caption = 'Actionneurs CDM'
ParentShowHint = False
ShowHint = True
TabOrder = 7
+40 -15
View File
@@ -821,7 +821,7 @@ type
Tliste = record // liste des paramètres avancés de la ValueListEditor
Nom : string; // Nom de la variable
aide : string; // pour le hint
typ : (Simple,PickList,titre); // type d'entrée : simple=entier picklist=combobox titre=texte sans variable associée
typ : (Simple,PickList,titre); // type d'entrée : simple=entier picklist=combobox titre=texte sans variable associée
masque : string; // masque de saisie des entiers
variable : pointer; // pointeur sur la variable à modifier
typeVar : (rien3,entier,bool,chaine); // type de la variable à modifier
@@ -7305,8 +7305,10 @@ begin
if index<1 then exit;
if Trains[index].nom_train='' then exit;
clicListe:=true;
with formconfig do
begin
LabelInfo.caption:='';
i:=trains[index].routePref[0][0].adresse;
s:='';
case i of
@@ -14291,13 +14293,33 @@ begin
end;
procedure TFormConfig.EditAdresseTrainChange(Sender: TObject);
var erreur,i :integer;
var erreur,i,j :integer;
trouve : boolean;
begin
if clicliste then exit;
if affevt then affiche('Evt change adresse train',clyellow);
if (ligneclicTrain<0) or (ligneclicTrain>=ntrains) or (ntrains<1) then exit;
val(EditAdresseTrain.text,i,erreur);
if i<1 then exit;
if (i<1) or (i>255) then
begin
LabelInfo.caption:='Erreur';
exit;
end;
j:=1;
repeat
trouve:=(trains[j].adresse=i) and (j<>ligneclicTrain+1);
inc(j);
until (j>ntrains) or trouve;
if trouve then
begin
dec(j);
LabelInfo.caption:='Erreur: le train '+Trains[j].nom_train+' a déjà l''adresse '+intToSTR(i);
exit;
end;
LabelInfo.caption:='';
trains[ligneclicTrain+1].adresse:=i;
formconfig.ListBoxTrains.items[ligneclicTrain]:=encode_train(ligneclicTrain+1);
ListBoxTrains.selected[ligneclicTrain]:=true;
@@ -16245,6 +16267,7 @@ begin
Affiche('Changement dans TCO '+intToSTR(i)+' cellule '+intToSTR(x)+','+intToSTR(y),clyellow);
end;
end;
Affiche_TCO(i);
end;
ButtonPropage.Hint:='Change les adresses dans les points de connexions'+#13+
@@ -17099,7 +17122,8 @@ begin
end;
procedure TFormConfig.ButtonNouvActClick(Sender: TObject);
begin ajoute_actionneur;
begin
ajoute_actionneur;
end;
procedure TFormConfig.ListBoxDetMouseDown(Sender: TObject;
@@ -18175,7 +18199,7 @@ begin
{$IF CompilerVersion >= 28.0} // si delphi>=11
TreeviewL.Selected.MoveTo(nodeB,naAddChildFirst);
{$ELSE}
TreeviewL.Selected.MoveTo(nodeB,naAdd);
TreeviewL.Selected.MoveTo(nodeB,naAdd);
{$IFEND}
idA:=nodeA.AbsoluteIndex;
idB:=nodeB.AbsoluteIndex;
@@ -18379,7 +18403,7 @@ begin
if fonction[foncCourante,0].adresse=0 then supprime_fonction(foncCourante);
end;
// supprime fonction logique;
// supprime fonction logique
procedure TFormConfig.ButtonSupLogClick(Sender: TObject);
begin
supprime_node;
@@ -18812,6 +18836,7 @@ begin
node.Text:=texte_tv(foncCourante,i);
end;
// modification d'une valeur de la listeditor
procedure TFormConfig.ValueListEditorSetEditText(Sender: TObject; ACol,ARow: Integer; const Value: String);
var i,erreur : integer;
s : string;
@@ -19355,15 +19380,15 @@ begin
val(LabeledEditFn.Text,i,erreur);
if (erreur<>0) or (i<0) or (i>1) then exit;
case boutonbloc of
1 : blocUSB[NumBlocUSB].Fnp1:=i;
2 : blocUSB[NumBlocUSB].Fnp2:=i;
3 : blocUSB[NumBlocUSB].Fnp3:=i;
4 : blocUSB[NumBlocUSB].Fnp4:=i;
5 : blocUSB[NumBlocUSB].Fnp5:=i;
6 : blocUSB[NumBlocUSB].Fnp6:=i;
7 : blocUSB[NumBlocUSB].Fnp7:=i;
8 : blocUSB[NumBlocUSB].Fnp8:=i;
9 : blocUSB[NumBlocUSB].Fnp9:=i;
1 : blocUSB[NumBlocUSB].Fnp1:=i;
2 : blocUSB[NumBlocUSB].Fnp2:=i;
3 : blocUSB[NumBlocUSB].Fnp3:=i;
4 : blocUSB[NumBlocUSB].Fnp4:=i;
5 : blocUSB[NumBlocUSB].Fnp5:=i;
6 : blocUSB[NumBlocUSB].Fnp6:=i;
7 : blocUSB[NumBlocUSB].Fnp7:=i;
8 : blocUSB[NumBlocUSB].Fnp8:=i;
9 : blocUSB[NumBlocUSB].Fnp9:=i;
10 : blocUSB[NumBlocUSB].Fnp10:=i;
end;
end;
+3 -2
View File
@@ -127,8 +127,9 @@ object FormModifAction: TFormModifAction
object ImageIcone: TImage
Left = 304
Top = 24
Width = 16
Height = 16
Width = 32
Height = 32
Stretch = True
end
object LabelInfoFonc: TLabel
Left = 136
+3 -15
View File
@@ -1318,7 +1318,8 @@ var
// trains[0] est utilisé pour le tri. L'indice 1 contient le 1er train.
trains : array[0..Max_Trains] of tTrain;
// éléments scannés et/ou verrouillés
// éléments scannés et/ou verrouillés ; rempli par detecteur_suivant trouve_actionneur etat_signal_suivant
// reserve_canton etat_signal_precedent
elements : array[1..Maxelements] of
record
adresse : integer;
@@ -5616,7 +5617,6 @@ begin
formCompteur[1].Show;
end;
// renseigne les composants image train, label et vitesse
procedure renseigne_comp_trains(i : integer);
begin
@@ -20125,18 +20125,6 @@ begin
event_det_tick[i].etat:=-1;
event_det_tick[i].reaffecte:=0 ;
end;
for i:=1 to NbMaxDet do
begin
// detecteur[i].etat:=false; ne pas razer les états de détecteurs
//detecteur[i].train:='';
//detecteur[i].adrTrain:=0;
//detecteur[i].IndexTrainRoulant:=0;
//detecteur[i].suivant:=0;
//detecteur[i].TypSuivant:=rien;
//detecteur[i].precedent:=0;
//detecteur[i].TypPrecedent:=rien;
//ancien_detecteur[i]:=detecteur[i].etat;
end;
for i:=1 to NbMaxDet do
for j:=1 to NbMaxDet do
begin
@@ -21465,7 +21453,7 @@ begin
procetape('Lecture de la configuration');
lit_config;
clientInfo.Open; // se connecte au serveur SC et envoie les infos
// clientInfo.Open; //zizi se connecte au serveur SC et envoie les infos
{$IF CompilerVersion >= 28.0}
//https://docwiki.embarcadero.com/RADStudio/Alexandria/en/Compiler_Versions
+1 -1
View File
@@ -523,7 +523,7 @@ begin
ncanton:=0;
TrainExistant:=0;
ideb:=trains[idTrain].PointRout;
ideb:=Pointeur;
ideb:=Pointeur; // zizi
AdrSig:=0;
SigBonSens:=false;
//TraceListe:=true;
+16 -15
View File
@@ -3148,8 +3148,10 @@ begin
begin
pen.color:=fond;
Brush.Color:=fond;
pen.width:=epaisseur div 2;
moveTo(xf,yc);LineTo(xc,yc);LineTo(x0,yf);
if testbit(ep,3) then pen.Width:=epaisseur div 4 else pen.width:=epaisseur div 2;
moveTo(xf,yc);LineTo(xc,yc);
if testbit(ep,6) then pen.Width:=epaisseur div 4 else pen.width:=epaisseur div 2;
LineTo(x0,yf);
end;
end;
@@ -3169,7 +3171,7 @@ begin
begin
pen.color:=fond;
Brush.Color:=fond;
pen.width:=epaisseur div 2;
if testbit(ep,7) or testbit(ep,3) then pen.Width:=epaisseur div 4 else pen.width:=epaisseur div 2;
moveTo(x0,yc);LineTo(xf,yc);
end;
end;
@@ -3291,7 +3293,7 @@ begin
begin
pen.color:=fond;
Brush.Color:=fond;
pen.width:=epaisseur div 2;
if testbit(ep,3) or testbit(ep,6) then pen.Width:=epaisseur div 4 else pen.width:=epaisseur div 2;
Arc(x1,y1,x2,y2,x3,y3,x4,y4); //courbe
end;
end;
@@ -3312,7 +3314,7 @@ begin
begin
pen.color:=fond;
Brush.Color:=fond;
pen.width:=epaisseur div 2;
if testbit(ep,3) or testbit(ep,7) then pen.Width:=epaisseur div 4 else pen.width:=epaisseur div 2;
moveTo(x0,yc);LineTo(xf,yc);
end;
end;
@@ -3430,8 +3432,10 @@ begin
begin
pen.color:=fond;
Brush.Color:=fond;
pen.width:=epaisseur div 2;
moveTo(x0,yc);LineTo(xc,yc);LineTo(xf,y0);
if testbit(ep,7) then pen.Width:=epaisseur div 4 else pen.width:=epaisseur div 2;
moveTo(x0,yc);LineTo(xc,yc);
if testbit(ep,2) then pen.Width:=epaisseur div 4 else pen.width:=epaisseur div 2;
LineTo(xf,y0);
end;
end;
@@ -3451,7 +3455,7 @@ begin
begin
pen.color:=fond;
Brush.Color:=fond;
pen.width:=epaisseur div 2;
if testbit(ep,7) or testbit(ep,3) then pen.Width:=epaisseur div 4 else pen.width:=epaisseur div 2;
moveTo(x0,yc);LineTo(xf,yc);
end;
end;
@@ -3576,9 +3580,8 @@ begin
begin
pen.color:=fond;
Brush.Color:=fond;
pen.width:=epaisseur div 2;
if testbit(ep,7) or testbit(ep,3) then pen.Width:=epaisseur div 4 else pen.width:=epaisseur div 2;
Arc(x1,y1,x2,y2,x3,y3,x4,y4);
//moveTo(x0,yc);LineTo(xc-round(4*FrxGlob[indexTCO]),yc);LineTo(xf,y0);
end;
end;
@@ -3598,7 +3601,7 @@ begin
begin
pen.color:=fond;
Brush.Color:=fond;
pen.width:=epaisseur div 2;
if testbit(ep,7) or testbit(ep,3) then pen.Width:=epaisseur div 4 else pen.width:=epaisseur div 2;
moveTo(x0,yc);LineTo(xf,yc);
end;
end;
@@ -3720,7 +3723,7 @@ begin
begin
pen.color:=fond;
Brush.Color:=fond;
if testbit(ep,0) then pen.Width:=epaisseur div 4 else pen.width:=epaisseur div 2;
if testbit(ep,7) then pen.Width:=epaisseur div 4 else pen.width:=epaisseur div 2;
moveTo(x0,yc);LineTo(xc,yc);
if testbit(ep,4) then pen.Width:=epaisseur div 4 else pen.width:=epaisseur div 2;
LineTo(xf,yf);
@@ -3867,7 +3870,7 @@ begin
begin
pen.color:=fond;
Brush.Color:=fond;
if testbit(ep,0) or testbit(ep,3) then pen.Width:=epaisseur div 4 else pen.width:=epaisseur div 2;
if testbit(ep,7) or testbit(ep,4) then pen.Width:=epaisseur div 4 else pen.width:=epaisseur div 2;
Arc(x1,y1,x2,y2,x3,y3,x4,y4);
end;
end;
@@ -8486,7 +8489,6 @@ begin
trajet_droit;
end;
if (position=const_Devie) then
begin
if not affposFil then
@@ -8729,7 +8731,6 @@ var x0,y0,jx2,jy2,jx3,jy3,xc,yc,jx1,jy1,xf,yf,position,ep : integer;
end;
end;
begin
x0:=(x-1)*LargeurCell[indexTCO]; // x origine
y0:=(y-1)*hauteurCell[indexTCO]; // y origine
+1 -1
View File
@@ -26,7 +26,7 @@ var
f : textFile;
Const
VersionSC = '10.53'; // sert à la comparaison de la version publiée
VersionSC = '10.54'; // sert à la comparaison de la version publiée
SousVersion=' '; // A B C ... en cas d'absence de sous version mettre un espace
// pour unzip
SHCONTCH_NOPROGRESSBOX=4;
+4 -1
View File
@@ -332,7 +332,10 @@ version 10.5 : Correction affichage r
version 10.51 : Correction placement des trains dans le TCO.
version 10.52 : Sélection routes pour plusieurs trains dans le TCO.
version 10.53 : Vérification du répertoire d'installation de CDM Rail.
Correction d'un bug sur la suppression/création train.
Correction d'un bug sur la suppression/création train.
version 10.54 : Améliorations diverses