StyleCop clean OpenRA.Game

This commit is contained in:
Matthias Mailänder
2015-01-02 15:11:36 +01:00
parent 9dd607c846
commit 44cd174a8d
61 changed files with 628 additions and 581 deletions

View File

@@ -30,16 +30,16 @@ namespace OpenRA.Support
List<PerfTimer> children;
long ticks;
static ThreadLocal<PerfTimer> Parent = new ThreadLocal<PerfTimer>();
static ThreadLocal<PerfTimer> parentThreadLocal = new ThreadLocal<PerfTimer>();
public PerfTimer(string name, float thresholdMs = 0)
{
this.name = name;
this.thresholdMs = thresholdMs;
parent = Parent.Value;
parent = parentThreadLocal.Value;
depth = parent == null ? (byte)0 : (byte)(parent.depth + 1);
Parent.Value = this;
parentThreadLocal.Value = this;
ticks = Stopwatch.GetTimestamp();
}
@@ -48,7 +48,7 @@ namespace OpenRA.Support
{
ticks = Stopwatch.GetTimestamp() - ticks;
Parent.Value = parent;
parentThreadLocal.Value = parent;
if (parent == null)
Write();