private void initTable()
        {
            treeListView      = new BrightIdeasSoftware.TreeListView();
            treeListView.Dock = DockStyle.Fill;
            mainPanel.Controls.Add(treeListView);

            // set the delegate that the tree uses to know if a node is expandable
            this.treeListView.CanExpandGetter = x => (x as NodeData).lstChannel.Count > 0;
            // set the delegate that the tree uses to know the children of a node
            this.treeListView.ChildrenGetter = x => (x as NodeData).lstChannel;

            // create the tree columns and set the delegates to print the desired object proerty
            var nameCol = new BrightIdeasSoftware.OLVColumn("Node", "Name");

            nameCol.AspectGetter = x => (x as NodeData).Name;

            var col1 = new BrightIdeasSoftware.OLVColumn("Sensor", "Column1");

            col1.AspectGetter = x => (x as NodeData).ID;

            var col2 = new BrightIdeasSoftware.OLVColumn("Type", "Column2");

            col2.AspectGetter = x => (x as NodeData).Type;

            var col3 = new BrightIdeasSoftware.OLVColumn("Calib. factor", "Column5");

            col3.AspectGetter = x => (x as NodeData).CalibFactor;

            var col4 = new BrightIdeasSoftware.OLVColumn("Status", "Column3");

            col4.AspectGetter = x => (x as NodeData).State;

            var col5 = new BrightIdeasSoftware.OLVColumn("Time", "Column4");

            col5.AspectGetter = x => (x as NodeData).Time;

            var col6 = new BrightIdeasSoftware.OLVColumn("Temp", "Column5");

            col6.AspectGetter = x => (x as NodeData).Temp;



            // add the columns to the tree

            this.treeListView.Columns.Add(nameCol);
            this.treeListView.Columns.Add(col1);
            this.treeListView.Columns.Add(col2);
            this.treeListView.Columns.Add(col3);
            this.treeListView.Columns.Add(col4);
            this.treeListView.Columns.Add(col5);
            this.treeListView.Columns.Add(col6);

            this.treeListView.Columns[0].Width = 100;
            this.treeListView.Columns[1].Width = 140;
            this.treeListView.Columns[2].Width = 100;
            this.treeListView.Columns[3].Width = 80;
            this.treeListView.Columns[4].Width = 100;
            this.treeListView.Columns[5].Width = 90;
            this.treeListView.Columns[6].Width = 50;
        }
        private void ChildrenGetter(BrightIdeasSoftware.TreeListView mytreeListView)
        {
            mytreeListView.ChildrenGetter = delegate(object x)
            {
                try
                {
                    if (x is Inputs)
                    {
                        return(((Inputs)x).Items);
                    }
                    if (x is Outputs)
                    {
                        return(((Outputs)x).Items);
                    }
                    if (x is Tools)
                    {
                        return(((Tools)x).Items);
                    }
                    if (x is Document doc)
                    {
                        List <DocFile> docFile = new List <DocFile>();
                        string[]       files   = Directory.GetFiles(doc.FolderPath, "*", SearchOption.AllDirectories);
                        foreach (var item in files)
                        {
                            docFile.Add(new DocFile()
                            {
                                FilePath = item
                            });
                        }
                        return(docFile);
                    }
                    if (x is Tool tool)
                    {
                        List <Tool> toolFile = new List <Tool>();
                        foreach (var item in Directory.GetFiles(tool.FolderPath, "*", SearchOption.AllDirectories))
                        {
                            toolFile.Add(new Tool()
                            {
                                Name = Path.GetFileName(item)
                            });
                        }
                        return(toolFile);
                    }

                    else
                    {
                        return(new ArrayList());
                    }
                }
                catch (UnauthorizedAccessException ex)
                {
                    //this.BeginInvoke((MethodInvoker)delegate ()
                    //{
                    mytreeListView.Collapse(x);
                    //    MessageBox.Show(this, ex.Message, "ObjectListViewDemo", MessageBoxButtons.OK, MessageBoxIcon.Exclamation);
                    //});
                    return(new ArrayList());
                }
            };
        }
        public static void SetupTree(BrightIdeasSoftware.TreeListView treeListView, object dataObject)
        {
            treeListView.CanExpandGetter = CanExpandGetter;
            treeListView.ChildrenGetter  = ChildrenGetter;

            // Create columns
            var nameCol = new BrightIdeasSoftware.OLVColumn("Name", nameof(Name))
            {
                Width = 300
            };

            treeListView.Columns.Add(nameCol);

            var valueCol = new BrightIdeasSoftware.OLVColumn("Value", nameof(Value))
            {
                Width = 500
            };

            treeListView.Columns.Add(valueCol);

            var typeCol = new BrightIdeasSoftware.OLVColumn("Type", nameof(TypeName))
            {
                Width = 200
            };

            treeListView.Columns.Add(typeCol);

            // Create a dummy root object to hold the top-level class members
            var rootObject = new TreeDataObjectNode(dataObject, "unnamed_dummy_root_node");

            treeListView.Roots = rootObject.Children;
        }
Exemple #4
0
        private void AddTree()
        {
            treeListView = new BrightIdeasSoftware.TreeListView();

            treeListView.Location = new Point(12, 27);
            treeListView.Size     = new Size(335, 273);
            this.Controls.Add(treeListView);
        }
