Added Windows.Forms.App to UnitTest to help test visual controls

pull/83/head
David Hall 2019-11-24 17:12:24 -07:00
parent 42643576e8
commit 2c64bbf832
11 changed files with 887 additions and 0 deletions

View File

@ -0,0 +1,282 @@
namespace Windows.Forms.App
{
partial class Form1
{
/// <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 Windows Form 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.components = new System.ComponentModel.Container();
System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(Form1));
this.groupBox1 = new System.Windows.Forms.GroupBox();
this.dlgCombo = new System.Windows.Forms.ComboBox();
this.propertyGrid1 = new System.Windows.Forms.PropertyGrid();
this.button1 = new System.Windows.Forms.Button();
this.trackBarEx1 = new Vanara.Windows.Forms.TrackBarEx();
this.splitButton1 = new Vanara.Windows.Forms.SplitButton();
this.contextMenuStrip1 = new System.Windows.Forms.ContextMenuStrip(this.components);
this.oneToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.twoToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.threeToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.enumComboBox1 = new Vanara.Windows.Forms.EnumComboBox();
this.customButton1 = new Vanara.Windows.Forms.CustomButton();
this.commandLink1 = new Vanara.Windows.Forms.CommandLink();
this.vistaControlExtender1 = new Vanara.Windows.Forms.VistaControlExtender(this.components);
this.glassExtenderProvider1 = new Vanara.Windows.Forms.GlassExtenderProvider();
this.themedLabel1 = new Vanara.Windows.Forms.ThemedLabel();
this.themedPanel1 = new Vanara.Windows.Forms.ThemedPanel();
this.themedImageDraw1 = new Vanara.Windows.Forms.ThemedImageDraw();
this.ipAddressBox1 = new Vanara.Windows.Forms.IPAddressBox();
this.groupBox1.SuspendLayout();
((System.ComponentModel.ISupportInitialize)(this.trackBarEx1)).BeginInit();
this.contextMenuStrip1.SuspendLayout();
((System.ComponentModel.ISupportInitialize)(this.vistaControlExtender1)).BeginInit();
this.SuspendLayout();
//
// groupBox1
//
this.groupBox1.Controls.Add(this.dlgCombo);
this.groupBox1.Controls.Add(this.propertyGrid1);
this.groupBox1.Controls.Add(this.button1);
this.groupBox1.Location = new System.Drawing.Point(350, 96);
this.groupBox1.Name = "groupBox1";
this.groupBox1.Size = new System.Drawing.Size(329, 411);
this.groupBox1.TabIndex = 0;
this.groupBox1.TabStop = false;
this.groupBox1.Text = "Dialogs";
//
// dlgCombo
//
this.vistaControlExtender1.SetCueBanner(this.dlgCombo, "Select which dialog to edit & show");
this.dlgCombo.FormattingEnabled = true;
this.dlgCombo.Location = new System.Drawing.Point(7, 23);
this.vistaControlExtender1.SetMinVisibleItems(this.dlgCombo, 0);
this.dlgCombo.Name = "dlgCombo";
this.dlgCombo.Size = new System.Drawing.Size(243, 23);
this.dlgCombo.TabIndex = 3;
this.dlgCombo.SelectedIndexChanged += new System.EventHandler(this.dlgCombo_SelectedIndexChanged);
//
// propertyGrid1
//
this.propertyGrid1.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.propertyGrid1.Location = new System.Drawing.Point(7, 53);
this.propertyGrid1.Name = "propertyGrid1";
this.propertyGrid1.Size = new System.Drawing.Size(316, 352);
this.propertyGrid1.TabIndex = 2;
//
// button1
//
this.button1.FlatStyle = System.Windows.Forms.FlatStyle.System;
this.button1.Location = new System.Drawing.Point(256, 23);
this.button1.Name = "button1";
this.vistaControlExtender1.SetShowShield(this.button1, true);
this.button1.Size = new System.Drawing.Size(67, 23);
this.button1.TabIndex = 1;
this.button1.Text = "Go";
this.button1.UseVisualStyleBackColor = true;
this.button1.Click += new System.EventHandler(this.button1_Click);
//
// trackBarEx1
//
this.trackBarEx1.Location = new System.Drawing.Point(12, 336);
this.trackBarEx1.Name = "trackBarEx1";
this.trackBarEx1.Size = new System.Drawing.Size(332, 33);
this.trackBarEx1.TabIndex = 5;
this.trackBarEx1.TickPositions = new int[] {
1,
2,
3,
4,
5,
6,
7,
8,
9};
//
// splitButton1
//
this.splitButton1.FlatStyle = System.Windows.Forms.FlatStyle.System;
this.splitButton1.Location = new System.Drawing.Point(12, 269);
this.splitButton1.Name = "splitButton1";
this.splitButton1.Size = new System.Drawing.Size(131, 23);
this.splitButton1.SplitMenuStrip = this.contextMenuStrip1;
this.splitButton1.TabIndex = 4;
this.splitButton1.Text = "splitButton1";
this.splitButton1.UseVisualStyleBackColor = true;
//
// contextMenuStrip1
//
this.contextMenuStrip1.Items.AddRange(new System.Windows.Forms.ToolStripItem[] {
this.oneToolStripMenuItem,
this.twoToolStripMenuItem,
this.threeToolStripMenuItem});
this.contextMenuStrip1.Name = "contextMenuStrip1";
this.contextMenuStrip1.Size = new System.Drawing.Size(105, 70);
//
// oneToolStripMenuItem
//
this.oneToolStripMenuItem.Name = "oneToolStripMenuItem";
this.oneToolStripMenuItem.Size = new System.Drawing.Size(104, 22);
this.oneToolStripMenuItem.Text = "One";
//
// twoToolStripMenuItem
//
this.twoToolStripMenuItem.Name = "twoToolStripMenuItem";
this.twoToolStripMenuItem.Size = new System.Drawing.Size(104, 22);
this.twoToolStripMenuItem.Text = "Two";
//
// threeToolStripMenuItem
//
this.threeToolStripMenuItem.Name = "threeToolStripMenuItem";
this.threeToolStripMenuItem.Size = new System.Drawing.Size(104, 22);
this.threeToolStripMenuItem.Text = "Three";
//
// enumComboBox1
//
this.enumComboBox1.ControlSize = new System.Drawing.Size(187, 105);
this.enumComboBox1.DropSize = new System.Drawing.Size(121, 106);
this.enumComboBox1.EnumTypeString = "System.AttributeTargets";
this.enumComboBox1.FormattingEnabled = true;
this.enumComboBox1.Location = new System.Drawing.Point(12, 302);
this.vistaControlExtender1.SetMinVisibleItems(this.enumComboBox1, 0);
this.enumComboBox1.Name = "enumComboBox1";
this.enumComboBox1.Size = new System.Drawing.Size(332, 23);
this.enumComboBox1.TabIndex = 3;
//
// customButton1
//
this.customButton1.AutoEllipsis = false;
this.customButton1.Image = ((System.Drawing.Image)(resources.GetObject("customButton1.Image")));
this.customButton1.Location = new System.Drawing.Point(12, 178);
this.customButton1.Name = "customButton1";
this.customButton1.Size = new System.Drawing.Size(102, 85);
this.customButton1.TabIndex = 2;
this.customButton1.Text = "customButton1";
this.customButton1.TextImageRelation = System.Windows.Forms.TextImageRelation.ImageAboveText;
//
// commandLink1
//
this.commandLink1.Location = new System.Drawing.Point(12, 96);
this.commandLink1.Name = "commandLink1";
this.commandLink1.NoteText = "This is the subtext that goes underneath.";
this.commandLink1.Size = new System.Drawing.Size(200, 76);
this.commandLink1.TabIndex = 1;
this.commandLink1.Text = "Command Link";
//
// themedLabel1
//
this.themedLabel1.Location = new System.Drawing.Point(9, 48);
this.themedLabel1.Name = "themedLabel1";
this.themedLabel1.Size = new System.Drawing.Size(100, 23);
this.themedLabel1.StyleClass = "WINDOW";
this.themedLabel1.StylePart = 1;
this.themedLabel1.StyleState = 1;
this.themedLabel1.SupportGlass = true;
this.themedLabel1.TabIndex = 6;
this.themedLabel1.Text = "themedLabel";
//
// themedPanel1
//
this.themedPanel1.Location = new System.Drawing.Point(12, 375);
this.themedPanel1.Name = "themedPanel1";
this.themedPanel1.Size = new System.Drawing.Size(332, 70);
this.themedPanel1.StyleClass = "ExplorerBar";
this.themedPanel1.StylePart = 1;
this.themedPanel1.TabIndex = 7;
//
// themedImageDraw1
//
this.themedImageDraw1.AutoEllipsis = false;
this.themedImageDraw1.BackgroundImage = ((System.Drawing.Image)(resources.GetObject("themedImageDraw1.BackgroundImage")));
this.themedImageDraw1.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Center;
this.themedImageDraw1.Location = new System.Drawing.Point(132, 48);
this.themedImageDraw1.Name = "themedImageDraw1";
this.themedImageDraw1.Size = new System.Drawing.Size(32, 32);
this.themedImageDraw1.StyleClass = "Button";
this.themedImageDraw1.SupportGlass = true;
this.themedImageDraw1.TabIndex = 8;
//
// ipAddressBox1
//
this.ipAddressBox1.Location = new System.Drawing.Point(12, 452);
this.ipAddressBox1.Name = "ipAddressBox1";
this.ipAddressBox1.Size = new System.Drawing.Size(102, 23);
this.ipAddressBox1.TabIndex = 9;
this.ipAddressBox1.Text = "255.255.255.255";
//
// Form1
//
this.AutoScaleDimensions = new System.Drawing.SizeF(7F, 15F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.ClientSize = new System.Drawing.Size(695, 519);
this.Controls.Add(this.ipAddressBox1);
this.Controls.Add(this.themedImageDraw1);
this.Controls.Add(this.themedLabel1);
this.Controls.Add(this.themedPanel1);
this.Controls.Add(this.trackBarEx1);
this.Controls.Add(this.splitButton1);
this.Controls.Add(this.enumComboBox1);
this.Controls.Add(this.customButton1);
this.Controls.Add(this.commandLink1);
this.Controls.Add(this.groupBox1);
this.Font = new System.Drawing.Font("Segoe UI", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.glassExtenderProvider1.SetGlassMargins(this, new System.Windows.Forms.Padding(0, 85, 0, 0));
this.Name = "Form1";
this.Text = "Form1";
this.groupBox1.ResumeLayout(false);
((System.ComponentModel.ISupportInitialize)(this.trackBarEx1)).EndInit();
this.contextMenuStrip1.ResumeLayout(false);
((System.ComponentModel.ISupportInitialize)(this.vistaControlExtender1)).EndInit();
this.ResumeLayout(false);
this.PerformLayout();
}
#endregion
private System.Windows.Forms.GroupBox groupBox1;
private System.Windows.Forms.PropertyGrid propertyGrid1;
private System.Windows.Forms.Button button1;
private Vanara.Windows.Forms.CommandLink commandLink1;
private Vanara.Windows.Forms.VistaControlExtender vistaControlExtender1;
private Vanara.Windows.Forms.CustomButton customButton1;
private Vanara.Windows.Forms.EnumComboBox enumComboBox1;
private Vanara.Windows.Forms.SplitButton splitButton1;
private Vanara.Windows.Forms.TrackBarEx trackBarEx1;
private System.Windows.Forms.ComboBox dlgCombo;
private System.Windows.Forms.ContextMenuStrip contextMenuStrip1;
private System.Windows.Forms.ToolStripMenuItem oneToolStripMenuItem;
private System.Windows.Forms.ToolStripMenuItem twoToolStripMenuItem;
private System.Windows.Forms.ToolStripMenuItem threeToolStripMenuItem;
private Vanara.Windows.Forms.GlassExtenderProvider glassExtenderProvider1;
private Vanara.Windows.Forms.ThemedLabel themedLabel1;
private Vanara.Windows.Forms.ThemedPanel themedPanel1;
private Vanara.Windows.Forms.ThemedImageDraw themedImageDraw1;
private Vanara.Windows.Forms.IPAddressBox ipAddressBox1;
}
}

