aboutsummaryrefslogtreecommitdiffstatsci
path: root/src
diff options
context:
space:
mode:
authorjpbruyere <jp.bruyere@hotmail.com>2016-02-04 19:29:28 +0100
committerjpbruyere <jp.bruyere@hotmail.com>2016-02-04 19:29:28 +0100
commit488add6f728a66abefb3c8c031ee973401925d49 (patch)
treeb11d92c55d559dbed3ceb2bc09650f214220f4da /src
parent7b8929e00f83ea8d5d176605ed7074a58f94cd86 (diff)
remove Lock for LayoutingQueue: no used for now
Diffstat (limited to 'src')
-rw-r--r--src/GraphicObjects/GraphicObject.cs12
-rw-r--r--src/OpenTKGameWindow.cs4
2 files changed, 7 insertions, 9 deletions
diff --git a/src/GraphicObjects/GraphicObject.cs b/src/GraphicObjects/GraphicObject.cs
index 6fe3a404..f6c9c84d 100644
--- a/src/GraphicObjects/GraphicObject.cs
+++ b/src/GraphicObjects/GraphicObject.cs
@@ -507,7 +507,7 @@ namespace Crow
#if DEBUG_LAYOUTING
Debug.WriteLine ("RegisterForLayouting => {1}->{0}", layoutType, this.ToString());
#endif
- lock (Interface.LayoutingQueue) {
+
deleteLQI (layoutType);
if ((layoutType & (int)LayoutingType.Width) > 0) {
if (Bounds.Width == 0) //stretch in parent
@@ -535,7 +535,7 @@ namespace Crow
//for x positionning, sizing of parent and this have to be done
Interface.LayoutingQueue.EnqueueAfterThisAndParentSizing (LayoutingType.Y, this);
}
- }
+
/// <summary> trigger dependant sizing component update </summary>
public virtual void OnLayoutChanges(LayoutingType layoutType)
@@ -702,11 +702,9 @@ namespace Crow
LastSlots.Height = Slot.Height;
break;
}
- lock (Interface.LayoutingQueue) {
- //if no layouting remains in queue for item, registre for redraw
- if (this.RegisteredLQIs.Count () <= 0 && bmp == null)
- this.RegisterForRedraw ();
- }
+ //if no layouting remains in queue for item, registre for redraw
+ if (this.RegisteredLQIs.Count () <= 0 && bmp == null)
+ this.RegisterForRedraw ();
}
/// <summary> This is the common overridable drawing routine to create new widget </summary>
diff --git a/src/OpenTKGameWindow.cs b/src/OpenTKGameWindow.cs
index b5317cef..587dd968 100644
--- a/src/OpenTKGameWindow.cs
+++ b/src/OpenTKGameWindow.cs
@@ -261,7 +261,7 @@ namespace Crow
invGOList = invGOList.Reverse ().ToArray ();
//Debug.WriteLine ("======= Layouting queue start =======");
- lock (Interface.LayoutingQueue) {
+
while (Interface.LayoutingQueue.Count > 0) {
// Stopwatch lqiProcTime = new Stopwatch ();
// lqiProcTime.Start ();
@@ -274,7 +274,7 @@ namespace Crow
// updateTime.ElapsedMilliseconds, lqi.ToString());
// }
}
- }
+
//Debug.WriteLine ("otd:" + gobjsToRedraw.Count.ToString () + "-");
//final redraw clips should be added only when layout is completed among parents,