Exemple #5
0
        public static void SetupTree(BrightIdeasSoftware.TreeListView treeListView, List <object> childObjects)
        {
            treeListView.CanExpandGetter = CanExpandGetter;
            treeListView.ChildrenGetter  = ChildrenGetter;

            // Create columns
            var typeCol = new BrightIdeasSoftware.OLVColumn("Object", nameof(TypeName))
            {
                Width      = 200,
                IsEditable = false,
            };

            treeListView.Columns.Add(typeCol);

            var nameCol = new BrightIdeasSoftware.OLVColumn("Name", nameof(Name))
            {
                Width      = 200,
                IsEditable = false,
            };

            treeListView.Columns.Add(nameCol);

            var uuidCol = new BrightIdeasSoftware.OLVColumn("UUID", nameof(UUID))
            {
                Width      = 300,
                IsEditable = false,
            };

            treeListView.Columns.Add(uuidCol);

            // Sort object list into each category based on the type name
            var categorizedObjects = new Dictionary <string, List <object> >();

            foreach (var obj in childObjects)
            {
                string typeString = obj.GetType().GetFriendlyName();

                if (!categorizedObjects.TryGetValue(typeString, out List <object> categoryList))
                {
                    categoryList = new List <object>();
                    categorizedObjects.Add(typeString, categoryList);
                }

                categoryList.Add(obj);
            }

            // Register list view categories
            var treeViewRoots = new List <TreeObjectNode>();

            foreach (string key in categorizedObjects.Keys.OrderBy(x => x))
            {
                treeViewRoots.Add(new TreeObjectNode(key, categorizedObjects[key]));
            }

            treeListView.Roots = treeViewRoots;
        }
 public TreeViewSetuper(frmMain frmMain)
 {
     m_frmMain      = frmMain;
     m_treeListView = m_frmMain.treeListView1;
     CreateColumns();
     CanExpandGetter(m_treeListView);
     ChildrenGetter(m_treeListView);
     SetupColumnsText();
     SetupColumpsImage();
     m_treeListView.SelectionChanged += treeListView_SelectionChanged;
 }
 public TreeViewSetuper2(frmMain frmMain)
 {
     m_frmMain       = frmMain;
     m_treeListView2 = m_frmMain.treeListView2;
     CreateColumns();
     CanExpandGetter(m_treeListView2);
     ChildrenGetter(m_treeListView2);
     SetupColumnsText();
     SetupColumnsImage();
     m_treeListView2.SelectionChanged += m_treeListView2_SelectionChanged;
 }
        public static BrightIdeasSoftware.TreeListView CreateTreeListView()
        {
            BrightIdeasSoftware.TreeListView treeListView = new BrightIdeasSoftware.TreeListView();

            treeListView.Location = new System.Drawing.Point(310, 100);
            treeListView.Size     = new System.Drawing.Size(500, 325);
            treeListView.Anchor   = (AnchorStyles.Top | AnchorStyles.Left);
            treeListView.UseAlternatingBackColors = true;
            treeListView.AlternateRowBackColor    = System.Drawing.Color.FromArgb(242, 242, 242);
            treeListView.CheckBoxes        = true;
            treeListView.CheckedAspectName = "Ticked";

            return(treeListView);
        }
 private void CanExpandGetter(BrightIdeasSoftware.TreeListView mytreeListView)
 {
     mytreeListView.CanExpandGetter = delegate(object x)
     {
         if (x is Project || x is LampCircuit || x is Cable || x is JunctionBox || x is Socket)
         {
             return(true);
         }
         else
         {
             return(false);
         }
         //return x is StromKreis;
     };
 }
 private void CanExpandGetter(BrightIdeasSoftware.TreeListView mytreeListView)
 {
     mytreeListView.CanExpandGetter = delegate(object x)
     {
         if (x is Inputs || x is Outputs || x is Tools || x is Document || x is Tool)
         {
             return(true);
         }
         else
         {
             return(false);
         }
         //return x is StromKreis;
     };
 }
