aboutsummaryrefslogtreecommitdiff
path: root/ShiftOS.Main/ShiftOS/Apps
diff options
context:
space:
mode:
authorFloppyDiskDrive <[email protected]>2017-10-01 09:52:26 -0500
committerFloppyDiskDrive <[email protected]>2017-10-01 09:52:26 -0500
commitaa44f27eab230f464e9778a4256c330a056a7b3c (patch)
treee6fbc5ac67890b11293f682c279ff7670ecef8cf /ShiftOS.Main/ShiftOS/Apps
parentc23e42cc396d4fc55799d659bae2149cc183dbf6 (diff)
downloadshiftos-rewind-aa44f27eab230f464e9778a4256c330a056a7b3c.tar.gz
shiftos-rewind-aa44f27eab230f464e9778a4256c330a056a7b3c.tar.bz2
shiftos-rewind-aa44f27eab230f464e9778a4256c330a056a7b3c.zip
Revert "Added a fuckton of changes"
This reverts commit c23e42cc396d4fc55799d659bae2149cc183dbf6.
Diffstat (limited to 'ShiftOS.Main/ShiftOS/Apps')
-rw-r--r--ShiftOS.Main/ShiftOS/Apps/ShifterStuff/SelectColor.cs10
-rw-r--r--ShiftOS.Main/ShiftOS/Apps/Snakey.Designer.cs93
-rw-r--r--ShiftOS.Main/ShiftOS/Apps/Snakey.cs123
-rw-r--r--ShiftOS.Main/ShiftOS/Apps/Snakey.resx120
-rw-r--r--ShiftOS.Main/ShiftOS/Apps/TestForm.Designer.cs168
-rw-r--r--ShiftOS.Main/ShiftOS/Apps/TestForm.cs24
6 files changed, 92 insertions, 446 deletions
diff --git a/ShiftOS.Main/ShiftOS/Apps/ShifterStuff/SelectColor.cs b/ShiftOS.Main/ShiftOS/Apps/ShifterStuff/SelectColor.cs
index 5eb5faa..697e22e 100644
--- a/ShiftOS.Main/ShiftOS/Apps/ShifterStuff/SelectColor.cs
+++ b/ShiftOS.Main/ShiftOS/Apps/ShifterStuff/SelectColor.cs
@@ -27,12 +27,12 @@ namespace ShiftOS.Main.ShiftOS.Apps
}
catch(FormatException ex)
{
- ShiftWM.StartInfoboxSession("Error!", "Failed to parse integer. Error:\n" + ex, InfoboxTemplate.ButtonType.Ok, InfoboxTemplate.ErrorIcon.Critical);
+ ShiftWM.StartInfoboxSession("Error!", "Failed to parse integer. Error:\n" + ex, InfoboxTemplate.ButtonType.Ok);
}
if (_colorType1 > 255 || _colorType2 > 255 || _colorType3 > 255)
{
- ShiftWM.StartInfoboxSession("Error!", "A value cannot be greater than 255!", InfoboxTemplate.ButtonType.Ok, InfoboxTemplate.ErrorIcon.Critical);
+ ShiftWM.StartInfoboxSession("Error!", "A value cannot be greater than 255!", InfoboxTemplate.ButtonType.Ok);
}
else
{
@@ -40,12 +40,12 @@ namespace ShiftOS.Main.ShiftOS.Apps
{
ShiftWindow sw = new ShiftWindow();
_finalColor = Color.FromArgb(_colorType1, _colorType2, _colorType3);
- ShiftWM.SetTitleBarColor(_finalColor);
- ShiftWM.StartInfoboxSession("Success!", "Changed color to:\n" + _colorType1.ToString() + ", " + _colorType2.ToString() + ", " + _colorType3.ToString() + ".", InfoboxTemplate.ButtonType.Ok, InfoboxTemplate.ErrorIcon.Info);
+ BackColor = _finalColor;
+ ShiftWM.StartInfoboxSession("Success!", "Changed color to:\n" + _colorType1.ToString() + ", " + _colorType2.ToString() + ", " + _colorType3.ToString() + ".", InfoboxTemplate.ButtonType.Ok);
}
catch (Exception)
{
- ShiftWM.StartInfoboxSession("Error!", "An error occured while setting the color.", InfoboxTemplate.ButtonType.Ok, InfoboxTemplate.ErrorIcon.Critical);
+ ShiftWM.StartInfoboxSession("Error!", "An error occured while setting the color.", InfoboxTemplate.ButtonType.Ok);
}
}
}
diff --git a/ShiftOS.Main/ShiftOS/Apps/Snakey.Designer.cs b/ShiftOS.Main/ShiftOS/Apps/Snakey.Designer.cs
deleted file mode 100644
index bef7a6b..0000000
--- a/ShiftOS.Main/ShiftOS/Apps/Snakey.Designer.cs
+++ /dev/null
@@ -1,93 +0,0 @@
-namespace ShiftOS.Main.ShiftOS.Apps
-{
- partial class Snakey
- {
- /// <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);
- }
-
- #region Component Designer generated code
-
- /// <summary>
- /// Required method for Designer support - do not modify
- /// the contents of this method with the code editor.
- /// </summary>
- private void InitializeComponent()
- {
- this.length = new System.Windows.Forms.Label();
- this.speed = new System.Windows.Forms.Label();
- this.score = new System.Windows.Forms.Label();
- this.SuspendLayout();
- //
- // length
- //
- this.length.AutoSize = true;
- this.length.BackColor = System.Drawing.Color.Transparent;
- this.length.Font = new System.Drawing.Font("Microsoft Sans Serif", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(238)));
- this.length.ForeColor = System.Drawing.Color.White;
- this.length.Location = new System.Drawing.Point(573, 18);
- this.length.Name = "length";
- this.length.Size = new System.Drawing.Size(76, 20);
- this.length.TabIndex = 16;
- this.length.Text = "Length: 5";
- //
- // speed
- //
- this.speed.AutoSize = true;
- this.speed.BackColor = System.Drawing.Color.Transparent;
- this.speed.Font = new System.Drawing.Font("Microsoft Sans Serif", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(238)));
- this.speed.ForeColor = System.Drawing.Color.White;
- this.speed.Location = new System.Drawing.Point(287, 18);
- this.speed.Name = "speed";
- this.speed.Size = new System.Drawing.Size(73, 20);
- this.speed.TabIndex = 15;
- this.speed.Text = "Speed: 1";
- //
- // score
- //
- this.score.AutoSize = true;
- this.score.BackColor = System.Drawing.Color.Transparent;
- this.score.Font = new System.Drawing.Font("Microsoft Sans Serif", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(238)));
- this.score.ForeColor = System.Drawing.Color.White;
- this.score.Location = new System.Drawing.Point(24, 18);
- this.score.Name = "score";
- this.score.Size = new System.Drawing.Size(100, 20);
- this.score.TabIndex = 14;
- this.score.Text = "Total Points: ";
- //
- // Snakey
- //
- this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
- this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
- this.BackColor = System.Drawing.Color.Black;
- this.Controls.Add(this.length);
- this.Controls.Add(this.speed);
- this.Controls.Add(this.score);
- this.Name = "Snakey";
- this.Size = new System.Drawing.Size(673, 447);
- this.ResumeLayout(false);
- this.PerformLayout();
-
- }
-
- #endregion
-
- internal System.Windows.Forms.Label length;
- internal System.Windows.Forms.Label speed;
- internal System.Windows.Forms.Label score;
- }
-}
diff --git a/ShiftOS.Main/ShiftOS/Apps/Snakey.cs b/ShiftOS.Main/ShiftOS/Apps/Snakey.cs
deleted file mode 100644
index d8d4a98..0000000
--- a/ShiftOS.Main/ShiftOS/Apps/Snakey.cs
+++ /dev/null
@@ -1,123 +0,0 @@
-using System;
-using System.Collections.Generic;
-using System.ComponentModel;
-using System.Drawing;
-using System.Data;
-using System.Linq;
-using System.Text;
-using System.Threading.Tasks;
-using System.Windows.Forms;
-using System.Drawing.Drawing2D;
-using ShiftOS.Engine;
-using ShiftOS.Main.Properties;
-
-namespace ShiftOS.Main.ShiftOS.Apps
-{
- public partial class Snakey : UserControl
- {
- public Snakey()
- {
- InitializeComponent();
- }
- private struct structSnake
- {
- public Rectangle rect;
- public int x;
- public int y;
- }
- private enum directions
- {
- Rightward,
- Downward,
- Leftward,
- Upward
- }
- #region Various-Objects
- private const int INTIAL_SNAKE_RECT_COUNT = 5;
- private const int COLUMN_COUNT = 65;
- private const int ROW_COUNT = 47;
- private int curRecCount;
- private Rectangle[,] Rects;
-
-
- private bool [,] isSnakePart;
- private List<structSnake> snake;
- private Brush snakeBrush = new SolidBrush(Color.FromArgb(255, 255, 255));
- private Brush backBrush = new SolidBrush(Color.FromArgb(1, 1, 1));
- private Brush tokenBrush = new SolidBrush(Color.FromArgb(255, 255, 255));
- private directions curDirection;
- private Bitmap buffer;
- private int columnCount;
- private int rowCount;
- private int snakePoints;
- private double snakeSpeed;
- private int snakeLength;
- private Rectangle token;
- #endregion
- private int xyIndexToRect(int X, int Y)
- {
- return (Y * (columnCount)) + X;
- }
- private void rectToIndexXY(double index, double X, double Y)
- {
- X = index % (columnCount);
- Y = Math.Round(index / columnCount);
- }
- private void initSnake()
- {
- int x;
- int y;
- int index;
- snake = new List<structSnake>();
- structSnake sSnake = new structSnake();
- x = ((columnCount) - 10 / 2);
- y = ((rowCount) - 6) / 2;
- Point snakePosition = new Point(x, y);
- index = xyIndexToRect(x, y);
- for (int i = 0; i < INTIAL_SNAKE_RECT_COUNT; i++)
- {
- rectToIndexXY(index + (i - 1), x, y);
- sSnake.rect = Rects[x, y];
- sSnake.x = x;
- sSnake.y = y;
- snake.Add(sSnake);
- }
- snakeLength = INTIAL_SNAKE_RECT_COUNT;
- snakeSpeed = 1;
- length.Text = "Length: " + snakeLength.ToString();
- speed.Text = "Speed: " + snakeSpeed.ToString();
- }
- private void selectRectangles()
- {
- Graphics g = Graphics.FromImage(Resources.snakeyback);
- int i;
- structSnake sSnake = new structSnake();
- for (i = 0; i < INTIAL_SNAKE_RECT_COUNT; i++)
- {
- sSnake = snake[i];
- g.FillRectangle(snakeBrush, sSnake.rect);
- isSnakePart[sSnake.x, sSnake.y] = true;
- }
- buffer = new Bitmap(Resources.snakeyback);
- g.Dispose();
- Refresh();
- }
- private void initRectangles()
- {
- int i;
- int j;
- columnCount = COLUMN_COUNT;
- rowCount = ROW_COUNT;
- Rects = new Rectangle[columnCount, rowCount];
- isSnakePart = new bool[columnCount, rowCount];
- for (j = 0; j < rowCount; j++)
- {
- for (i = 0; i < columnCount; i++)
- {
- //TO-DO: I can't really port this over right now. Commiting soon. -FDD
- }
- }
- }
- }
-}
-
diff --git a/ShiftOS.Main/ShiftOS/Apps/Snakey.resx b/ShiftOS.Main/ShiftOS/Apps/Snakey.resx
deleted file mode 100644
index 1af7de1..0000000
--- a/ShiftOS.Main/ShiftOS/Apps/Snakey.resx
+++ /dev/null
@@ -1,120 +0,0 @@
-<?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, System.Windows.Forms, ...</resheader>
- <resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</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, System.Windows.Forms, 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>
- </resheader>
-</root> \ No newline at end of file
diff --git a/ShiftOS.Main/ShiftOS/Apps/TestForm.Designer.cs b/ShiftOS.Main/ShiftOS/Apps/TestForm.Designer.cs
index 53765bd..50bcb58 100644
--- a/ShiftOS.Main/ShiftOS/Apps/TestForm.Designer.cs
+++ b/ShiftOS.Main/ShiftOS/Apps/TestForm.Designer.cs
@@ -28,57 +28,60 @@
/// </summary>
private void InitializeComponent()
{
- this.components = new System.ComponentModel.Container();
- this.textBox1 = new System.Windows.Forms.TextBox();
- this.textBox2 = new System.Windows.Forms.TextBox();
- this.button1 = new System.Windows.Forms.Button();
- this.button2 = new System.Windows.Forms.Button();
- this.comboBox1 = new System.Windows.Forms.ComboBox();
- this.systemIconsBindingSource = new System.Windows.Forms.BindingSource(this.components);
- this.panel1 = new System.Windows.Forms.Panel();
- ((System.ComponentModel.ISupportInitialize)(this.systemIconsBindingSource)).BeginInit();
- this.SuspendLayout();
- //
- // textBox1
- //
- this.textBox1.Location = new System.Drawing.Point(12, 13);
- this.textBox1.Name = "textBox1";
- this.textBox1.Size = new System.Drawing.Size(260, 20);
- this.textBox1.TabIndex = 0;
- this.textBox1.Text = "Title";
- //
- // textBox2
- //
- this.textBox2.Location = new System.Drawing.Point(12, 39);
- this.textBox2.Name = "textBox2";
- this.textBox2.Size = new System.Drawing.Size(260, 20);
- this.textBox2.TabIndex = 1;
- this.textBox2.Text = "Contents";
- //
- // button1
- //
- this.button1.Location = new System.Drawing.Point(9, 97);
- this.button1.Name = "button1";
- this.button1.Size = new System.Drawing.Size(128, 23);
- this.button1.TabIndex = 2;
- this.button1.Text = "Create Window";
- this.button1.UseVisualStyleBackColor = true;
- this.button1.Click += new System.EventHandler(this.Button1_Click);
- //
- // button2
- //
- this.button2.Location = new System.Drawing.Point(145, 97);
- this.button2.Name = "button2";
- this.button2.Size = new System.Drawing.Size(126, 23);
- this.button2.TabIndex = 4;
- this.button2.Text = "Test Shifter";
- this.button2.UseVisualStyleBackColor = true;
- this.button2.Click += new System.EventHandler(this.button2_Click);
- //
- // comboBox1
- //
- this.comboBox1.FormattingEnabled = true;
- this.comboBox1.Items.AddRange(new object[] {
+ this.components = new System.ComponentModel.Container();
+ this.textBox1 = new System.Windows.Forms.TextBox();
+ this.textBox2 = new System.Windows.Forms.TextBox();
+ this.button1 = new System.Windows.Forms.Button();
+ this.button2 = new System.Windows.Forms.Button();
+ this.comboBox1 = new System.Windows.Forms.ComboBox();
+ this.systemIconsBindingSource = new System.Windows.Forms.BindingSource(this.components);
+ ((System.ComponentModel.ISupportInitialize)(this.systemIconsBindingSource)).BeginInit();
+ this.SuspendLayout();
+ //
+ // textBox1
+ //
+ this.textBox1.Location = new System.Drawing.Point(18, 20);
+ this.textBox1.Margin = new System.Windows.Forms.Padding(4, 5, 4, 5);
+ this.textBox1.Name = "textBox1";
+ this.textBox1.Size = new System.Drawing.Size(388, 26);
+ this.textBox1.TabIndex = 0;
+ this.textBox1.Text = "Title";
+ //
+ // textBox2
+ //
+ this.textBox2.Location = new System.Drawing.Point(18, 60);
+ this.textBox2.Margin = new System.Windows.Forms.Padding(4, 5, 4, 5);
+ this.textBox2.Name = "textBox2";
+ this.textBox2.Size = new System.Drawing.Size(388, 26);
+ this.textBox2.TabIndex = 1;
+ this.textBox2.Text = "Contents";
+ //
+ // button1
+ //
+ this.button1.Location = new System.Drawing.Point(13, 149);
+ this.button1.Margin = new System.Windows.Forms.Padding(4, 5, 4, 5);
+ this.button1.Name = "button1";
+ this.button1.Size = new System.Drawing.Size(192, 35);
+ this.button1.TabIndex = 2;
+ this.button1.Text = "Create Window";
+ this.button1.UseVisualStyleBackColor = true;
+ this.button1.Click += new System.EventHandler(this.Button1_Click);
+ //
+ // button2
+ //
+ this.button2.Location = new System.Drawing.Point(217, 149);
+ this.button2.Margin = new System.Windows.Forms.Padding(4, 5, 4, 5);
+ this.button2.Name = "button2";
+ this.button2.Size = new System.Drawing.Size(189, 35);
+ this.button2.TabIndex = 4;
+ this.button2.Text = "Test Shifter";
+ this.button2.UseVisualStyleBackColor = true;
+ this.button2.Click += new System.EventHandler(this.button2_Click);
+ //
+ // comboBox1
+ //
+ this.comboBox1.FormattingEnabled = true;
+ this.comboBox1.Items.AddRange(new object[] {
"Application",
"Asterisk",
"Error",
@@ -89,41 +92,31 @@
"Shield",
"Warning",
"WinLogo"});
- this.comboBox1.Location = new System.Drawing.Point(12, 68);
- this.comboBox1.Margin = new System.Windows.Forms.Padding(2);
- this.comboBox1.Name = "comboBox1";
- this.comboBox1.Size = new System.Drawing.Size(260, 21);
- this.comboBox1.TabIndex = 5;
- //
- // systemIconsBindingSource
- //
- this.systemIconsBindingSource.DataSource = typeof(System.Drawing.SystemIcons);
- //
- // panel1
- //
- this.panel1.BackColor = System.Drawing.SystemColors.ControlDarkDark;
- this.panel1.Location = new System.Drawing.Point(71, 138);
- this.panel1.Name = "panel1";
- this.panel1.Size = new System.Drawing.Size(200, 37);
- this.panel1.TabIndex = 6;
- this.panel1.MouseMove += new System.Windows.Forms.MouseEventHandler(this.panel1_MouseMove);
- //
- // TestForm
- //
- this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
- this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
- this.ClientSize = new System.Drawing.Size(284, 175);
- this.Controls.Add(this.panel1);
- this.Controls.Add(this.comboBox1);
- this.Controls.Add(this.button2);
- this.Controls.Add(this.button1);
- this.Controls.Add(this.textBox2);
- this.Controls.Add(this.textBox1);
- this.Name = "TestForm";
- this.Text = "TestForm";
- ((System.ComponentModel.ISupportInitialize)(this.systemIconsBindingSource)).EndInit();
- this.ResumeLayout(false);
- this.PerformLayout();
+ this.comboBox1.Location = new System.Drawing.Point(18, 104);
+ this.comboBox1.Name = "comboBox1";
+ this.comboBox1.Size = new System.Drawing.Size(388, 28);
+ this.comboBox1.TabIndex = 5;
+ //
+ // systemIconsBindingSource
+ //
+ this.systemIconsBindingSource.DataSource = typeof(System.Drawing.SystemIcons);
+ //
+ // TestForm
+ //
+ this.AutoScaleDimensions = new System.Drawing.SizeF(9F, 20F);
+ this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
+ this.ClientSize = new System.Drawing.Size(426, 198);
+ this.Controls.Add(this.comboBox1);
+ this.Controls.Add(this.button2);
+ this.Controls.Add(this.button1);
+ this.Controls.Add(this.textBox2);
+ this.Controls.Add(this.textBox1);
+ this.Margin = new System.Windows.Forms.Padding(4, 5, 4, 5);
+ this.Name = "TestForm";
+ this.Text = "TestForm";
+ ((System.ComponentModel.ISupportInitialize)(this.systemIconsBindingSource)).EndInit();
+ this.ResumeLayout(false);
+ this.PerformLayout();
}
@@ -135,6 +128,5 @@
private System.Windows.Forms.Button button2;
private System.Windows.Forms.ComboBox comboBox1;
private System.Windows.Forms.BindingSource systemIconsBindingSource;
- private System.Windows.Forms.Panel panel1;
- }
+ }
} \ No newline at end of file
diff --git a/ShiftOS.Main/ShiftOS/Apps/TestForm.cs b/ShiftOS.Main/ShiftOS/Apps/TestForm.cs
index e8360e0..1fd3b18 100644
--- a/ShiftOS.Main/ShiftOS/Apps/TestForm.cs
+++ b/ShiftOS.Main/ShiftOS/Apps/TestForm.cs
@@ -10,7 +10,6 @@ namespace ShiftOS.Main
{
public partial class TestForm : Form
{
- Point loc;
public TestForm()
{
InitializeComponent();
@@ -18,25 +17,16 @@ namespace ShiftOS.Main
private void Button1_Click(object sender, EventArgs e)
{
- ShiftDemo demo = new ShiftDemo { label1 = { Text = textBox2.Text } };
+ ShiftDemo demo = new ShiftDemo {label1 = {Text = textBox2.Text}};
- var item = typeof(SystemIcons).GetProperties()
- .First(p => p.Name == comboBox1.SelectedItem as string);
+ var item = typeof(SystemIcons).GetProperties()
+ .First(p => p.Name == comboBox1.SelectedItem as string);
- ShiftWM.Init(demo, textBox1.Text, (item.GetMethod.Invoke(null, new object[0]) as Icon));
- ShiftWM.StartInfoboxSession(textBox1.Text, textBox2.Text, InfoboxTemplate.ButtonType.Ok, InfoboxTemplate.ErrorIcon.Critical);
+ ShiftWM.Init(demo, textBox1.Text, (item.GetMethod.Invoke(null, new object[0]) as Icon));
+ ShiftWM.StartInfoboxSession(textBox1.Text, textBox2.Text, InfoboxTemplate.ButtonType.Ok);
}
- private void button2_Click(object sender, EventArgs e)
- => ShiftWM.Init(new Shifter(), "Shifter", Properties.Resources.iconShifter.ToIcon());
-
- private void panel1_MouseMove(object sender, MouseEventArgs e)
- {
- if (e.Button == MouseButtons.Left)
- {
- loc = new Point(Cursor.Position.X, Cursor.Position.Y);
- this.Location = loc;
- }
- }
+ private void button2_Click(object sender, EventArgs e)
+ => ShiftWM.Init(new Shifter(), "Shifter", Properties.Resources.iconShifter.ToIcon());
}
}