Private
Public Access
Made sure that ErrorWindow didn't send mixed messages
This commit is contained in:
1 parent
55a9e79991
commit
b3d7b5f722
2 files changed
+35
-16
No files matched your search
Generated
+17
-16
@@ -23,28 +23,27 @@
|
||||
/// the contents of this method with the code editor.
|
||||
/// </summary>
|
||||
private void InitializeComponent() {
|
||||
System.Windows.Forms.GroupBox groupBox1;
|
||||
this.pictureBox1 = new System.Windows.Forms.PictureBox();
|
||||
this.label1 = new System.Windows.Forms.Label();
|
||||
this.button1 = new System.Windows.Forms.Button();
|
||||
this.button2 = new System.Windows.Forms.Button();
|
||||
groupBox1 = new System.Windows.Forms.GroupBox();
|
||||
groupBox1.SuspendLayout();
|
||||
this.groupBox1 = new System.Windows.Forms.GroupBox();
|
||||
this.groupBox1.SuspendLayout();
|
||||
((System.ComponentModel.ISupportInitialize)(this.pictureBox1)).BeginInit();
|
||||
this.SuspendLayout();
|
||||
//
|
||||
// groupBox1
|
||||
//
|
||||
groupBox1.AutoSize = true;
|
||||
groupBox1.Controls.Add(this.pictureBox1);
|
||||
groupBox1.Controls.Add(this.label1);
|
||||
groupBox1.Dock = System.Windows.Forms.DockStyle.Bottom;
|
||||
groupBox1.Location = new System.Drawing.Point(0, 6);
|
||||
groupBox1.Name = "groupBox1";
|
||||
groupBox1.Size = new System.Drawing.Size(336, 98);
|
||||
groupBox1.TabIndex = 4;
|
||||
groupBox1.TabStop = false;
|
||||
groupBox1.Text = "Error";
|
||||
this.groupBox1.AutoSize = true;
|
||||
this.groupBox1.Controls.Add(this.pictureBox1);
|
||||
this.groupBox1.Controls.Add(this.label1);
|
||||
this.groupBox1.Dock = System.Windows.Forms.DockStyle.Bottom;
|
||||
this.groupBox1.Location = new System.Drawing.Point(0, 6);
|
||||
this.groupBox1.Name = "groupBox1";
|
||||
this.groupBox1.Size = new System.Drawing.Size(336, 98);
|
||||
this.groupBox1.TabIndex = 4;
|
||||
this.groupBox1.TabStop = false;
|
||||
this.groupBox1.Text = "Error";
|
||||
//
|
||||
// pictureBox1
|
||||
//
|
||||
@@ -92,7 +91,7 @@
|
||||
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
|
||||
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
|
||||
this.ClientSize = new System.Drawing.Size(336, 150);
|
||||
this.Controls.Add(groupBox1);
|
||||
this.Controls.Add(this.groupBox1);
|
||||
this.Controls.Add(this.button2);
|
||||
this.Controls.Add(this.button1);
|
||||
this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedDialog;
|
||||
@@ -100,8 +99,9 @@
|
||||
this.MinimizeBox = false;
|
||||
this.Name = "ErrorWindow";
|
||||
this.Text = "Error";
|
||||
groupBox1.ResumeLayout(false);
|
||||
groupBox1.PerformLayout();
|
||||
this.Load += new System.EventHandler(this.ErrorWindow_Load);
|
||||
this.groupBox1.ResumeLayout(false);
|
||||
this.groupBox1.PerformLayout();
|
||||
((System.ComponentModel.ISupportInitialize)(this.pictureBox1)).EndInit();
|
||||
this.ResumeLayout(false);
|
||||
this.PerformLayout();
|
||||
@@ -114,5 +114,6 @@
|
||||
private System.Windows.Forms.Button button1;
|
||||
private System.Windows.Forms.Label label1;
|
||||
private System.Windows.Forms.Button button2;
|
||||
private System.Windows.Forms.GroupBox groupBox1;
|
||||
}
|
||||
}
|
||||
@@ -48,6 +48,20 @@ namespace Advanced_Software_Engineering {
|
||||
protected void SetPicture(int type) {
|
||||
pictureBox1.Image = IMAGEDIR[type];
|
||||
pictureBox1.Refresh();
|
||||
|
||||
switch(type) {
|
||||
case ERROR_MESSAGE:
|
||||
groupBox1.Text = "Error";
|
||||
break;
|
||||
|
||||
case WARNING_MESSAGE:
|
||||
groupBox1.Text = "Warning";
|
||||
break;
|
||||
|
||||
case INFO_MESSAGE:
|
||||
groupBox1.Text = "Info";
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
private void button1_Click(object sender, EventArgs e) {
|
||||
@@ -57,5 +71,9 @@ namespace Advanced_Software_Engineering {
|
||||
private void button2_Click(object sender, EventArgs e) {
|
||||
new DetailsWindow(desc).Show();
|
||||
}
|
||||
|
||||
private void ErrorWindow_Load(object sender, EventArgs e) {
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user