1
0
mirror of https://github.com/Kopano-dev/kopano-ol-extension.git synced 2023-10-10 13:37:40 +02:00

[KOE-130] Removed cached property accessor, as that seems to keep the wrapper alive when it's no longer used.

This commit is contained in:
Patrick Simpson 2017-07-05 16:21:23 +02:00
parent 59ad301b03
commit 4ba62b1e1d
5 changed files with 677 additions and 377 deletions

View File

@ -32,6 +32,10 @@
System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(DebugDialog));
System.Windows.Forms.ColumnHeader columnFile;
System.Windows.Forms.ColumnHeader columnLine;
System.Windows.Forms.ColumnHeader columnEvent;
System.Windows.Forms.ColumnHeader columnCount;
System.Windows.Forms.ColumnHeader columnId;
System.Windows.Forms.ColumnHeader columnEvents;
this.tableMain = new System.Windows.Forms.TableLayoutPanel();
this.flowButtons = new System.Windows.Forms.FlowLayoutPanel();
this.buttonGC = new System.Windows.Forms.Button();
@ -51,9 +55,17 @@
this.listWrapperLocations = new System.Windows.Forms.ListView();
this.columnHeader3 = ((System.Windows.Forms.ColumnHeader)(new System.Windows.Forms.ColumnHeader()));
this.columnHeader4 = ((System.Windows.Forms.ColumnHeader)(new System.Windows.Forms.ColumnHeader()));
this._tabItemEvents = new System.Windows.Forms.TabPage();
this._layoutItemEvents = new System.Windows.Forms.TableLayoutPanel();
this.listItemEventDetails = new System.Windows.Forms.ListView();
this.listItemEvents = new System.Windows.Forms.ListView();
columnMethod = ((System.Windows.Forms.ColumnHeader)(new System.Windows.Forms.ColumnHeader()));
columnFile = ((System.Windows.Forms.ColumnHeader)(new System.Windows.Forms.ColumnHeader()));
columnLine = ((System.Windows.Forms.ColumnHeader)(new System.Windows.Forms.ColumnHeader()));
columnEvent = ((System.Windows.Forms.ColumnHeader)(new System.Windows.Forms.ColumnHeader()));
columnCount = ((System.Windows.Forms.ColumnHeader)(new System.Windows.Forms.ColumnHeader()));
columnId = ((System.Windows.Forms.ColumnHeader)(new System.Windows.Forms.ColumnHeader()));
columnEvents = ((System.Windows.Forms.ColumnHeader)(new System.Windows.Forms.ColumnHeader()));
this.tableMain.SuspendLayout();
this.flowButtons.SuspendLayout();
this._tabs.SuspendLayout();
@ -61,6 +73,8 @@
this._tabWrapperTypes.SuspendLayout();
this._tabWrapperLocations.SuspendLayout();
this._layoutLocations.SuspendLayout();
this._tabItemEvents.SuspendLayout();
this._layoutItemEvents.SuspendLayout();
this.SuspendLayout();
//
// columnMethod
@ -75,6 +89,18 @@
//
resources.ApplyResources(columnLine, "columnLine");
//
// columnEvent
//
resources.ApplyResources(columnEvent, "columnEvent");
//
// columnCount
//
resources.ApplyResources(columnCount, "columnCount");
//
// columnId
//
resources.ApplyResources(columnId, "columnId");
//
// tableMain
//
resources.ApplyResources(this.tableMain, "tableMain");
@ -125,6 +151,7 @@
this._tabs.Controls.Add(this._tabProperties);
this._tabs.Controls.Add(this._tabWrapperTypes);
this._tabs.Controls.Add(this._tabWrapperLocations);
this._tabs.Controls.Add(this._tabItemEvents);
resources.ApplyResources(this._tabs, "_tabs");
this._tabs.Name = "_tabs";
this._tabs.SelectedIndex = 0;
@ -223,6 +250,53 @@
//
resources.ApplyResources(this.columnHeader4, "columnHeader4");
//
// _tabItemEvents
//
this._tabItemEvents.Controls.Add(this._layoutItemEvents);
resources.ApplyResources(this._tabItemEvents, "_tabItemEvents");
this._tabItemEvents.Name = "_tabItemEvents";
this._tabItemEvents.UseVisualStyleBackColor = true;
//
// _layoutItemEvents
//
resources.ApplyResources(this._layoutItemEvents, "_layoutItemEvents");
this._layoutItemEvents.Controls.Add(this.listItemEventDetails, 0, 1);
this._layoutItemEvents.Controls.Add(this.listItemEvents, 0, 0);
this._layoutItemEvents.Name = "_layoutItemEvents";
//
// listItemEventDetails
//
this.listItemEventDetails.Columns.AddRange(new System.Windows.Forms.ColumnHeader[] {
columnEvent,
columnCount});
resources.ApplyResources(this.listItemEventDetails, "listItemEventDetails");
this.listItemEventDetails.FullRowSelect = true;
this.listItemEventDetails.MultiSelect = false;
this.listItemEventDetails.Name = "listItemEventDetails";
this.listItemEventDetails.ShowItemToolTips = true;
this.listItemEventDetails.UseCompatibleStateImageBehavior = false;
this.listItemEventDetails.View = System.Windows.Forms.View.Details;
//
// listItemEvents
//
this.listItemEvents.Columns.AddRange(new System.Windows.Forms.ColumnHeader[] {
columnId,
columnEvents});
resources.ApplyResources(this.listItemEvents, "listItemEvents");
this.listItemEvents.FullRowSelect = true;
this.listItemEvents.HideSelection = false;
this.listItemEvents.MultiSelect = false;
this.listItemEvents.Name = "listItemEvents";
this.listItemEvents.ShowItemToolTips = true;
this.listItemEvents.Sorting = System.Windows.Forms.SortOrder.Descending;
this.listItemEvents.UseCompatibleStateImageBehavior = false;
this.listItemEvents.View = System.Windows.Forms.View.Details;
this.listItemEvents.SelectedIndexChanged += new System.EventHandler(this.listItemEvents_SelectedIndexChanged);
//
// columnEvents
//
resources.ApplyResources(columnEvents, "columnEvents");
//
// DebugDialog
//
resources.ApplyResources(this, "$this");
@ -241,6 +315,8 @@
this._tabWrapperTypes.ResumeLayout(false);
this._tabWrapperLocations.ResumeLayout(false);
this._layoutLocations.ResumeLayout(false);
this._tabItemEvents.ResumeLayout(false);
this._layoutItemEvents.ResumeLayout(false);
this.ResumeLayout(false);
this.PerformLayout();
@ -267,5 +343,9 @@
private System.Windows.Forms.ListView listWrapperLocations;
private System.Windows.Forms.ColumnHeader columnHeader3;
private System.Windows.Forms.ColumnHeader columnHeader4;
private System.Windows.Forms.TabPage _tabItemEvents;
private System.Windows.Forms.TableLayoutPanel _layoutItemEvents;
private System.Windows.Forms.ListView listItemEventDetails;
private System.Windows.Forms.ListView listItemEvents;
}
}

