aboutsummaryrefslogtreecommitdiff
path: root/ShiftOS.Engine/WindowManager
diff options
context:
space:
mode:
Diffstat (limited to 'ShiftOS.Engine/WindowManager')
-rw-r--r--ShiftOS.Engine/WindowManager/InfoboxTemplate.Designer.cs60
-rw-r--r--ShiftOS.Engine/WindowManager/InfoboxTemplate.cs12
-rw-r--r--ShiftOS.Engine/WindowManager/ShiftWM.cs6
3 files changed, 35 insertions, 43 deletions
diff --git a/ShiftOS.Engine/WindowManager/InfoboxTemplate.Designer.cs b/ShiftOS.Engine/WindowManager/InfoboxTemplate.Designer.cs
index 82575d1..1f4af1b 100644
--- a/ShiftOS.Engine/WindowManager/InfoboxTemplate.Designer.cs
+++ b/ShiftOS.Engine/WindowManager/InfoboxTemplate.Designer.cs
@@ -31,9 +31,9 @@
this.components = new System.ComponentModel.Container();
this.pictureBox1 = new System.Windows.Forms.PictureBox();
this.changeSize = new System.Windows.Forms.Timer(this.components);
- this.label1 = new System.Windows.Forms.TextBox();
- this.btnOpt1 = new ShiftOS.Engine.UI.ShiftButton();
- this.btnOpt2 = new ShiftOS.Engine.UI.ShiftButton();
+ this.label1 = new System.Windows.Forms.Label();
+ this.btnOpt1 = new System.Windows.Forms.Button();
+ this.btnOpt2 = new System.Windows.Forms.Button();
((System.ComponentModel.ISupportInitialize)(this.pictureBox1)).BeginInit();
this.SuspendLayout();
//
@@ -42,7 +42,7 @@
this.pictureBox1.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
| System.Windows.Forms.AnchorStyles.Left)));
this.pictureBox1.Image = global::ShiftOS.Engine.Properties.Resources.Symbolinfo;
- this.pictureBox1.Location = new System.Drawing.Point(3, 35);
+ this.pictureBox1.Location = new System.Drawing.Point(3, 38);
this.pictureBox1.Name = "pictureBox1";
this.pictureBox1.Size = new System.Drawing.Size(80, 70);
this.pictureBox1.SizeMode = System.Windows.Forms.PictureBoxSizeMode.AutoSize;
@@ -55,57 +55,47 @@
//
// label1
//
- this.label1.BackColor = System.Drawing.Color.White;
- this.label1.BorderStyle = System.Windows.Forms.BorderStyle.None;
- this.label1.Font = new System.Drawing.Font("Lucida Console", 8.25F);
- this.label1.Location = new System.Drawing.Point(90, 35);
- this.label1.Multiline = true;
+ this.label1.AutoSize = true;
+ this.label1.Font = new System.Drawing.Font("Courier New", 8.25F);
+ this.label1.Location = new System.Drawing.Point(105, 63);
this.label1.Name = "label1";
- this.label1.Size = new System.Drawing.Size(256, 125);
- this.label1.TabIndex = 6;
+ this.label1.Size = new System.Drawing.Size(49, 14);
+ this.label1.TabIndex = 3;
+ this.label1.Text = "label1";
//
// btnOpt1
//
this.btnOpt1.BackColor = System.Drawing.Color.White;
- this.btnOpt1.FlatAppearance.BorderColor = System.Drawing.Color.Black;
this.btnOpt1.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
- this.btnOpt1.Font = new System.Drawing.Font("Lucida Console", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
- this.btnOpt1.ForeColor = System.Drawing.Color.Black;
- this.btnOpt1.Location = new System.Drawing.Point(105, 163);
- this.btnOpt1.Margin = new System.Windows.Forms.Padding(0);
- this.btnOpt1.MinimumSize = new System.Drawing.Size(75, 23);
+ this.btnOpt1.Location = new System.Drawing.Point(108, 171);
this.btnOpt1.Name = "btnOpt1";
- this.btnOpt1.Padding = new System.Windows.Forms.Padding(3);
- this.btnOpt1.Size = new System.Drawing.Size(105, 26);
- this.btnOpt1.TabIndex = 7;
- this.btnOpt1.Text = "shiftButton1";
+ this.btnOpt1.Size = new System.Drawing.Size(75, 23);
+ this.btnOpt1.TabIndex = 4;
+ this.btnOpt1.Text = "button1";
this.btnOpt1.UseVisualStyleBackColor = false;
+ this.btnOpt1.Click += new System.EventHandler(this.btnOpt1_Click);
//
// btnOpt2
//
this.btnOpt2.BackColor = System.Drawing.Color.White;
- this.btnOpt2.FlatAppearance.BorderColor = System.Drawing.Color.Black;
this.btnOpt2.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
- this.btnOpt2.Font = new System.Drawing.Font("Lucida Console", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
- this.btnOpt2.ForeColor = System.Drawing.Color.Black;
- this.btnOpt2.Location = new System.Drawing.Point(229, 163);
- this.btnOpt2.Margin = new System.Windows.Forms.Padding(0);
- this.btnOpt2.MinimumSize = new System.Drawing.Size(75, 23);
+ this.btnOpt2.Location = new System.Drawing.Point(247, 171);
this.btnOpt2.Name = "btnOpt2";
- this.btnOpt2.Padding = new System.Windows.Forms.Padding(3);
- this.btnOpt2.Size = new System.Drawing.Size(105, 26);
- this.btnOpt2.TabIndex = 8;
- this.btnOpt2.Text = "shiftButton2";
+ this.btnOpt2.Size = new System.Drawing.Size(75, 23);
+ this.btnOpt2.TabIndex = 5;
+ this.btnOpt2.Text = "button2";
this.btnOpt2.UseVisualStyleBackColor = false;
+ this.btnOpt1.Click += new System.EventHandler(this.btnOpt1_Click);
//
// InfoboxTemplate
//
- this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
+ this.AutoScaleDimensions = new System.Drawing.SizeF(7F, 14F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.Controls.Add(this.btnOpt2);
this.Controls.Add(this.btnOpt1);
this.Controls.Add(this.label1);
this.Controls.Add(this.pictureBox1);
+ this.Font = new System.Drawing.Font("Courier New", 8.25F);
this.Name = "InfoboxTemplate";
this.Size = new System.Drawing.Size(438, 210);
this.Load += new System.EventHandler(this.InfoboxTemplate_Load);
@@ -118,8 +108,8 @@
#endregion
public System.Windows.Forms.PictureBox pictureBox1;
private System.Windows.Forms.Timer changeSize;
- public System.Windows.Forms.TextBox label1;
- private UI.ShiftButton btnOpt1;
- private UI.ShiftButton btnOpt2;
+ private System.Windows.Forms.Button btnOpt1;
+ private System.Windows.Forms.Button btnOpt2;
+ public System.Windows.Forms.Label label1;
}
}
diff --git a/ShiftOS.Engine/WindowManager/InfoboxTemplate.cs b/ShiftOS.Engine/WindowManager/InfoboxTemplate.cs
index 54d2a0a..2a0d4bd 100644
--- a/ShiftOS.Engine/WindowManager/InfoboxTemplate.cs
+++ b/ShiftOS.Engine/WindowManager/InfoboxTemplate.cs
@@ -51,22 +51,18 @@ namespace ShiftOS.Engine.WindowManager
void btnOpt1_Click(object sender, EventArgs e)
{
isOK = true;
- MessageBox.Show("button was clicked");
ParentForm?.Close();
}
void btnOpt2_Click(object sender, EventArgs e)
{
- switch (btnOpt2.Text)
- {
- case "No":
+ switch (btnOpt2.Text)
+ {
+ case "No":
isNo = true;
ParentForm?.Close();
break;
- case "Cancel":
- isNo = true;
- break;
- }
+ }
}
public void Play()
diff --git a/ShiftOS.Engine/WindowManager/ShiftWM.cs b/ShiftOS.Engine/WindowManager/ShiftWM.cs
index a910c0c..a95ab6e 100644
--- a/ShiftOS.Engine/WindowManager/ShiftWM.cs
+++ b/ShiftOS.Engine/WindowManager/ShiftWM.cs
@@ -40,6 +40,12 @@ namespace ShiftOS.Engine.WindowManager
Title = { Text = title }
};
+ if (showAsInfobox)
+ {
+ app.btnMin.Visible = false;
+ app.btnMax.Visible = false;
+ }
+
app.Width = content.Width + app.leftSide.Width + app.rightSide.Width;
app.Height = content.Height + app.bottomSide.Height + app.titleBar.Height;