View File

@ -0,0 +1,43 @@
using System;
using System.Data;
using System.Linq;
using System.Reflection;
using System.Windows.Forms;
namespace Windows.Forms.App
{
public partial class Form1 : Form
{
private object currentDlg;
public Form1()
{
InitializeComponent();
FillComboWithDialogs(dlgCombo);
}
private static void FillComboWithDialogs(ComboBox cb) => cb.Items.AddRange(Assembly.GetAssembly(typeof(Vanara.Windows.Forms.AccessControlEditorDialog)).GetTypes().Where(t => !t.IsNested && typeof(CommonDialog).IsAssignableFrom(t) || typeof(Form).IsAssignableFrom(t)).ToArray());
private void button1_Click(object sender, EventArgs e)
{
if (currentDlg is null) return;
try
{
if (currentDlg is CommonDialog c)
c.ShowDialog();
else if (currentDlg is Form f)
f.ShowDialog();
}
catch (Exception ex)
{
MessageBox.Show(ex.ToString(), null, MessageBoxButtons.OK, MessageBoxIcon.Error);
}
}
private void dlgCombo_SelectedIndexChanged(object sender, EventArgs e)
{
currentDlg = dlgCombo.SelectedItem is null ? null : Activator.CreateInstance((Type)dlgCombo.SelectedItem);
propertyGrid1.SelectedObject = currentDlg;
}
}
}

