From 7c68097b0f82d3efd6a31c651175d33c056df89c Mon Sep 17 00:00:00 2001 From: Jonas Rapp Date: Sun, 26 Sep 2021 12:18:18 +0200 Subject: [PATCH] Added tree builder menu to show metadata --- .../DockControls/TreeBuilderControl.cs | 5 ++++ .../TreeBuilderControl.designer.cs | 24 ++++++++++++++++-- .../DockControls/TreeBuilderControl.resx | 25 +++++++++++++++++++ FetchXmlBuilder/FetchXmlBuilder.cs | 5 ++++ 4 files changed, 57 insertions(+), 2 deletions(-) diff --git a/FetchXmlBuilder/DockControls/TreeBuilderControl.cs b/FetchXmlBuilder/DockControls/TreeBuilderControl.cs index 5ceeabda..4204f84e 100644 --- a/FetchXmlBuilder/DockControls/TreeBuilderControl.cs +++ b/FetchXmlBuilder/DockControls/TreeBuilderControl.cs @@ -958,6 +958,11 @@ private void tvFetch_NodeMouseClick(object sender, TreeNodeMouseClickEventArgs e } } + private void showMetadataToolStripMenuItem_Click(object sender, EventArgs e) + { + fxb.ShowMetadataControl(); + } + #endregion Control Event Handlers } } \ No newline at end of file diff --git a/FetchXmlBuilder/DockControls/TreeBuilderControl.designer.cs b/FetchXmlBuilder/DockControls/TreeBuilderControl.designer.cs index 9a0f4368..b2579438 100644 --- a/FetchXmlBuilder/DockControls/TreeBuilderControl.designer.cs +++ b/FetchXmlBuilder/DockControls/TreeBuilderControl.designer.cs @@ -29,6 +29,7 @@ protected override void Dispose(bool disposing) private void InitializeComponent() { this.components = new System.ComponentModel.Container(); + System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(TreeBuilderControl)); this.splitContainer1 = new System.Windows.Forms.SplitContainer(); this.tvFetch = new System.Windows.Forms.TreeView(); this.panProperties = new System.Windows.Forms.Panel(); @@ -52,6 +53,8 @@ private void InitializeComponent() this.moveUpToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); this.moveDownToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); this.tt = new System.Windows.Forms.ToolTip(this.components); + this.toolStripSeparator1 = new System.Windows.Forms.ToolStripSeparator(); + this.showMetadataToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); ((System.ComponentModel.ISupportInitialize)(this.splitContainer1)).BeginInit(); this.splitContainer1.Panel1.SuspendLayout(); this.splitContainer1.Panel2.SuspendLayout(); @@ -232,9 +235,11 @@ private void InitializeComponent() this.uncommentToolStripMenuItem, this.toolStripMenuItem1, this.moveUpToolStripMenuItem, - this.moveDownToolStripMenuItem}); + this.moveDownToolStripMenuItem, + this.toolStripSeparator1, + this.showMetadataToolStripMenuItem}); this.nodeMenu.Name = "nodeMenu"; - this.nodeMenu.Size = new System.Drawing.Size(203, 170); + this.nodeMenu.Size = new System.Drawing.Size(203, 220); this.nodeMenu.ItemClicked += new System.Windows.Forms.ToolStripItemClickedEventHandler(this.nodeMenu_ItemClicked); // // selectAttributesToolStripMenuItem @@ -294,6 +299,19 @@ private void InitializeComponent() this.moveDownToolStripMenuItem.Text = "Move down"; this.moveDownToolStripMenuItem.Click += new System.EventHandler(this.toolStripButtonMoveDown_Click); // + // toolStripSeparator1 + // + this.toolStripSeparator1.Name = "toolStripSeparator1"; + this.toolStripSeparator1.Size = new System.Drawing.Size(199, 6); + // + // showMetadataToolStripMenuItem + // + this.showMetadataToolStripMenuItem.Image = ((System.Drawing.Image)(resources.GetObject("showMetadataToolStripMenuItem.Image"))); + this.showMetadataToolStripMenuItem.Name = "showMetadataToolStripMenuItem"; + this.showMetadataToolStripMenuItem.Size = new System.Drawing.Size(202, 22); + this.showMetadataToolStripMenuItem.Text = "Show Metadata"; + this.showMetadataToolStripMenuItem.Click += new System.EventHandler(this.showMetadataToolStripMenuItem_Click); + // // TreeBuilderControl // this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F); @@ -353,5 +371,7 @@ private void InitializeComponent() private System.Windows.Forms.Panel panProperties; internal System.Windows.Forms.Label lblQAExpander; private System.Windows.Forms.ToolTip tt; + private System.Windows.Forms.ToolStripSeparator toolStripSeparator1; + private System.Windows.Forms.ToolStripMenuItem showMetadataToolStripMenuItem; } } diff --git a/FetchXmlBuilder/DockControls/TreeBuilderControl.resx b/FetchXmlBuilder/DockControls/TreeBuilderControl.resx index cefb98a8..efd3c7da 100644 --- a/FetchXmlBuilder/DockControls/TreeBuilderControl.resx +++ b/FetchXmlBuilder/DockControls/TreeBuilderControl.resx @@ -123,6 +123,31 @@ 244, 17 + + + + iVBORw0KGgoAAAANSUhEUgAAABgAAAAYCAYAAADgdz34AAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8 + YQUAAAAJcEhZcwAACxMAAAsTAQCanBgAAAQKSURBVEhLtZTrV1JZGIf5m+YcHNfMrNWMNZUWSSpiilKK + CioXxQtS431ChBQV0FQgjByLUcdLiihI2mQfW7WaNWOW/Se/efc5yCVZzRfnwwOczd7Pb78vmy1JJBL/ + KzkHz5Ocg5nE9+JYiWwgvLmK7dgOcs35GjkHd+Ix2EIeKBwmSO9WgLMqU1wdakDXnB3r0c1UmO9lCN2H + Nhhe9+DeKzsW9sOp77LEDG84iIL+2iwp132W76yVGA644Tzwov51J+oPO6E57IDmlYhvPySEZMnv+pw5 + ZVlYiK5ycK2lkHaVoXBRhzoS1v4pcuelSOOBFbFEDCl57yOXuPirkJhhLgOnl0PqqAbnUuPmmh63D9pF + 9s1QJ/G/eCIGzK8+g1TYXVLAdiiggLSnAnn3q/CtvRpFbi2uOjSQmkpovgLcWI0QkO+tRc0Lc5qEGdV7 + ZgzuucSAMpsBXCctYHSkYWLeWQ31ogUzbwOY/yeE4FEInjezqAy1g6PvTkNYFap4W4oqwhQfgCS0Gk4K + qewMpAOVgqDmN4sgDRzNw38UxNzRI8weBTDzwQflglkMoYDLC1pUxUi824ZKxk4rancskHRM28SeZsBT + JfyYWuix591sUuoXpNPHs5g6noGHGHk3AX6EVaHGxfkG3Iq2EiZUMLZNUG23Q1L2qz4tbxOR9t0SSr/s + bcTDD3MZ0odwH09j4ngK4x+9cH104yd3nTD30uNGKCOmLDQRKyQXumkHSTGDZ8ePes8W/exp+ELqEaRj + nybw4NM4nCcu/DgpBlwLN0GxZYRi04iy5yKmrSFIeDoRX5JnVwmLeJsK9vcuQTqaIXWcjGH4ZBS976m9 + tirkTdxG6boRpRtpSujZHp2CJL+N+m0kcQbSIfqBqa8cBZU/1gvSkaTUdvIA908cGPo8Avm8TphzZUFH + QgNK1gx0mohVkeXYGiTXf6k/G3CP7h86GeyEfNOnhMKvRd/fNkE6+HkY1r8GUBzUgqNWXvTXi8I/DJCf + smKAfmNQvCo0IxbwBhIbbqZgfyR+lALoFLGAggk1ZIF6yIONKJypww9OFS547qDwiRbFyy0oXtHjxjKj + BTL2vGxAOLYqBjiCXvB6Erdkk8eqGFYhn3osX2rBjXAzZE91kNHdI3vaBBl7XmKQVIA+/96M6zQ+FplL + 36aR3Si+NyrBN5M4E60cvEWBK7TrzN1lyk6F156JFBH2zemUXAhgL8O+SfBNJNUlITmnkaHD2Y/xiA8l + S8a0LClkMpEmFFJFynA7AtuLWfJUAMO74Ed5TwsKWqtQatXCMedOTd6Ib6H/+SQqlzoFWeEiQ4ciem9Y + 6oVr009Xc/yMnHFm4L+I7u1iZXcda7EtxBN7OaWZ5Bw8T3IOnh8Jyb/1r01c7p6sKwAAAABJRU5ErkJg + gg== + + 355, 17 diff --git a/FetchXmlBuilder/FetchXmlBuilder.cs b/FetchXmlBuilder/FetchXmlBuilder.cs index 55915736..d5ac4ec3 100644 --- a/FetchXmlBuilder/FetchXmlBuilder.cs +++ b/FetchXmlBuilder/FetchXmlBuilder.cs @@ -1934,6 +1934,11 @@ private void ShowContentControl(ref XmlContentControl control, ContentType conte UpdateLiveXML(); } + internal void ShowMetadataControl() + { + ShowMetadataControl(ref dockControlMeta, DockState.DockRight); + } + private void ShowMetadataControl(ref MetadataControl control, DockState defaultstate) { LogUse($"Show-Metadata");