protected override Size ArrangeOverride(Size finalSize) { long startTicks = Stopwatch.GetTimestamp(); Size sz = base.ArrangeOverride(finalSize); long endTicks = Stopwatch.GetTimestamp(); double ticks = (double)(endTicks - startTicks); double nanoSecs = PerfStatic.GetNanoSecondsFromTicks(ticks, Stopwatch.Frequency); arrangeNanoSecsTotal += nanoSecs; arrangeCount++; return(sz); }
protected override Size MeasureOverride(Size availableSize) { long startTicks = Stopwatch.GetTimestamp(); Size sz = base.MeasureOverride(availableSize); long endTicks = Stopwatch.GetTimestamp(); double ticks = (double)(endTicks - startTicks); double nanoSecs = PerfStatic.GetNanoSecondsFromTicks(ticks, Stopwatch.Frequency); measureNanoSecsTotal += nanoSecs; measureCount++; return(sz); }