View File

@ -0,0 +1,176 @@
<?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>
<metadata name="vistaControlExtender1.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<value>17, 17</value>
</metadata>
<metadata name="contextMenuStrip1.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<value>366, 17</value>
</metadata>
<assembly alias="System.Drawing" name="System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
<data name="customButton1.Image" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>
iVBORw0KGgoAAAANSUhEUgAAADAAAAAwCAYAAABXAvmHAAAABGdBTUEAALGPC/xhBQAAAAlwSFlzAAAI
TQAACE0BIYghgQAABLpJREFUaEPNmT9IHEEUxq8URDzxUJEDrxQbDxUrg6nEIqCdgoUpUggiHnZBxDRC
4AoFi6BFPIRgcyCmtNHCIlaKWFgknMY/sQhRCCFCis18y80xjt/MztxtIAM/bv3cnffezJs3s3eJIAhi
Z3Nzc3xmZiZ3fX397fb2toTrRCKRYffWChWr4fDw8MXU1NRZR0eH6DURsr+/HyL/bmlp+dXb21sQ10nW
RzVQ0ZPk+vr6YWNjY8VRiR6ApL6+/o8IdIL05Q0VPciOjY391B2UmAKQZDKZD6RPL6joSHJ6evqBOSaJ
CgCk0+kV0rczVHRhZ2fnmDmk4hJAmefMhgtUdOC5ulhNuAbQ0NDwndhwgopRYNEyR3Q8ZgCMMltRUDGC
5OTkpG6c4hNAKpXaI7YioWIEL1nJZPgEUFdX90BsRUJFG3uiMQcYPgGU8U4jKtqYnZ3VjRrxDaC1tfU9
s2mDihZGXaqPxDeAaqoRFU0cHx8XmWETvgGU8Tr0UdFEPp//TQwaqTKAHLNtgooGst3d3boxK9UE0NbW
dkpsG6Ei4+rq6h0zaKPKGQDOx20qarwU7N/c3DxIh1wRQYew/9m4vLw8EzadDnlU1EAAn05PT6mxf4Gw
hWoUWwAg57r7xoHPrkxFHdfDW8w47cpU1Eiy3RczAn17ezsQp4tgY2MjcDnkDQ4OBsvLy+EzYHFxMWCb
o+uuTEWNJ7svyund3V3FAekQ2tHRURicer8EQZZKpfB+PAegoenBiz5+CJn58wgqquzu7n5UOwZwAiOp
63AcziGIkZGRSiC4lrOkPwPQFwaEzESW+aRCRRV998Xow0FVW1lZwQv6o3vkyKIhYJmGuC+XywXZbLZy
P0Cfeqo2Nze/Fo9TvyRUVHiy+2K0MJqqJs5Iwfn5+SPNBO69v79/ost0VLWmpqYS8ekRVJSw3RdpAWdN
eQ4dIynXBBquodmeQQqxtBRYD3dUlKyurn4lHYYpgiAwYjAKB5C/cBKOmBr+pwaCT6wPpI9pfQiwkVL/
ABXLZGxlEcYRAPK7loYybLPT3t5+IG5j/oVQsYzzuy/QF66pYQb0dRWFaLpvFagIisXiAevMBtIBDSmh
phKuMdJort9oaBi/+KIimJ+ft35tyICTssRilGUQcsQxQ0g59RlH3ki/dKgI9JIWBUZWNrkhYYGr/cj1
YlmwJv5tABhhtWHk8bxMJeS9vtg9U8k/AFMJ1cFCr7YSGeo+w1hKqQguLi7eulQhnH2qbZgdx0pnfMWk
Yplk1EJGrtfaotZD1LGaigqjtpqN3I6jkVNoSCqVQhpbX/CpqHJycjIxMDDwR+8cyNpea8NA6H2n0+kz
8Rn57QQVCZmFhYXPer6i0sTR9Fnu6enJC5n58QQqmtja2sqrxuJYA5hF2Z8499yKz8iXGBUqRpCdm5uD
odCouoH5NuwTcla7urqKQmL2rFDRhUKhUJSLD2cgn70A98qNUizUn52dnS+ETO1EQUVX8Ou8+jsxNiYs
SDjHQKBqxRGvl/i6pqZf7anoifGXehP/0y/1FWzlVkWM+mfxWdOoq1CxBpJra2uF4eHhX7rjfX19X4aG
hsbJMzVBxZhILi0tverv739G/hcTQeIvO9R6uMvTfGcAAAAASUVORK5CYII=
</value>
</data>
<metadata name="glassExtenderProvider1.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<value>188, 17</value>
</metadata>
<data name="themedImageDraw1.BackgroundImage" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>
iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAABGdBTUEAALGPC/xhBQAAAAlwSFlzAAAF
iQAABYkBbWid+gAAA1RJREFUWEedlzFIHEEUhq1FcSux8PBABRHF4wq7QyuRKKeNGLRQEFIIIrESDPG4
RkFE4TywUhsxNtqm0kPSmMLDWBghcEESCAixCBaGyGb+IW+Znf33duPAx+38O/Pemzez73ZrXNf9X5xC
ofB6bGysdHh4+PPo6OhbNpt9PzEx8YKMjYSKYRwcHKx1d3f/qVHTQC6X00i/q6vrR29vb4bNDYOKjHw+
/0EcCXYAQlNT0yyzwaCiTalUyjc0NAQchQVQV1eHLCWZLRsqWjhDQ0O/bScgLADQ3Nz8mdgKQEWTm5ub
WeYAVAvgH5FZoKLJ6urqBTGsiQqgtbU1z2yaUNFkZGQkYFiICqC9vf2C2TShosEoMyxEBQAsewGoKGxt
bZ0wo0KcABSjzLZARWFycvKRGPSIE0BHR8cJsy1QUdGv2F5ZWfGcMFR90LB7wvr6+qOylTNs+6Ciov/2
9vYTM/gcrq+vt4kPDRXBzMzMHUvpc0gmk/vMB6CiItnT0+MZwPXu7q57enrqHh8fu319fd69OGMSicQd
8aGhImq/TG5paXHPzs60weXlZc3GxoY7Pz/vOZiamnKLxaJ3H7WjXC7bgdKqGBDA4uLilUyEIzjE9ebm
pjs9Pa2vERh0rBoOVZrdvb09/Yv7EqjYCauKAUHhmNUPq4MxXKdSKQ2uMcZcseM4XnAAupmlzs7OK+JL
3QmKgeoHY/f39zqt2F/82g2anIFKpaJ/yV+4o4b6/Pk6IKz6wRj2FKtCMKwhAIzB9jAb7EXF1wHj4+O/
2GSTy8tLLxCAbYLGxpqwqujrAOvkBoAzpBjXePTQxzW2QM5KGG1tbV9tf74OqBYAHEpDEHIesN/SJCCG
ekK+qCE+f74OUC+f39lkAKdRDVtiFjGTdDq9pob4/Pk64Pz8fJi9gGJlcRsyYs+vra3Fe2X0UwB2dnbe
2kGYaY7TzCzgLTnseyEgCMjE4ODggxhBVYvbsA2yABw89RtYuUBFA2dhYeEjjIGw599u2K76+vontuc2
VLRRp/0VPslQYFBs2GHEFiFLGIN/v7ifaFQMwZmbm0M6dWrDyGQy78jcUKhYDXygqhU+2Y4bGxsfVKUb
ZnOqQcUYOEtLS2/wiY5P84GBgZdkTAzcmr9rHX1M8zEnawAAAABJRU5ErkJggg==
</value>
</data>
</root>

