aboutsummaryrefslogtreecommitdiffstatsci
path: root/src/Interface.cs
diff options
context:
space:
mode:
authorjpbruyere <jp.bruyere@hotmail.com>2017-06-15 17:32:04 +0200
committerjpbruyere <jp.bruyere@hotmail.com>2017-06-15 17:32:04 +0200
commit1fdbaaf4ae209e26ef8767ae13ebb9aa9d1f79c7 (patch)
tree5586932c635ca68a67bddcb83918b74ecad79758 /src/Interface.cs
parent570f6f9b7c9ed25adf618b02f5cfe0f1b3e9afe7 (diff)
Revert "replace foreach loops with for ones"
This reverts commit 1c3263454961eb207a01b67c51d0acf88376d522.
Diffstat (limited to 'src/Interface.cs')
-rw-r--r--src/Interface.cs8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/Interface.cs b/src/Interface.cs
index f451dc56..8439c31e 100644
--- a/src/Interface.cs
+++ b/src/Interface.cs
@@ -630,8 +630,8 @@ namespace Crow
/// <summary>Search a Graphic object in the tree named 'nameToFind'</summary>
public GraphicObject FindByName (string nameToFind)
{
- for (int i = 0; i < GraphicTree.Count; i++) {
- GraphicObject r = GraphicTree[i].FindByName (nameToFind);
+ foreach (GraphicObject w in GraphicTree) {
+ GraphicObject r = w.FindByName (nameToFind);
if (r != null)
return r;
}
@@ -647,8 +647,8 @@ namespace Crow
int bmpSize = Math.Abs (stride) * ClientRectangle.Height;
bmp = new byte[bmpSize];
- for (int i = 0; i < GraphicTree.Count; i++)
- GraphicTree[i].RegisterForLayouting (LayoutingType.All);
+ foreach (GraphicObject g in GraphicTree)
+ g.RegisterForLayouting (LayoutingType.All);
clipping.AddRectangle (clientRectangle);
}