View File

@ -51,9 +51,11 @@ namespace Acacia.Features.DebugSupport
}
else
{
listWrapperTypes.ListViewItemSorter = new WrapperCountSorter();
listWrapperLocations.ListViewItemSorter = new WrapperCountSorter();
listWrapperTypes.ListViewItemSorter = new WrapperCountSorter(1);
listWrapperLocations.ListViewItemSorter = new WrapperCountSorter(1);
listItemEvents.ListViewItemSorter = new WrapperCountSorter(0);
RefreshWrappers();
RefreshItemEvents();
// Make it a bit bigger
Width = Width + 400;
@ -65,6 +67,7 @@ namespace Acacia.Features.DebugSupport
{
Properties.Refresh();
RefreshWrappers();
RefreshItemEvents();
}
#region Wrappers
@ -104,10 +107,17 @@ namespace Acacia.Features.DebugSupport
private class WrapperCountSorter : IComparer
{
private readonly int _index;
public WrapperCountSorter(int index)
{
this._index = index;
}
public int Compare(object x, object y)
{
int ix = int.Parse(((ListViewItem)x).SubItems[1].Text);
int iy = int.Parse(((ListViewItem)y).SubItems[1].Text);
int ix = int.Parse(((ListViewItem)x).SubItems[_index].Text);
int iy = int.Parse(((ListViewItem)y).SubItems[_index].Text);
return iy - ix;
}
}
@ -132,6 +142,42 @@ namespace Acacia.Features.DebugSupport
#endregion
#region Item events
private void RefreshItemEvents()
{
listItemEvents.Items.Clear();
foreach(MailEvents.MailEventDebug events in MailEvents.MailEventsDebug)
{
ListViewItem item = new ListViewItem(events.Id);
item.Tag = events;
item.SubItems.Add(string.Join(", ", events.GetEvents()));
listItemEvents.Items.Add(item);
}
foreach (ColumnHeader header in listItemEvents.Columns)
header.Width = -2;
}
private void listItemEvents_SelectedIndexChanged(object sender, EventArgs e)
{
listItemEventDetails.Items.Clear();
if (listItemEvents.SelectedItems.Count > 0)
{
MailEvents.MailEventDebug debug = (MailEvents.MailEventDebug)listItemEvents.SelectedItems[0].Tag;
foreach (MailEvents.DebugEvent evt in typeof(MailEvents.DebugEvent).GetEnumValues())
{
ListViewItem item = new ListViewItem(evt.ToString());
item.SubItems.Add(debug.GetEventCount(evt).ToString());
listItemEventDetails.Items.Add(item);
}
}
foreach (ColumnHeader header in listItemEventDetails.Columns)
header.Width = -2;
}
#endregion
#region Cycling
private class DebugCycleInfo

View File

@ -142,6 +142,30 @@
<data name="columnLine.Text" xml:space="preserve">
<value>Line</value>
</data>
<metadata name="columnEvent.GenerateMember" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>False</value>
</metadata>
<data name="columnEvent.Text" xml:space="preserve">
<value>Event</value>
</data>
<data name="columnEvent.Width" type="System.Int32, mscorlib">
<value>44</value>
</data>
<metadata name="columnCount.GenerateMember" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>False</value>
</metadata>
<data name="columnCount.Text" xml:space="preserve">
<value>Count</value>
</data>
<metadata name="columnId.GenerateMember" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>False</value>
</metadata>
<data name="columnId.Text" xml:space="preserve">
<value>Id</value>
</data>
<data name="columnId.Width" type="System.Int32, mscorlib">
<value>44</value>
</data>
<assembly alias="System.Windows.Forms" name="System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" />
<data name="tableMain.Anchor" type="System.Windows.Forms.AnchorStyles, System.Windows.Forms">
<value>Top, Bottom, Left, Right</value>
@ -161,325 +185,10 @@
<data name="flowButtons.AutoSize" type="System.Boolean, mscorlib">
<value>True</value>
</data>
<data name="&gt;&gt;buttonGC.Name" xml:space="preserve">
<value>buttonGC</value>
</data>
<data name="&gt;&gt;buttonGC.Type" xml:space="preserve">
<value>System.Windows.Forms.Button, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</data>
<data name="&gt;&gt;buttonGC.Parent" xml:space="preserve">
<value>flowButtons</value>
</data>
<data name="&gt;&gt;buttonGC.ZOrder" xml:space="preserve">
<value>0</value>
</data>
<data name="&gt;&gt;buttonRefresh.Name" xml:space="preserve">
<value>buttonRefresh</value>
</data>
<data name="&gt;&gt;buttonRefresh.Type" xml:space="preserve">
<value>System.Windows.Forms.Button, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</data>
<data name="&gt;&gt;buttonRefresh.Parent" xml:space="preserve">
<value>flowButtons</value>
</data>
<data name="&gt;&gt;buttonRefresh.ZOrder" xml:space="preserve">
<value>1</value>
</data>
<data name="&gt;&gt;buttonClose.Name" xml:space="preserve">
<value>buttonClose</value>
</data>
<data name="&gt;&gt;buttonClose.Type" xml:space="preserve">
<value>System.Windows.Forms.Button, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</data>
<data name="&gt;&gt;buttonClose.Parent" xml:space="preserve">
<value>flowButtons</value>
</data>
<data name="&gt;&gt;buttonClose.ZOrder" xml:space="preserve">
<value>2</value>
</data>
<data name="&gt;&gt;buttonLog.Name" xml:space="preserve">
<value>buttonLog</value>
</data>
<data name="&gt;&gt;buttonLog.Type" xml:space="preserve">
<value>System.Windows.Forms.Button, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</data>
<data name="&gt;&gt;buttonLog.Parent" xml:space="preserve">
<value>flowButtons</value>
</data>
<data name="&gt;&gt;buttonLog.ZOrder" xml:space="preserve">
<value>3</value>
</data>
<data name="flowButtons.FlowDirection" type="System.Windows.Forms.FlowDirection, System.Windows.Forms">
<value>RightToLeft</value>
</data>
<assembly alias="System.Drawing" name="System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
<data name="flowButtons.Location" type="System.Drawing.Point, System.Drawing">
<value>4, 703</value>
</data>
<data name="flowButtons.Margin" type="System.Windows.Forms.Padding, System.Windows.Forms">
<value>4, 3, 4, 3</value>
</data>
<data name="flowButtons.Size" type="System.Drawing.Size, System.Drawing">
<value>615, 64</value>
</data>
<data name="flowButtons.TabIndex" type="System.Int32, mscorlib">
<value>1</value>
</data>
<data name="&gt;&gt;flowButtons.Name" xml:space="preserve">
<value>flowButtons</value>
</data>
<data name="&gt;&gt;flowButtons.Type" xml:space="preserve">
<value>System.Windows.Forms.FlowLayoutPanel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</data>
<data name="&gt;&gt;flowButtons.Parent" xml:space="preserve">
<value>tableMain</value>
</data>
<data name="&gt;&gt;flowButtons.ZOrder" xml:space="preserve">
<value>0</value>
</data>
<data name="&gt;&gt;Properties.Name" xml:space="preserve">
<value>Properties</value>
</data>
<data name="&gt;&gt;Properties.Type" xml:space="preserve">
<value>System.Windows.Forms.PropertyGrid, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</data>
<data name="&gt;&gt;Properties.Parent" xml:space="preserve">
<value>_tabProperties</value>
</data>
<data name="&gt;&gt;Properties.ZOrder" xml:space="preserve">
<value>0</value>
</data>
<data name="_tabProperties.Location" type="System.Drawing.Point, System.Drawing">
<value>4, 33</value>
</data>
<data name="_tabProperties.Padding" type="System.Windows.Forms.Padding, System.Windows.Forms">
<value>3, 3, 3, 3</value>
</data>
<data name="_tabProperties.Size" type="System.Drawing.Size, System.Drawing">
<value>609, 657</value>
</data>
<data name="_tabProperties.TabIndex" type="System.Int32, mscorlib">
<value>0</value>
</data>
<data name="_tabProperties.Text" xml:space="preserve">
<value>General</value>
</data>
<data name="&gt;&gt;_tabProperties.Name" xml:space="preserve">
<value>_tabProperties</value>
</data>
<data name="&gt;&gt;_tabProperties.Type" xml:space="preserve">
<value>System.Windows.Forms.TabPage, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</data>
<data name="&gt;&gt;_tabProperties.Parent" xml:space="preserve">
<value>_tabs</value>
</data>
<data name="&gt;&gt;_tabProperties.ZOrder" xml:space="preserve">
<value>0</value>
</data>
<data name="&gt;&gt;listWrapperTypes.Name" xml:space="preserve">
<value>listWrapperTypes</value>
</data>
<data name="&gt;&gt;listWrapperTypes.Type" xml:space="preserve">
<value>System.Windows.Forms.ListView, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</data>
<data name="&gt;&gt;listWrapperTypes.Parent" xml:space="preserve">
<value>_tabWrapperTypes</value>
</data>
<data name="&gt;&gt;listWrapperTypes.ZOrder" xml:space="preserve">
<value>0</value>
</data>
<data name="_tabWrapperTypes.Location" type="System.Drawing.Point, System.Drawing">
<value>4, 33</value>
</data>
<data name="_tabWrapperTypes.Padding" type="System.Windows.Forms.Padding, System.Windows.Forms">
<value>3, 3, 3, 3</value>
</data>
<data name="_tabWrapperTypes.Size" type="System.Drawing.Size, System.Drawing">
<value>609, 657</value>
</data>
<data name="_tabWrapperTypes.TabIndex" type="System.Int32, mscorlib">
<value>1</value>
</data>
<data name="_tabWrapperTypes.Text" xml:space="preserve">
<value>Wrapper types</value>
</data>
<data name="&gt;&gt;_tabWrapperTypes.Name" xml:space="preserve">
<value>_tabWrapperTypes</value>
</data>
<data name="&gt;&gt;_tabWrapperTypes.Type" xml:space="preserve">
<value>System.Windows.Forms.TabPage, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</data>
<data name="&gt;&gt;_tabWrapperTypes.Parent" xml:space="preserve">
<value>_tabs</value>
</data>
<data name="&gt;&gt;_tabWrapperTypes.ZOrder" xml:space="preserve">
<value>1</value>
</data>
<data name="_layoutLocations.ColumnCount" type="System.Int32, mscorlib">
<value>1</value>
</data>
<data name="listStackTrace.Dock" type="System.Windows.Forms.DockStyle, System.Windows.Forms">
<value>Fill</value>
</data>
<data name="listStackTrace.Location" type="System.Drawing.Point, System.Drawing">
<value>3, 328</value>
</data>
<data name="listStackTrace.Size" type="System.Drawing.Size, System.Drawing">
<value>597, 320</value>
</data>
<data name="listStackTrace.TabIndex" type="System.Int32, mscorlib">
<value>3</value>
</data>
<data name="&gt;&gt;listStackTrace.Name" xml:space="preserve">
<value>listStackTrace</value>
</data>
<data name="&gt;&gt;listStackTrace.Type" xml:space="preserve">
<value>System.Windows.Forms.ListView, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</data>
<data name="&gt;&gt;listStackTrace.Parent" xml:space="preserve">
<value>_layoutLocations</value>
</data>
<data name="&gt;&gt;listStackTrace.ZOrder" xml:space="preserve">
<value>0</value>
</data>
<data name="listWrapperLocations.Dock" type="System.Windows.Forms.DockStyle, System.Windows.Forms">
<value>Fill</value>
</data>
<data name="listWrapperLocations.Location" type="System.Drawing.Point, System.Drawing">
<value>3, 3</value>
</data>
<data name="listWrapperLocations.Size" type="System.Drawing.Size, System.Drawing">
<value>597, 319</value>
</data>
<data name="listWrapperLocations.TabIndex" type="System.Int32, mscorlib">
<value>2</value>
</data>
<data name="&gt;&gt;listWrapperLocations.Name" xml:space="preserve">
<value>listWrapperLocations</value>
</data>
<data name="&gt;&gt;listWrapperLocations.Type" xml:space="preserve">
<value>System.Windows.Forms.ListView, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</data>
<data name="&gt;&gt;listWrapperLocations.Parent" xml:space="preserve">
<value>_layoutLocations</value>
</data>
<data name="&gt;&gt;listWrapperLocations.ZOrder" xml:space="preserve">
<value>1</value>
</data>
<data name="_layoutLocations.Dock" type="System.Windows.Forms.DockStyle, System.Windows.Forms">
<value>Fill</value>
</data>
<data name="_layoutLocations.Location" type="System.Drawing.Point, System.Drawing">
<value>3, 3</value>
</data>
<data name="_layoutLocations.RowCount" type="System.Int32, mscorlib">
<value>2</value>
</data>
<data name="_layoutLocations.Size" type="System.Drawing.Size, System.Drawing">
<value>603, 651</value>
</data>
<data name="_layoutLocations.TabIndex" type="System.Int32, mscorlib">
<value>2</value>
</data>
<data name="&gt;&gt;_layoutLocations.Name" xml:space="preserve">
<value>_layoutLocations</value>
</data>
<data name="&gt;&gt;_layoutLocations.Type" xml:space="preserve">
<value>System.Windows.Forms.TableLayoutPanel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</data>
<data name="&gt;&gt;_layoutLocations.Parent" xml:space="preserve">
<value>_tabWrapperLocations</value>
</data>
<data name="&gt;&gt;_layoutLocations.ZOrder" xml:space="preserve">
<value>0</value>
</data>
<data name="_layoutLocations.LayoutSettings" type="System.Windows.Forms.TableLayoutSettings, System.Windows.Forms">
<value>&lt;?xml version="1.0" encoding="utf-16"?&gt;&lt;TableLayoutSettings&gt;&lt;Controls&gt;&lt;Control Name="listStackTrace" Row="1" RowSpan="1" Column="0" ColumnSpan="1" /&gt;&lt;Control Name="listWrapperLocations" Row="0" RowSpan="1" Column="0" ColumnSpan="1" /&gt;&lt;/Controls&gt;&lt;Columns Styles="Percent,100,Absolute,20" /&gt;&lt;Rows Styles="Percent,50,Percent,50" /&gt;&lt;/TableLayoutSettings&gt;</value>
</data>
<data name="_tabWrapperLocations.Location" type="System.Drawing.Point, System.Drawing">
<value>4, 33</value>
</data>
<data name="_tabWrapperLocations.Padding" type="System.Windows.Forms.Padding, System.Windows.Forms">
<value>3, 3, 3, 3</value>
</data>
<data name="_tabWrapperLocations.Size" type="System.Drawing.Size, System.Drawing">
<value>609, 657</value>
</data>
<data name="_tabWrapperLocations.TabIndex" type="System.Int32, mscorlib">
<value>2</value>
</data>
<data name="_tabWrapperLocations.Text" xml:space="preserve">
<value>Wrapper locations</value>
</data>
<data name="&gt;&gt;_tabWrapperLocations.Name" xml:space="preserve">
<value>_tabWrapperLocations</value>
</data>
<data name="&gt;&gt;_tabWrapperLocations.Type" xml:space="preserve">
<value>System.Windows.Forms.TabPage, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</data>
<data name="&gt;&gt;_tabWrapperLocations.Parent" xml:space="preserve">
<value>_tabs</value>
</data>
<data name="&gt;&gt;_tabWrapperLocations.ZOrder" xml:space="preserve">
<value>2</value>
</data>
<data name="_tabs.Dock" type="System.Windows.Forms.DockStyle, System.Windows.Forms">
<value>Fill</value>
</data>
<data name="_tabs.Location" type="System.Drawing.Point, System.Drawing">
<value>3, 3</value>
</data>
<data name="_tabs.Size" type="System.Drawing.Size, System.Drawing">
<value>617, 694</value>
</data>
<data name="_tabs.TabIndex" type="System.Int32, mscorlib">
<value>3</value>
</data>
<data name="&gt;&gt;_tabs.Name" xml:space="preserve">
<value>_tabs</value>
</data>
<data name="&gt;&gt;_tabs.Type" xml:space="preserve">
<value>System.Windows.Forms.TabControl, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</data>
<data name="&gt;&gt;_tabs.Parent" xml:space="preserve">
<value>tableMain</value>
</data>
<data name="&gt;&gt;_tabs.ZOrder" xml:space="preserve">
<value>1</value>
</data>
<data name="tableMain.Location" type="System.Drawing.Point, System.Drawing">
<value>0, 0</value>
</data>
<data name="tableMain.Margin" type="System.Windows.Forms.Padding, System.Windows.Forms">
<value>4, 3, 4, 3</value>
</data>
<data name="tableMain.RowCount" type="System.Int32, mscorlib">
<value>2</value>
</data>
<data name="tableMain.Size" type="System.Drawing.Size, System.Drawing">
<value>623, 770</value>
</data>
<data name="tableMain.TabIndex" type="System.Int32, mscorlib">
<value>0</value>
</data>
<data name="&gt;&gt;tableMain.Name" xml:space="preserve">
<value>tableMain</value>
</data>
<data name="&gt;&gt;tableMain.Type" xml:space="preserve">
<value>System.Windows.Forms.TableLayoutPanel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</data>
<data name="&gt;&gt;tableMain.Parent" xml:space="preserve">
<value>$this</value>
</data>
<data name="&gt;&gt;tableMain.ZOrder" xml:space="preserve">
<value>0</value>
</data>
<data name="tableMain.LayoutSettings" type="System.Windows.Forms.TableLayoutSettings, System.Windows.Forms">
<value>&lt;?xml version="1.0" encoding="utf-16"?&gt;&lt;TableLayoutSettings&gt;&lt;Controls&gt;&lt;Control Name="flowButtons" Row="1" RowSpan="1" Column="0" ColumnSpan="1" /&gt;&lt;Control Name="_tabs" Row="0" RowSpan="1" Column="0" ColumnSpan="1" /&gt;&lt;/Controls&gt;&lt;Columns Styles="Percent,100" /&gt;&lt;Rows Styles="Percent,100,AutoSize,0,Absolute,20" /&gt;&lt;/TableLayoutSettings&gt;</value>
</data>
<data name="buttonGC.AutoSize" type="System.Boolean, mscorlib">
<value>True</value>
</data>
<assembly alias="System.Drawing" name="System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
<data name="buttonGC.Location" type="System.Drawing.Point, System.Drawing">
<value>483, 6</value>
</data>
@ -597,6 +306,33 @@
<data name="&gt;&gt;buttonLog.ZOrder" xml:space="preserve">
<value>3</value>
</data>
<data name="flowButtons.FlowDirection" type="System.Windows.Forms.FlowDirection, System.Windows.Forms">
<value>RightToLeft</value>
</data>
<data name="flowButtons.Location" type="System.Drawing.Point, System.Drawing">
<value>4, 703</value>
</data>
<data name="flowButtons.Margin" type="System.Windows.Forms.Padding, System.Windows.Forms">
<value>4, 3, 4, 3</value>
</data>
<data name="flowButtons.Size" type="System.Drawing.Size, System.Drawing">
<value>615, 64</value>
</data>
<data name="flowButtons.TabIndex" type="System.Int32, mscorlib">
<value>1</value>
</data>
<data name="&gt;&gt;flowButtons.Name" xml:space="preserve">
<value>flowButtons</value>
</data>
<data name="&gt;&gt;flowButtons.Type" xml:space="preserve">
<value>System.Windows.Forms.FlowLayoutPanel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</data>
<data name="&gt;&gt;flowButtons.Parent" xml:space="preserve">
<value>tableMain</value>
</data>
<data name="&gt;&gt;flowButtons.ZOrder" xml:space="preserve">
<value>0</value>
</data>
<data name="Properties.Dock" type="System.Windows.Forms.DockStyle, System.Windows.Forms">
<value>Fill</value>
</data>
@ -627,6 +363,45 @@
<data name="&gt;&gt;Properties.ZOrder" xml:space="preserve">
<value>0</value>
</data>
<data name="_tabProperties.Location" type="System.Drawing.Point, System.Drawing">
<value>4, 33</value>
</data>
<data name="_tabProperties.Padding" type="System.Windows.Forms.Padding, System.Windows.Forms">
<value>3, 3, 3, 3</value>
</data>
<data name="_tabProperties.Size" type="System.Drawing.Size, System.Drawing">
<value>609, 657</value>
</data>
<data name="_tabProperties.TabIndex" type="System.Int32, mscorlib">
<value>0</value>
</data>
<data name="_tabProperties.Text" xml:space="preserve">
<value>General</value>
</data>
<data name="&gt;&gt;_tabProperties.Name" xml:space="preserve">
<value>_tabProperties</value>
</data>
<data name="&gt;&gt;_tabProperties.Type" xml:space="preserve">
<value>System.Windows.Forms.TabPage, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</data>
<data name="&gt;&gt;_tabProperties.Parent" xml:space="preserve">
<value>_tabs</value>
</data>
<data name="&gt;&gt;_tabProperties.ZOrder" xml:space="preserve">
<value>0</value>
</data>
<data name="columnHeader1.Text" xml:space="preserve">
<value>Type</value>
</data>
<data name="columnHeader1.Width" type="System.Int32, mscorlib">
<value>44</value>
</data>
<data name="columnHeader2.Text" xml:space="preserve">
<value>Count</value>
</data>
<data name="columnHeader2.Width" type="System.Int32, mscorlib">
<value>44</value>
</data>
<data name="listWrapperTypes.Dock" type="System.Windows.Forms.DockStyle, System.Windows.Forms">
<value>Fill</value>
</data>
@ -651,17 +426,59 @@
<data name="&gt;&gt;listWrapperTypes.ZOrder" xml:space="preserve">
<value>0</value>
</data>
<data name="columnHeader1.Text" xml:space="preserve">
<value>Type</value>
<data name="_tabWrapperTypes.Location" type="System.Drawing.Point, System.Drawing">
<value>4, 33</value>
</data>
<data name="columnHeader1.Width" type="System.Int32, mscorlib">
<value>44</value>
<data name="_tabWrapperTypes.Padding" type="System.Windows.Forms.Padding, System.Windows.Forms">
<value>3, 3, 3, 3</value>
</data>
<data name="columnHeader2.Text" xml:space="preserve">
<value>Count</value>
<data name="_tabWrapperTypes.Size" type="System.Drawing.Size, System.Drawing">
<value>609, 657</value>
</data>
<data name="columnHeader2.Width" type="System.Int32, mscorlib">
<value>44</value>
<data name="_tabWrapperTypes.TabIndex" type="System.Int32, mscorlib">
<value>1</value>
</data>
<data name="_tabWrapperTypes.Text" xml:space="preserve">
<value>Wrapper types</value>
</data>
<data name="&gt;&gt;_tabWrapperTypes.Name" xml:space="preserve">
<value>_tabWrapperTypes</value>
</data>
<data name="&gt;&gt;_tabWrapperTypes.Type" xml:space="preserve">
<value>System.Windows.Forms.TabPage, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</data>
<data name="&gt;&gt;_tabWrapperTypes.Parent" xml:space="preserve">
<value>_tabs</value>
</data>
<data name="&gt;&gt;_tabWrapperTypes.ZOrder" xml:space="preserve">
<value>1</value>
</data>
<data name="_layoutLocations.ColumnCount" type="System.Int32, mscorlib">
<value>1</value>
</data>
<data name="listStackTrace.Dock" type="System.Windows.Forms.DockStyle, System.Windows.Forms">
<value>Fill</value>
</data>
<data name="listStackTrace.Location" type="System.Drawing.Point, System.Drawing">
<value>3, 328</value>
</data>
<data name="listStackTrace.Size" type="System.Drawing.Size, System.Drawing">
<value>597, 320</value>
</data>
<data name="listStackTrace.TabIndex" type="System.Int32, mscorlib">
<value>3</value>
</data>
<data name="&gt;&gt;listStackTrace.Name" xml:space="preserve">
<value>listStackTrace</value>
</data>
<data name="&gt;&gt;listStackTrace.Type" xml:space="preserve">
<value>System.Windows.Forms.ListView, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</data>
<data name="&gt;&gt;listStackTrace.Parent" xml:space="preserve">
<value>_layoutLocations</value>
</data>
<data name="&gt;&gt;listStackTrace.ZOrder" xml:space="preserve">
<value>0</value>
</data>
<data name="columnHeader3.Text" xml:space="preserve">
<value>Type</value>
@ -675,6 +492,255 @@
<data name="columnHeader4.Width" type="System.Int32, mscorlib">
<value>44</value>
</data>
<data name="listWrapperLocations.Dock" type="System.Windows.Forms.DockStyle, System.Windows.Forms">
<value>Fill</value>
</data>
<data name="listWrapperLocations.Location" type="System.Drawing.Point, System.Drawing">
<value>3, 3</value>
</data>
<data name="listWrapperLocations.Size" type="System.Drawing.Size, System.Drawing">
<value>597, 319</value>
</data>
<data name="listWrapperLocations.TabIndex" type="System.Int32, mscorlib">
<value>2</value>
</data>
<data name="&gt;&gt;listWrapperLocations.Name" xml:space="preserve">
<value>listWrapperLocations</value>
</data>
<data name="&gt;&gt;listWrapperLocations.Type" xml:space="preserve">
<value>System.Windows.Forms.ListView, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</data>
<data name="&gt;&gt;listWrapperLocations.Parent" xml:space="preserve">
<value>_layoutLocations</value>
</data>
<data name="&gt;&gt;listWrapperLocations.ZOrder" xml:space="preserve">
<value>1</value>
</data>
<data name="_layoutLocations.Dock" type="System.Windows.Forms.DockStyle, System.Windows.Forms">
<value>Fill</value>
</data>
<data name="_layoutLocations.Location" type="System.Drawing.Point, System.Drawing">
<value>3, 3</value>
</data>
<data name="_layoutLocations.RowCount" type="System.Int32, mscorlib">
<value>2</value>
</data>
<data name="_layoutLocations.Size" type="System.Drawing.Size, System.Drawing">
<value>603, 651</value>
</data>
<data name="_layoutLocations.TabIndex" type="System.Int32, mscorlib">
<value>2</value>
</data>
<data name="&gt;&gt;_layoutLocations.Name" xml:space="preserve">
<value>_layoutLocations</value>
</data>
<data name="&gt;&gt;_layoutLocations.Type" xml:space="preserve">
<value>System.Windows.Forms.TableLayoutPanel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</data>
<data name="&gt;&gt;_layoutLocations.Parent" xml:space="preserve">
<value>_tabWrapperLocations</value>
</data>
<data name="&gt;&gt;_layoutLocations.ZOrder" xml:space="preserve">
<value>0</value>
</data>
<data name="_layoutLocations.LayoutSettings" type="System.Windows.Forms.TableLayoutSettings, System.Windows.Forms">
<value>&lt;?xml version="1.0" encoding="utf-16"?&gt;&lt;TableLayoutSettings&gt;&lt;Controls&gt;&lt;Control Name="listStackTrace" Row="1" RowSpan="1" Column="0" ColumnSpan="1" /&gt;&lt;Control Name="listWrapperLocations" Row="0" RowSpan="1" Column="0" ColumnSpan="1" /&gt;&lt;/Controls&gt;&lt;Columns Styles="Percent,100,Absolute,20" /&gt;&lt;Rows Styles="Percent,50,Percent,50" /&gt;&lt;/TableLayoutSettings&gt;</value>
</data>
<data name="_tabWrapperLocations.Location" type="System.Drawing.Point, System.Drawing">
<value>4, 33</value>
</data>
<data name="_tabWrapperLocations.Padding" type="System.Windows.Forms.Padding, System.Windows.Forms">
<value>3, 3, 3, 3</value>
</data>
<data name="_tabWrapperLocations.Size" type="System.Drawing.Size, System.Drawing">
<value>609, 657</value>
</data>
<data name="_tabWrapperLocations.TabIndex" type="System.Int32, mscorlib">
<value>2</value>
</data>
<data name="_tabWrapperLocations.Text" xml:space="preserve">
<value>Wrapper locations</value>
</data>
<data name="&gt;&gt;_tabWrapperLocations.Name" xml:space="preserve">
<value>_tabWrapperLocations</value>
</data>
<data name="&gt;&gt;_tabWrapperLocations.Type" xml:space="preserve">
<value>System.Windows.Forms.TabPage, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</data>
<data name="&gt;&gt;_tabWrapperLocations.Parent" xml:space="preserve">
<value>_tabs</value>
</data>
<data name="&gt;&gt;_tabWrapperLocations.ZOrder" xml:space="preserve">
<value>2</value>
</data>
<data name="_layoutItemEvents.ColumnCount" type="System.Int32, mscorlib">
<value>1</value>
</data>
<data name="listItemEventDetails.Dock" type="System.Windows.Forms.DockStyle, System.Windows.Forms">
<value>Fill</value>
</data>
<data name="listItemEventDetails.Location" type="System.Drawing.Point, System.Drawing">
<value>3, 328</value>
</data>
<data name="listItemEventDetails.Size" type="System.Drawing.Size, System.Drawing">
<value>597, 320</value>
</data>
<data name="listItemEventDetails.TabIndex" type="System.Int32, mscorlib">
<value>3</value>
</data>
<data name="&gt;&gt;listItemEventDetails.Name" xml:space="preserve">
<value>listItemEventDetails</value>
</data>
<data name="&gt;&gt;listItemEventDetails.Type" xml:space="preserve">
<value>System.Windows.Forms.ListView, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</data>
<data name="&gt;&gt;listItemEventDetails.Parent" xml:space="preserve">
<value>_layoutItemEvents</value>
</data>
<data name="&gt;&gt;listItemEventDetails.ZOrder" xml:space="preserve">
<value>0</value>
</data>
<metadata name="columnEvents.GenerateMember" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>False</value>
</metadata>
<data name="columnEvents.Text" xml:space="preserve">
<value>Events</value>
</data>
<data name="listItemEvents.Dock" type="System.Windows.Forms.DockStyle, System.Windows.Forms">
<value>Fill</value>
</data>
<data name="listItemEvents.Location" type="System.Drawing.Point, System.Drawing">
<value>3, 3</value>
</data>
<data name="listItemEvents.Size" type="System.Drawing.Size, System.Drawing">
<value>597, 319</value>
</data>
<data name="listItemEvents.TabIndex" type="System.Int32, mscorlib">
<value>2</value>
</data>
<data name="&gt;&gt;listItemEvents.Name" xml:space="preserve">
<value>listItemEvents</value>
</data>
<data name="&gt;&gt;listItemEvents.Type" xml:space="preserve">
<value>System.Windows.Forms.ListView, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</data>
<data name="&gt;&gt;listItemEvents.Parent" xml:space="preserve">
<value>_layoutItemEvents</value>
</data>
<data name="&gt;&gt;listItemEvents.ZOrder" xml:space="preserve">
<value>1</value>
</data>
<data name="_layoutItemEvents.Dock" type="System.Windows.Forms.DockStyle, System.Windows.Forms">
<value>Fill</value>
</data>
<data name="_layoutItemEvents.Location" type="System.Drawing.Point, System.Drawing">
<value>3, 3</value>
</data>
<data name="_layoutItemEvents.RowCount" type="System.Int32, mscorlib">
<value>2</value>
</data>
<data name="_layoutItemEvents.Size" type="System.Drawing.Size, System.Drawing">
<value>603, 651</value>
</data>
<data name="_layoutItemEvents.TabIndex" type="System.Int32, mscorlib">
<value>3</value>
</data>
<data name="&gt;&gt;_layoutItemEvents.Name" xml:space="preserve">
<value>_layoutItemEvents</value>
</data>
<data name="&gt;&gt;_layoutItemEvents.Type" xml:space="preserve">
<value>System.Windows.Forms.TableLayoutPanel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</data>
<data name="&gt;&gt;_layoutItemEvents.Parent" xml:space="preserve">
<value>_tabItemEvents</value>
</data>
<data name="&gt;&gt;_layoutItemEvents.ZOrder" xml:space="preserve">
<value>0</value>
</data>
<data name="_layoutItemEvents.LayoutSettings" type="System.Windows.Forms.TableLayoutSettings, System.Windows.Forms">
<value>&lt;?xml version="1.0" encoding="utf-16"?&gt;&lt;TableLayoutSettings&gt;&lt;Controls&gt;&lt;Control Name="listItemEventDetails" Row="1" RowSpan="1" Column="0" ColumnSpan="1" /&gt;&lt;Control Name="listItemEvents" Row="0" RowSpan="1" Column="0" ColumnSpan="1" /&gt;&lt;/Controls&gt;&lt;Columns Styles="Percent,100,Absolute,20" /&gt;&lt;Rows Styles="Percent,50,Percent,50" /&gt;&lt;/TableLayoutSettings&gt;</value>
</data>
<data name="_tabItemEvents.Location" type="System.Drawing.Point, System.Drawing">
<value>4, 33</value>
</data>
<data name="_tabItemEvents.Padding" type="System.Windows.Forms.Padding, System.Windows.Forms">
<value>3, 3, 3, 3</value>
</data>
<data name="_tabItemEvents.Size" type="System.Drawing.Size, System.Drawing">
<value>609, 657</value>
</data>
<data name="_tabItemEvents.TabIndex" type="System.Int32, mscorlib">
<value>3</value>
</data>
<data name="_tabItemEvents.Text" xml:space="preserve">
<value>Item events</value>
</data>
<data name="&gt;&gt;_tabItemEvents.Name" xml:space="preserve">
<value>_tabItemEvents</value>
</data>
<data name="&gt;&gt;_tabItemEvents.Type" xml:space="preserve">
<value>System.Windows.Forms.TabPage, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</data>
<data name="&gt;&gt;_tabItemEvents.Parent" xml:space="preserve">
<value>_tabs</value>
</data>
<data name="&gt;&gt;_tabItemEvents.ZOrder" xml:space="preserve">
<value>3</value>
</data>
<data name="_tabs.Dock" type="System.Windows.Forms.DockStyle, System.Windows.Forms">
<value>Fill</value>
</data>
<data name="_tabs.Location" type="System.Drawing.Point, System.Drawing">
<value>3, 3</value>
</data>
<data name="_tabs.Size" type="System.Drawing.Size, System.Drawing">
<value>617, 694</value>
</data>
<data name="_tabs.TabIndex" type="System.Int32, mscorlib">
<value>3</value>
</data>
<data name="&gt;&gt;_tabs.Name" xml:space="preserve">
<value>_tabs</value>
</data>
<data name="&gt;&gt;_tabs.Type" xml:space="preserve">
<value>System.Windows.Forms.TabControl, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</data>
<data name="&gt;&gt;_tabs.Parent" xml:space="preserve">
<value>tableMain</value>
</data>
<data name="&gt;&gt;_tabs.ZOrder" xml:space="preserve">
<value>1</value>
</data>
<data name="tableMain.Location" type="System.Drawing.Point, System.Drawing">
<value>0, 0</value>
</data>
<data name="tableMain.Margin" type="System.Windows.Forms.Padding, System.Windows.Forms">
<value>4, 3, 4, 3</value>
</data>
<data name="tableMain.RowCount" type="System.Int32, mscorlib">
<value>2</value>
</data>
<data name="tableMain.Size" type="System.Drawing.Size, System.Drawing">
<value>623, 770</value>
</data>
<data name="tableMain.TabIndex" type="System.Int32, mscorlib">
<value>0</value>
</data>
<data name="&gt;&gt;tableMain.Name" xml:space="preserve">
<value>tableMain</value>
</data>
<data name="&gt;&gt;tableMain.Type" xml:space="preserve">
<value>System.Windows.Forms.TableLayoutPanel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</data>
<data name="&gt;&gt;tableMain.Parent" xml:space="preserve">
<value>$this</value>
</data>
<data name="&gt;&gt;tableMain.ZOrder" xml:space="preserve">
<value>0</value>
</data>
<data name="tableMain.LayoutSettings" type="System.Windows.Forms.TableLayoutSettings, System.Windows.Forms">
<value>&lt;?xml version="1.0" encoding="utf-16"?&gt;&lt;TableLayoutSettings&gt;&lt;Controls&gt;&lt;Control Name="flowButtons" Row="1" RowSpan="1" Column="0" ColumnSpan="1" /&gt;&lt;Control Name="_tabs" Row="0" RowSpan="1" Column="0" ColumnSpan="1" /&gt;&lt;/Controls&gt;&lt;Columns Styles="Percent,100" /&gt;&lt;Rows Styles="Percent,100,AutoSize,0,Absolute,20" /&gt;&lt;/TableLayoutSettings&gt;</value>
</data>
<metadata name="$this.Localizable" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
@ -714,6 +780,24 @@
<data name="&gt;&gt;columnLine.Type" xml:space="preserve">
<value>System.Windows.Forms.ColumnHeader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</data>
<data name="&gt;&gt;columnEvent.Name" xml:space="preserve">
<value>columnEvent</value>
</data>
<data name="&gt;&gt;columnEvent.Type" xml:space="preserve">
<value>System.Windows.Forms.ColumnHeader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</data>
<data name="&gt;&gt;columnCount.Name" xml:space="preserve">
<value>columnCount</value>
</data>
<data name="&gt;&gt;columnCount.Type" xml:space="preserve">
<value>System.Windows.Forms.ColumnHeader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</data>
<data name="&gt;&gt;columnId.Name" xml:space="preserve">
<value>columnId</value>
</data>
<data name="&gt;&gt;columnId.Type" xml:space="preserve">
<value>System.Windows.Forms.ColumnHeader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</data>
<data name="&gt;&gt;columnHeader1.Name" xml:space="preserve">
<value>columnHeader1</value>
</data>
@ -738,6 +822,12 @@
<data name="&gt;&gt;columnHeader4.Type" xml:space="preserve">
<value>System.Windows.Forms.ColumnHeader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</data>
<data name="&gt;&gt;columnEvents.Name" xml:space="preserve">
<value>columnEvents</value>
</data>
<data name="&gt;&gt;columnEvents.Type" xml:space="preserve">
<value>System.Windows.Forms.ColumnHeader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</data>
<data name="&gt;&gt;$this.Name" xml:space="preserve">
<value>DebugDialog</value>
</data>

View File

@ -41,37 +41,10 @@ namespace Acacia.Stubs.OutlookWrappers
{
}
protected override void DoRelease()
{
// Always release props, as we allocated that
if (_props != null)
{
ComRelease.Release(_props);
_props = null;
}
base.DoRelease();
}
#endregion
#region Properties implementation
// Assigned in Props, released in DoRelease
private NSOutlook.PropertyAccessor _props;
private NSOutlook.PropertyAccessor Props
{
get
{
if (_props == null)
{
_props = GetPropertyAccessor();
}
return _props;
}
}
/// <summary>
/// Returns the wrapped item's property accessor.
/// </summary>
@ -145,11 +118,11 @@ namespace Acacia.Stubs.OutlookWrappers
// into a string which must be parsed again.
get
{
return Props.GetProperty(OutlookConstants.PR_CATEGORIES);
return (string[])GetProperty(OutlookConstants.PR_CATEGORIES);
}
set
{
Props.SetProperty(OutlookConstants.PR_CATEGORIES, value);
SetProperty(OutlookConstants.PR_CATEGORIES, value);
}
}
@ -159,7 +132,7 @@ namespace Acacia.Stubs.OutlookWrappers
{
try
{
return Props.GetProperty(OutlookConstants.PR_ATTR_HIDDEN);
return (bool)GetProperty(OutlookConstants.PR_ATTR_HIDDEN);
}
catch(System.Exception)
{
@ -168,30 +141,51 @@ namespace Acacia.Stubs.OutlookWrappers
}
set
{
Props.SetProperty(OutlookConstants.PR_ATTR_HIDDEN, value);
SetProperty(OutlookConstants.PR_ATTR_HIDDEN, value);
}
}
public object GetProperty(string property)
{
NSOutlook.PropertyAccessor props = GetPropertyAccessor();
try
{
object val = Props.GetProperty(property);
object val = props.GetProperty(property);
if (val is DBNull)
return null;
return val;
}
catch(System.Exception) { return null; }
finally
{
ComRelease.Release(props);
}
}
public void SetProperty(string property, object value)
{
Props.SetProperty(property, value);
NSOutlook.PropertyAccessor props = GetPropertyAccessor();
try
{
props.SetProperty(property, value);
}
finally
{
ComRelease.Release(props);
}
}
public void SetProperties(string[] properties, object[] values)
{
Props.SetProperties(properties, values);
NSOutlook.PropertyAccessor props = GetPropertyAccessor();
try
{
props.SetProperties(properties, values);
}
finally
{
ComRelease.Release(props);
}
}
#endregion