View File

@ -0,0 +1,22 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Threading.Tasks;
using System.Windows.Forms;
namespace Windows.Forms.App
{
static class Program
{
/// <summary>
/// The main entry point for the application.
/// </summary>
[STAThread]
static void Main()
{
Application.EnableVisualStyles();
Application.SetCompatibleTextRenderingDefault(false);
Application.Run(new Form1());
}
}
}

View File

@ -0,0 +1,36 @@
using System.Reflection;
using System.Runtime.CompilerServices;
using System.Runtime.InteropServices;
// General Information about an assembly is controlled through the following
// set of attributes. Change these attribute values to modify the information
// associated with an assembly.
[assembly: AssemblyTitle("Windows.Forms.App")]
[assembly: AssemblyDescription("")]
[assembly: AssemblyConfiguration("")]
[assembly: AssemblyCompany("")]
[assembly: AssemblyProduct("Windows.Forms.App")]
[assembly: AssemblyCopyright("Copyright © 2019")]
[assembly: AssemblyTrademark("")]
[assembly: AssemblyCulture("")]
// Setting ComVisible to false makes the types in this assembly not visible
// to COM components. If you need to access a type in this assembly from
// COM, set the ComVisible attribute to true on that type.
[assembly: ComVisible(false)]
// The following GUID is for the ID of the typelib if this project is exposed to COM
[assembly: Guid("9520ec8b-9c63-47e6-a7bd-1ccf9bbb5bfa")]
// Version information for an assembly consists of the following four values:
//
// Major Version
// Minor Version
// Build Number
// Revision
//
// You can specify all the values or you can default the Build and Revision Numbers
// by using the '*' as shown below:
// [assembly: AssemblyVersion("1.0.*")]
[assembly: AssemblyVersion("1.0.0.0")]
[assembly: AssemblyFileVersion("1.0.0.0")]

