diff options
| author | Jean-Philippe Bruyère <jp_bruyere@hotmail.com> | 2017-01-03 14:51:10 +0100 |
|---|---|---|
| committer | Jean-Philippe Bruyère <jp_bruyere@hotmail.com> | 2017-01-03 14:52:17 +0100 |
| commit | da219db6d69beff054f58f1c9449bb5deb392860 (patch) | |
| tree | b4ce2d754161152182b82e8a44920b2fed09db12 /src/LayoutingQueueItem.cs | |
| parent | 3d3e97a4f86c5efd7292142f74dbd2f1168b61d0 (diff) | |
lqi as struct instead of class, output in debug layouring tries and discard if > 1
Diffstat (limited to 'src/LayoutingQueueItem.cs')
| -rw-r--r-- | src/LayoutingQueueItem.cs | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/src/LayoutingQueueItem.cs b/src/LayoutingQueueItem.cs index 2257ae8e..61646b15 100644 --- a/src/LayoutingQueueItem.cs +++ b/src/LayoutingQueueItem.cs @@ -41,7 +41,7 @@ namespace Crow /// <summary> /// Element class of the LayoutingQueue /// </summary> - public class LayoutingQueueItem + public struct LayoutingQueueItem { /// <summary> Instance of widget to be layouted</summary> public ILayoutable Layoutable; @@ -79,6 +79,8 @@ namespace Crow LayoutType = _layoutType; Layoutable = _graphicObject; Layoutable.RegisteredLayoutings |= LayoutType; + LayoutingTries = 0; + DiscardCount = 0; #if DEBUG_LAYOUTING GraphicObject g = graphicObject; g.CurrentInterface.curLQIs.Add(this); @@ -121,6 +123,11 @@ namespace Crow #endif } #if DEBUG_LAYOUTING + else{ + if (LayoutingTries > 1 || DiscardCount > 0) + Debug.WriteLine (this.ToString ()); + } + LQITime.Stop(); #endif } |