View File

@ -22,6 +22,8 @@ using System.Threading.Tasks;
using Acacia.Stubs;
using Acacia.Stubs.OutlookWrappers;
using System.Reflection;
using System.Threading;
using System.Collections.Concurrent;
namespace Acacia.Utils
{
@ -360,13 +362,47 @@ namespace Acacia.Utils
}
}
public enum DebugEvent
{
BeforeDelete,
Forward,
PropertyChange,
Read,
Reply,
ReplyAll,
Unload,
Write,
Dispose,
GC
}
public interface MailEventDebug
{
string Id { get; }
int GetEventCount(DebugEvent which);
IEnumerable<DebugEvent> GetEvents();
}
public static IEnumerable<MailEventDebug> MailEventsDebug
{
get { return _hookers.Values; }
}
private static readonly ConcurrentDictionary<int, MailEventDebugImpl> _hookers = new ConcurrentDictionary<int, MailEventDebugImpl>();
private static int _nextHookerId;
private class MailEventHooker : DisposableWrapper
{
private readonly MailEventDebugImpl _debug;
private IItem _item;
private readonly MailEvents _events;
public MailEventHooker(IItem item, MailEvents events)
{
_debug = new MailEventDebugImpl(Interlocked.Increment(ref _nextHookerId));
_hookers.TryAdd(_debug._id, _debug);
this._item = item;
this._events = events;
HookEvents(true);
@ -374,7 +410,19 @@ namespace Acacia.Utils
protected override void DoRelease()
{
_item.Dispose();
if (_item != null)
{
_debug.RecordEvent(DebugEvent.Dispose);
_item.Dispose();
_item = null;
}
MailEventDebugImpl dummy;
_hookers.TryRemove(_debug._id, out dummy);
}
~MailEventHooker()
{
_debug.RecordEvent(DebugEvent.GC);
}
private void HookEvents(bool add)
@ -383,11 +431,10 @@ namespace Acacia.Utils
{
if (add)
{
events.Read += HandleRead;
events.BeforeDelete += HandleBeforeDelete;
events.Forward += HandleForward;
events.PropertyChange += HandlePropertyChange;
events.Read += HandleRead;
events.Reply += HandleReply;
events.ReplyAll += HandleReplyAll;
events.Unload += HandleUnload;
@ -395,10 +442,10 @@ namespace Acacia.Utils
}
else
{
events.Read -= HandleRead;
events.BeforeDelete -= HandleBeforeDelete;
events.Forward -= HandleForward;
events.PropertyChange -= HandlePropertyChange;
events.Read -= HandleRead;
events.Reply -= HandleReply;
events.ReplyAll -= HandleReplyAll;
events.Unload -= HandleUnload;
@ -409,41 +456,52 @@ namespace Acacia.Utils
private void HandleBeforeDelete(object item, ref bool cancel)
{
using (IItem wrapped = item.WrapOrDefault<IItem>(false))
_events.OnBeforeDelete(wrapped, ref cancel);
_debug.RecordEvent(DebugEvent.BeforeDelete);
//using (IItem wrapped = item.WrapOrDefault<IItem>(false))
// _events.OnBeforeDelete(wrapped, ref cancel);
}
private void HandleForward(object response, ref bool cancel)
{
using (IItem wrapped = response.WrapOrDefault<IItem>(false))
_events.OnForward(_item as IMailItem, wrapped as IMailItem);
_debug.RecordEvent(DebugEvent.Forward);
//using (IItem wrapped = response.WrapOrDefault<IItem>(false))
// _events.OnForward(_item as IMailItem, wrapped as IMailItem);
}
private void HandlePropertyChange(string name)
{
_events.OnPropertyChange(_item, name);
_debug.RecordEvent(DebugEvent.PropertyChange);
//_events.OnPropertyChange(_item, name);
}
private void HandleRead()
{
_debug.RecordEvent(DebugEvent.Read);
// TODO: should this not be simply an IItem?
_events.OnRead(_item as IMailItem);
IMailItem mail = _item as IMailItem;
if (mail != null)
{
_events.OnRead(mail);
}
}
private void HandleReply(object response, ref bool cancel)
{
using (IItem wrapped = response.WrapOrDefault<IItem>(false))
_events.OnReply(_item as IMailItem, wrapped as IMailItem);
_debug.RecordEvent(DebugEvent.Reply);
//using (IItem wrapped = response.WrapOrDefault<IItem>(false))
// _events.OnReply(_item as IMailItem, wrapped as IMailItem);
}
private void HandleReplyAll(object response, ref bool cancel)
{
using (IItem wrapped = response.WrapOrDefault<IItem>(false))
_events.OnReplyAll(_item as IMailItem, wrapped as IMailItem);
_debug.RecordEvent(DebugEvent.ReplyAll);
//using (IItem wrapped = response.WrapOrDefault<IItem>(false))
// _events.OnReplyAll(_item as IMailItem, wrapped as IMailItem);
}
private void HandleUnload()
{
_debug.RecordEvent(DebugEvent.Unload);
// All events must be unhooked on unload, otherwise a resource leak is created.
HookEvents(false);
Dispose();
@ -451,10 +509,42 @@ namespace Acacia.Utils
private void HandleWrite(ref bool cancel)
{
_events.OnWrite(_item, ref cancel);
_debug.RecordEvent(DebugEvent.Write);
//_events.OnWrite(_item, ref cancel);
}
}
private class MailEventDebugImpl : MailEventDebug
{
private readonly ConcurrentDictionary<DebugEvent, int> _eventCounts = new ConcurrentDictionary<DebugEvent, int>();
public readonly int _id;
public MailEventDebugImpl(int id)
{
this._id = id;
}
public int GetEventCount(DebugEvent which)
{
int count;
_eventCounts.TryGetValue(which, out count);
return count;
}
public void RecordEvent(DebugEvent which)
{
_eventCounts.AddOrUpdate(which, 1, (i, value) => value + 1);
}
public IEnumerable<DebugEvent> GetEvents()
{
return _eventCounts.Keys;
}
public string Id { get { return _id.ToString(); } }
}
#endregion
}
}