View File

@ -0,0 +1,71 @@
//------------------------------------------------------------------------------
// <auto-generated>
// This code was generated by a tool.
// Runtime Version:4.0.30319.42000
//
// Changes to this file may cause incorrect behavior and will be lost if
// the code is regenerated.
// </auto-generated>
//------------------------------------------------------------------------------
namespace Windows.Forms.App.Properties
{
/// <summary>
/// A strongly-typed resource class, for looking up localized strings, etc.
/// </summary>
// This class was auto-generated by the StronglyTypedResourceBuilder
// class via a tool like ResGen or Visual Studio.
// To add or remove a member, edit your .ResX file then rerun ResGen
// with the /str option, or rebuild your VS project.
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Resources.Tools.StronglyTypedResourceBuilder", "4.0.0.0")]
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
internal class Resources
{
private static global::System.Resources.ResourceManager resourceMan;
private static global::System.Globalization.CultureInfo resourceCulture;
[global::System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")]
internal Resources()
{
}
/// <summary>
/// Returns the cached ResourceManager instance used by this class.
/// </summary>
[global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)]
internal static global::System.Resources.ResourceManager ResourceManager
{
get
{
if ((resourceMan == null))
{
global::System.Resources.ResourceManager temp = new global::System.Resources.ResourceManager("Windows.Forms.App.Properties.Resources", typeof(Resources).Assembly);
resourceMan = temp;
}
return resourceMan;
}
}
/// <summary>
/// Overrides the current thread's CurrentUICulture property for all
/// resource lookups using this strongly typed resource class.
/// </summary>
[global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)]
internal static global::System.Globalization.CultureInfo Culture
{
get
{
return resourceCulture;
}
set
{
resourceCulture = value;
}
}
}
}

