aboutsummaryrefslogtreecommitdiff
path: root/source/WindowsFormsApplication1/Controls
diff options
context:
space:
mode:
Diffstat (limited to 'source/WindowsFormsApplication1/Controls')
-rw-r--r--source/WindowsFormsApplication1/Controls/Computer.Designer.cs10
-rw-r--r--source/WindowsFormsApplication1/Controls/Computer.cs4
-rw-r--r--source/WindowsFormsApplication1/Controls/Computer.resx8
-rw-r--r--source/WindowsFormsApplication1/Controls/Connection.Designer.cs2
-rw-r--r--source/WindowsFormsApplication1/Controls/Connection.cs4
-rw-r--r--source/WindowsFormsApplication1/Controls/Connection.resx8
-rw-r--r--source/WindowsFormsApplication1/Controls/DesktopIcon.Designer.cs16
-rw-r--r--source/WindowsFormsApplication1/Controls/DesktopIcon.cs4
-rw-r--r--source/WindowsFormsApplication1/Controls/DesktopIcon.resx8
-rw-r--r--source/WindowsFormsApplication1/Controls/IconControl.Designer.cs40
-rw-r--r--source/WindowsFormsApplication1/Controls/IconControl.cs8
-rw-r--r--source/WindowsFormsApplication1/Controls/IconControl.resx8
-rw-r--r--source/WindowsFormsApplication1/Controls/ImageSelector.Designer.cs20
-rw-r--r--source/WindowsFormsApplication1/Controls/ImageSelector.cs4
-rw-r--r--source/WindowsFormsApplication1/Controls/ImageSelector.resx8
-rw-r--r--source/WindowsFormsApplication1/Controls/NetModuleStatus.Designer.cs20
-rw-r--r--source/WindowsFormsApplication1/Controls/NetModuleStatus.cs4
-rw-r--r--source/WindowsFormsApplication1/Controls/NetModuleStatus.resx8
-rw-r--r--source/WindowsFormsApplication1/Controls/Notification.Designer.cs20
-rw-r--r--source/WindowsFormsApplication1/Controls/Notification.cs4
-rw-r--r--source/WindowsFormsApplication1/Controls/Notification.resx8
-rw-r--r--source/WindowsFormsApplication1/Controls/ProgressBarEX.Designer.cs2
-rw-r--r--source/WindowsFormsApplication1/Controls/ProgressBarEX.cs14
-rw-r--r--source/WindowsFormsApplication1/Controls/ProgressBarEX.resx8
-rw-r--r--source/WindowsFormsApplication1/Controls/ShifterColorInput.Designer.cs26
-rw-r--r--source/WindowsFormsApplication1/Controls/ShifterColorInput.cs2
-rw-r--r--source/WindowsFormsApplication1/Controls/ShifterColorInput.resx8
-rw-r--r--source/WindowsFormsApplication1/Controls/ShifterGraphicInput.Designer.cs26
-rw-r--r--source/WindowsFormsApplication1/Controls/ShifterGraphicInput.cs2
-rw-r--r--source/WindowsFormsApplication1/Controls/ShifterGraphicInput.resx8
-rw-r--r--source/WindowsFormsApplication1/Controls/ShifterIntInput.Designer.cs28
-rw-r--r--source/WindowsFormsApplication1/Controls/ShifterIntInput.cs2
-rw-r--r--source/WindowsFormsApplication1/Controls/ShifterIntInput.resx8
-rw-r--r--source/WindowsFormsApplication1/Controls/ShifterTextInput.Designer.cs22
-rw-r--r--source/WindowsFormsApplication1/Controls/ShifterTextInput.cs4
-rw-r--r--source/WindowsFormsApplication1/Controls/ShifterTextInput.resx8
-rw-r--r--source/WindowsFormsApplication1/Controls/SyntaxHighlighter.cs10
-rw-r--r--source/WindowsFormsApplication1/Controls/WinFormsHost.cs86
-rw-r--r--source/WindowsFormsApplication1/Controls/WindowBorder.Designer.cs152
-rw-r--r--source/WindowsFormsApplication1/Controls/WindowBorder.cs41
-rw-r--r--source/WindowsFormsApplication1/Controls/WindowBorder.resx8
-rw-r--r--source/WindowsFormsApplication1/Controls/infobox (copy).cs113
-rw-r--r--source/WindowsFormsApplication1/Controls/infobox (copy).resx120
-rw-r--r--source/WindowsFormsApplication1/Controls/infobox.Designer (copy).cs183
-rw-r--r--source/WindowsFormsApplication1/Controls/infobox.Designer.cs96
-rw-r--r--source/WindowsFormsApplication1/Controls/infobox.cs2
-rw-r--r--source/WindowsFormsApplication1/Controls/infobox.resx8
47 files changed, 849 insertions, 354 deletions
diff --git a/source/WindowsFormsApplication1/Controls/Computer.Designer.cs b/source/WindowsFormsApplication1/Controls/Computer.Designer.cs
index 4157592..0a37bc1 100644
--- a/source/WindowsFormsApplication1/Controls/Computer.Designer.cs
+++ b/source/WindowsFormsApplication1/Controls/Computer.Designer.cs
@@ -32,12 +32,12 @@
/// </summary>
private void InitializeComponent()
{
- this.lbstats = new System.Windows.Forms.Label();
+ this.lbstats = new ShiftUI.Label();
this.SuspendLayout();
//
// lbstats
//
- this.lbstats.Dock = System.Windows.Forms.DockStyle.Fill;
+ this.lbstats.Dock = ShiftUI.DockStyle.Fill;
this.lbstats.ForeColor = System.Drawing.Color.Black;
this.lbstats.Location = new System.Drawing.Point(0, 0);
this.lbstats.Name = "lbstats";
@@ -49,9 +49,9 @@
//
// Computer
//
- this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.None;
+ this.AutoScaleMode = ShiftUI.AutoScaleMode.None;
this.BackColor = System.Drawing.Color.White;
- this.Controls.Add(this.lbstats);
+ this.Widgets.Add(this.lbstats);
this.Name = "Computer";
this.Size = new System.Drawing.Size(64, 64);
this.Load += new System.EventHandler(this.Computer_Load);
@@ -61,6 +61,6 @@
#endregion
- private System.Windows.Forms.Label lbstats;
+ private ShiftUI.Label lbstats;
}
}
diff --git a/source/WindowsFormsApplication1/Controls/Computer.cs b/source/WindowsFormsApplication1/Controls/Computer.cs
index ad33a58..a9bfda0 100644
--- a/source/WindowsFormsApplication1/Controls/Computer.cs
+++ b/source/WindowsFormsApplication1/Controls/Computer.cs
@@ -6,11 +6,11 @@ using System.Data;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
-using System.Windows.Forms;
+using ShiftUI;
namespace ShiftOS
{
- public partial class Computer : UserControl
+ public partial class Computer : UserWidget
{
public int TotalHP = 100;
diff --git a/source/WindowsFormsApplication1/Controls/Computer.resx b/source/WindowsFormsApplication1/Controls/Computer.resx
index 1af7de1..ffb4fb5 100644
--- a/source/WindowsFormsApplication1/Controls/Computer.resx
+++ b/source/WindowsFormsApplication1/Controls/Computer.resx
@@ -15,8 +15,8 @@
... ado.net/XML headers & schema ...
<resheader name="resmimetype">text/microsoft-resx</resheader>
<resheader name="version">2.0</resheader>
- <resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
- <resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
+ <resheader name="reader">System.Resources.ResXResourceReader, ShiftUI, ...</resheader>
+ <resheader name="writer">System.Resources.ResXResourceWriter, ShiftUI, ...</resheader>
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
@@ -112,9 +112,9 @@
<value>2.0</value>
</resheader>
<resheader name="reader">
- <value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
+ <value>System.Resources.ResXResourceReader, ShiftUI, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
- <value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
+ <value>System.Resources.ResXResourceWriter, ShiftUI, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
</root> \ No newline at end of file
diff --git a/source/WindowsFormsApplication1/Controls/Connection.Designer.cs b/source/WindowsFormsApplication1/Controls/Connection.Designer.cs
index 071ff4a..a6ab301 100644
--- a/source/WindowsFormsApplication1/Controls/Connection.Designer.cs
+++ b/source/WindowsFormsApplication1/Controls/Connection.Designer.cs
@@ -33,7 +33,7 @@
// Connection
//
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
- this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
+ this.AutoScaleMode = ShiftUI.AutoScaleMode.Font;
this.Name = "Connection";
this.Size = new System.Drawing.Size(150, 10);
this.ResumeLayout(false);
diff --git a/source/WindowsFormsApplication1/Controls/Connection.cs b/source/WindowsFormsApplication1/Controls/Connection.cs
index b322581..6829a50 100644
--- a/source/WindowsFormsApplication1/Controls/Connection.cs
+++ b/source/WindowsFormsApplication1/Controls/Connection.cs
@@ -6,11 +6,11 @@ using System.Data;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
-using System.Windows.Forms;
+using ShiftUI;
namespace ShiftOS
{
- public partial class Connection : UserControl
+ public partial class Connection : UserWidget
{
public Connection()
{
diff --git a/source/WindowsFormsApplication1/Controls/Connection.resx b/source/WindowsFormsApplication1/Controls/Connection.resx
index 1af7de1..ffb4fb5 100644
--- a/source/WindowsFormsApplication1/Controls/Connection.resx
+++ b/source/WindowsFormsApplication1/Controls/Connection.resx
@@ -15,8 +15,8 @@
... ado.net/XML headers & schema ...
<resheader name="resmimetype">text/microsoft-resx</resheader>
<resheader name="version">2.0</resheader>
- <resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
- <resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
+ <resheader name="reader">System.Resources.ResXResourceReader, ShiftUI, ...</resheader>
+ <resheader name="writer">System.Resources.ResXResourceWriter, ShiftUI, ...</resheader>
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
@@ -112,9 +112,9 @@
<value>2.0</value>
</resheader>
<resheader name="reader">
- <value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
+ <value>System.Resources.ResXResourceReader, ShiftUI, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
- <value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
+ <value>System.Resources.ResXResourceWriter, ShiftUI, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
</root> \ No newline at end of file
diff --git a/source/WindowsFormsApplication1/Controls/DesktopIcon.Designer.cs b/source/WindowsFormsApplication1/Controls/DesktopIcon.Designer.cs
index 98369ab..48f90a9 100644
--- a/source/WindowsFormsApplication1/Controls/DesktopIcon.Designer.cs
+++ b/source/WindowsFormsApplication1/Controls/DesktopIcon.Designer.cs
@@ -28,8 +28,8 @@
/// </summary>
private void InitializeComponent()
{
- this.pbicon = new System.Windows.Forms.PictureBox();
- this.lbiconname = new System.Windows.Forms.Label();
+ this.pbicon = new ShiftUI.PictureBox();
+ this.lbiconname = new ShiftUI.Label();
((System.ComponentModel.ISupportInitialize)(this.pbicon)).BeginInit();
this.SuspendLayout();
//
@@ -38,7 +38,7 @@
this.pbicon.Location = new System.Drawing.Point(4, 4);
this.pbicon.Name = "pbicon";
this.pbicon.Size = new System.Drawing.Size(78, 50);
- this.pbicon.SizeMode = System.Windows.Forms.PictureBoxSizeMode.CenterImage;
+ this.pbicon.SizeMode = ShiftUI.PictureBoxSizeMode.CenterImage;
this.pbicon.TabIndex = 0;
this.pbicon.TabStop = false;
this.pbicon.DoubleClick += new System.EventHandler(this.Icon_Click);
@@ -57,10 +57,10 @@
// DesktopIcon
//
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
- this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
+ this.AutoScaleMode = ShiftUI.AutoScaleMode.Font;
this.BackColor = System.Drawing.Color.Transparent;
- this.Controls.Add(this.lbiconname);
- this.Controls.Add(this.pbicon);
+ this.Widgets.Add(this.lbiconname);
+ this.Widgets.Add(this.pbicon);
this.Name = "DesktopIcon";
this.Size = new System.Drawing.Size(85, 85);
this.Load += new System.EventHandler(this.DesktopIcon_Load);
@@ -72,7 +72,7 @@
#endregion
- private System.Windows.Forms.PictureBox pbicon;
- private System.Windows.Forms.Label lbiconname;
+ private ShiftUI.PictureBox pbicon;
+ private ShiftUI.Label lbiconname;
}
}
diff --git a/source/WindowsFormsApplication1/Controls/DesktopIcon.cs b/source/WindowsFormsApplication1/Controls/DesktopIcon.cs
index bfb0940..175ccdb 100644
--- a/source/WindowsFormsApplication1/Controls/DesktopIcon.cs
+++ b/source/WindowsFormsApplication1/Controls/DesktopIcon.cs
@@ -6,12 +6,12 @@ using System.Data;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
-using System.Windows.Forms;
+using ShiftUI;
using System.IO;
namespace ShiftOS
{
- public partial class DesktopIcon : UserControl
+ public partial class DesktopIcon : UserWidget
{
/// <summary>
/// User control for a desktop icon.
diff --git a/source/WindowsFormsApplication1/Controls/DesktopIcon.resx b/source/WindowsFormsApplication1/Controls/DesktopIcon.resx
index 1af7de1..ffb4fb5 100644
--- a/source/WindowsFormsApplication1/Controls/DesktopIcon.resx
+++ b/source/WindowsFormsApplication1/Controls/DesktopIcon.resx
@@ -15,8 +15,8 @@
... ado.net/XML headers & schema ...
<resheader name="resmimetype">text/microsoft-resx</resheader>
<resheader name="version">2.0</resheader>
- <resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
- <resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
+ <resheader name="reader">System.Resources.ResXResourceReader, ShiftUI, ...</resheader>
+ <resheader name="writer">System.Resources.ResXResourceWriter, ShiftUI, ...</resheader>
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
@@ -112,9 +112,9 @@
<value>2.0</value>
</resheader>
<resheader name="reader">
- <value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
+ <value>System.Resources.ResXResourceReader, ShiftUI, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
- <value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
+ <value>System.Resources.ResXResourceWriter, ShiftUI, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
</root> \ No newline at end of file
diff --git a/source/WindowsFormsApplication1/Controls/IconControl.Designer.cs b/source/WindowsFormsApplication1/Controls/IconControl.Designer.cs
index b86f908..62a3cca 100644
--- a/source/WindowsFormsApplication1/Controls/IconControl.Designer.cs
+++ b/source/WindowsFormsApplication1/Controls/IconControl.Designer.cs
@@ -1,6 +1,6 @@
namespace ShiftOS
{
- partial class IconControl
+ partial class IconWidget
{
/// <summary>
/// Required designer variable.
@@ -28,19 +28,19 @@
/// </summary>
private void InitializeComponent()
{
- this.panel1 = new System.Windows.Forms.Panel();
- this.pblarge = new System.Windows.Forms.PictureBox();
- this.lbname = new System.Windows.Forms.Label();
+ this.panel1 = new ShiftUI.Panel();
+ this.pblarge = new ShiftUI.PictureBox();
+ this.lbname = new ShiftUI.Label();
this.panel1.SuspendLayout();
((System.ComponentModel.ISupportInitialize)(this.pblarge)).BeginInit();
this.SuspendLayout();
//
// panel1
//
- this.panel1.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;
- this.panel1.Controls.Add(this.pblarge);
- this.panel1.Controls.Add(this.lbname);
- this.panel1.Dock = System.Windows.Forms.DockStyle.Fill;
+ this.panel1.BorderStyle = ShiftUI.BorderStyle.FixedSingle;
+ this.panel1.Widgets.Add(this.pblarge);
+ this.panel1.Widgets.Add(this.lbname);
+ this.panel1.Dock = ShiftUI.DockStyle.Fill;
this.panel1.Location = new System.Drawing.Point(0, 0);
this.panel1.Name = "panel1";
this.panel1.Size = new System.Drawing.Size(171, 56);
@@ -48,19 +48,19 @@
//
// pblarge
//
- this.pblarge.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;
+ this.pblarge.BorderStyle = ShiftUI.BorderStyle.FixedSingle;
this.pblarge.Location = new System.Drawing.Point(135, 3);
this.pblarge.Name = "pblarge";
this.pblarge.Size = new System.Drawing.Size(32, 32);
- this.pblarge.SizeMode = System.Windows.Forms.PictureBoxSizeMode.CenterImage;
+ this.pblarge.SizeMode = ShiftUI.PictureBoxSizeMode.CenterImage;
this.pblarge.TabIndex = 2;
this.pblarge.TabStop = false;
this.pblarge.Click += new System.EventHandler(this.pblarge_Click);
//
// lbname
//
- this.lbname.Cursor = System.Windows.Forms.Cursors.IBeam;
- this.lbname.Dock = System.Windows.Forms.DockStyle.Left;
+ this.lbname.Cursor = ShiftUI.Cursors.IBeam;
+ this.lbname.Dock = ShiftUI.DockStyle.Left;
this.lbname.Font = new System.Drawing.Font("Microsoft Sans Serif", 12F);
this.lbname.Location = new System.Drawing.Point(0, 0);
this.lbname.Name = "lbname";
@@ -69,14 +69,14 @@
this.lbname.Text = "Icon Name";
this.lbname.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
//
- // IconControl
+ // IconWidget
//
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
- this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
- this.Controls.Add(this.panel1);
- this.Name = "IconControl";
+ this.AutoScaleMode = ShiftUI.AutoScaleMode.Font;
+ this.Widgets.Add(this.panel1);
+ this.Name = "IconWidget";
this.Size = new System.Drawing.Size(171, 56);
- this.Load += new System.EventHandler(this.IconControl_Load);
+ this.Load += new System.EventHandler(this.IconWidget_Load);
this.panel1.ResumeLayout(false);
((System.ComponentModel.ISupportInitialize)(this.pblarge)).EndInit();
this.ResumeLayout(false);
@@ -85,8 +85,8 @@
#endregion
- private System.Windows.Forms.Panel panel1;
- private System.Windows.Forms.Label lbname;
- private System.Windows.Forms.PictureBox pblarge;
+ private ShiftUI.Panel panel1;
+ private ShiftUI.Label lbname;
+ private ShiftUI.PictureBox pblarge;
}
}
diff --git a/source/WindowsFormsApplication1/Controls/IconControl.cs b/source/WindowsFormsApplication1/Controls/IconControl.cs
index e103ced..5971744 100644
--- a/source/WindowsFormsApplication1/Controls/IconControl.cs
+++ b/source/WindowsFormsApplication1/Controls/IconControl.cs
@@ -6,21 +6,21 @@ using System.Data;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
-using System.Windows.Forms;
+using ShiftUI;
using System.Drawing.Imaging;
using Newtonsoft.Json;
using System.IO;
namespace ShiftOS
{
- public partial class IconControl : UserControl
+ public partial class IconWidget : UserWidget
{
- public IconControl()
+ public IconWidget()
{
InitializeComponent();
}
- private void IconControl_Load(object sender, EventArgs e)
+ private void IconWidget_Load(object sender, EventArgs e)
{
pblarge.Top = (this.Height - pblarge.Height) / 2;
}
diff --git a/source/WindowsFormsApplication1/Controls/IconControl.resx b/source/WindowsFormsApplication1/Controls/IconControl.resx
index 1af7de1..ffb4fb5 100644
--- a/source/WindowsFormsApplication1/Controls/IconControl.resx
+++ b/source/WindowsFormsApplication1/Controls/IconControl.resx
@@ -15,8 +15,8 @@
... ado.net/XML headers & schema ...
<resheader name="resmimetype">text/microsoft-resx</resheader>
<resheader name="version">2.0</resheader>
- <resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
- <resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
+ <resheader name="reader">System.Resources.ResXResourceReader, ShiftUI, ...</resheader>
+ <resheader name="writer">System.Resources.ResXResourceWriter, ShiftUI, ...</resheader>
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
@@ -112,9 +112,9 @@
<value>2.0</value>
</resheader>
<resheader name="reader">
- <value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
+ <value>System.Resources.ResXResourceReader, ShiftUI, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
- <value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
+ <value>System.Resources.ResXResourceWriter, ShiftUI, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
</root> \ No newline at end of file
diff --git a/source/WindowsFormsApplication1/Controls/ImageSelector.Designer.cs b/source/WindowsFormsApplication1/Controls/ImageSelector.Designer.cs
index 7340ceb..0d79e51 100644
--- a/source/WindowsFormsApplication1/Controls/ImageSelector.Designer.cs
+++ b/source/WindowsFormsApplication1/Controls/ImageSelector.Designer.cs
@@ -28,14 +28,14 @@
/// </summary>
private void InitializeComponent()
{
- this.label1 = new System.Windows.Forms.Label();
- this.btnselect = new System.Windows.Forms.Button();
+ this.label1 = new ShiftUI.Label();
+ this.btnselect = new ShiftUI.Button();
this.SuspendLayout();
//
// label1
//
this.label1.BackColor = System.Drawing.Color.White;
- this.label1.Dock = System.Windows.Forms.DockStyle.Left;
+ this.label1.Dock = ShiftUI.DockStyle.Left;
this.label1.Font = new System.Drawing.Font("Microsoft Sans Serif", 10F);
this.label1.ForeColor = System.Drawing.Color.Black;
this.label1.Location = new System.Drawing.Point(0, 0);
@@ -47,8 +47,8 @@
//
// btnselect
//
- this.btnselect.Dock = System.Windows.Forms.DockStyle.Fill;
- this.btnselect.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
+ this.btnselect.Dock = ShiftUI.DockStyle.Fill;
+ this.btnselect.FlatStyle = ShiftUI.FlatStyle.Standard;
this.btnselect.Location = new System.Drawing.Point(186, 0);
this.btnselect.Name = "btnselect";
this.btnselect.Size = new System.Drawing.Size(40, 33);
@@ -59,9 +59,9 @@
// ImageSelector
//
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
- this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
- this.Controls.Add(this.btnselect);
- this.Controls.Add(this.label1);
+ this.AutoScaleMode = ShiftUI.AutoScaleMode.Font;
+ this.Widgets.Add(this.btnselect);
+ this.Widgets.Add(this.label1);
this.Name = "ImageSelector";
this.Size = new System.Drawing.Size(226, 33);
this.ResumeLayout(false);
@@ -70,7 +70,7 @@
#endregion
- private System.Windows.Forms.Label label1;
- private System.Windows.Forms.Button btnselect;
+ private ShiftUI.Label label1;
+ private ShiftUI.Button btnselect;
}
}
diff --git a/source/WindowsFormsApplication1/Controls/ImageSelector.cs b/source/WindowsFormsApplication1/Controls/ImageSelector.cs
index b1aa4d2..f912ec8 100644
--- a/source/WindowsFormsApplication1/Controls/ImageSelector.cs
+++ b/source/WindowsFormsApplication1/Controls/ImageSelector.cs
@@ -6,12 +6,12 @@ using System.Data;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
-using System.Windows.Forms;
+using ShiftUI;
using System.IO;
namespace ShiftOS
{
- public partial class ImageSelector : UserControl
+ public partial class ImageSelector : UserWidget
{
public ImageSelector()
{
diff --git a/source/WindowsFormsApplication1/Controls/ImageSelector.resx b/source/WindowsFormsApplication1/Controls/ImageSelector.resx
index 1af7de1..ffb4fb5 100644
--- a/source/WindowsFormsApplication1/Controls/ImageSelector.resx
+++ b/source/WindowsFormsApplication1/Controls/ImageSelector.resx
@@ -15,8 +15,8 @@
... ado.net/XML headers & schema ...
<resheader name="resmimetype">text/microsoft-resx</resheader>
<resheader name="version">2.0</resheader>
- <resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
- <resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
+ <resheader name="reader">System.Resources.ResXResourceReader, ShiftUI, ...</resheader>
+ <resheader name="writer">System.Resources.ResXResourceWriter, ShiftUI, ...</resheader>
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
@@ -112,9 +112,9 @@
<value>2.0</value>
</resheader>
<resheader name="reader">
- <value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
+ <value>System.Resources.ResXResourceReader, ShiftUI, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
- <value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
+ <value>System.Resources.ResXResourceWriter, ShiftUI, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
</root> \ No newline at end of file
diff --git a/source/WindowsFormsApplication1/Controls/NetModuleStatus.Designer.cs b/source/WindowsFormsApplication1/Controls/NetModuleStatus.Designer.cs
index 31608d4..3770b37 100644
--- a/source/WindowsFormsApplication1/Controls/NetModuleStatus.Designer.cs
+++ b/source/WindowsFormsApplication1/Controls/NetModuleStatus.Designer.cs
@@ -28,14 +28,14 @@
/// </summary>
private void InitializeComponent()
{
- this.lbinfo = new System.Windows.Forms.Label();
+ this.lbinfo = new ShiftUI.Label();
this.pghealth = new ShiftOS.ProgressBarEX();
this.SuspendLayout();
//
// lbinfo
//
- this.lbinfo.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
- | System.Windows.Forms.AnchorStyles.Left)));
+ this.lbinfo.Anchor = ((ShiftUI.AnchorStyles)(((ShiftUI.AnchorStyles.Top | ShiftUI.AnchorStyles.Bottom)
+ | ShiftUI.AnchorStyles.Left)));
this.lbinfo.Location = new System.Drawing.Point(4, 4);
this.lbinfo.Name = "lbinfo";
this.lbinfo.Size = new System.Drawing.Size(102, 22);
@@ -44,9 +44,9 @@
//
// pghealth
//
- this.pghealth.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
- | System.Windows.Forms.AnchorStyles.Left)
- | System.Windows.Forms.AnchorStyles.Right)));
+ this.pghealth.Anchor = ((ShiftUI.AnchorStyles)((((ShiftUI.AnchorStyles.Top | ShiftUI.AnchorStyles.Bottom)
+ | ShiftUI.AnchorStyles.Left)
+ | ShiftUI.AnchorStyles.Right)));
this.pghealth.BackColor = System.Drawing.Color.Black;
this.pghealth.BlockSeparation = 3;
this.pghealth.BlockWidth = 5;
@@ -67,9 +67,9 @@
// NetModuleStatus
//
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
- this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
- this.Controls.Add(this.lbinfo);
- this.Controls.Add(this.pghealth);
+ this.AutoScaleMode = ShiftUI.AutoScaleMode.Font;
+ this.Widgets.Add(this.lbinfo);
+ this.Widgets.Add(this.pghealth);
this.Name = "NetModuleStatus";
this.Size = new System.Drawing.Size(352, 26);
this.ResumeLayout(false);
@@ -79,6 +79,6 @@
#endregion
private ProgressBarEX pghealth;
- private System.Windows.Forms.Label lbinfo;
+ private ShiftUI.Label lbinfo;
}
}
diff --git a/source/WindowsFormsApplication1/Controls/NetModuleStatus.cs b/source/WindowsFormsApplication1/Controls/NetModuleStatus.cs
index 037f73a..947bd46 100644
--- a/source/WindowsFormsApplication1/Controls/NetModuleStatus.cs
+++ b/source/WindowsFormsApplication1/Controls/NetModuleStatus.cs
@@ -6,11 +6,11 @@ using System.Data;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
-using System.Windows.Forms;
+using ShiftUI;
namespace ShiftOS
{
- public partial class NetModuleStatus : UserControl
+ public partial class NetModuleStatus : UserWidget
{
private Module _module = null;
diff --git a/source/WindowsFormsApplication1/Controls/NetModuleStatus.resx b/source/WindowsFormsApplication1/Controls/NetModuleStatus.resx
index 1af7de1..ffb4fb5 100644
--- a/source/WindowsFormsApplication1/Controls/NetModuleStatus.resx
+++ b/source/WindowsFormsApplication1/Controls/NetModuleStatus.resx
@@ -15,8 +15,8 @@
... ado.net/XML headers & schema ...
<resheader name="resmimetype">text/microsoft-resx</resheader>
<resheader name="version">2.0</resheader>
- <resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
- <resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
+ <resheader name="reader">System.Resources.ResXResourceReader, ShiftUI, ...</resheader>
+ <resheader name="writer">System.Resources.ResXResourceWriter, ShiftUI, ...</resheader>
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
@@ -112,9 +112,9 @@
<value>2.0</value>
</resheader>
<resheader name="reader">
- <value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
+ <value>System.Resources.ResXResourceReader, ShiftUI, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
- <value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
+ <value>System.Resources.ResXResourceWriter, ShiftUI, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
</root> \ No newline at end of file
diff --git a/source/WindowsFormsApplication1/Controls/Notification.Designer.cs b/source/WindowsFormsApplication1/Controls/Notification.Designer.cs
index 57b6416..614550c 100644
--- a/source/WindowsFormsApplication1/Controls/Notification.Designer.cs
+++ b/source/WindowsFormsApplication1/Controls/Notification.Designer.cs
@@ -28,8 +28,8 @@
/// </summary>
private void InitializeComponent()
{
- this.lbtitle = new System.Windows.Forms.Label();
- this.lbmessage = new System.Windows.Forms.Label();
+ this.lbtitle = new ShiftUI.Label();
+ this.lbmessage = new ShiftUI.Label();
this.SuspendLayout();
//
// lbtitle
@@ -44,9 +44,9 @@
//
// lbmessage
//
- this.lbmessage.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
- | System.Windows.Forms.AnchorStyles.Left)
- | System.Windows.Forms.AnchorStyles.Right)));
+ this.lbmessage.Anchor = ((ShiftUI.AnchorStyles)((((ShiftUI.AnchorStyles.Top | ShiftUI.AnchorStyles.Bottom)
+ | ShiftUI.AnchorStyles.Left)
+ | ShiftUI.AnchorStyles.Right)));
this.lbmessage.Font = new System.Drawing.Font("Microsoft Sans Serif", 10F);
this.lbmessage.Location = new System.Drawing.Point(7, 33);
this.lbmessage.Name = "lbmessage";
@@ -57,10 +57,10 @@
// Notification
//
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
- this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
+ this.AutoScaleMode = ShiftUI.AutoScaleMode.Font;
this.BackColor = System.Drawing.Color.Gray;
- this.Controls.Add(this.lbmessage);
- this.Controls.Add(this.lbtitle);
+ this.Widgets.Add(this.lbmessage);
+ this.Widgets.Add(this.lbtitle);
this.ForeColor = System.Drawing.Color.White;
this.Name = "Notification";
this.Size = new System.Drawing.Size(355, 100);
@@ -72,7 +72,7 @@
#endregion
- private System.Windows.Forms.Label lbtitle;
- private System.Windows.Forms.Label lbmessage;
+ private ShiftUI.Label lbtitle;
+ private ShiftUI.Label lbmessage;
}
}
diff --git a/source/WindowsFormsApplication1/Controls/Notification.cs b/source/WindowsFormsApplication1/Controls/Notification.cs
index b5e1693..7fd5574 100644
--- a/source/WindowsFormsApplication1/Controls/Notification.cs
+++ b/source/WindowsFormsApplication1/Controls/Notification.cs
@@ -6,11 +6,11 @@ using System.Data;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
-using System.Windows.Forms;
+using ShiftUI;
namespace ShiftOS
{
- public partial class Notification : UserControl
+ public partial class Notification : UserWidget
{
public Notification(string title, string text)
{
diff --git a/source/WindowsFormsApplication1/Controls/Notification.resx b/source/WindowsFormsApplication1/Controls/Notification.resx
index 1af7de1..ffb4fb5 100644
--- a/source/WindowsFormsApplication1/Controls/Notification.resx
+++ b/source/WindowsFormsApplication1/Controls/Notification.resx
@@ -15,8 +15,8 @@
... ado.net/XML headers & schema ...
<resheader name="resmimetype">text/microsoft-resx</resheader>
<resheader name="version">2.0</resheader>
- <resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
- <resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
+ <resheader name="reader">System.Resources.ResXResourceReader, ShiftUI, ...</resheader>
+ <resheader name="writer">System.Resources.ResXResourceWriter, ShiftUI, ...</resheader>
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
@@ -112,9 +112,9 @@
<value>2.0</value>
</resheader>
<resheader name="reader">
- <value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
+ <value>System.Resources.ResXResourceReader, ShiftUI, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
- <value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
+ <value>System.Resources.ResXResourceWriter, ShiftUI, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
</root> \ No newline at end of file
diff --git a/source/WindowsFormsApplication1/Controls/ProgressBarEX.Designer.cs b/source/WindowsFormsApplication1/Controls/ProgressBarEX.Designer.cs
index 219fb73..847868a 100644
--- a/source/WindowsFormsApplication1/Controls/ProgressBarEX.Designer.cs
+++ b/source/WindowsFormsApplication1/Controls/ProgressBarEX.Designer.cs
@@ -27,7 +27,7 @@
// ProgressBarEX
//
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
- this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
+ this.AutoScaleMode = ShiftUI.AutoScaleMode.Font;
this.Name = "ProgressBarEX";
this.Size = new System.Drawing.Size(340, 32);
this.ResumeLayout(false);
diff --git a/source/WindowsFormsApplication1/Controls/ProgressBarEX.cs b/source/WindowsFormsApplication1/Controls/ProgressBarEX.cs
index 4896292..8febdcd 100644
--- a/source/WindowsFormsApplication1/Controls/ProgressBarEX.cs
+++ b/source/WindowsFormsApplication1/Controls/ProgressBarEX.cs
@@ -6,11 +6,11 @@ using System.Data;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
-using System.Windows.Forms;
+using ShiftUI;
namespace ShiftOS
{
- public partial class ProgressBarEX : UserControl
+ public partial class ProgressBarEX : UserWidget
{
public ProgressBarEX()
{
@@ -102,13 +102,7 @@ namespace ShiftOS
get { return _MaxValue; }
set
{
- if (value > this.MinValue)
- {
- _MaxValue = value;
- }
- else {
- throw new ArgumentOutOfRangeException("The maximum value must be more than the minimum value.");
- }
+ _MaxValue = value;
}
}
@@ -279,7 +273,7 @@ namespace ShiftOS
#region " Drawing "
- protected override void OnPaint(System.Windows.Forms.PaintEventArgs e)
+ protected override void OnPaint(ShiftUI.PaintEventArgs e)
{
base.OnPaint(e);
DoPaintBackground(e.Graphics);
diff --git a/source/WindowsFormsApplication1/Controls/ProgressBarEX.resx b/source/WindowsFormsApplication1/Controls/ProgressBarEX.resx
index 1af7de1..ffb4fb5 100644
--- a/source/WindowsFormsApplication1/Controls/ProgressBarEX.resx
+++ b/source/WindowsFormsApplication1/Controls/ProgressBarEX.resx
@@ -15,8 +15,8 @@
... ado.net/XML headers & schema ...
<resheader name="resmimetype">text/microsoft-resx</resheader>
<resheader name="version">2.0</resheader>
- <resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
- <resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
+ <resheader name="reader">System.Resources.ResXResourceReader, ShiftUI, ...</resheader>
+ <resheader name="writer">System.Resources.ResXResourceWriter, ShiftUI, ...</resheader>
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
@@ -112,9 +112,9 @@
<value>2.0</value>
</resheader>
<resheader name="reader">
- <value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
+ <value>System.Resources.ResXResourceReader, ShiftUI, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
- <value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
+ <value>System.Resources.ResXResourceWriter, ShiftUI, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
</root> \ No newline at end of file
diff --git a/source/WindowsFormsApplication1/Controls/ShifterColorInput.Designer.cs b/source/WindowsFormsApplication1/Controls/ShifterColorInput.Designer.cs
index 47cf0a1..3703960 100644
--- a/source/WindowsFormsApplication1/Controls/ShifterColorInput.Designer.cs
+++ b/source/WindowsFormsApplication1/Controls/ShifterColorInput.Designer.cs
@@ -28,15 +28,15 @@
/// </summary>
private void InitializeComponent()
{
- this.pnlmainbuttoncolour = new System.Windows.Forms.Panel();
- this.lblabel = new System.Windows.Forms.Label();
+ this.pnlmainbuttoncolour = new ShiftUI.Panel();
+ this.lblabel = new ShiftUI.Label();
this.SuspendLayout();
//
// pnlmainbuttoncolour
//
- this.pnlmainbuttoncolour.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
- | System.Windows.Forms.AnchorStyles.Right)));
- this.pnlmainbuttoncolour.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;
+ this.pnlmainbuttoncolour.Anchor = ((ShiftUI.AnchorStyles)(((ShiftUI.AnchorStyles.Top | ShiftUI.AnchorStyles.Bottom)
+ | ShiftUI.AnchorStyles.Right)));
+ this.pnlmainbuttoncolour.BorderStyle = ShiftUI.BorderStyle.FixedSingle;
this.pnlmainbuttoncolour.Location = new System.Drawing.Point(128, 3);
this.pnlmainbuttoncolour.MaximumSize = new System.Drawing.Size(41, 20);
this.pnlmainbuttoncolour.Name = "pnlmainbuttoncolour";
@@ -45,9 +45,9 @@
//
// lblabel
//
- this.lblabel.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
- | System.Windows.Forms.AnchorStyles.Left)
- | System.Windows.Forms.AnchorStyles.Right)));
+ this.lblabel.Anchor = ((ShiftUI.AnchorStyles)((((ShiftUI.AnchorStyles.Top | ShiftUI.AnchorStyles.Bottom)
+ | ShiftUI.AnchorStyles.Left)
+ | ShiftUI.AnchorStyles.Right)));
this.lblabel.Font = new System.Drawing.Font("Microsoft Sans Serif", 9.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.lblabel.Location = new System.Drawing.Point(3, 6);
this.lblabel.Name = "lblabel";
@@ -59,9 +59,9 @@
// ShifterColorInput
//
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
- this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
- this.Controls.Add(this.pnlmainbuttoncolour);
- this.Controls.Add(this.lblabel);
+ this.AutoScaleMode = ShiftUI.AutoScaleMode.Font;
+ this.Widgets.Add(this.pnlmainbuttoncolour);
+ this.Widgets.Add(this.lblabel);
this.Name = "ShifterColorInput";
this.Size = new System.Drawing.Size(173, 28);
this.ResumeLayout(false);
@@ -70,8 +70,8 @@
#endregion
- private System.Windows.Forms.Panel pnlmainbuttoncolour;
- private System.Windows.Forms.Label lblabel;
+ private ShiftUI.Panel pnlmainbuttoncolour;
+ private ShiftUI.Label lblabel;
}
}
diff --git a/source/WindowsFormsApplication1/Controls/ShifterColorInput.cs b/source/WindowsFormsApplication1/Controls/ShifterColorInput.cs
index 11bedf0..67d18f4 100644
--- a/source/WindowsFormsApplication1/Controls/ShifterColorInput.cs
+++ b/source/WindowsFormsApplication1/Controls/ShifterColorInput.cs
@@ -6,7 +6,7 @@ using System.Data;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
-using System.Windows.Forms;
+using ShiftUI;
namespace ShiftOS
{
diff --git a/source/WindowsFormsApplication1/Controls/ShifterColorInput.resx b/source/WindowsFormsApplication1/Controls/ShifterColorInput.resx
index 1af7de1..ffb4fb5 100644
--- a/source/WindowsFormsApplication1/Controls/ShifterColorInput.resx
+++ b/source/WindowsFormsApplication1/Controls/ShifterColorInput.resx
@@ -15,8 +15,8 @@
... ado.net/XML headers & schema ...
<resheader name="resmimetype">text/microsoft-resx</resheader>
<resheader name="version">2.0</resheader>
- <resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
- <resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
+ <resheader name="reader">System.Resources.ResXResourceReader, ShiftUI, ...</resheader>
+ <resheader name="writer">System.Resources.ResXResourceWriter, ShiftUI, ...</resheader>
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
@@ -112,9 +112,9 @@
<value>2.0</value>
</resheader>
<resheader name="reader">
- <value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
+ <value>System.Resources.ResXResourceReader, ShiftUI, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
- <value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
+ <value>System.Resources.ResXResourceWriter, ShiftUI, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
</root> \ No newline at end of file
diff --git a/source/WindowsFormsApplication1/Controls/ShifterGraphicInput.Designer.cs b/source/WindowsFormsApplication1/Controls/ShifterGraphicInput.Designer.cs
index b09416f..4b9f262 100644
--- a/source/WindowsFormsApplication1/Controls/ShifterGraphicInput.Designer.cs
+++ b/source/WindowsFormsApplication1/Controls/ShifterGraphicInput.Designer.cs
@@ -28,15 +28,15 @@
/// </summary>
private void InitializeComponent()
{
- this.pnlmainbuttoncolour = new System.Windows.Forms.Panel();
- this.lblabel = new System.Windows.Forms.Label();
+ this.pnlmainbuttoncolour = new ShiftUI.Panel();
+ this.lblabel = new ShiftUI.Label();
this.SuspendLayout();
//
// pnlmainbuttoncolour
//
- this.pnlmainbuttoncolour.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
- | System.Windows.Forms.AnchorStyles.Right)));
- this.pnlmainbuttoncolour.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;
+ this.pnlmainbuttoncolour.Anchor = ((ShiftUI.AnchorStyles)(((ShiftUI.AnchorStyles.Top | ShiftUI.AnchorStyles.Bottom)
+ | ShiftUI.AnchorStyles.Right)));
+ this.pnlmainbuttoncolour.BorderStyle = ShiftUI.BorderStyle.FixedSingle;
this.pnlmainbuttoncolour.Location = new System.Drawing.Point(129, 3);
this.pnlmainbuttoncolour.MaximumSize = new System.Drawing.Size(41, 20);
this.pnlmainbuttoncolour.Name = "pnlmainbuttoncolour";
@@ -45,9 +45,9 @@
//
// lblabel
//
- this.lblabel.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
- | System.Windows.Forms.AnchorStyles.Left)
- | System.Windows.Forms.AnchorStyles.Right)));
+ this.lblabel.Anchor = ((ShiftUI.AnchorStyles)((((ShiftUI.AnchorStyles.Top | ShiftUI.AnchorStyles.Bottom)
+ | ShiftUI.AnchorStyles.Left)
+ | ShiftUI.AnchorStyles.Right)));
this.lblabel.Font = new System.Drawing.Font("Microsoft Sans Serif", 9.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.lblabel.Location = new System.Drawing.Point(3, 6);
this.lblabel.Name = "lblabel";
@@ -59,9 +59,9 @@
// ShifterGraphicInput
//
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
- this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
- this.Controls.Add(this.pnlmainbuttoncolour);
- this.Controls.Add(this.lblabel);
+ this.AutoScaleMode = ShiftUI.AutoScaleMode.Font;
+ this.Widgets.Add(this.pnlmainbuttoncolour);
+ this.Widgets.Add(this.lblabel);
this.Name = "ShifterGraphicInput";
this.Size = new System.Drawing.Size(174, 27);
this.ResumeLayout(false);
@@ -70,7 +70,7 @@
#endregion
- private System.Windows.Forms.Panel pnlmainbuttoncolour;
- private System.Windows.Forms.Label lblabel;
+ private ShiftUI.Panel pnlmainbuttoncolour;
+ private ShiftUI.Label lblabel;
}
}
diff --git a/source/WindowsFormsApplication1/Controls/ShifterGraphicInput.cs b/source/WindowsFormsApplication1/Controls/ShifterGraphicInput.cs
index 8e15e07..d0c9310 100644
--- a/source/WindowsFormsApplication1/Controls/ShifterGraphicInput.cs
+++ b/source/WindowsFormsApplication1/Controls/ShifterGraphicInput.cs
@@ -6,7 +6,7 @@ using System.Data;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
-using System.Windows.Forms;
+using ShiftUI;
namespace ShiftOS
{
diff --git a/source/WindowsFormsApplication1/Controls/ShifterGraphicInput.resx b/source/WindowsFormsApplication1/Controls/ShifterGraphicInput.resx
index 1af7de1..ffb4fb5 100644
--- a/source/WindowsFormsApplication1/Controls/ShifterGraphicInput.resx
+++ b/source/WindowsFormsApplication1/Controls/ShifterGraphicInput.resx
@@ -15,8 +15,8 @@
... ado.net/XML headers & schema ...
<resheader name="resmimetype">text/microsoft-resx</resheader>
<resheader name="version">2.0</resheader>
- <resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
- <resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
+ <resheader name="reader">System.Resources.ResXResourceReader, ShiftUI, ...</resheader>
+ <resheader name="writer">System.Resources.ResXResourceWriter, ShiftUI, ...</resheader>
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
@@ -112,9 +112,9 @@
<value>2.0</value>
</resheader>
<resheader name="reader">
- <value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
+ <value>System.Resources.ResXResourceReader, ShiftUI, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
- <value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
+ <value>System.Resources.ResXResourceWriter, ShiftUI, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
</root> \ No newline at end of file
diff --git a/source/WindowsFormsApplication1/Controls/ShifterIntInput.Designer.cs b/source/WindowsFormsApplication1/Controls/ShifterIntInput.Designer.cs
index 130db0c..365786c 100644
--- a/source/WindowsFormsApplication1/Controls/ShifterIntInput.Designer.cs
+++ b/source/WindowsFormsApplication1/Controls/ShifterIntInput.Designer.cs
@@ -28,16 +28,16 @@
/// </summary>
private void InitializeComponent()
{
- this.txttext = new System.Windows.Forms.TextBox();
- this.Label51 = new System.Windows.Forms.Label();
+ this.txttext = new ShiftUI.TextBox();
+ this.Label51 = new ShiftUI.Label();
this.SuspendLayout();
//
// txttext
//
- this.txttext.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
- | System.Windows.Forms.AnchorStyles.Right)));
+ this.txttext.Anchor = ((ShiftUI.AnchorStyles)(((ShiftUI.AnchorStyles.Top | ShiftUI.AnchorStyles.Bottom)
+ | ShiftUI.AnchorStyles.Right)));
this.txttext.BackColor = System.Drawing.Color.White;
- this.txttext.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;
+ this.txttext.BorderStyle = ShiftUI.BorderStyle.FixedSingle;
this.txttext.Font = new System.Drawing.Font("Microsoft Sans Serif", 9.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.txttext.ForeColor = System.Drawing.Color.Black;
this.txttext.Location = new System.Drawing.Point(174, 3);
@@ -49,9 +49,9 @@
//
// Label51
//
- this.Label51.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
- | System.Windows.Forms.AnchorStyles.Left)
- | System.Windows.Forms.AnchorStyles.Right)));
+ this.Label51.Anchor = ((ShiftUI.AnchorStyles)((((ShiftUI.AnchorStyles.Top | ShiftUI.AnchorStyles.Bottom)
+ | ShiftUI.AnchorStyles.Left)
+ | ShiftUI.AnchorStyles.Right)));
this.Label51.Font = new System.Drawing.Font("Microsoft Sans Serif", 9.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.Label51.Location = new System.Drawing.Point(0, 0);
this.Label51.Name = "Label51";
@@ -63,10 +63,10 @@
// ShifterIntInput
//
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
- this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
- this.AutoSizeMode = System.Windows.Forms.AutoSizeMode.GrowAndShrink;
- this.Controls.Add(this.txttext);
- this.Controls.Add(this.Label51);
+ this.AutoScaleMode = ShiftUI.AutoScaleMode.Font;
+ this.AutoSizeMode = ShiftUI.AutoSizeMode.GrowAndShrink;
+ this.Widgets.Add(this.txttext);
+ this.Widgets.Add(this.Label51);
this.Name = "ShifterIntInput";
this.Size = new System.Drawing.Size(213, 29);
this.ResumeLayout(false);
@@ -76,8 +76,8 @@
#endregion
- private System.Windows.Forms.TextBox txttext;
- private System.Windows.Forms.Label Label51;
+ private ShiftUI.TextBox txttext;
+ private ShiftUI.Label Label51;
}
}
diff --git a/source/WindowsFormsApplication1/Controls/ShifterIntInput.cs b/source/WindowsFormsApplication1/Controls/ShifterIntInput.cs
index 782d265..7c438a5 100644
--- a/source/WindowsFormsApplication1/Controls/ShifterIntInput.cs
+++ b/source/WindowsFormsApplication1/Controls/ShifterIntInput.cs
@@ -6,7 +6,7 @@ using System.Data;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
-using System.Windows.Forms;
+using ShiftUI;
namespace ShiftOS
{
diff --git a/source/WindowsFormsApplication1/Controls/ShifterIntInput.resx b/source/WindowsFormsApplication1/Controls/ShifterIntInput.resx
index 1af7de1..ffb4fb5 100644
--- a/source/WindowsFormsApplication1/Controls/ShifterIntInput.resx
+++ b/source/WindowsFormsApplication1/Controls/ShifterIntInput.resx
@@ -15,8 +15,8 @@
... ado.net/XML headers & schema ...
<resheader name="resmimetype">text/microsoft-resx</resheader>
<resheader name="version">2.0</resheader>
- <resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
- <resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
+ <resheader name="reader">System.Resources.ResXResourceReader, ShiftUI, ...</resheader>
+ <resheader name="writer">System.Resources.ResXResourceWriter, ShiftUI, ...</resheader>
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
@@ -112,9 +112,9 @@
<value>2.0</value>
</resheader>
<resheader name="reader">
- <value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
+ <value>System.Resources.ResXResourceReader, ShiftUI, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
- <value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
+ <value>System.Resources.ResXResourceWriter, ShiftUI, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
</root> \ No newline at end of file
diff --git a/source/WindowsFormsApplication1/Controls/ShifterTextInput.Designer.cs b/source/WindowsFormsApplication1/Controls/ShifterTextInput.Designer.cs
index 9da62c6..db028b1 100644
--- a/source/WindowsFormsApplication1/Controls/ShifterTextInput.Designer.cs
+++ b/source/WindowsFormsApplication1/Controls/ShifterTextInput.Designer.cs
@@ -28,15 +28,15 @@
/// </summary>
private void InitializeComponent()
{
- this.txttext = new System.Windows.Forms.TextBox();
- this.Label51 = new System.Windows.Forms.Label();
+ this.txttext = new ShiftUI.TextBox();
+ this.Label51 = new ShiftUI.Label();
this.SuspendLayout();
//
// txttext
//
- this.txttext.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
+ this.txttext.Anchor = ((ShiftUI.AnchorStyles)((ShiftUI.AnchorStyles.Top | ShiftUI.AnchorStyles.Right)));
this.txttext.BackColor = System.Drawing.Color.White;
- this.txttext.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;
+ this.txttext.BorderStyle = ShiftUI.BorderStyle.FixedSingle;
this.txttext.Font = new System.Drawing.Font("Microsoft Sans Serif", 9.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.txttext.ForeColor = System.Drawing.Color.Black;
this.txttext.Location = new System.Drawing.Point(106, 7);
@@ -47,7 +47,7 @@
//
// Label51
//
- this.Label51.Dock = System.Windows.Forms.DockStyle.Left;
+ this.Label51.Dock = ShiftUI.DockStyle.Left;
this.Label51.Font = new System.Drawing.Font("Microsoft Sans Serif", 9.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.Label51.Location = new System.Drawing.Point(0, 0);
this.Label51.Name = "Label51";
@@ -59,10 +59,10 @@
// ShifterTextInput
//
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
- this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
- this.AutoSizeMode = System.Windows.Forms.AutoSizeMode.GrowAndShrink;
- this.Controls.Add(this.txttext);
- this.Controls.Add(this.Label51);
+ this.AutoScaleMode = ShiftUI.AutoScaleMode.Font;
+ this.AutoSizeMode = ShiftUI.AutoSizeMode.GrowAndShrink;
+ this.Widgets.Add(this.txttext);
+ this.Widgets.Add(this.Label51);
this.Name = "ShifterTextInput";
this.Size = new System.Drawing.Size(222, 29);
this.ResumeLayout(false);
@@ -72,7 +72,7 @@
#endregion
- private System.Windows.Forms.TextBox txttext;
- private System.Windows.Forms.Label Label51;
+ private ShiftUI.TextBox txttext;
+ private ShiftUI.Label Label51;
}
}
diff --git a/source/WindowsFormsApplication1/Controls/ShifterTextInput.cs b/source/WindowsFormsApplication1/Controls/ShifterTextInput.cs
index 6e59649..24dbf8d 100644
--- a/source/WindowsFormsApplication1/Controls/ShifterTextInput.cs
+++ b/source/WindowsFormsApplication1/Controls/ShifterTextInput.cs
@@ -6,7 +6,7 @@ using System.Data;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
-using System.Windows.Forms;
+using ShiftUI;
namespace ShiftOS
{
@@ -50,7 +50,7 @@ namespace ShiftOS
}
- public class IShifterSetting : UserControl
+ public class IShifterSetting : UserWidget
{
public virtual string Text { get; set; }
public virtual object Value { get; set; }
diff --git a/source/WindowsFormsApplication1/Controls/ShifterTextInput.resx b/source/WindowsFormsApplication1/Controls/ShifterTextInput.resx
index 1af7de1..ffb4fb5 100644
--- a/source/WindowsFormsApplication1/Controls/ShifterTextInput.resx
+++ b/source/WindowsFormsApplication1/Controls/ShifterTextInput.resx
@@ -15,8 +15,8 @@
... ado.net/XML headers & schema ...
<resheader name="resmimetype">text/microsoft-resx</resheader>
<resheader name="version">2.0</resheader>
- <resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
- <resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
+ <resheader name="reader">System.Resources.ResXResourceReader, ShiftUI, ...</resheader>
+ <resheader name="writer">System.Resources.ResXResourceWriter, ShiftUI, ...</resheader>
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
@@ -112,9 +112,9 @@
<value>2.0</value>
</resheader>
<resheader name="reader">
- <value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
+ <value>System.Resources.ResXResourceReader, ShiftUI, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
- <value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
+ <value>System.Resources.ResXResourceWriter, ShiftUI, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
</root> \ No newline at end of file
diff --git a/source/WindowsFormsApplication1/Controls/SyntaxHighlighter.cs b/source/WindowsFormsApplication1/Controls/SyntaxHighlighter.cs
index 1139096..8a5e123 100644
--- a/source/WindowsFormsApplication1/Controls/SyntaxHighlighter.cs
+++ b/source/WindowsFormsApplication1/Controls/SyntaxHighlighter.cs
@@ -4,14 +4,14 @@ using System;
using System.Collections.Generic;
using System.Text;
using System.IO;
-using System.Windows.Forms;
+using ShiftUI;
using System.ComponentModel;
using System.Text.RegularExpressions;
using System.Drawing;
namespace ShiftOS
{
- public class SyntaxRichTextBox : System.Windows.Forms.RichTextBox
+ public class SyntaxRichTextBox : ShiftUI.RichTextBox
{
private SyntaxSettings m_settings = new SyntaxSettings();
private static bool m_bPaint = true;
@@ -35,7 +35,7 @@ namespace ShiftOS
/// WndProc
/// </summary>
/// <param name="m"></param>
- protected override void WndProc(ref System.Windows.Forms.Message m)
+ protected override void WndProc(ref ShiftUI.Message m)
{
if (m.Msg == 0x00f)
{
@@ -51,7 +51,7 @@ namespace ShiftOS
public void SetLanguage(SyntaxSettings.Language lang)
{
Color white = Color.Black;
- Color keyword = Color.Red;
+ Color keyword = Color.Orange;
Color integer = Color.LightGreen;
Color comment = Color.DarkGray;
Color str = Color.Orange;
@@ -76,7 +76,7 @@ namespace ShiftOS
switch (lang)
{
case SyntaxSettings.Language.Lua:
- var kw = new List<string>() { "function", "local", "return", "if", "else", "elseif", "while", "true", "do", "next", "end", "for", "pairs", "in", "{", "}", "false", "=", "+", "-", "/", "*", "..", "," };
+ var kw = new List<string>() { "function", "then", "local", "return", "if", "else", "elseif", "while", "true", "do", "next", "end", "for", "pairs", "in", "{", "}", "false", "=", "+", "-", "/", "*", "..", "," };
Settings.Keywords.Clear();
foreach (var k in kw)
{
diff --git a/source/WindowsFormsApplication1/Controls/WinFormsHost.cs b/source/WindowsFormsApplication1/Controls/WinFormsHost.cs
new file mode 100644
index 0000000..e2be505
--- /dev/null
+++ b/source/WindowsFormsApplication1/Controls/WinFormsHost.cs
@@ -0,0 +1,86 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+using System.Threading.Tasks;
+using ShiftUI;
+using System.Reflection;
+using System.Drawing;
+
+namespace ShiftOS.Controls
+{
+ class WinFormsHost : Widget
+ {
+ private System.Windows.Forms.Control guest = null;
+
+ /// <summary>
+ /// Creates a new Windows Forms host that will host the given control.
+ /// </summary>
+ /// <param name="ctrl">The control to use.</param>
+ public WinFormsHost(System.Windows.Forms.Control ctrl)
+ {
+ guest = ctrl;
+ ScanProperties();
+ }
+
+ /// <summary>
+ /// Scan the guest for any properties that this widget contains, and set our properties to the ShiftUI equivalent.
+ /// </summary>
+ private void ScanProperties()
+ {
+ var guest_properties = guest.GetType().GetProperties(BindingFlags.Public | BindingFlags.Instance);
+ var host_properties = this.GetType().GetProperties(BindingFlags.Public | BindingFlags.Instance);
+
+ var valid_types = new Type[] { typeof(string), typeof(int), typeof(Size), typeof(Point), typeof(Font), typeof(Color), typeof(bool) };
+
+ var guest_names = new Dictionary<string, PropertyInfo>();
+ var host_names = new Dictionary<string, PropertyInfo>();
+
+ foreach(var property in guest_properties)
+ {
+ if (!property.CanWrite || !property.CanRead)
+ continue; //We want to be able to read and write from and to the property...
+
+ if (!valid_types.Contains(property.PropertyType) || !property.PropertyType.IsEnum)
+ continue; //Need to be valid propertytype...
+
+ guest_names.Add(property.Name, property); //Add to the guest dictionary for easy access.
+ }
+
+ //Now let's do the same for our host.
+ foreach (var property in host_properties)
+ {
+ if (!property.CanWrite || !property.CanRead)
+ continue; //We want to be able to read and write from and to the property...
+
+ if (!valid_types.Contains(property.PropertyType) || !property.PropertyType.IsEnum)
+ continue; //Need to be valid propertytype...
+
+ host_names.Add(property.Name, property); //Add to the guest dictionary for easy access.
+ }
+
+ //Cool. Properties scanned. Let's set our properties to the guest's!
+ foreach(var property in host_names)
+ {
+ if(guest_names.ContainsKey(property.Key))
+ {
+ var p = guest_names[property.Key];
+ if(p.PropertyType.IsEnum)
+ {
+ //If it's an enum, convert it to an integer value
+ //so that Reflection won't yell at us.
+
+ var value = p.GetValue(guest); //Get the guest's value of this property
+ int value_int = (int)value;
+ property.Value.SetValue(this, value_int);
+ }
+ else
+ {
+ var value = p.GetValue(guest);
+ property.Value.SetValue(this, value);
+ }
+ }
+ }
+ }
+ }
+}
diff --git a/source/WindowsFormsApplication1/Controls/WindowBorder.Designer.cs b/source/WindowsFormsApplication1/Controls/WindowBorder.Designer.cs
index 6e0970e..373210a 100644
--- a/source/WindowsFormsApplication1/Controls/WindowBorder.Designer.cs
+++ b/source/WindowsFormsApplication1/Controls/WindowBorder.Designer.cs
@@ -25,23 +25,23 @@ namespace ShiftOS
private void InitializeComponent()
{
this.components = new System.ComponentModel.Container();
- this.pgleft = new System.Windows.Forms.Panel();
- this.pgbottomlcorner = new System.Windows.Forms.Panel();
- this.pgright = new System.Windows.Forms.Panel();
- this.pgbottomrcorner = new System.Windows.Forms.Panel();
- this.titlebar = new System.Windows.Forms.Panel();
- this.minimizebutton = new System.Windows.Forms.Panel();
- this.pnlicon = new System.Windows.Forms.PictureBox();
- this.rollupbutton = new System.Windows.Forms.Panel();
- this.closebutton = new System.Windows.Forms.Panel();
- this.lbtitletext = new System.Windows.Forms.Label();
- this.pgtoplcorner = new System.Windows.Forms.Panel();
- this.pgtoprcorner = new System.Windows.Forms.Panel();
- this.pgbottom = new System.Windows.Forms.Panel();
- this.pgcontents = new System.Windows.Forms.Panel();
- this.pullbs = new System.Windows.Forms.Timer(this.components);
- this.pullbottom = new System.Windows.Forms.Timer(this.components);
- this.pullside = new System.Windows.Forms.Timer(this.components);
+ this.pgleft = new ShiftUI.Panel();
+ this.pgbottomlcorner = new ShiftUI.Panel();
+ this.pgright = new ShiftUI.Panel();
+ this.pgbottomrcorner = new ShiftUI.Panel();
+ this.titlebar = new ShiftUI.Panel();
+ this.minimizebutton = new ShiftUI.Panel();
+ this.pnlicon = new ShiftUI.PictureBox();
+ this.rollupbutton = new ShiftUI.Panel();
+ this.closebutton = new ShiftUI.Panel();
+ this.lbtitletext = new ShiftUI.Label();
+ this.pgtoplcorner = new ShiftUI.Panel();
+ this.pgtoprcorner = new ShiftUI.Panel();
+ this.pgbottom = new ShiftUI.Panel();
+ this.pgcontents = new ShiftUI.Panel();
+ this.pullbs = new ShiftUI.Timer(this.components);
+ this.pullbottom = new ShiftUI.Timer(this.components);
+ this.pullside = new ShiftUI.Timer(this.components);
this.pgleft.SuspendLayout();
this.pgright.SuspendLayout();
this.titlebar.SuspendLayout();
@@ -51,76 +51,76 @@ namespace ShiftOS
// pgleft
//
this.pgleft.BackColor = System.Drawing.Color.Gray;
- this.pgleft.Controls.Add(this.pgbottomlcorner);
- this.pgleft.Dock = System.Windows.Forms.DockStyle.Left;
+ this.pgleft.Widgets.Add(this.pgbottomlcorner);
+ this.pgleft.Dock = ShiftUI.DockStyle.Left;
this.pgleft.Location = new System.Drawing.Point(0, 30);
this.pgleft.Name = "pgleft";
this.pgleft.Size = new System.Drawing.Size(2, 345);
this.pgleft.TabIndex = 16;
- this.pgleft.MouseDown += new System.Windows.Forms.MouseEventHandler(this.Rightpull_MouseDown);
+ this.pgleft.MouseDown += new ShiftUI.MouseEventHandler(this.Rightpull_MouseDown);
this.pgleft.MouseEnter += new System.EventHandler(this.RightCursorOn_MouseDown);
this.pgleft.MouseLeave += new System.EventHandler(this.SizeCursoroff_MouseDown);
- this.pgleft.MouseUp += new System.Windows.Forms.MouseEventHandler(this.rightpull_MouseUp);
+ this.pgleft.MouseUp += new ShiftUI.MouseEventHandler(this.rightpull_MouseUp);
//
// pgbottomlcorner
//
this.pgbottomlcorner.BackColor = System.Drawing.Color.Red;
- this.pgbottomlcorner.Dock = System.Windows.Forms.DockStyle.Bottom;
+ this.pgbottomlcorner.Dock = ShiftUI.DockStyle.Bottom;
this.pgbottomlcorner.Location = new System.Drawing.Point(0, 343);
this.pgbottomlcorner.Name = "pgbottomlcorner";
this.pgbottomlcorner.Size = new System.Drawing.Size(2, 2);
this.pgbottomlcorner.TabIndex = 14;
- this.pgbottomlcorner.MouseDown += new System.Windows.Forms.MouseEventHandler(this.bspull_MouseDown);
+ this.pgbottomlcorner.MouseDown += new ShiftUI.MouseEventHandler(this.bspull_MouseDown);
this.pgbottomlcorner.MouseEnter += new System.EventHandler(this.CornerCursorOn_MouseDown);
this.pgbottomlcorner.MouseLeave += new System.EventHandler(this.SizeCursoroff_MouseDown);
- this.pgbottomlcorner.MouseUp += new System.Windows.Forms.MouseEventHandler(this.bspull_MouseUp);
+ this.pgbottomlcorner.MouseUp += new ShiftUI.MouseEventHandler(this.bspull_MouseUp);
//
// pgright
//
this.pgright.BackColor = System.Drawing.Color.Gray;
- this.pgright.Controls.Add(this.pgbottomrcorner);
- this.pgright.Dock = System.Windows.Forms.DockStyle.Right;
+ this.pgright.Widgets.Add(this.pgbottomrcorner);
+ this.pgright.Dock = ShiftUI.DockStyle.Right;
this.pgright.Location = new System.Drawing.Point(545, 30);
this.pgright.Name = "pgright";
this.pgright.Size = new System.Drawing.Size(2, 345);
this.pgright.TabIndex = 17;
- this.pgright.MouseDown += new System.Windows.Forms.MouseEventHandler(this.Rightpull_MouseDown);
+ this.pgright.MouseDown += new ShiftUI.MouseEventHandler(this.Rightpull_MouseDown);
this.pgright.MouseEnter += new System.EventHandler(this.RightCursorOn_MouseDown);
this.pgright.MouseLeave += new System.EventHandler(this.SizeCursoroff_MouseDown);
- this.pgright.MouseUp += new System.Windows.Forms.MouseEventHandler(this.rightpull_MouseUp);
+ this.pgright.MouseUp += new ShiftUI.MouseEventHandler(this.rightpull_MouseUp);
//
// pgbottomrcorner
//
this.pgbottomrcorner.BackColor = System.Drawing.Color.Red;
- this.pgbottomrcorner.Dock = System.Windows.Forms.DockStyle.Bottom;
- this.pgbottomrcorner.Location = new System.Drawing.Point(0, 343);
+ this.pgbottomrcorner.Dock = ShiftUI.DockStyle.Bottom;
+ this.pgbottomrcorner.Location = new System.Drawing.Point(363, 343);
this.pgbottomrcorner.Name = "pgbottomrcorner";
this.pgbottomrcorner.Size = new System.Drawing.Size(2, 2);
this.pgbottomrcorner.TabIndex = 15;
- this.pgbottomrcorner.MouseDown += new System.Windows.Forms.MouseEventHandler(this.bspull_MouseDown);
+ this.pgbottomrcorner.MouseDown += new ShiftUI.MouseEventHandler(this.bspull_MouseDown);
this.pgbottomrcorner.MouseEnter += new System.EventHandler(this.CornerCursorOn_MouseDown);
this.pgbottomrcorner.MouseLeave += new System.EventHandler(this.SizeCursoroff_MouseDown);
- this.pgbottomrcorner.MouseUp += new System.Windows.Forms.MouseEventHandler(this.bspull_MouseUp);
+ this.pgbottomrcorner.MouseUp += new ShiftUI.MouseEventHandler(this.bspull_MouseUp);
//
// titlebar
//
this.titlebar.BackColor = System.Drawing.Color.Gray;
- this.titlebar.Controls.Add(this.minimizebutton);
- this.titlebar.Controls.Add(this.pnlicon);
- this.titlebar.Controls.Add(this.rollupbutton);
- this.titlebar.Controls.Add(this.closebutton);
- this.titlebar.Controls.Add(this.lbtitletext);
- this.titlebar.Controls.Add(this.pgtoplcorner);
- this.titlebar.Controls.Add(this.pgtoprcorner);
- this.titlebar.Dock = System.Windows.Forms.DockStyle.Top;
+ this.titlebar.Widgets.Add(this.minimizebutton);
+ this.titlebar.Widgets.Add(this.pnlicon);
+ this.titlebar.Widgets.Add(this.rollupbutton);
+ this.titlebar.Widgets.Add(this.closebutton);
+ this.titlebar.Widgets.Add(this.lbtitletext);
+ this.titlebar.Widgets.Add(this.pgtoplcorner);
+ this.titlebar.Widgets.Add(this.pgtoprcorner);
+ this.titlebar.Dock = ShiftUI.DockStyle.Top;
this.titlebar.ForeColor = System.Drawing.Color.White;
this.titlebar.Location = new System.Drawing.Point(0, 0);
this.titlebar.Name = "titlebar";
this.titlebar.Size = new System.Drawing.Size(547, 30);
this.titlebar.TabIndex = 14;
- this.titlebar.MouseDown += new System.Windows.Forms.MouseEventHandler(this.titlebar_MouseDown);
- this.titlebar.MouseMove += new System.Windows.Forms.MouseEventHandler(this.titlebar_MouseMove);
- this.titlebar.MouseUp += new System.Windows.Forms.MouseEventHandler(this.titlebar_MouseUp);
+ this.titlebar.MouseDown += new ShiftUI.MouseEventHandler(this.titlebar_MouseDown);
+ this.titlebar.MouseMove += new ShiftUI.MouseEventHandler(this.titlebar_MouseMove);
+ this.titlebar.MouseUp += new ShiftUI.MouseEventHandler(this.titlebar_MouseUp);
//
// minimizebutton
//
@@ -137,7 +137,7 @@ namespace ShiftOS
this.pnlicon.Location = new System.Drawing.Point(8, 8);
this.pnlicon.Name = "pnlicon";
this.pnlicon.Size = new System.Drawing.Size(16, 16);
- this.pnlicon.SizeMode = System.Windows.Forms.PictureBoxSizeMode.StretchImage;
+ this.pnlicon.SizeMode = ShiftUI.PictureBoxSizeMode.StretchImage;
this.pnlicon.TabIndex = 24;
this.pnlicon.TabStop = false;
this.pnlicon.Visible = false;
@@ -170,14 +170,14 @@ namespace ShiftOS
this.lbtitletext.Size = new System.Drawing.Size(77, 18);
this.lbtitletext.TabIndex = 19;
this.lbtitletext.Text = "Template";
- this.lbtitletext.MouseDown += new System.Windows.Forms.MouseEventHandler(this.titlebar_MouseDown);
- this.lbtitletext.MouseMove += new System.Windows.Forms.MouseEventHandler(this.titlebar_MouseMove);
- this.lbtitletext.MouseUp += new System.Windows.Forms.MouseEventHandler(this.titlebar_MouseUp);
+ this.lbtitletext.MouseDown += new ShiftUI.MouseEventHandler(this.titlebar_MouseDown);
+ this.lbtitletext.MouseMove += new ShiftUI.MouseEventHandler(this.titlebar_MouseMove);
+ this.lbtitletext.MouseUp += new ShiftUI.MouseEventHandler(this.titlebar_MouseUp);
//
// pgtoplcorner
//
this.pgtoplcorner.BackColor = System.Drawing.Color.Red;
- this.pgtoplcorner.Dock = System.Windows.Forms.DockStyle.Left;
+ this.pgtoplcorner.Dock = ShiftUI.DockStyle.Left;
this.pgtoplcorner.Location = new System.Drawing.Point(0, 0);
this.pgtoplcorner.Name = "pgtoplcorner";
this.pgtoplcorner.Size = new System.Drawing.Size(2, 30);
@@ -186,7 +186,7 @@ namespace ShiftOS
// pgtoprcorner
//
this.pgtoprcorner.BackColor = System.Drawing.Color.Red;
- this.pgtoprcorner.Dock = System.Windows.Forms.DockStyle.Right;
+ this.pgtoprcorner.Dock = ShiftUI.DockStyle.Right;
this.pgtoprcorner.Location = new System.Drawing.Point(545, 0);
this.pgtoprcorner.Name = "pgtoprcorner";
this.pgtoprcorner.Size = new System.Drawing.Size(2, 30);
@@ -195,19 +195,19 @@ namespace ShiftOS
// pgbottom
//
this.pgbottom.BackColor = System.Drawing.Color.Gray;
- this.pgbottom.Dock = System.Windows.Forms.DockStyle.Bottom;
+ this.pgbottom.Dock = ShiftUI.DockStyle.Bottom;
this.pgbottom.Location = new System.Drawing.Point(2, 373);
this.pgbottom.Name = "pgbottom";
this.pgbottom.Size = new System.Drawing.Size(543, 2);
this.pgbottom.TabIndex = 18;
- this.pgbottom.MouseDown += new System.Windows.Forms.MouseEventHandler(this.bottompull_MouseDown);
+ this.pgbottom.MouseDown += new ShiftUI.MouseEventHandler(this.bottompull_MouseDown);
this.pgbottom.MouseEnter += new System.EventHandler(this.bottomCursorOn_MouseDown);
this.pgbottom.MouseLeave += new System.EventHandler(this.SizeCursoroff_MouseDown);
- this.pgbottom.MouseUp += new System.Windows.Forms.MouseEventHandler(this.bottompull_MouseUp);
+ this.pgbottom.MouseUp += new ShiftUI.MouseEventHandler(this.bottompull_MouseUp);
//
// pgcontents
//
- this.pgcontents.Dock = System.Windows.Forms.DockStyle.Fill;
+ this.pgcontents.Dock = ShiftUI.DockStyle.Fill;
this.pgcontents.Location = new System.Drawing.Point(2, 30);
this.pgcontents.Name = "pgcontents";
this.pgcontents.Size = new System.Drawing.Size(543, 343);
@@ -231,12 +231,12 @@ namespace ShiftOS
// WindowBorder
//
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
- this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
- this.Controls.Add(this.pgcontents);
- this.Controls.Add(this.pgbottom);
- this.Controls.Add(this.pgright);
- this.Controls.Add(this.pgleft);
- this.Controls.Add(this.titlebar);
+ this.AutoScaleMode = ShiftUI.AutoScaleMode.Font;
+ this.Widgets.Add(this.pgcontents);
+ this.Widgets.Add(this.pgbottom);
+ this.Widgets.Add(this.pgright);
+ this.Widgets.Add(this.pgleft);
+ this.Widgets.Add(this.titlebar);
this.Name = "WindowBorder";
this.Size = new System.Drawing.Size(547, 375);
this.Load += new System.EventHandler(this.Template_Load);
@@ -248,23 +248,23 @@ namespace ShiftOS
this.ResumeLayout(false);
}
- internal System.Windows.Forms.Panel pgleft;
- internal System.Windows.Forms.Panel pgbottomlcorner;
- internal System.Windows.Forms.Panel pgright;
- internal System.Windows.Forms.Panel pgbottomrcorner;
- internal System.Windows.Forms.Panel titlebar;
- internal System.Windows.Forms.Panel pgtoplcorner;
- internal System.Windows.Forms.Panel pgtoprcorner;
- internal System.Windows.Forms.Panel pgbottom;
- internal System.Windows.Forms.Panel pgcontents;
- internal System.Windows.Forms.Label lbtitletext;
- internal System.Windows.Forms.Panel closebutton;
- internal System.Windows.Forms.Panel rollupbutton;
- internal System.Windows.Forms.PictureBox pnlicon;
- internal System.Windows.Forms.Panel minimizebutton;
- internal System.Windows.Forms.Timer pullbs;
- internal System.Windows.Forms.Timer pullbottom;
- internal System.Windows.Forms.Timer pullside;
+ internal ShiftUI.Panel pgleft;
+ internal ShiftUI.Panel pgbottomlcorner;
+ internal ShiftUI.Panel pgright;
+ internal ShiftUI.Panel pgbottomrcorner;
+ internal ShiftUI.Panel titlebar;
+ internal ShiftUI.Panel pgtoplcorner;
+ internal ShiftUI.Panel pgtoprcorner;
+ internal ShiftUI.Panel pgbottom;
+ internal ShiftUI.Panel pgcontents;
+ internal ShiftUI.Label lbtitletext;
+ internal ShiftUI.Panel closebutton;
+ internal ShiftUI.Panel rollupbutton;
+ internal ShiftUI.PictureBox pnlicon;
+ internal ShiftUI.Panel minimizebutton;
+ internal ShiftUI.Timer pullbs;
+ internal ShiftUI.Timer pullbottom;
+ internal ShiftUI.Timer pullside;
}
}
diff --git a/source/WindowsFormsApplication1/Controls/WindowBorder.cs b/source/WindowsFormsApplication1/Controls/WindowBorder.cs
index 50f245d..288aff7 100644
--- a/source/WindowsFormsApplication1/Controls/WindowBorder.cs
+++ b/source/WindowsFormsApplication1/Controls/WindowBorder.cs
@@ -6,11 +6,11 @@ using System.Data;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
-using System.Windows.Forms;
+using ShiftUI;
namespace ShiftOS
{
- public partial class WindowBorder : UserControl
+ public partial class WindowBorder : UserWidget
{
public Timer updater = new Timer();
@@ -18,20 +18,20 @@ namespace ShiftOS
//Lua Methods
- public void RegisterWidget(string ident, Control ctrl)
+ public void RegisterWidget(string ident, Widget ctrl)
{
- _widgets.Add(new BorderWidget { Identifier = ident, Control = ctrl });
+ _widgets.Add(new BorderWidget { Identifier = ident, Widget = ctrl });
resettitlebar();
}
- public Control GetWidget(string ident)
+ public Widget GetWidget(string ident)
{
- Control ctrl = null;
+ Widget ctrl = null;
foreach(var widget in _widgets)
{
if(widget.Identifier == ident)
{
- ctrl = widget.Control;
+ ctrl = widget.Widget;
}
}
if (ctrl == null)
@@ -51,11 +51,11 @@ namespace ShiftOS
}
if (ctrl == null)
throw new Exception($"The identifier {ident} was not found.");
- var wControl = ctrl.Control;
- wControl.Parent.Controls.Remove(wControl);
- wControl.Hide();
+ var wWidget = ctrl.Widget;
+ wWidget.Parent.Widgets.Remove(wWidget);
+ wWidget.Hide();
_widgets.Remove(ctrl);
- wControl.Dispose();
+ wWidget.Dispose();
}
@@ -112,7 +112,7 @@ namespace ShiftOS
case "left":
return pgbottomlcorner;
case "right":
- return pgbottomlcorner;
+ return pgbottomrcorner;
default:
return null;
}
@@ -223,6 +223,7 @@ namespace ShiftOS
ParentForm.Tag = ParentForm.Location;
WindowComposition.WindowsEverywhere(this.ParentForm);
ParentForm.Text = this.AppName;
+ API.CurrentSession.InvokeWindowOp("brdr_redraw", this.ParentForm);
}
private PanelButton pbtn = null;
@@ -251,6 +252,7 @@ namespace ShiftOS
}
//ShiftOSDesktop.log = //ShiftOSDesktop.log + My.Computer.Clock.LocalTime + " User dragged " + this.Name + " to " + this.Location.ToString + Environment.NewLine;
}
+
}
private bool Resizing = false;
@@ -289,6 +291,7 @@ namespace ShiftOS
ParentForm.Top += top;
ParentForm.Tag = ParentForm.Location;
}
+ resettitlebar();
}
if(Viruses.InfectedWith("windowspazzer"))
{
@@ -596,7 +599,7 @@ namespace ShiftOS
//delete this for non-resizable windows
// ERROR: Handles clauses are not supported in C#
- private void Rightpull_MouseDown(object sender, System.Windows.Forms.MouseEventArgs e)
+ private void Rightpull_MouseDown(object sender, ShiftUI.MouseEventArgs e)
{
if (API.Upgrades["resizablewindows"] == true)
{
@@ -641,7 +644,7 @@ namespace ShiftOS
}
// ERROR: Handles clauses are not supported in C#
- private void rightpull_MouseUp(object sender, System.Windows.Forms.MouseEventArgs e)
+ private void rightpull_MouseUp(object sender, ShiftUI.MouseEventArgs e)
{
if (API.Upgrades["resizablewindows"] == true)
{
@@ -650,7 +653,7 @@ namespace ShiftOS
}
// ERROR: Handles clauses are not supported in C#
- private void bottompull_MouseDown(object sender, System.Windows.Forms.MouseEventArgs e)
+ private void bottompull_MouseDown(object sender, ShiftUI.MouseEventArgs e)
{
if (API.Upgrades["resizablewindows"] == true)
{
@@ -659,7 +662,7 @@ namespace ShiftOS
}
// ERROR: Handles clauses are not supported in C#
- private void bottompull_MouseUp(object sender, System.Windows.Forms.MouseEventArgs e)
+ private void bottompull_MouseUp(object sender, ShiftUI.MouseEventArgs e)
{
if (API.Upgrades["resizablewindows"] == true)
{
@@ -668,7 +671,7 @@ namespace ShiftOS
}
// ERROR: Handles clauses are not supported in C#
- private void bspull_MouseDown(object sender, System.Windows.Forms.MouseEventArgs e)
+ private void bspull_MouseDown(object sender, ShiftUI.MouseEventArgs e)
{
if (API.Upgrades["resizablewindows"] == true)
{
@@ -677,7 +680,7 @@ namespace ShiftOS
}
// ERROR: Handles clauses are not supported in C#
- private void bspull_MouseUp(object sender, System.Windows.Forms.MouseEventArgs e)
+ private void bspull_MouseUp(object sender, ShiftUI.MouseEventArgs e)
{
if (API.Upgrades["resizablewindows"] == true)
{
@@ -793,7 +796,7 @@ namespace ShiftOS
public class BorderWidget
{
public string Identifier { get; set; }
- public Control Control { get; set; }
+ public Widget Widget { get; set; }
}
}
diff --git a/source/WindowsFormsApplication1/Controls/WindowBorder.resx b/source/WindowsFormsApplication1/Controls/WindowBorder.resx
index 8bf59aa..a651f01 100644
--- a/source/WindowsFormsApplication1/Controls/WindowBorder.resx
+++ b/source/WindowsFormsApplication1/Controls/WindowBorder.resx
@@ -15,8 +15,8 @@
... ado.net/XML headers & schema ...
<resheader name="resmimetype">text/microsoft-resx</resheader>
<resheader name="version">2.0</resheader>
- <resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
- <resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
+ <resheader name="reader">System.Resources.ResXResourceReader, ShiftUI, ...</resheader>
+ <resheader name="writer">System.Resources.ResXResourceWriter, ShiftUI, ...</resheader>
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
@@ -112,10 +112,10 @@
<value>2.0</value>
</resheader>
<resheader name="reader">
- <value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
+ <value>System.Resources.ResXResourceReader, ShiftUI, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
- <value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
+ <value>System.Resources.ResXResourceWriter, ShiftUI, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<metadata name="pullbs.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<value>17, 17</value>
diff --git a/source/WindowsFormsApplication1/Controls/infobox (copy).cs b/source/WindowsFormsApplication1/Controls/infobox (copy).cs
new file mode 100644
index 0000000..77d4d2a
--- /dev/null
+++ b/source/WindowsFormsApplication1/Controls/infobox (copy).cs
@@ -0,0 +1,113 @@
+using System;
+using System.Collections.Generic;
+using System.ComponentModel;
+using System.Data;
+using System.Drawing;
+using System.Linq;
+using System.Text;
+using System.Threading.Tasks;
+using ShiftUI;
+
+namespace ShiftOS
+{
+ public partial class infobox : Form
+ {
+ /// <summary>
+ /// Creates a new Infobox instance.
+ /// </summary>
+ /// <param name="Message">Message to display.</param>
+ /// <param name="mode">UI mode.</param>
+ public infobox(string Message, InfoboxMode mode)
+ {
+ InitializeComponent();
+
+ message = Message;
+ displayMode = mode;
+ }
+
+ public string Result = "Cancelled";
+ public enum InfoboxMode
+ {
+ YesNo,
+ TextEntry,
+ Info,
+ }
+ public InfoboxMode displayMode = InfoboxMode.Info;
+ private string message = "This is an infobox.";
+ public string TextEntry
+ {
+ get
+ {
+ return txtuserinput.Text;
+ }
+ }
+
+
+
+
+
+ private void btnyes_Click(object sender, EventArgs e)
+ {
+ Result = "Yes";
+ this.Close();
+ }
+
+ private void btnno_Click(object sender, EventArgs e)
+ {
+ Result = "No";
+ this.Close();
+ }
+
+ private void btnok_Click(object sender, EventArgs e)
+ {
+ Result = "OK";
+ this.Close();
+ }
+
+ private void infobox_Load(object sender, EventArgs e)
+ {
+
+ switch(displayMode)
+ {
+ case InfoboxMode.Info:
+ txtmessage.Show();
+ txtmessage.BringToFront();
+ txtmessage.Text = message;
+ this.pnlyesno.Hide();
+ this.txtuserinput.Hide();
+ break;
+ case InfoboxMode.YesNo:
+ txtmessage.Show();
+ txtmessage.BringToFront();
+ txtmessage.Text = message;
+ this.pnlyesno.Show();
+ this.pnlyesno.BringToFront();
+ this.txtuserinput.Hide();
+ break;
+ case InfoboxMode.TextEntry:
+ txtmessage.Hide();
+ lblintructtext.Show();
+ lblintructtext.BringToFront();
+ lblintructtext.Text = message;
+ this.pnlyesno.Hide();
+ this.txtuserinput.Show();
+ this.txtuserinput.BringToFront();
+ break;
+ }
+ txtuserinput.KeyDown += (object s, KeyEventArgs a) =>
+ {
+ if (a.KeyCode == Keys.Enter)
+ {
+ a.SuppressKeyPress = true;
+ btnok_Click(s, (EventArgs)a);
+ }
+ };
+ if (API.InfoboxesPlaySounds)
+ {
+ API.PlaySound(Properties.Resources.infobox);
+ }
+ }
+
+
+ }
+}
diff --git a/source/WindowsFormsApplication1/Controls/infobox (copy).resx b/source/WindowsFormsApplication1/Controls/infobox (copy).resx
new file mode 100644
index 0000000..ffb4fb5
--- /dev/null
+++ b/source/WindowsFormsApplication1/Controls/infobox (copy).resx
@@ -0,0 +1,120 @@
+<?xml version="1.0" encoding="utf-8"?>
+<root>
+ <!--
+ Microsoft ResX Schema
+
+ Version 2.0
+
+ The primary goals of this format is to allow a simple XML format
+ that is mostly human readable. The generation and parsing of the
+ various data types are done through the TypeConverter classes
+ associated with the data types.
+
+ Example:
+
+ ... ado.net/XML headers & schema ...
+ <resheader name="resmimetype">text/microsoft-resx</resheader>
+ <resheader name="version">2.0</resheader>
+ <resheader name="reader">System.Resources.ResXResourceReader, ShiftUI, ...</resheader>
+ <resheader name="writer">System.Resources.ResXResourceWriter, ShiftUI, ...</resheader>
+ <data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
+ <data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
+ <data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
+ <value>[base64 mime encoded serialized .NET Framework object]</value>
+ </data>
+ <data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
+ <value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
+ <comment>This is a comment</comment>
+ </data>
+
+ There are any number of "resheader" rows that contain simple
+ name/value pairs.
+
+ Each data row contains a name, and value. The row also contains a
+ type or mimetype. Type corresponds to a .NET class that support
+ text/value conversion through the TypeConverter architecture.
+ Classes that don't support this are serialized and stored with the
+ mimetype set.
+
+ The mimetype is used for serialized objects, and tells the
+ ResXResourceReader how to depersist the object. This is currently not
+ extensible. For a given mimetype the value must be set accordingly:
+
+ Note - application/x-microsoft.net.object.binary.base64 is the format
+ that the ResXResourceWriter will generate, however the reader can
+ read any of the formats listed below.
+
+ mimetype: application/x-microsoft.net.object.binary.base64
+ value : The object must be serialized with
+ : System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
+ : and then encoded with base64 encoding.
+
+ mimetype: application/x-microsoft.net.object.soap.base64
+ value : The object must be serialized with
+ : System.Runtime.Serialization.Formatters.Soap.SoapFormatter
+ : and then encoded with base64 encoding.
+
+ mimetype: application/x-microsoft.net.object.bytearray.base64
+ value : The object must be serialized into a byte array
+ : using a System.ComponentModel.TypeConverter
+ : and then encoded with base64 encoding.
+ -->
+ <xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
+ <xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
+ <xsd:element name="root" msdata:IsDataSet="true">
+ <xsd:complexType>
+ <xsd:choice maxOccurs="unbounded">
+ <xsd:element name="metadata">
+ <xsd:complexType>
+ <xsd:sequence>
+ <xsd:element name="value" type="xsd:string" minOccurs="0" />
+ </xsd:sequence>
+ <xsd:attribute name="name" use="required" type="xsd:string" />
+ <xsd:attribute name="type" type="xsd:string" />
+ <xsd:attribute name="mimetype" type="xsd:string" />
+ <xsd:attribute ref="xml:space" />
+ </xsd:complexType>
+ </xsd:element>
+ <xsd:element name="assembly">
+ <xsd:complexType>
+ <xsd:attribute name="alias" type="xsd:string" />
+ <xsd:attribute name="name" type="xsd:string" />
+ </xsd:complexType>
+ </xsd:element>
+ <xsd:element name="data">
+ <xsd:complexType>
+ <xsd:sequence>
+ <xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
+ <xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
+ </xsd:sequence>
+ <xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
+ <xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
+ <xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
+ <xsd:attribute ref="xml:space" />
+ </xsd:complexType>
+ </xsd:element>
+ <xsd:element name="resheader">
+ <xsd:complexType>
+ <xsd:sequence>
+ <xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
+ </xsd:sequence>
+ <xsd:attribute name="name" type="xsd:string" use="required" />
+ </xsd:complexType>
+ </xsd:element>
+ </xsd:choice>
+ </xsd:complexType>
+ </xsd:element>
+ </xsd:schema>
+ <resheader name="resmimetype">
+ <value>text/microsoft-resx</value>
+ </resheader>
+ <resheader name="version">
+ <value>2.0</value>
+ </resheader>
+ <resheader name="reader">
+ <value>System.Resources.ResXResourceReader, ShiftUI, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
+ </resheader>
+ <resheader name="writer">
+ <value>System.Resources.ResXResourceWriter, ShiftUI, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
+ </resheader>
+</root> \ No newline at end of file
diff --git a/source/WindowsFormsApplication1/Controls/infobox.Designer (copy).cs b/source/WindowsFormsApplication1/Controls/infobox.Designer (copy).cs
new file mode 100644
index 0000000..d1c7e55
--- /dev/null
+++ b/source/WindowsFormsApplication1/Controls/infobox.Designer (copy).cs
@@ -0,0 +1,183 @@
+using System;
+
+namespace ShiftOS
+{
+ partial class infobox
+ {
+ /// <summary>
+ /// Required designer variable.
+ /// </summary>
+ private System.ComponentModel.IContainer components = null;
+
+ /// <summary>
+ /// Clean up any resources being used.
+ /// </summary>
+ /// <param name="disposing">true if managed resources should be disposed; otherwise, false.</param>
+ protected override void Dispose(bool disposing)
+ {
+ if (disposing && (components != null))
+ {
+ components.Dispose();
+ }
+ base.Dispose(disposing);
+ }
+
+ private void InitializeComponent()
+ {
+ this.pgcontents = new ShiftUI.Panel();
+ this.txtuserinput = new ShiftUI.TextBox();
+ this.btnok = new ShiftUI.Button();
+ this.txtmessage = new ShiftUI.Label();
+ this.pboximage = new ShiftUI.PictureBox();
+ this.lblintructtext = new ShiftUI.Label();
+ this.pnlyesno = new ShiftUI.Panel();
+ this.btnno = new ShiftUI.Button();
+ this.btnyes = new ShiftUI.Button();
+ this.pgcontents.SuspendLayout();
+ ((System.ComponentModel.ISupportInitialize)(this.pboximage)).BeginInit();
+ this.pnlyesno.SuspendLayout();
+ this.SuspendLayout();
+ //
+ // pgcontents
+ //
+ this.pgcontents.BackColor = System.Drawing.Color.White;
+ this.pgcontents.Widgets.Add(this.txtuserinput);
+ this.pgcontents.Widgets.Add(this.btnok);
+ this.pgcontents.Widgets.Add(this.txtmessage);
+ this.pgcontents.Widgets.Add(this.pboximage);
+ this.pgcontents.Widgets.Add(this.lblintructtext);
+ this.pgcontents.Widgets.Add(this.pnlyesno);
+ this.pgcontents.Dock = ShiftUI.DockStyle.Fill;
+ this.pgcontents.Location = new System.Drawing.Point(0, 0);
+ this.pgcontents.Name = "pgcontents";
+ this.pgcontents.Size = new System.Drawing.Size(371, 154);
+ this.pgcontents.TabIndex = 20;
+ //
+ // txtuserinput
+ //
+ //this.txtuserinput.Anchor = ShiftUI.AnchorStyles.Bottom;
+ this.txtuserinput.BorderStyle = ShiftUI.BorderStyle.FixedSingle;
+ this.txtuserinput.Font = new System.Drawing.Font("Microsoft Sans Serif", 9.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
+ this.txtuserinput.Location = new System.Drawing.Point(103, 56);
+ this.txtuserinput.Multiline = true;
+ this.txtuserinput.Name = "txtuserinput";
+ this.txtuserinput.Size = new System.Drawing.Size(256, 23);
+ this.txtuserinput.TabIndex = 8;
+ this.txtuserinput.TextAlign = ShiftUI.HorizontalAlignment.Center;
+ this.txtuserinput.Visible = false;
+ //
+ // btnok
+ //
+ //this.btnok.Anchor = ((ShiftUI.AnchorStyles)(((ShiftUI.AnchorStyles.Bottom | ShiftUI.AnchorStyles.Left) | ShiftUI.AnchorStyles.Right)));
+ this.btnok.FlatStyle = ShiftUI.FlatStyle.Standard;
+ this.btnok.Font = new System.Drawing.Font("Microsoft Sans Serif", 9.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
+ this.btnok.ForeColor = System.Drawing.Color.Black;
+ this.btnok.Location = new System.Drawing.Point(134, 88);
+ this.btnok.Name = "btnok";
+ this.btnok.Size = new System.Drawing.Size(109, 30);
+ this.btnok.TabIndex = 7;
+ this.btnok.TabStop = false;
+ this.btnok.Text = "Ok";
+ this.btnok.UseVisualStyleBackColor = true;
+ this.btnok.Click += new System.EventHandler(this.btnok_Click);
+ //
+ // txtmessage
+ //
+ //this.txtmessage.Anchor = ((ShiftUI.AnchorStyles)(((ShiftUI.AnchorStyles.Top | ShiftUI.AnchorStyles.Bottom) | ShiftUI.AnchorStyles.Right)));
+ this.txtmessage.Font = new System.Drawing.Font("Microsoft Sans Serif", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
+ this.txtmessage.Location = new System.Drawing.Point(102, 7);
+ this.txtmessage.Name = "txtmessage";
+ this.txtmessage.Size = new System.Drawing.Size(266, 75);
+ this.txtmessage.TabIndex = 2;
+ this.txtmessage.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
+ //
+ // pboximage
+ //
+ this.pboximage.Image = global::ShiftOS.Properties.Resources.Symbolinfo1;
+ this.pboximage.Location = new System.Drawing.Point(12, 17);
+ this.pboximage.Name = "pboximage";
+ this.pboximage.Size = new System.Drawing.Size(80, 70);
+ this.pboximage.TabIndex = 0;
+ this.pboximage.TabStop = false;
+ //
+ // lblintructtext
+ //
+ //this.lblintructtext.Anchor = ((ShiftUI.AnchorStyles)(((ShiftUI.AnchorStyles.Top | ShiftUI.AnchorStyles.Bottom) | ShiftUI.AnchorStyles.Right)));
+ this.lblintructtext.Font = new System.Drawing.Font("Microsoft Sans Serif", 8.25F);
+ this.lblintructtext.Location = new System.Drawing.Point(105, 7);
+ this.lblintructtext.Name = "lblintructtext";
+ this.lblintructtext.Size = new System.Drawing.Size(256, 56);
+ this.lblintructtext.TabIndex = 9;
+ this.lblintructtext.TextAlign = System.Drawing.ContentAlignment.TopCenter;
+ this.lblintructtext.Visible = false;
+ //
+ // pnlyesno
+ //
+ //this.pnlyesno.Anchor = ((ShiftUI.AnchorStyles)(((ShiftUI.AnchorStyles.Bottom | ShiftUI.AnchorStyles.Left) | ShiftUI.AnchorStyles.Right)));
+ this.pnlyesno.Widgets.Add(this.btnno);
+ this.pnlyesno.Widgets.Add(this.btnyes);
+ this.pnlyesno.Location = new System.Drawing.Point(57, 85);
+ this.pnlyesno.Name = "pnlyesno";
+ this.pnlyesno.Size = new System.Drawing.Size(269, 33);
+ this.pnlyesno.TabIndex = 10;
+ this.pnlyesno.Visible = false;
+ //
+ // btnno
+ //
+ this.btnno.FlatStyle = ShiftUI.FlatStyle.Standard;
+ this.btnno.Font = new System.Drawing.Font("Microsoft Sans Serif", 9.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
+ this.btnno.ForeColor = System.Drawing.Color.Black;
+ this.btnno.Location = new System.Drawing.Point(142, 2);
+ this.btnno.Name = "btnno";
+ this.btnno.Size = new System.Drawing.Size(105, 30);
+ this.btnno.TabIndex = 9;
+ this.btnno.TabStop = false;
+ this.btnno.Text = "No";
+ this.btnno.UseVisualStyleBackColor = true;
+ this.btnno.Click += new System.EventHandler(this.btnno_Click);
+ //
+ // btnyes
+ //
+ this.btnyes.FlatStyle = ShiftUI.FlatStyle.Standard;
+ this.btnyes.Font = new System.Drawing.Font("Microsoft Sans Serif", 9.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
+ this.btnyes.ForeColor = System.Drawing.Color.Black;
+ this.btnyes.Location = new System.Drawing.Point(29, 2);
+ this.btnyes.Name = "btnyes";
+ this.btnyes.Size = new System.Drawing.Size(105, 30);
+ this.btnyes.TabIndex = 8;
+ this.btnyes.TabStop = false;
+ this.btnyes.Text = "Yes";
+ this.btnyes.UseVisualStyleBackColor = true;
+ this.btnyes.Click += new System.EventHandler(this.btnyes_Click);
+ //
+ // infobox
+ //
+ this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
+ this.AutoScaleMode = ShiftUI.AutoScaleMode.Font;
+ this.ClientSize = new System.Drawing.Size(371, 154);
+ this.Widgets.Add(this.pgcontents);
+ this.DoubleBuffered = true;
+ this.FormBorderStyle = ShiftUI.FormBorderStyle.None;
+ this.KeyPreview = true;
+ this.Name = "infobox";
+ this.Text = "infobox";
+ this.TopMost = true;
+ this.Load += new System.EventHandler(this.infobox_Load);
+ this.pgcontents.ResumeLayout(false);
+ this.pgcontents.PerformLayout();
+ ((System.ComponentModel.ISupportInitialize)(this.pboximage)).EndInit();
+ this.pnlyesno.ResumeLayout(false);
+ this.ResumeLayout(false);
+
+ }
+ internal ShiftUI.Panel pgcontents;
+ internal ShiftUI.Button btnok;
+ internal ShiftUI.Label txtmessage;
+ internal ShiftUI.PictureBox pboximage;
+ internal ShiftUI.Label lblintructtext;
+ internal ShiftUI.TextBox txtuserinput;
+ internal ShiftUI.Panel pnlyesno;
+ internal ShiftUI.Button btnno;
+ internal ShiftUI.Button btnyes;
+ }
+} \ No newline at end of file
diff --git a/source/WindowsFormsApplication1/Controls/infobox.Designer.cs b/source/WindowsFormsApplication1/Controls/infobox.Designer.cs
index 1472a09..d1c7e55 100644
--- a/source/WindowsFormsApplication1/Controls/infobox.Designer.cs
+++ b/source/WindowsFormsApplication1/Controls/infobox.Designer.cs
@@ -24,15 +24,15 @@ namespace ShiftOS
private void InitializeComponent()
{
- this.pgcontents = new System.Windows.Forms.Panel();
- this.txtuserinput = new System.Windows.Forms.TextBox();
- this.btnok = new System.Windows.Forms.Button();
- this.txtmessage = new System.Windows.Forms.Label();
- this.pboximage = new System.Windows.Forms.PictureBox();
- this.lblintructtext = new System.Windows.Forms.Label();
- this.pnlyesno = new System.Windows.Forms.Panel();
- this.btnno = new System.Windows.Forms.Button();
- this.btnyes = new System.Windows.Forms.Button();
+ this.pgcontents = new ShiftUI.Panel();
+ this.txtuserinput = new ShiftUI.TextBox();
+ this.btnok = new ShiftUI.Button();
+ this.txtmessage = new ShiftUI.Label();
+ this.pboximage = new ShiftUI.PictureBox();
+ this.lblintructtext = new ShiftUI.Label();
+ this.pnlyesno = new ShiftUI.Panel();
+ this.btnno = new ShiftUI.Button();
+ this.btnyes = new ShiftUI.Button();
this.pgcontents.SuspendLayout();
((System.ComponentModel.ISupportInitialize)(this.pboximage)).BeginInit();
this.pnlyesno.SuspendLayout();
@@ -41,13 +41,13 @@ namespace ShiftOS
// pgcontents
//
this.pgcontents.BackColor = System.Drawing.Color.White;
- this.pgcontents.Controls.Add(this.txtuserinput);
- this.pgcontents.Controls.Add(this.btnok);
- this.pgcontents.Controls.Add(this.txtmessage);
- this.pgcontents.Controls.Add(this.pboximage);
- this.pgcontents.Controls.Add(this.lblintructtext);
- this.pgcontents.Controls.Add(this.pnlyesno);
- this.pgcontents.Dock = System.Windows.Forms.DockStyle.Fill;
+ this.pgcontents.Widgets.Add(this.txtuserinput);
+ this.pgcontents.Widgets.Add(this.btnok);
+ this.pgcontents.Widgets.Add(this.txtmessage);
+ this.pgcontents.Widgets.Add(this.pboximage);
+ this.pgcontents.Widgets.Add(this.lblintructtext);
+ this.pgcontents.Widgets.Add(this.pnlyesno);
+ this.pgcontents.Dock = ShiftUI.DockStyle.Fill;
this.pgcontents.Location = new System.Drawing.Point(0, 0);
this.pgcontents.Name = "pgcontents";
this.pgcontents.Size = new System.Drawing.Size(371, 154);
@@ -55,25 +55,24 @@ namespace ShiftOS
//
// txtuserinput
//
- this.txtuserinput.Anchor = System.Windows.Forms.AnchorStyles.Bottom;
- this.txtuserinput.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;
+ //this.txtuserinput.Anchor = ShiftUI.AnchorStyles.Bottom;
+ this.txtuserinput.BorderStyle = ShiftUI.BorderStyle.FixedSingle;
this.txtuserinput.Font = new System.Drawing.Font("Microsoft Sans Serif", 9.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
- this.txtuserinput.Location = new System.Drawing.Point(103, 86);
+ this.txtuserinput.Location = new System.Drawing.Point(103, 56);
this.txtuserinput.Multiline = true;
this.txtuserinput.Name = "txtuserinput";
this.txtuserinput.Size = new System.Drawing.Size(256, 23);
this.txtuserinput.TabIndex = 8;
- this.txtuserinput.TextAlign = System.Windows.Forms.HorizontalAlignment.Center;
+ this.txtuserinput.TextAlign = ShiftUI.HorizontalAlignment.Center;
this.txtuserinput.Visible = false;
//
// btnok
//
- this.btnok.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left)
- | System.Windows.Forms.AnchorStyles.Right)));
- this.btnok.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
+ //this.btnok.Anchor = ((ShiftUI.AnchorStyles)(((ShiftUI.AnchorStyles.Bottom | ShiftUI.AnchorStyles.Left) | ShiftUI.AnchorStyles.Right)));
+ this.btnok.FlatStyle = ShiftUI.FlatStyle.Standard;
this.btnok.Font = new System.Drawing.Font("Microsoft Sans Serif", 9.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.btnok.ForeColor = System.Drawing.Color.Black;
- this.btnok.Location = new System.Drawing.Point(134, 118);
+ this.btnok.Location = new System.Drawing.Point(134, 88);
this.btnok.Name = "btnok";
this.btnok.Size = new System.Drawing.Size(109, 30);
this.btnok.TabIndex = 7;
@@ -84,19 +83,18 @@ namespace ShiftOS
//
// txtmessage
//
- this.txtmessage.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
- | System.Windows.Forms.AnchorStyles.Right)));
+ //this.txtmessage.Anchor = ((ShiftUI.AnchorStyles)(((ShiftUI.AnchorStyles.Top | ShiftUI.AnchorStyles.Bottom) | ShiftUI.AnchorStyles.Right)));
this.txtmessage.Font = new System.Drawing.Font("Microsoft Sans Serif", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.txtmessage.Location = new System.Drawing.Point(102, 7);
this.txtmessage.Name = "txtmessage";
- this.txtmessage.Size = new System.Drawing.Size(266, 102);
+ this.txtmessage.Size = new System.Drawing.Size(266, 75);
this.txtmessage.TabIndex = 2;
this.txtmessage.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
//
// pboximage
//
this.pboximage.Image = global::ShiftOS.Properties.Resources.Symbolinfo1;
- this.pboximage.Location = new System.Drawing.Point(12, 7);
+ this.pboximage.Location = new System.Drawing.Point(12, 17);
this.pboximage.Name = "pboximage";
this.pboximage.Size = new System.Drawing.Size(80, 70);
this.pboximage.TabIndex = 0;
@@ -104,23 +102,21 @@ namespace ShiftOS
//
// lblintructtext
//
- this.lblintructtext.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
- | System.Windows.Forms.AnchorStyles.Right)));
+ //this.lblintructtext.Anchor = ((ShiftUI.AnchorStyles)(((ShiftUI.AnchorStyles.Top | ShiftUI.AnchorStyles.Bottom) | ShiftUI.AnchorStyles.Right)));
this.lblintructtext.Font = new System.Drawing.Font("Microsoft Sans Serif", 8.25F);
this.lblintructtext.Location = new System.Drawing.Point(105, 7);
this.lblintructtext.Name = "lblintructtext";
- this.lblintructtext.Size = new System.Drawing.Size(256, 76);
+ this.lblintructtext.Size = new System.Drawing.Size(256, 56);
this.lblintructtext.TabIndex = 9;
this.lblintructtext.TextAlign = System.Drawing.ContentAlignment.TopCenter;
this.lblintructtext.Visible = false;
//
// pnlyesno
//
- this.pnlyesno.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left)
- | System.Windows.Forms.AnchorStyles.Right)));
- this.pnlyesno.Controls.Add(this.btnno);
- this.pnlyesno.Controls.Add(this.btnyes);
- this.pnlyesno.Location = new System.Drawing.Point(57, 115);
+ //this.pnlyesno.Anchor = ((ShiftUI.AnchorStyles)(((ShiftUI.AnchorStyles.Bottom | ShiftUI.AnchorStyles.Left) | ShiftUI.AnchorStyles.Right)));
+ this.pnlyesno.Widgets.Add(this.btnno);
+ this.pnlyesno.Widgets.Add(this.btnyes);
+ this.pnlyesno.Location = new System.Drawing.Point(57, 85);
this.pnlyesno.Name = "pnlyesno";
this.pnlyesno.Size = new System.Drawing.Size(269, 33);
this.pnlyesno.TabIndex = 10;
@@ -128,7 +124,7 @@ namespace ShiftOS
//
// btnno
//
- this.btnno.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
+ this.btnno.FlatStyle = ShiftUI.FlatStyle.Standard;
this.btnno.Font = new System.Drawing.Font("Microsoft Sans Serif", 9.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.btnno.ForeColor = System.Drawing.Color.Black;
this.btnno.Location = new System.Drawing.Point(142, 2);
@@ -142,7 +138,7 @@ namespace ShiftOS
//
// btnyes
//
- this.btnyes.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
+ this.btnyes.FlatStyle = ShiftUI.FlatStyle.Standard;
this.btnyes.Font = new System.Drawing.Font("Microsoft Sans Serif", 9.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.btnyes.ForeColor = System.Drawing.Color.Black;
this.btnyes.Location = new System.Drawing.Point(29, 2);
@@ -157,11 +153,11 @@ namespace ShiftOS
// infobox
//
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
- this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
+ this.AutoScaleMode = ShiftUI.AutoScaleMode.Font;
this.ClientSize = new System.Drawing.Size(371, 154);
- this.Controls.Add(this.pgcontents);
+ this.Widgets.Add(this.pgcontents);
this.DoubleBuffered = true;
- this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.None;
+ this.FormBorderStyle = ShiftUI.FormBorderStyle.None;
this.KeyPreview = true;
this.Name = "infobox";
this.Text = "infobox";
@@ -174,14 +170,14 @@ namespace ShiftOS
this.ResumeLayout(false);
}
- internal System.Windows.Forms.Panel pgcontents;
- internal System.Windows.Forms.Button btnok;
- internal System.Windows.Forms.Label txtmessage;
- internal System.Windows.Forms.PictureBox pboximage;
- internal System.Windows.Forms.Label lblintructtext;
- internal System.Windows.Forms.TextBox txtuserinput;
- internal System.Windows.Forms.Panel pnlyesno;
- internal System.Windows.Forms.Button btnno;
- internal System.Windows.Forms.Button btnyes;
+ internal ShiftUI.Panel pgcontents;
+ internal ShiftUI.Button btnok;
+ internal ShiftUI.Label txtmessage;
+ internal ShiftUI.PictureBox pboximage;
+ internal ShiftUI.Label lblintructtext;
+ internal ShiftUI.TextBox txtuserinput;
+ internal ShiftUI.Panel pnlyesno;
+ internal ShiftUI.Button btnno;
+ internal ShiftUI.Button btnyes;
}
} \ No newline at end of file
diff --git a/source/WindowsFormsApplication1/Controls/infobox.cs b/source/WindowsFormsApplication1/Controls/infobox.cs
index 2f706d2..77d4d2a 100644
--- a/source/WindowsFormsApplication1/Controls/infobox.cs
+++ b/source/WindowsFormsApplication1/Controls/infobox.cs
@@ -6,7 +6,7 @@ using System.Drawing;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
-using System.Windows.Forms;
+using ShiftUI;
namespace ShiftOS
{
diff --git a/source/WindowsFormsApplication1/Controls/infobox.resx b/source/WindowsFormsApplication1/Controls/infobox.resx
index 1af7de1..ffb4fb5 100644
--- a/source/WindowsFormsApplication1/Controls/infobox.resx
+++ b/source/WindowsFormsApplication1/Controls/infobox.resx
@@ -15,8 +15,8 @@
... ado.net/XML headers & schema ...
<resheader name="resmimetype">text/microsoft-resx</resheader>
<resheader name="version">2.0</resheader>
- <resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
- <resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
+ <resheader name="reader">System.Resources.ResXResourceReader, ShiftUI, ...</resheader>
+ <resheader name="writer">System.Resources.ResXResourceWriter, ShiftUI, ...</resheader>
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
@@ -112,9 +112,9 @@
<value>2.0</value>
</resheader>
<resheader name="reader">
- <value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
+ <value>System.Resources.ResXResourceReader, ShiftUI, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
- <value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
+ <value>System.Resources.ResXResourceWriter, ShiftUI, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
</root> \ No newline at end of file