Exemple #11
0
        public static BrightIdeasSoftware.TreeListView CreateTreeListView()
        {
            BrightIdeasSoftware.TreeListView treeListView = new BrightIdeasSoftware.TreeListView();

            treeListView.Location = new System.Drawing.Point(20, 100);
            treeListView.Size     = new System.Drawing.Size(275, 325);
            treeListView.Anchor   = (AnchorStyles.Top | AnchorStyles.Left);
            treeListView.UseAlternatingBackColors = true;
            treeListView.AlternateRowBackColor    = System.Drawing.Color.FromArgb(242, 242, 242);
            treeListView.CheckBoxes        = false;
            treeListView.CheckedAspectName = "Ticked";
            treeListView.ExpandAll();

            //need to create an image list and assign this to "SmallImageList"

            return(treeListView);
        }
 private void ChildrenGetter(BrightIdeasSoftware.TreeListView mytreeListView)
 {
     mytreeListView.ChildrenGetter = delegate(object x)
     {
         try
         {
             if (x is Project project)
             {
                 return(project.Items);
             }
             if (x is LampCircuit lampCircuit)
             {
                 return(lampCircuit.Items);
             }
             if (x is Cable cable)
             {
                 return(cable.Items);
             }
             if (x is JunctionBox junctionBox)
             {
                 return(junctionBox.Items.OrderBy(o => o.BMK).ToList());
             }
             if (x is Socket socket)
             {
                 return(socket.Items);
             }
             else
             {
                 return(new ArrayList());
             }
         }
         catch (UnauthorizedAccessException ex)
         {
             //this.BeginInvoke((MethodInvoker)delegate ()
             //{
             mytreeListView.Collapse(x);
             //    MessageBox.Show(this, ex.Message, "ObjectListViewDemo", MessageBoxButtons.OK, MessageBoxIcon.Exclamation);
             //});
             return(new ArrayList());
         }
     };
 }
 private void InitializeComponent()
 {
     this.olvTree = new BrightIdeasSoftware.TreeListView();
     this.olvName = ((BrightIdeasSoftware.OLVColumn)(new BrightIdeasSoftware.OLVColumn()));
     ((System.ComponentModel.ISupportInitialize)(this.olvTree)).BeginInit();
     this.SuspendLayout();
     //
     // olvRecent
     //
     this.olvTree.AllColumns.Add(this.olvName);
     this.olvTree.CellEditUseWholeCell = false;
     this.olvTree.Columns.AddRange(new System.Windows.Forms.ColumnHeader[] {
         this.olvName
     });
     this.olvTree.Cursor        = System.Windows.Forms.Cursors.Default;
     this.olvTree.Dock          = System.Windows.Forms.DockStyle.Fill;
     this.olvTree.FullRowSelect = true;
     this.olvTree.HideSelection = false;
     this.olvTree.Location      = new System.Drawing.Point(0, 0);
     this.olvTree.Name          = "olvRecent";
     this.olvTree.RowHeight     = 19;
     this.olvTree.ShowGroups    = false;
     this.olvTree.Size          = new System.Drawing.Size(487, 518);
     this.olvTree.TabIndex      = 4;
     this.olvTree.UseCompatibleStateImageBehavior = false;
     this.olvTree.View        = System.Windows.Forms.View.Details;
     this.olvTree.VirtualMode = true;
     //
     // olvName
     //
     this.olvName.Groupable = false;
     this.olvName.Text      = "Name";
     //
     // SessionCollectionUI
     //
     this.Controls.Add(this.olvTree);
     this.Name = "SessionCollectionUI";
     this.Size = new System.Drawing.Size(487, 518);
     ((System.ComponentModel.ISupportInitialize)(this.olvTree)).EndInit();
     this.ResumeLayout(false);
 }
        /// <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();
            BrightIdeasSoftware.HeaderStateStyle headerStateStyle1 = new BrightIdeasSoftware.HeaderStateStyle();
            BrightIdeasSoftware.HeaderStateStyle headerStateStyle2 = new BrightIdeasSoftware.HeaderStateStyle();
            BrightIdeasSoftware.HeaderStateStyle headerStateStyle3 = new BrightIdeasSoftware.HeaderStateStyle();
            System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(MainForm));
            this.btnParse = new System.Windows.Forms.Button();
            this.headerFormatStyle1 = new BrightIdeasSoftware.HeaderFormatStyle();
            this.treeListView1 = new BrightIdeasSoftware.TreeListView();
            this.colName = ((BrightIdeasSoftware.OLVColumn)(new BrightIdeasSoftware.OLVColumn()));
            this.colId = ((BrightIdeasSoftware.OLVColumn)(new BrightIdeasSoftware.OLVColumn()));
            this.colValue = ((BrightIdeasSoftware.OLVColumn)(new BrightIdeasSoftware.OLVColumn()));
            this.lblMessageType = new System.Windows.Forms.Label();
            this.lblMessageVersion = new System.Windows.Forms.Label();
            this.tbMessage = new System.Windows.Forms.TextBox();
            this.tbVersion = new System.Windows.Forms.TextBox();
            this.label1 = new System.Windows.Forms.Label();
            ((System.ComponentModel.ISupportInitialize)(this.treeListView1)).BeginInit();
            this.SuspendLayout();
            // 
            // btnParse
            // 
            this.btnParse.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
            this.btnParse.Location = new System.Drawing.Point(621, 3);
            this.btnParse.Name = "btnParse";
            this.btnParse.Size = new System.Drawing.Size(75, 23);
            this.btnParse.TabIndex = 0;
            this.btnParse.Text = "Parse";
            this.btnParse.UseVisualStyleBackColor = true;
            this.btnParse.Click += new System.EventHandler(this.btnParse_Click);
            // 
            // headerFormatStyle1
            // 
            this.headerFormatStyle1.Hot = headerStateStyle1;
            this.headerFormatStyle1.Normal = headerStateStyle2;
            this.headerFormatStyle1.Pressed = headerStateStyle3;
            // 
            // treeListView1
            // 
            this.treeListView1.AllColumns.Add(this.colName);
            this.treeListView1.AllColumns.Add(this.colId);
            this.treeListView1.AllColumns.Add(this.colValue);
            this.treeListView1.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.treeListView1.CheckBoxes = false;
            this.treeListView1.Columns.AddRange(new System.Windows.Forms.ColumnHeader[] {
            this.colName,
            this.colId,
            this.colValue});
            this.treeListView1.FullRowSelect = true;
            this.treeListView1.GridLines = true;
            this.treeListView1.Location = new System.Drawing.Point(11, 253);
            this.treeListView1.Name = "treeListView1";
            this.treeListView1.OwnerDraw = true;
            this.treeListView1.ShowGroups = false;
            this.treeListView1.Size = new System.Drawing.Size(685, 300);
            this.treeListView1.TabIndex = 6;
            this.treeListView1.UseCompatibleStateImageBehavior = false;
            this.treeListView1.View = System.Windows.Forms.View.Details;
            this.treeListView1.VirtualMode = true;
            // 
            // colName
            // 
            this.colName.AspectName = "Name";
            this.colName.Text = "Name";
            this.colName.Width = 240;
            // 
            // colId
            // 
            this.colId.AspectName = "Id";
            this.colId.Text = "Id";
            // 
            // colValue
            // 
            this.colValue.AspectName = "Value";
            this.colValue.FillsFreeSpace = true;
            this.colValue.Text = "Value";
            this.colValue.Width = 180;
            // 
            // lblMessageType
            // 
            this.lblMessageType.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) 
            | System.Windows.Forms.AnchorStyles.Left)));
            this.lblMessageType.AutoSize = true;
            this.lblMessageType.Location = new System.Drawing.Point(11, 233);
            this.lblMessageType.Name = "lblMessageType";
            this.lblMessageType.Size = new System.Drawing.Size(0, 13);
            this.lblMessageType.TabIndex = 7;
            this.lblMessageType.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
            // 
            // lblMessageVersion
            // 
            this.lblMessageVersion.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) 
            | System.Windows.Forms.AnchorStyles.Right)));
            this.lblMessageVersion.AutoSize = true;
            this.lblMessageVersion.Location = new System.Drawing.Point(642, 232);
            this.lblMessageVersion.Name = "lblMessageVersion";
            this.lblMessageVersion.RightToLeft = System.Windows.Forms.RightToLeft.No;
            this.lblMessageVersion.Size = new System.Drawing.Size(0, 13);
            this.lblMessageVersion.TabIndex = 8;
            this.lblMessageVersion.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
            // 
            // tbMessage
            // 
            this.tbMessage.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.tbMessage.Font = new System.Drawing.Font("Courier New", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
            this.tbMessage.Location = new System.Drawing.Point(14, 32);
            this.tbMessage.MaximumSize = new System.Drawing.Size(10000, 197);
            this.tbMessage.Multiline = true;
            this.tbMessage.Name = "tbMessage";
            this.tbMessage.ScrollBars = System.Windows.Forms.ScrollBars.Both;
            this.tbMessage.Size = new System.Drawing.Size(681, 197);
            this.tbMessage.TabIndex = 9;
            this.tbMessage.WordWrap = false;
            this.tbMessage.TextChanged += new System.EventHandler(this.tbMessage_TextChanged);
            // 
            // tbVersion
            // 
            this.tbVersion.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
            this.tbVersion.Location = new System.Drawing.Point(515, 5);
            this.tbVersion.Name = "tbVersion";
            this.tbVersion.Size = new System.Drawing.Size(100, 20);
            this.tbVersion.TabIndex = 10;
            // 
            // label1
            // 
            this.label1.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
            this.label1.AutoSize = true;
            this.label1.Location = new System.Drawing.Point(466, 8);
            this.label1.Name = "label1";
            this.label1.Size = new System.Drawing.Size(45, 13);
            this.label1.TabIndex = 11;
            this.label1.Text = "Version:";
            // 
            // MainForm
            // 
            this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
            this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
            this.ClientSize = new System.Drawing.Size(709, 575);
            this.Controls.Add(this.label1);
            this.Controls.Add(this.tbVersion);
            this.Controls.Add(this.tbMessage);
            this.Controls.Add(this.lblMessageVersion);
            this.Controls.Add(this.lblMessageType);
            this.Controls.Add(this.treeListView1);
            this.Controls.Add(this.btnParse);
            this.Icon = ((System.Drawing.Icon)(resources.GetObject("$this.Icon")));
            this.Name = "MainForm";
            this.Text = "NHapi HL7 Snoop";
            ((System.ComponentModel.ISupportInitialize)(this.treeListView1)).EndInit();
            this.ResumeLayout(false);
            this.PerformLayout();

        }
 public CheckedTreeViewHelper( BrightIdeasSoftware.TreeListView treeView )
 {
     mTreeView = treeView;
     mTreeView.CheckStateGetter = new BrightIdeasSoftware.CheckStateGetterDelegate( CheckStateGetterMethod );
     mTreeView.CheckStatePutter = new BrightIdeasSoftware.CheckStatePutterDelegate( CheckStateSetterMethod );
 }
		private void InitializeComponent()
		{
            this.components = new System.ComponentModel.Container();
            this.olvConnections = new BrightIdeasSoftware.TreeListView();
            this.olvNameColumn = ((BrightIdeasSoftware.OLVColumn)(new BrightIdeasSoftware.OLVColumn()));
            this.imgListTree = new System.Windows.Forms.ImageList(this.components);
            this.pnlConnections = new System.Windows.Forms.Panel();
            this.PictureBox1 = new System.Windows.Forms.PictureBox();
            this.txtSearch = new System.Windows.Forms.TextBox();
            this.msMain = new System.Windows.Forms.MenuStrip();
            this.mMenAddConnection = new System.Windows.Forms.ToolStripMenuItem();
            this.mMenAddFolder = new System.Windows.Forms.ToolStripMenuItem();
            this.mMenView = new System.Windows.Forms.ToolStripMenuItem();
            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();
            // 
            // olvConnections
            // 
            this.olvConnections.AllColumns.Add(this.olvNameColumn);
            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.Columns.AddRange(new System.Windows.Forms.ColumnHeader[] {
            this.olvNameColumn});
            this.olvConnections.Cursor = System.Windows.Forms.Cursors.Default;
            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.MultiSelect = false;
            this.olvConnections.Name = "olvConnections";
            this.olvConnections.SelectedBackColor = System.Drawing.SystemColors.Highlight;
            this.olvConnections.SelectedForeColor = System.Drawing.SystemColors.HighlightText;
            this.olvConnections.ShowGroups = false;
            this.olvConnections.Size = new System.Drawing.Size(192, 410);
            this.olvConnections.SmallImageList = this.imgListTree;
            this.olvConnections.TabIndex = 20;
            this.olvConnections.UnfocusedSelectedBackColor = System.Drawing.SystemColors.Highlight;
            this.olvConnections.UnfocusedSelectedForeColor = System.Drawing.SystemColors.HighlightText;
            this.olvConnections.UseCompatibleStateImageBehavior = false;
            this.olvConnections.View = System.Windows.Forms.View.Details;
            this.olvConnections.VirtualMode = true;
            // 
            // olvNameColumn
            // 
            this.olvNameColumn.AspectName = "Name";
            this.olvNameColumn.FillsFreeSpace = true;
            this.olvNameColumn.IsButton = true;
            // 
            // imgListTree
            // 
            this.imgListTree.ColorDepth = System.Windows.Forms.ColorDepth.Depth32Bit;
            this.imgListTree.ImageSize = new System.Drawing.Size(16, 16);
            this.imgListTree.TransparentColor = System.Drawing.Color.Transparent;
            // 
            // 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)));
            this.msMain.Items.AddRange(new System.Windows.Forms.ToolStripItem[] {
            this.mMenAddConnection,
            this.mMenAddFolder,
            this.mMenView,
            this.mMenSortAscending});
            this.msMain.Location = new System.Drawing.Point(0, 0);
            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.TabIndex = 10;
            this.msMain.Text = "MenuStrip1";
            // 
            // mMenAddConnection
            // 
            this.mMenAddConnection.DisplayStyle = System.Windows.Forms.ToolStripItemDisplayStyle.Image;
            this.mMenAddConnection.Image = global::mRemoteNG.Resources.Connection_Add;
            this.mMenAddConnection.Name = "mMenAddConnection";
            this.mMenAddConnection.Size = new System.Drawing.Size(28, 20);
            this.mMenAddConnection.Click += new System.EventHandler(this.cMenTreeAddConnection_Click);
            // 
            // mMenAddFolder
            // 
            this.mMenAddFolder.DisplayStyle = System.Windows.Forms.ToolStripItemDisplayStyle.Image;
            this.mMenAddFolder.Image = global::mRemoteNG.Resources.Folder_Add;
            this.mMenAddFolder.Name = "mMenAddFolder";
            this.mMenAddFolder.Size = new System.Drawing.Size(28, 20);
            this.mMenAddFolder.Click += new System.EventHandler(this.cMenTreeAddFolder_Click);
            // 
            // mMenView
            // 
            this.mMenView.DisplayStyle = System.Windows.Forms.ToolStripItemDisplayStyle.Image;
            this.mMenView.DropDownItems.AddRange(new System.Windows.Forms.ToolStripItem[] {
            this.mMenViewExpandAllFolders,
            this.mMenViewCollapseAllFolders});
            this.mMenView.Image = global::mRemoteNG.Resources.View;
            this.mMenView.Name = "mMenView";
            this.mMenView.Size = new System.Drawing.Size(28, 20);
            this.mMenView.Text = "&View";
            // 
            // mMenViewExpandAllFolders
            // 
            this.mMenViewExpandAllFolders.Image = global::mRemoteNG.Resources.Expand;
            this.mMenViewExpandAllFolders.Name = "mMenViewExpandAllFolders";
            this.mMenViewExpandAllFolders.Size = new System.Drawing.Size(172, 22);
            this.mMenViewExpandAllFolders.Text = "Expand all folders";
            // 
            // mMenViewCollapseAllFolders
            // 
            this.mMenViewCollapseAllFolders.Image = global::mRemoteNG.Resources.Collapse;
            this.mMenViewCollapseAllFolders.Name = "mMenViewCollapseAllFolders";
            this.mMenViewCollapseAllFolders.Size = new System.Drawing.Size(172, 22);
            this.mMenViewCollapseAllFolders.Text = "Collapse all folders";
            // 
            // mMenSortAscending
            // 
            this.mMenSortAscending.DisplayStyle = System.Windows.Forms.ToolStripItemDisplayStyle.Image;
            this.mMenSortAscending.Image = global::mRemoteNG.Resources.Sort_AZ;
            this.mMenSortAscending.Name = "mMenSortAscending";
            this.mMenSortAscending.Size = new System.Drawing.Size(28, 20);
            // 
            // ConnectionTreeWindow
            // 
            this.ClientSize = new System.Drawing.Size(192, 453);
            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;
            this.Name = "ConnectionTreeWindow";
            this.TabText = "Connections";
            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.ResumeLayout(false);
            this.PerformLayout();

		}
 public CheckedTreeViewHelper(BrightIdeasSoftware.TreeListView treeView)
 {
     mTreeView = treeView;
     mTreeView.CheckStateGetter = new BrightIdeasSoftware.CheckStateGetterDelegate(CheckStateGetterMethod);
     mTreeView.CheckStatePutter = new BrightIdeasSoftware.CheckStatePutterDelegate(CheckStateSetterMethod);
 }
