aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorFloppyDiskDrive <[email protected]>2017-09-27 20:00:17 -0500
committerFloppyDiskDrive <[email protected]>2017-09-27 20:00:17 -0500
commit23791cf63b61a2a922e80e5077ec5a3ad0ce7c53 (patch)
tree17659924fc9e5004015d33c16a689226e2c48584
parent1c2bf50041e376adc3e901fdc94326d2f9beec77 (diff)
downloadshiftos-rewind-23791cf63b61a2a922e80e5077ec5a3ad0ce7c53.tar.gz
shiftos-rewind-23791cf63b61a2a922e80e5077ec5a3ad0ce7c53.tar.bz2
shiftos-rewind-23791cf63b61a2a922e80e5077ec5a3ad0ce7c53.zip
Added a buggy dynamically changing infobox (this will most likely not work)
-rw-r--r--.vs/ShiftOS/v15/sqlite3/storage.idebin3678208 -> 3678208 bytes
-rw-r--r--ShiftOS.Engine/WindowManager/InfoboxTemplate.Designer.cs2
-rw-r--r--ShiftOS.Engine/WindowManager/InfoboxTemplate.cs20
3 files changed, 19 insertions, 3 deletions
diff --git a/.vs/ShiftOS/v15/sqlite3/storage.ide b/.vs/ShiftOS/v15/sqlite3/storage.ide
index a031093..daba2e0 100644
--- a/.vs/ShiftOS/v15/sqlite3/storage.ide
+++ b/.vs/ShiftOS/v15/sqlite3/storage.ide
Binary files differ
diff --git a/ShiftOS.Engine/WindowManager/InfoboxTemplate.Designer.cs b/ShiftOS.Engine/WindowManager/InfoboxTemplate.Designer.cs
index a076c2a..29d9299 100644
--- a/ShiftOS.Engine/WindowManager/InfoboxTemplate.Designer.cs
+++ b/ShiftOS.Engine/WindowManager/InfoboxTemplate.Designer.cs
@@ -70,7 +70,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(0, 34);
this.pictureBox1.Name = "pictureBox1";
this.pictureBox1.Size = new System.Drawing.Size(80, 70);
this.pictureBox1.SizeMode = System.Windows.Forms.PictureBoxSizeMode.AutoSize;
diff --git a/ShiftOS.Engine/WindowManager/InfoboxTemplate.cs b/ShiftOS.Engine/WindowManager/InfoboxTemplate.cs
index a5be129..d8ad071 100644
--- a/ShiftOS.Engine/WindowManager/InfoboxTemplate.cs
+++ b/ShiftOS.Engine/WindowManager/InfoboxTemplate.cs
@@ -11,6 +11,12 @@ namespace ShiftOS.Engine.WindowManager
Stream _str;
private int _buttonChoice;
private int _buttonSelected;
+ private int _leftDistance;
+ private int _rightDistance;
+ private int _textWidth;
+ private int _textHeight;
+ private int _topDistance;
+ private int _bottomDistance;
public InfoboxTemplate(ButtonType type)
{
InitializeComponent();
@@ -84,8 +90,18 @@ namespace ShiftOS.Engine.WindowManager
private void changeSize_Tick(object sender, EventArgs e)
{
- this.Height += label1.Height;
- this.Width += label1.Width;
+ ChangeSize();
+ }
+ private void ChangeSize()
+ {
+ _textHeight = label1.Height;
+ _textWidth = label1.Width;
+ _topDistance = 55;
+ _bottomDistance = 121;
+ _rightDistance = 101;
+ _leftDistance = 55;
+ this.Height = _textHeight + _topDistance + _bottomDistance;
+ this.Width = _textWidth + _leftDistance + _rightDistance;
}
}
}