View File

@ -0,0 +1,117 @@
<?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.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: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" type="xsd:string" />
<xsd:attribute name="type" type="xsd:string" />
<xsd:attribute name="mimetype" type="xsd:string" />
</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" msdata:Ordinal="1" />
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
</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=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
</root>

View File

@ -0,0 +1,30 @@
//------------------------------------------------------------------------------
// <auto-generated>
// This code was generated by a tool.
// Runtime Version:4.0.30319.42000
//
// Changes to this file may cause incorrect behavior and will be lost if
// the code is regenerated.
// </auto-generated>
//------------------------------------------------------------------------------
namespace Windows.Forms.App.Properties
{
[global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Editors.SettingsDesigner.SettingsSingleFileGenerator", "11.0.0.0")]
internal sealed partial class Settings : global::System.Configuration.ApplicationSettingsBase
{
private static Settings defaultInstance = ((Settings)(global::System.Configuration.ApplicationSettingsBase.Synchronized(new Settings())));
public static Settings Default
{
get
{
return defaultInstance;
}
}
}
}

View File

@ -0,0 +1,7 @@
<?xml version='1.0' encoding='utf-8'?>
<SettingsFile xmlns="http://schemas.microsoft.com/VisualStudio/2004/01/settings" CurrentProfile="(Default)">
<Profiles>
<Profile Name="(Default)" />
</Profiles>
<Settings />
</SettingsFile>

View File

@ -0,0 +1,94 @@
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props" Condition="Exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props')" />
<PropertyGroup>
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
<ProjectGuid>{9520EC8B-9C63-47E6-A7BD-1CCF9BBB5BFA}</ProjectGuid>
<OutputType>WinExe</OutputType>
<RootNamespace>Windows.Forms.App</RootNamespace>
<AssemblyName>Windows.Forms.App</AssemblyName>
<TargetFrameworkVersion>v4.5.2</TargetFrameworkVersion>
<FileAlignment>512</FileAlignment>
<AutoGenerateBindingRedirects>true</AutoGenerateBindingRedirects>
<Deterministic>true</Deterministic>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
<PlatformTarget>AnyCPU</PlatformTarget>
<DebugSymbols>true</DebugSymbols>
<DebugType>full</DebugType>
<Optimize>false</Optimize>
<OutputPath>bin\Debug\</OutputPath>
<DefineConstants>DEBUG;TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
<PlatformTarget>AnyCPU</PlatformTarget>
<DebugType>pdbonly</DebugType>
<Optimize>true</Optimize>
<OutputPath>bin\Release\</OutputPath>
<DefineConstants>TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
</PropertyGroup>
<ItemGroup>
<Reference Include="System" />
<Reference Include="System.Core" />
<Reference Include="System.Xml.Linq" />
<Reference Include="System.Data.DataSetExtensions" />
<Reference Include="Microsoft.CSharp" />
<Reference Include="System.Data" />
<Reference Include="System.Deployment" />
<Reference Include="System.Drawing" />
<Reference Include="System.Net.Http" />
<Reference Include="System.Windows.Forms" />
<Reference Include="System.Xml" />
</ItemGroup>
<ItemGroup>
<Compile Include="Form1.cs">
<SubType>Form</SubType>
</Compile>
<Compile Include="Form1.Designer.cs">
<DependentUpon>Form1.cs</DependentUpon>
</Compile>
<Compile Include="Program.cs" />
<Compile Include="Properties\AssemblyInfo.cs" />
<EmbeddedResource Include="Form1.resx">
<DependentUpon>Form1.cs</DependentUpon>
</EmbeddedResource>
<EmbeddedResource Include="Properties\Resources.resx">
<Generator>ResXFileCodeGenerator</Generator>
<LastGenOutput>Resources.Designer.cs</LastGenOutput>
<SubType>Designer</SubType>
</EmbeddedResource>
<Compile Include="Properties\Resources.Designer.cs">
<AutoGen>True</AutoGen>
<DependentUpon>Resources.resx</DependentUpon>
</Compile>
<None Include="Properties\Settings.settings">
<Generator>SettingsSingleFileGenerator</Generator>
<LastGenOutput>Settings.Designer.cs</LastGenOutput>
</None>
<Compile Include="Properties\Settings.Designer.cs">
<AutoGen>True</AutoGen>
<DependentUpon>Settings.settings</DependentUpon>
<DesignTimeSharedInput>True</DesignTimeSharedInput>
</Compile>
</ItemGroup>
<ItemGroup>
<ProjectReference Include="..\..\Core\Vanara.Core.csproj">
<Project>{241f73ee-9298-45c9-b869-a045dff94c03}</Project>
<Name>Vanara.Core</Name>
</ProjectReference>
<ProjectReference Include="..\..\Windows.Forms\Vanara.Windows.Forms.csproj">
<Project>{51986cd3-eeda-4369-93a4-255512548f68}</Project>
<Name>Vanara.Windows.Forms</Name>
</ProjectReference>
<ProjectReference Include="..\..\Windows.Shell\Vanara.Windows.Shell.csproj">
<Project>{43685be2-a65e-4b01-be16-479526940f23}</Project>
<Name>Vanara.Windows.Shell</Name>
</ProjectReference>
</ItemGroup>
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
</Project>

View File

@ -179,6 +179,8 @@ Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "VirtualDisk", "UnitTests\Vi
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ExplorerBrowserDemo", "UnitTests\ExplorerBrowser\ExplorerBrowserDemo.csproj", "{2AACFF7E-F4B1-44F6-92C6-20ACBB647A4D}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Windows.Forms.App", "UnitTests\Windows.Forms.App\Windows.Forms.App.csproj", "{9520EC8B-9C63-47E6-A7BD-1CCF9BBB5BFA}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug (no Unit Tests)|Any CPU = Debug (no Unit Tests)|Any CPU
@ -589,6 +591,12 @@ Global
{2AACFF7E-F4B1-44F6-92C6-20ACBB647A4D}.Debug|Any CPU.Build.0 = Debug|Any CPU
{2AACFF7E-F4B1-44F6-92C6-20ACBB647A4D}.Release|Any CPU.ActiveCfg = Release|Any CPU
{2AACFF7E-F4B1-44F6-92C6-20ACBB647A4D}.Release|Any CPU.Build.0 = Release|Any CPU
{9520EC8B-9C63-47E6-A7BD-1CCF9BBB5BFA}.Debug (no Unit Tests)|Any CPU.ActiveCfg = Debug|Any CPU
{9520EC8B-9C63-47E6-A7BD-1CCF9BBB5BFA}.Debug (no Unit Tests)|Any CPU.Build.0 = Debug|Any CPU
{9520EC8B-9C63-47E6-A7BD-1CCF9BBB5BFA}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{9520EC8B-9C63-47E6-A7BD-1CCF9BBB5BFA}.Debug|Any CPU.Build.0 = Debug|Any CPU
{9520EC8B-9C63-47E6-A7BD-1CCF9BBB5BFA}.Release|Any CPU.ActiveCfg = Release|Any CPU
{9520EC8B-9C63-47E6-A7BD-1CCF9BBB5BFA}.Release|Any CPU.Build.0 = Release|Any CPU
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
@ -666,6 +674,7 @@ Global
{5558B8E3-FF1C-401F-978E-E91D1E78B898} = {3EC6B40D-71D3-4E59-A0E0-544EC605FE11}
{687F9162-8CA0-4277-B868-4E7F2EC614F8} = {3EC6B40D-71D3-4E59-A0E0-544EC605FE11}
{2AACFF7E-F4B1-44F6-92C6-20ACBB647A4D} = {3EC6B40D-71D3-4E59-A0E0-544EC605FE11}
{9520EC8B-9C63-47E6-A7BD-1CCF9BBB5BFA} = {3EC6B40D-71D3-4E59-A0E0-544EC605FE11}
EndGlobalSection
GlobalSection(ExtensibilityGlobals) = postSolution
SolutionGuid = {543FAC75-2AF1-4EF1-9609-B242B63FEED4}