Exemple #18
0
 /// <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();
     BrightIdeasSoftware.HeaderStateStyle           headerStateStyle1 = new BrightIdeasSoftware.HeaderStateStyle();
     BrightIdeasSoftware.HeaderStateStyle           headerStateStyle2 = new BrightIdeasSoftware.HeaderStateStyle();
     BrightIdeasSoftware.HeaderStateStyle           headerStateStyle3 = new BrightIdeasSoftware.HeaderStateStyle();
     System.ComponentModel.ComponentResourceManager resources         = new System.ComponentModel.ComponentResourceManager(typeof(MainForm));
     this.btnParse           = new System.Windows.Forms.Button();
     this.headerFormatStyle1 = new BrightIdeasSoftware.HeaderFormatStyle();
     this.treeListView1      = new BrightIdeasSoftware.TreeListView();
     this.colName            = ((BrightIdeasSoftware.OLVColumn)(new BrightIdeasSoftware.OLVColumn()));
     this.colId               = ((BrightIdeasSoftware.OLVColumn)(new BrightIdeasSoftware.OLVColumn()));
     this.colValue            = ((BrightIdeasSoftware.OLVColumn)(new BrightIdeasSoftware.OLVColumn()));
     this.lblMessageType      = new System.Windows.Forms.Label();
     this.lblMessageVersion   = new System.Windows.Forms.Label();
     this.tbMessage           = new System.Windows.Forms.TextBox();
     this.tbVersion           = new System.Windows.Forms.TextBox();
     this.label1              = new System.Windows.Forms.Label();
     this.checkBoxEmptyFields = new System.Windows.Forms.CheckBox();
     ((System.ComponentModel.ISupportInitialize)(this.treeListView1)).BeginInit();
     this.SuspendLayout();
     //
     // btnParse
     //
     this.btnParse.Anchor   = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
     this.btnParse.Location = new System.Drawing.Point(621, 3);
     this.btnParse.Name     = "btnParse";
     this.btnParse.Size     = new System.Drawing.Size(75, 23);
     this.btnParse.TabIndex = 0;
     this.btnParse.Text     = "Parse";
     this.btnParse.UseVisualStyleBackColor = true;
     this.btnParse.Click += new System.EventHandler(this.btnParse_Click);
     //
     // headerFormatStyle1
     //
     this.headerFormatStyle1.Hot     = headerStateStyle1;
     this.headerFormatStyle1.Normal  = headerStateStyle2;
     this.headerFormatStyle1.Pressed = headerStateStyle3;
     //
     // treeListView1
     //
     this.treeListView1.AllColumns.Add(this.colName);
     this.treeListView1.AllColumns.Add(this.colId);
     this.treeListView1.AllColumns.Add(this.colValue);
     this.treeListView1.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.treeListView1.CellEditUseWholeCell = false;
     this.treeListView1.Columns.AddRange(new System.Windows.Forms.ColumnHeader[] {
         this.colName,
         this.colId,
         this.colValue
     });
     this.treeListView1.FullRowSelect = true;
     this.treeListView1.GridLines     = true;
     this.treeListView1.Location      = new System.Drawing.Point(11, 253);
     this.treeListView1.Name          = "treeListView1";
     this.treeListView1.ShowGroups    = false;
     this.treeListView1.Size          = new System.Drawing.Size(685, 300);
     this.treeListView1.TabIndex      = 6;
     this.treeListView1.UseCompatibleStateImageBehavior = false;
     this.treeListView1.View        = System.Windows.Forms.View.Details;
     this.treeListView1.VirtualMode = true;
     //
     // colName
     //
     this.colName.AspectName = "Name";
     this.colName.Text       = "Name";
     this.colName.Width      = 240;
     //
     // colId
     //
     this.colId.AspectName = "Id";
     this.colId.Text       = "Id";
     //
     // colValue
     //
     this.colValue.AspectName     = "Value";
     this.colValue.FillsFreeSpace = true;
     this.colValue.Text           = "Value";
     this.colValue.Width          = 180;
     //
     // lblMessageType
     //
     this.lblMessageType.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
                                                                        | System.Windows.Forms.AnchorStyles.Left)));
     this.lblMessageType.AutoSize  = true;
     this.lblMessageType.Location  = new System.Drawing.Point(11, 233);
     this.lblMessageType.Name      = "lblMessageType";
     this.lblMessageType.Size      = new System.Drawing.Size(0, 13);
     this.lblMessageType.TabIndex  = 7;
     this.lblMessageType.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
     //
     // lblMessageVersion
     //
     this.lblMessageVersion.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
                                                                           | System.Windows.Forms.AnchorStyles.Right)));
     this.lblMessageVersion.AutoSize    = true;
     this.lblMessageVersion.Location    = new System.Drawing.Point(642, 232);
     this.lblMessageVersion.Name        = "lblMessageVersion";
     this.lblMessageVersion.RightToLeft = System.Windows.Forms.RightToLeft.No;
     this.lblMessageVersion.Size        = new System.Drawing.Size(0, 13);
     this.lblMessageVersion.TabIndex    = 8;
     this.lblMessageVersion.TextAlign   = System.Drawing.ContentAlignment.MiddleRight;
     //
     // tbMessage
     //
     this.tbMessage.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.tbMessage.Font         = new System.Drawing.Font("Courier New", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
     this.tbMessage.Location     = new System.Drawing.Point(14, 32);
     this.tbMessage.MaximumSize  = new System.Drawing.Size(10000, 197);
     this.tbMessage.Multiline    = true;
     this.tbMessage.Name         = "tbMessage";
     this.tbMessage.ScrollBars   = System.Windows.Forms.ScrollBars.Both;
     this.tbMessage.Size         = new System.Drawing.Size(681, 197);
     this.tbMessage.TabIndex     = 9;
     this.tbMessage.WordWrap     = false;
     this.tbMessage.TextChanged += new System.EventHandler(this.tbMessage_TextChanged);
     //
     // tbVersion
     //
     this.tbVersion.Anchor   = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
     this.tbVersion.Location = new System.Drawing.Point(515, 5);
     this.tbVersion.Name     = "tbVersion";
     this.tbVersion.Size     = new System.Drawing.Size(100, 20);
     this.tbVersion.TabIndex = 10;
     //
     // label1
     //
     this.label1.Anchor   = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
     this.label1.AutoSize = true;
     this.label1.Location = new System.Drawing.Point(466, 8);
     this.label1.Name     = "label1";
     this.label1.Size     = new System.Drawing.Size(45, 13);
     this.label1.TabIndex = 11;
     this.label1.Text     = "Version:";
     //
     // checkBoxEmptyFields
     //
     this.checkBoxEmptyFields.Anchor   = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
     this.checkBoxEmptyFields.AutoSize = true;
     this.checkBoxEmptyFields.Location = new System.Drawing.Point(342, 7);
     this.checkBoxEmptyFields.Name     = "checkBoxEmptyFields";
     this.checkBoxEmptyFields.Size     = new System.Drawing.Size(119, 17);
     this.checkBoxEmptyFields.TabIndex = 12;
     this.checkBoxEmptyFields.Text     = "Display Empty fields";
     this.checkBoxEmptyFields.UseVisualStyleBackColor = true;
     //
     // MainForm
     //
     this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
     this.AutoScaleMode       = System.Windows.Forms.AutoScaleMode.Font;
     this.ClientSize          = new System.Drawing.Size(709, 575);
     this.Controls.Add(this.checkBoxEmptyFields);
     this.Controls.Add(this.label1);
     this.Controls.Add(this.tbVersion);
     this.Controls.Add(this.tbMessage);
     this.Controls.Add(this.lblMessageVersion);
     this.Controls.Add(this.lblMessageType);
     this.Controls.Add(this.treeListView1);
     this.Controls.Add(this.btnParse);
     this.Icon = ((System.Drawing.Icon)(resources.GetObject("$this.Icon")));
     this.Name = "MainForm";
     this.Text = "NHapi HL7 Snoop";
     ((System.ComponentModel.ISupportInitialize)(this.treeListView1)).EndInit();
     this.ResumeLayout(false);
     this.PerformLayout();
 }
 /// <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(Window));
     this.structureTreeListView = new BrightIdeasSoftware.TreeListView();
     this.fieldColumn = ((BrightIdeasSoftware.OLVColumn)(new BrightIdeasSoftware.OLVColumn()));
     this.valueColumn = ((BrightIdeasSoftware.OLVColumn)(new BrightIdeasSoftware.OLVColumn()));
     this.actualValueColumn = ((BrightIdeasSoftware.OLVColumn)(new BrightIdeasSoftware.OLVColumn()));
     this.descriptionColumn = ((BrightIdeasSoftware.OLVColumn)(new BrightIdeasSoftware.OLVColumn()));
     ((System.ComponentModel.ISupportInitialize)(this.structureTreeListView)).BeginInit();
     this.SuspendLayout();
     //
     // structureTreeListView
     //
     this.structureTreeListView.AllColumns.Add(this.fieldColumn);
     this.structureTreeListView.AllColumns.Add(this.valueColumn);
     this.structureTreeListView.AllColumns.Add(this.actualValueColumn);
     this.structureTreeListView.AllColumns.Add(this.descriptionColumn);
     this.structureTreeListView.CellEditActivation = BrightIdeasSoftware.ObjectListView.CellEditActivateMode.SingleClick;
     this.structureTreeListView.CellEditEnterChangesRows = true;
     this.structureTreeListView.CellEditTabChangesRows = true;
     this.structureTreeListView.Columns.AddRange(new System.Windows.Forms.ColumnHeader[] {
     this.fieldColumn,
     this.valueColumn,
     this.actualValueColumn,
     this.descriptionColumn});
     this.structureTreeListView.Dock = System.Windows.Forms.DockStyle.Fill;
     this.structureTreeListView.Location = new System.Drawing.Point(0, 0);
     this.structureTreeListView.Name = "structureTreeListView";
     this.structureTreeListView.OwnerDraw = true;
     this.structureTreeListView.ShowGroups = false;
     this.structureTreeListView.Size = new System.Drawing.Size(1100, 446);
     this.structureTreeListView.TabIndex = 0;
     this.structureTreeListView.UseCellFormatEvents = true;
     this.structureTreeListView.UseCompatibleStateImageBehavior = false;
     this.structureTreeListView.View = System.Windows.Forms.View.Details;
     this.structureTreeListView.VirtualMode = true;
     //
     // fieldColumn
     //
     this.fieldColumn.AspectName = "";
     this.fieldColumn.CellPadding = null;
     this.fieldColumn.IsEditable = false;
     this.fieldColumn.Text = "Field name";
     this.fieldColumn.ToolTipText = "The name of the field";
     this.fieldColumn.Width = 180;
     //
     // valueColumn
     //
     this.valueColumn.AspectName = "";
     this.valueColumn.CellPadding = null;
     this.valueColumn.Text = "Value";
     this.valueColumn.Width = 180;
     //
     // actualValueColumn
     //
     this.actualValueColumn.CellPadding = null;
     this.actualValueColumn.IsEditable = false;
     this.actualValueColumn.Text = "Actual value";
     this.actualValueColumn.Width = 180;
     //
     // descriptionColumn
     //
     this.descriptionColumn.AspectName = "";
     this.descriptionColumn.CellPadding = null;
     this.descriptionColumn.FillsFreeSpace = true;
     this.descriptionColumn.IsEditable = false;
     this.descriptionColumn.Text = "Description";
     this.descriptionColumn.Width = 400;
     //
     // Window
     //
     this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
     this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
     this.ClientSize = new System.Drawing.Size(1100, 446);
     this.Controls.Add(this.structureTreeListView);
     this.Font = new System.Drawing.Font("Microsoft Sans Serif", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
     this.Icon = ((System.Drawing.Icon)(resources.GetObject("$this.Icon")));
     this.Name = "Window";
     this.Text = "Structure Editor";
     ((System.ComponentModel.ISupportInitialize)(this.structureTreeListView)).EndInit();
     this.ResumeLayout(false);
 }
 private void InitializeComponent()
 {
     this.components                 = new System.ComponentModel.Container();
     this.olvConnections             = new BrightIdeasSoftware.TreeListView();
     this.olvNameColumn              = ((BrightIdeasSoftware.OLVColumn)(new BrightIdeasSoftware.OLVColumn()));
     this.imgListTree                = new System.Windows.Forms.ImageList(this.components);
     this.pnlConnections             = new System.Windows.Forms.Panel();
     this.PictureBox1                = new System.Windows.Forms.PictureBox();
     this.txtSearch                  = new System.Windows.Forms.TextBox();
     this.msMain                     = new System.Windows.Forms.MenuStrip();
     this.mMenAddConnection          = new System.Windows.Forms.ToolStripMenuItem();
     this.mMenAddFolder              = new System.Windows.Forms.ToolStripMenuItem();
     this.mMenView                   = new System.Windows.Forms.ToolStripMenuItem();
     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();
     //
     // olvConnections
     //
     this.olvConnections.AllColumns.Add(this.olvNameColumn);
     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.Columns.AddRange(new System.Windows.Forms.ColumnHeader[] {
         this.olvNameColumn
     });
     this.olvConnections.Cursor             = System.Windows.Forms.Cursors.Default;
     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.MultiSelect        = false;
     this.olvConnections.Name = "olvConnections";
     this.olvConnections.SelectedBackColor = System.Drawing.SystemColors.Highlight;
     this.olvConnections.SelectedForeColor = System.Drawing.SystemColors.HighlightText;
     this.olvConnections.ShowGroups        = false;
     this.olvConnections.Size                            = new System.Drawing.Size(192, 410);
     this.olvConnections.SmallImageList                  = this.imgListTree;
     this.olvConnections.TabIndex                        = 20;
     this.olvConnections.UnfocusedSelectedBackColor      = System.Drawing.SystemColors.Highlight;
     this.olvConnections.UnfocusedSelectedForeColor      = System.Drawing.SystemColors.HighlightText;
     this.olvConnections.UseCompatibleStateImageBehavior = false;
     this.olvConnections.View                            = System.Windows.Forms.View.Details;
     this.olvConnections.VirtualMode                     = true;
     //
     // olvNameColumn
     //
     this.olvNameColumn.AspectName     = "Name";
     this.olvNameColumn.FillsFreeSpace = true;
     this.olvNameColumn.IsButton       = true;
     //
     // imgListTree
     //
     this.imgListTree.ColorDepth       = System.Windows.Forms.ColorDepth.Depth32Bit;
     this.imgListTree.ImageSize        = new System.Drawing.Size(16, 16);
     this.imgListTree.TransparentColor = System.Drawing.Color.Transparent;
     //
     // 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)));
     this.msMain.Items.AddRange(new System.Windows.Forms.ToolStripItem[] {
         this.mMenAddConnection,
         this.mMenAddFolder,
         this.mMenView,
         this.mMenSortAscending
     });
     this.msMain.Location         = new System.Drawing.Point(0, 0);
     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.TabIndex         = 10;
     this.msMain.Text             = "MenuStrip1";
     //
     // mMenAddConnection
     //
     this.mMenAddConnection.DisplayStyle = System.Windows.Forms.ToolStripItemDisplayStyle.Image;
     this.mMenAddConnection.Image        = global::mRemoteNG.Resources.Connection_Add;
     this.mMenAddConnection.Name         = "mMenAddConnection";
     this.mMenAddConnection.Size         = new System.Drawing.Size(28, 20);
     this.mMenAddConnection.Click       += new System.EventHandler(this.cMenTreeAddConnection_Click);
     //
     // mMenAddFolder
     //
     this.mMenAddFolder.DisplayStyle = System.Windows.Forms.ToolStripItemDisplayStyle.Image;
     this.mMenAddFolder.Image        = global::mRemoteNG.Resources.Folder_Add;
     this.mMenAddFolder.Name         = "mMenAddFolder";
     this.mMenAddFolder.Size         = new System.Drawing.Size(28, 20);
     this.mMenAddFolder.Click       += new System.EventHandler(this.cMenTreeAddFolder_Click);
     //
     // mMenView
     //
     this.mMenView.DisplayStyle = System.Windows.Forms.ToolStripItemDisplayStyle.Image;
     this.mMenView.DropDownItems.AddRange(new System.Windows.Forms.ToolStripItem[] {
         this.mMenViewExpandAllFolders,
         this.mMenViewCollapseAllFolders
     });
     this.mMenView.Image = global::mRemoteNG.Resources.View;
     this.mMenView.Name  = "mMenView";
     this.mMenView.Size  = new System.Drawing.Size(28, 20);
     this.mMenView.Text  = "&View";
     //
     // mMenViewExpandAllFolders
     //
     this.mMenViewExpandAllFolders.Image = global::mRemoteNG.Resources.Expand;
     this.mMenViewExpandAllFolders.Name  = "mMenViewExpandAllFolders";
     this.mMenViewExpandAllFolders.Size  = new System.Drawing.Size(172, 22);
     this.mMenViewExpandAllFolders.Text  = "Expand all folders";
     //
     // mMenViewCollapseAllFolders
     //
     this.mMenViewCollapseAllFolders.Image = global::mRemoteNG.Resources.Collapse;
     this.mMenViewCollapseAllFolders.Name  = "mMenViewCollapseAllFolders";
     this.mMenViewCollapseAllFolders.Size  = new System.Drawing.Size(172, 22);
     this.mMenViewCollapseAllFolders.Text  = "Collapse all folders";
     //
     // mMenSortAscending
     //
     this.mMenSortAscending.DisplayStyle = System.Windows.Forms.ToolStripItemDisplayStyle.Image;
     this.mMenSortAscending.Image        = global::mRemoteNG.Resources.Sort_AZ;
     this.mMenSortAscending.Name         = "mMenSortAscending";
     this.mMenSortAscending.Size         = new System.Drawing.Size(28, 20);
     //
     // ConnectionTreeWindow
     //
     this.ClientSize = new System.Drawing.Size(192, 453);
     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;
     this.Name        = "ConnectionTreeWindow";
     this.TabText     = "Connections";
     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.ResumeLayout(false);
     this.PerformLayout();
 }
 private void AddTree()
 {
     treeListView      = new BrightIdeasSoftware.TreeListView();
     treeListView.Dock = DockStyle.Fill;
     this.Controls.Add(treeListView);
 }