Commit c76bb323 authored by Jae Beojkkoch's avatar Jae Beojkkoch
Browse files

[WIP] Login code avec timer

parent 09fbabb4
......@@ -60,13 +60,16 @@
this.txtbNouveauCode = new System.Windows.Forms.TextBox();
this.txtbCodeProprio = new System.Windows.Forms.TextBox();
this.txtbAncienCode = new System.Windows.Forms.TextBox();
this.pbxValidation = new System.Windows.Forms.PictureBox();
this.gxPortier.SuspendLayout();
this.gbxAdmin.SuspendLayout();
this.gbxChangementCode.SuspendLayout();
((System.ComponentModel.ISupportInitialize)(this.pbxValidation)).BeginInit();
this.SuspendLayout();
//
// gxPortier
//
this.gxPortier.Controls.Add(this.pbxValidation);
this.gxPortier.Controls.Add(this.btnAdmin);
this.gxPortier.Controls.Add(this.btnB);
this.gxPortier.Controls.Add(this.btn0);
......@@ -352,6 +355,15 @@
this.txtbAncienCode.Size = new System.Drawing.Size(100, 20);
this.txtbAncienCode.TabIndex = 29;
//
// pbxValidation
//
this.pbxValidation.BackColor = System.Drawing.Color.Red;
this.pbxValidation.Location = new System.Drawing.Point(60, 250);
this.pbxValidation.Name = "pbxValidation";
this.pbxValidation.Size = new System.Drawing.Size(89, 40);
this.pbxValidation.TabIndex = 37;
this.pbxValidation.TabStop = false;
//
// FrmPortier
//
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
......@@ -367,6 +379,7 @@
this.gbxAdmin.PerformLayout();
this.gbxChangementCode.ResumeLayout(false);
this.gbxChangementCode.PerformLayout();
((System.ComponentModel.ISupportInitialize)(this.pbxValidation)).EndInit();
this.ResumeLayout(false);
}
......@@ -403,6 +416,7 @@
private System.Windows.Forms.TextBox txtbNouveauCode;
private System.Windows.Forms.TextBox txtbCodeProprio;
private System.Windows.Forms.TextBox txtbAncienCode;
private System.Windows.Forms.PictureBox pbxValidation;
}
}
......@@ -17,8 +17,8 @@ namespace WACSPortierACode
// Cadenas initialise
private bool _CADENAS_INIT = false;
// chaque instance de frmPortier a un champ privé _leCadenas de type Cadenas
private Cadenas _leCadenas;
// Code saisi
private String _CODE_SAISI = "";
public FrmPortier()
{
......@@ -86,6 +86,24 @@ namespace WACSPortierACode
MessageBox.Show(infoMessage, "Information");
}
private void numericalPadUserInput(Object sender, EventArgs e)
{
if(!this._CADENAS_INIT)
{
makeError("Le cadenas n'a pas initialise.\nVeuillez definir un mot de passe administrateur ainsi qu'un code.");
return;
}
if(this._CODE_SAISI.Length < 4)
{
String selectedCode = (sender as Button).Text;
this._CODE_SAISI += selectedCode;
return;
}
}
private void btnValider_Click(object sender, EventArgs e)
{
if(this._CADENAS_INIT)
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment