initial redesign of connection tree window using table layout panel

This commit is contained in:
David Sparer
2018-09-02 17:56:10 -05:00
parent 6ee4353bbd
commit 0c77fa43ff
2 changed files with 81 additions and 70 deletions

View File

@@ -8,13 +8,10 @@ namespace mRemoteNG.UI.Window
public partial class ConnectionTreeWindow : BaseWindow
{
#region Windows Form Designer generated code
internal Controls.Base.NGTextBox txtSearch;
internal System.Windows.Forms.Panel pnlConnections;
internal System.Windows.Forms.MenuStrip msMain;
internal System.Windows.Forms.ToolStripMenuItem mMenView;
internal System.Windows.Forms.ToolStripMenuItem mMenViewExpandAllFolders;
internal System.Windows.Forms.ToolStripMenuItem mMenViewCollapseAllFolders;
internal System.Windows.Forms.PictureBox PictureBox1;
internal System.Windows.Forms.ToolStripMenuItem mMenSortAscending;
internal System.Windows.Forms.ToolStripMenuItem mMenAddConnection;
internal System.Windows.Forms.ToolStripMenuItem mMenAddFolder;
@@ -22,13 +19,11 @@ namespace mRemoteNG.UI.Window
private void InitializeComponent()
{
this.components = new System.ComponentModel.Container();
mRemoteNG.Tree.ConnectionTreeModel connectionTreeModel1 = new mRemoteNG.Tree.ConnectionTreeModel();
mRemoteNG.Tree.TreeNodeCompositeClickHandler treeNodeCompositeClickHandler1 = new mRemoteNG.Tree.TreeNodeCompositeClickHandler();
mRemoteNG.Tree.AlwaysConfirmYes alwaysConfirmYes1 = new mRemoteNG.Tree.AlwaysConfirmYes();
mRemoteNG.Tree.TreeNodeCompositeClickHandler treeNodeCompositeClickHandler2 = new mRemoteNG.Tree.TreeNodeCompositeClickHandler();
this.olvConnections = new mRemoteNG.UI.Controls.ConnectionTree();
this.pnlConnections = new System.Windows.Forms.Panel();
this.PictureBox1 = new System.Windows.Forms.PictureBox();
this.txtSearch = new Controls.Base.NGTextBox();
this.msMain = new System.Windows.Forms.MenuStrip();
this.mMenAddConnection = new System.Windows.Forms.ToolStripMenuItem();
this.mMenAddFolder = new System.Windows.Forms.ToolStripMenuItem();
@@ -36,33 +31,33 @@ namespace mRemoteNG.UI.Window
this.mMenViewExpandAllFolders = new System.Windows.Forms.ToolStripMenuItem();
this.mMenViewCollapseAllFolders = new System.Windows.Forms.ToolStripMenuItem();
this.mMenSortAscending = new System.Windows.Forms.ToolStripMenuItem();
((System.ComponentModel.ISupportInitialize)(this.olvConnections)).BeginInit();
this.pnlConnections.SuspendLayout();
((System.ComponentModel.ISupportInitialize)(this.PictureBox1)).BeginInit();
this.msMain.SuspendLayout();
this.SuspendLayout();
//
//Theming support
//
this.vsToolStripExtender = new WeifenLuo.WinFormsUI.Docking.VisualStudioToolStripExtender(this.components);
this.tableLayoutPanel1 = new System.Windows.Forms.TableLayoutPanel();
this.txtSearch = new mRemoteNG.UI.Controls.Base.NGTextBox();
this.PictureBox1 = new System.Windows.Forms.PictureBox();
((System.ComponentModel.ISupportInitialize)(this.olvConnections)).BeginInit();
this.msMain.SuspendLayout();
this.tableLayoutPanel1.SuspendLayout();
((System.ComponentModel.ISupportInitialize)(this.PictureBox1)).BeginInit();
this.SuspendLayout();
//
// olvConnections
//
this.olvConnections.AllowDrop = true;
this.olvConnections.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.olvConnections.BorderStyle = System.Windows.Forms.BorderStyle.None;
this.olvConnections.CellEditUseWholeCell = false;
this.olvConnections.ConnectionTreeModel = new ConnectionTreeModel();
this.tableLayoutPanel1.SetColumnSpan(this.olvConnections, 2);
this.olvConnections.ConnectionTreeModel = connectionTreeModel1;
this.olvConnections.Cursor = System.Windows.Forms.Cursors.Default;
treeNodeCompositeClickHandler1.ClickHandlers = new ITreeNodeClickHandler<ConnectionInfo>[0];
this.olvConnections.Dock = System.Windows.Forms.DockStyle.Fill;
treeNodeCompositeClickHandler1.ClickHandlers = new mRemoteNG.Tree.ITreeNodeClickHandler<mRemoteNG.Connection.ConnectionInfo>[0];
this.olvConnections.DoubleClickHandler = treeNodeCompositeClickHandler1;
this.olvConnections.HeaderStyle = System.Windows.Forms.ColumnHeaderStyle.None;
this.olvConnections.HideSelection = false;
this.olvConnections.IsSimpleDragSource = true;
this.olvConnections.IsSimpleDropSink = true;
this.olvConnections.LabelEdit = true;
this.olvConnections.Location = new System.Drawing.Point(0, 0);
this.olvConnections.Location = new System.Drawing.Point(3, 3);
this.olvConnections.MultiSelect = false;
this.olvConnections.Name = "olvConnections";
this.olvConnections.NodeDeletionConfirmer = alwaysConfirmYes1;
@@ -70,9 +65,9 @@ namespace mRemoteNG.UI.Window
this.olvConnections.SelectedBackColor = System.Drawing.SystemColors.Highlight;
this.olvConnections.SelectedForeColor = System.Drawing.SystemColors.HighlightText;
this.olvConnections.ShowGroups = false;
treeNodeCompositeClickHandler2.ClickHandlers = new mRemoteNG.Tree.ITreeNodeClickHandler<ConnectionInfo>[0];
treeNodeCompositeClickHandler2.ClickHandlers = new mRemoteNG.Tree.ITreeNodeClickHandler<mRemoteNG.Connection.ConnectionInfo>[0];
this.olvConnections.SingleClickHandler = treeNodeCompositeClickHandler2;
this.olvConnections.Size = new System.Drawing.Size(192, 410);
this.olvConnections.Size = new System.Drawing.Size(381, 365);
this.olvConnections.TabIndex = 20;
this.olvConnections.UnfocusedSelectedBackColor = System.Drawing.SystemColors.Highlight;
this.olvConnections.UnfocusedSelectedForeColor = System.Drawing.SystemColors.HighlightText;
@@ -81,47 +76,6 @@ namespace mRemoteNG.UI.Window
this.olvConnections.View = System.Windows.Forms.View.Details;
this.olvConnections.VirtualMode = true;
//
// pnlConnections
//
this.pnlConnections.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.pnlConnections.Controls.Add(this.PictureBox1);
this.pnlConnections.Controls.Add(this.txtSearch);
this.pnlConnections.Controls.Add(this.olvConnections);
this.pnlConnections.Location = new System.Drawing.Point(0, 25);
this.pnlConnections.Name = "pnlConnections";
this.pnlConnections.Size = new System.Drawing.Size(192, 428);
this.pnlConnections.TabIndex = 9;
//
// PictureBox1
//
this.PictureBox1.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left)));
this.PictureBox1.Image = global::mRemoteNG.Resources.Search;
this.PictureBox1.Location = new System.Drawing.Point(2, 412);
this.PictureBox1.Name = "PictureBox1";
this.PictureBox1.Size = new System.Drawing.Size(16, 16);
this.PictureBox1.SizeMode = System.Windows.Forms.PictureBoxSizeMode.AutoSize;
this.PictureBox1.TabIndex = 1;
this.PictureBox1.TabStop = false;
//
// txtSearch
//
this.txtSearch.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.txtSearch.BorderStyle = System.Windows.Forms.BorderStyle.None;
this.txtSearch.ForeColor = System.Drawing.SystemColors.GrayText;
this.txtSearch.Location = new System.Drawing.Point(19, 413);
this.txtSearch.Name = "txtSearch";
this.txtSearch.Size = new System.Drawing.Size(171, 15);
this.txtSearch.TabIndex = 30;
this.txtSearch.TabStop = false;
this.txtSearch.Text = "Search";
this.txtSearch.TextChanged += new System.EventHandler(this.txtSearch_TextChanged);
this.txtSearch.GotFocus += new System.EventHandler(this.txtSearch_GotFocus);
this.txtSearch.KeyDown += new System.Windows.Forms.KeyEventHandler(this.txtSearch_KeyDown);
this.txtSearch.LostFocus += new System.EventHandler(this.txtSearch_LostFocus);
//
// msMain
//
this.msMain.Font = new System.Drawing.Font("Segoe UI", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
@@ -134,7 +88,7 @@ namespace mRemoteNG.UI.Window
this.msMain.Name = "msMain";
this.msMain.RenderMode = System.Windows.Forms.ToolStripRenderMode.Professional;
this.msMain.ShowItemToolTips = true;
this.msMain.Size = new System.Drawing.Size(192, 24);
this.msMain.Size = new System.Drawing.Size(204, 24);
this.msMain.TabIndex = 10;
this.msMain.Text = "MenuStrip1";
//
@@ -186,11 +140,62 @@ namespace mRemoteNG.UI.Window
this.mMenSortAscending.Name = "mMenSortAscending";
this.mMenSortAscending.Size = new System.Drawing.Size(28, 20);
//
// vsToolStripExtender
//
this.vsToolStripExtender.DefaultRenderer = null;
//
// tableLayoutPanel1
//
this.tableLayoutPanel1.AutoSizeMode = System.Windows.Forms.AutoSizeMode.GrowAndShrink;
this.tableLayoutPanel1.ColumnCount = 2;
this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle());
this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle());
this.tableLayoutPanel1.Controls.Add(this.olvConnections, 0, 0);
this.tableLayoutPanel1.Controls.Add(this.PictureBox1, 0, 1);
this.tableLayoutPanel1.Controls.Add(this.txtSearch, 1, 1);
this.tableLayoutPanel1.Dock = System.Windows.Forms.DockStyle.Fill;
this.tableLayoutPanel1.Location = new System.Drawing.Point(0, 24);
this.tableLayoutPanel1.Name = "tableLayoutPanel1";
this.tableLayoutPanel1.RowCount = 2;
this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 100F));
this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle());
this.tableLayoutPanel1.Size = new System.Drawing.Size(204, 387);
this.tableLayoutPanel1.TabIndex = 31;
//
// txtSearch
//
this.txtSearch.BorderStyle = System.Windows.Forms.BorderStyle.None;
this.txtSearch.Dock = System.Windows.Forms.DockStyle.Fill;
this.txtSearch.ForeColor = System.Drawing.SystemColors.GrayText;
this.txtSearch.Location = new System.Drawing.Point(16, 371);
this.txtSearch.Margin = new System.Windows.Forms.Padding(0);
this.txtSearch.Name = "txtSearch";
this.txtSearch.Size = new System.Drawing.Size(371, 15);
this.txtSearch.TabIndex = 30;
this.txtSearch.TabStop = false;
this.txtSearch.Text = "Search";
this.txtSearch.TextChanged += new System.EventHandler(this.txtSearch_TextChanged);
this.txtSearch.GotFocus += new System.EventHandler(this.txtSearch_GotFocus);
this.txtSearch.KeyDown += new System.Windows.Forms.KeyEventHandler(this.txtSearch_KeyDown);
this.txtSearch.LostFocus += new System.EventHandler(this.txtSearch_LostFocus);
//
// PictureBox1
//
this.PictureBox1.Dock = System.Windows.Forms.DockStyle.Fill;
this.PictureBox1.Image = global::mRemoteNG.Resources.Search;
this.PictureBox1.Location = new System.Drawing.Point(0, 371);
this.PictureBox1.Margin = new System.Windows.Forms.Padding(0);
this.PictureBox1.Name = "PictureBox1";
this.PictureBox1.Size = new System.Drawing.Size(16, 16);
this.PictureBox1.SizeMode = System.Windows.Forms.PictureBoxSizeMode.AutoSize;
this.PictureBox1.TabIndex = 1;
this.PictureBox1.TabStop = false;
//
// ConnectionTreeWindow
//
this.ClientSize = new System.Drawing.Size(192, 453);
this.ClientSize = new System.Drawing.Size(204, 411);
this.Controls.Add(this.tableLayoutPanel1);
this.Controls.Add(this.msMain);
this.Controls.Add(this.pnlConnections);
this.Font = new System.Drawing.Font("Segoe UI", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.HideOnClose = true;
this.Icon = global::mRemoteNG.Resources.Root_Icon;
@@ -199,11 +204,11 @@ namespace mRemoteNG.UI.Window
this.Text = "Connections";
this.Load += new System.EventHandler(this.Tree_Load);
((System.ComponentModel.ISupportInitialize)(this.olvConnections)).EndInit();
this.pnlConnections.ResumeLayout(false);
this.pnlConnections.PerformLayout();
((System.ComponentModel.ISupportInitialize)(this.PictureBox1)).EndInit();
this.msMain.ResumeLayout(false);
this.msMain.PerformLayout();
this.tableLayoutPanel1.ResumeLayout(false);
this.tableLayoutPanel1.PerformLayout();
((System.ComponentModel.ISupportInitialize)(this.PictureBox1)).EndInit();
this.ResumeLayout(false);
this.PerformLayout();
@@ -213,5 +218,8 @@ namespace mRemoteNG.UI.Window
private System.ComponentModel.IContainer components;
private Controls.ConnectionTree olvConnections;
private WeifenLuo.WinFormsUI.Docking.VisualStudioToolStripExtender vsToolStripExtender;
private System.Windows.Forms.TableLayoutPanel tableLayoutPanel1;
internal System.Windows.Forms.PictureBox PictureBox1;
internal Controls.Base.NGTextBox txtSearch;
}
}

View File

@@ -118,6 +118,9 @@
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<metadata name="msMain.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<value>119, 19</value>
<value>177, 17</value>
</metadata>
<metadata name="vsToolStripExtender.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<value>17, 17</value>
</metadata>
</root>