This commit is contained in:
f1iwq2
2025-01-18 11:54:21 +01:00
parent e8b0207e63
commit c6802b6639
7 changed files with 40 additions and 60 deletions
+6 -3
View File
@@ -4071,10 +4071,12 @@ begin
'Voulez vous continuer l''importation? (aiguillages & branches)',mtConfirmation,[mbyes,mbNo],0)=mrNo then
begin
Affiche('Importation annulée',clOrange);
formAnalyseCDM.hide;
exit;
end;
end;
formAnalyseCDM.Hide;
MaxAiguillage:=0;
n:=0;
Affiche('Importation des aiguillages et des branches',clWhite);
@@ -4309,9 +4311,10 @@ begin
exit;
end;
formImportation.showmodal;
formImportation.showmodal; // fenêtre d'importation , demande infos pour l'importation
if not(faireImport) then exit;
ndet_cdm:=0;
//debugAnalyse:=true;
//debugBranche:=true;
@@ -4329,7 +4332,6 @@ begin
NomModuleCDM:=AnsiLowerCase(Lignes[0]+'.cdm');
formAnalyseCDM.Caption:='Squelette du réseau '+NomModuleCDM;
formAnalyseCDM.Show;
Affiche('Compilation en cours',clWhite);
// on compile: on crée la base de données
@@ -4615,7 +4617,7 @@ begin
AfficheDebug('Nombre de détecteurs='+intToSTR(NDet_cdm),clyellow);
for i:=1 to Ndet_cdm do AfficheDebug(intToSTR(Det_cdm[i]),clYellow);
end;
formAnalyseCDM.Show;
formprinc.ButtonAffAnalyseCDM.Visible:=true;
Affiche('Compilation terminée. Nombre de segments='+intToSTR(nSeg),clWhite);
@@ -4637,6 +4639,7 @@ begin
Affiche('Au moins un aiguillage n''a pas d''adresse dans CDM et',clAqua);
Affiche('la modélisation du réseau ne peut pas être complète.',clAqua);
end;
formAnalyseCDM.show;
end;
+11 -11
View File
@@ -683,7 +683,7 @@ object FormConfig: TFormConfig
Top = 8
Width = 633
Height = 505
ActivePage = TabSheetBranches
ActivePage = TabSheetAig
Font.Charset = DEFAULT_CHARSET
Font.Color = clBlack
Font.Height = -11
@@ -1208,7 +1208,7 @@ object FormConfig: TFormConfig
'S'#233'lection du style d'#39#39'affichage - Le style sera chang'#233' '#224' la ferm' +
'eture de la fen'#234'tre'#39
Style = csDropDownList
ItemHeight = 0
ItemHeight = 13
ParentShowHint = False
ShowHint = True
TabOrder = 0
@@ -2415,7 +2415,7 @@ object FormConfig: TFormConfig
Width = 137
Height = 21
Style = csDropDownList
ItemHeight = 0
ItemHeight = 13
TabOrder = 1
OnChange = ComboBoxDecChange
end
@@ -2546,7 +2546,7 @@ object FormConfig: TFormConfig
Width = 137
Height = 21
Style = csDropDownList
ItemHeight = 0
ItemHeight = 13
TabOrder = 2
OnChange = ComboBoxAspChange
end
@@ -2854,7 +2854,7 @@ object FormConfig: TFormConfig
Top = 56
Width = 193
Height = 21
ItemHeight = 0
ItemHeight = 13
TabOrder = 0
OnChange = ComboBoxDecodeurPersoChange
end
@@ -2873,7 +2873,7 @@ object FormConfig: TFormConfig
Width = 145
Height = 21
Style = csDropDownList
ItemHeight = 0
ItemHeight = 13
TabOrder = 2
OnChange = ComboBoxNationChange
end
@@ -2919,7 +2919,7 @@ object FormConfig: TFormConfig
Width = 193
Height = 21
Style = csDropDownList
ItemHeight = 0
ItemHeight = 13
TabOrder = 6
OnChange = ComboBoxDecCdeChange
end
@@ -3134,7 +3134,7 @@ object FormConfig: TFormConfig
Top = 96
Width = 137
Height = 21
ItemHeight = 0
ItemHeight = 13
TabOrder = 2
OnChange = ComboBoxOperateurChange
OnDrawItem = ComboBoxOperateurDrawItem
@@ -3154,7 +3154,7 @@ object FormConfig: TFormConfig
Top = 96
Width = 161
Height = 21
ItemHeight = 0
ItemHeight = 13
ParentShowHint = False
ShowHint = True
TabOrder = 4
@@ -3255,7 +3255,7 @@ object FormConfig: TFormConfig
Width = 145
Height = 21
Style = csDropDownList
ItemHeight = 0
ItemHeight = 13
TabOrder = 7
OnChange = ComboBoxFLChange
end
@@ -3807,7 +3807,7 @@ object FormConfig: TFormConfig
Height = 21
Hint = 'Nom de l'#39'accessoire d'#233'fini dans l'#39'onglet "p'#233'riph'#233'riques COM/USB"'
Style = csDropDownList
ItemHeight = 0
ItemHeight = 13
ParentShowHint = False
ShowHint = True
TabOrder = 10
+11 -34
View File
@@ -10762,7 +10762,6 @@ begin
end;
end;
// exclure les TJD/S
if (modAig<>tjd) and (modAig<>tjs) then
begin
@@ -15431,6 +15430,13 @@ begin
Nb:=Nb+'A'+intToSTR(adresseBr)+',';
end
else
if s[1]='T' then
begin
delete(s,1,1);
val(s,adresseBr,erreur);
Nb:=Nb+'T'+intToSTR(adresseBr)+',';
end
else
begin
val(s,adresseBr,erreur);
Nb:=Nb+intToSTR(adresseBr)+',';
@@ -15657,12 +15663,6 @@ begin
EditIPLenz.text:=AdresseIP;
EditportLenz.text:=IntToSTR(PortInterface);
EditTempoAig.Text:=IntToSTR(Tempo_Aig);
//EditFiltrDet.text:=intToSTR(filtrageDet0);
//EditnCantonsRes.Text:=intToSTR(nCantonsRes);
//EditAntiTO.Text:=intToSTR(AntiTimeoutEthLenz);
//EditTempoTC.Text:=intToSTR(TempoTC);
//EditMaxParcours.Text:=intToSTR(MaxParcours);
//EditMaxRoutes.Text:=intToSTR(MaxRoutes);
EditOuvreEcran.Text:=intToSTR(ecran_SC);
EditComUSB.Text:=PortCom;
EditFonte.text:=IntToSTR(TailleFonte);
@@ -15717,12 +15717,6 @@ begin
CheckPosAig.checked:=AvecDemandeAiguillages;
CheckBoxDemarUSB.checked:=AvecDemandeInterfaceUSB;
CheckBoxDemarEth.checked:=AvecDemandeInterfaceEth;
//cbAffSig.Checked:=AffSig;
//cbRes.Checked:=affRes;
//cbAck.Checked:=avecAck;
//cbDebugRoulage.checked:=DebugRoulage;
//cbAffLoc.checked:=AffLoc;
//CheckBoxOptionDemiTour.checked:=option_demitour;
CheckBoxSombre.Checked:=Modesombre;
RadioButtonXpress.Checked:=protocole=1;
@@ -15754,12 +15748,6 @@ begin
end;
ListBoxAig.itemindex:=0;
//if serveurIPCDM_Touche then RadioServeurCDM.ItemIndex:=0 else RadioServeurCDM.ItemIndex:=1;
//editAlgo.Text:=intToSTR(Algo_localisation);
//EditMaxSignalSens.Text:=intToSTR(Max_Signal_Sens);
//EditChemin.text:=cheminProgrammesCDM;
// branches à réafficher si changement de style
RichBranche.clear;
for i:=1 to NbreBranches do
@@ -15774,20 +15762,6 @@ begin
Perform(EM_SCROLLCARET,0,0);
end;
// et DCC
{
i:=1;
RichCdeDCCpp.clear;
repeat
if CdeDccpp[i]<>'' then
begin
RichCdeDccpp.Lines.add(CdeDccpp[i]);
RE_ColorLine(RichCdeDccpp,RichCdeDccpp.lines.count-1,ClAqua);
end;
inc(i);
until (CdeDccpp[i]='') or (i>MaxCdeDccpp);
}
// trains
with ListBoxTrains do
begin
@@ -16394,7 +16368,7 @@ begin
exit;
end;
AncligneclicDet:=ligneclicDet;
AncligneclicDet:=lc;
ligneclicDet:=lc;
end;
@@ -16798,6 +16772,7 @@ procedure TFormConfig.ListBoxDetKeyDown(Sender: TObject; var Key: Word;
Shift: TShiftState);
begin
if nDetecteurs<1 then exit;
//if key=VK_delete then supprime_detecteur;
if ord(Key)=VK_UP then
@@ -16850,6 +16825,7 @@ procedure TFormConfig.LEAdrDetChange(Sender: TObject);
var i,erreur : integer;
s : string;
begin
if clicListe then exit;
val(LEAdrDet.text,i,erreur);
if (erreur<>0) or (i<1) then
begin
@@ -16867,6 +16843,7 @@ procedure TFormConfig.LElongDetChange(Sender: TObject);
var r,i,erreur :integer;
s : string;
begin
if clicListe then exit;
val(LElongDet.Text,i,erreur);
if (erreur<>0) or (i<1) then
begin
+2 -2
View File
@@ -743,11 +743,11 @@ begin
clVoies[indexTCO]:=$A00000;
ClFond[indexTCO]:=$A00000;
ClGrille[IndexTCO]:=$FFC0C0; // bleu
CoulCantonLibre[IndexTco]:=$A0F0A0; // vert
CoulCantonLibre[IndexTco]:=$A0D0A0; // vert
CoulCantonOccupe[IndexTCO]:=$A0A0FF; // rouge
for y:=1 to NbreCellY[indexTCO] do
for x:=1 to NbreCellX[indexTCO] do
TCO[indexTCO,x,y].CouleurFond:=$B0B0B0; // blanc doux
TCO[indexTCO,x,y].CouleurFond:=$c0c0c0; // blanc doux
end;
end;
+9 -9
View File
@@ -1970,17 +1970,21 @@ begin
Result:='mac non trouvée';
end;
// renvoyer date heure, MAC, version SC , verif_version
// ex 1 ... renvoie celui de la virtual box
procedure envoie_infos;
var ts : tstrings;
s,cmd : string;
retour,i,erreur : integer;
f : textFile;
begin
s:='';
cmd:='/c vol c: >vol.txt'; // /c ferme la fenetre en fin d'exec /k ne ferme pas
s:=GetCurrentProcessEnvVar('SystemDrive'); // s='c:'
cmd:='/c vol '+s+' >vol.txt'; // /c ferme la fenetre en fin d'exec /k ne ferme pas
// si on fait un runas au lieu de open, çà ouvre une fenetre de demande admin sur les postes non admin
// ou dont le niveau d'utilisateur est bas dans le profil
retour:=ShellExecute(formprinc.Handle,pchar('open'),pchar('cmd.Exe'),PChar(cmd),nil,SW_SHOWNORMAL);
s:='';
if retour<=32 then
begin
ShowMessage(SysErrorMessage(GetLastError));
@@ -2001,7 +2005,7 @@ begin
if i>4 then
begin
i:=i-4;
s:=copy(s,i,9)+' ';
s:=copy(s,i,9)+' '; // Id de formatage de c:\
end;
end;
end;
@@ -8100,7 +8104,7 @@ var i,adr : integer;
repeat
adr:=BrancheN[Num_Branche,i].adresse;
trouve:=(AdrAig=adr) and ((BrancheN[Num_Branche,i].Btype=aig) or (BrancheN[Num_branche,i].BType=buttoir)); // cherche un aiguillage
//Affiche('cherche='+intToSTR(det)+'/explore='+intToSTR(adr)+' Branche='+intToStr(Num_branche)+' index='+intToStr(i),ClWhite);
//Affiche('cherche='+intToSTR(AdrAig)+'/explore='+intToSTR(adr)+' Branche='+intToStr(Num_branche)+' index='+intToStr(i),ClWhite);
if not(trouve) then inc(i);
//if trouve then Affiche('Trouvé en branche'+IntToSTR(Num_branche)+' index='+IntToSTR(i),clGreen);
until trouve or (adr=0) or (i>MaxElBranches) ;
@@ -18902,10 +18906,6 @@ begin
Maj_Signaux(false);
end;
// renvoyer date heure, MAC, version SC , verif_version
// ex 1 ... renvoie celui de la virtual box
// positionne les composants de la fenêtre principale
// i : position X du splitter
procedure positionne_elements(i : integer);
@@ -19527,7 +19527,7 @@ var n,t,i,j,index,OrgMilieu : integer;
begin
Ancien_Nom_Style:='';
Nom_style_aff:='windows';
af:='Client TCP-IP ou USB CDM Rail - Système XpressNet DCC++ Version '+VersionSC+sousVersion+' alpha';
af:='Client TCP-IP ou USB CDM Rail - Système XpressNet DCC++ Version '+VersionSC+sousVersion;
vc:='';
{$IF CompilerVersion >= 28.0}
vc:=' D12';
+1 -1
View File
@@ -26,7 +26,7 @@ var
f : text;
Const
VersionSC = '9.75'; //'9.76'; // sert à la comparaison de la version publiée
VersionSC = '9.76'; // 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;