Hardware/CPU/CPUGroup.cs
changeset 195 0ee888c485d5
parent 191 6545fa3ae298
child 236 763675f19ff4
     1.1 --- a/Hardware/CPU/CPUGroup.cs	Tue Sep 21 10:33:28 2010 +0000
     1.2 +++ b/Hardware/CPU/CPUGroup.cs	Tue Sep 21 20:32:36 2010 +0000
     1.3 @@ -43,9 +43,9 @@
     1.4  namespace OpenHardwareMonitor.Hardware.CPU {
     1.5  
     1.6    internal class CPUGroup : IGroup { 
     1.7 -    private List<IHardware> hardware = new List<IHardware>();
     1.8 +    private readonly List<IHardware> hardware = new List<IHardware>();
     1.9  
    1.10 -    private CPUID[][][] threads;
    1.11 +    private readonly CPUID[][][] threads;
    1.12  
    1.13      private static CPUID[][] GetProcessorThreads() {
    1.14  
    1.15 @@ -77,7 +77,7 @@
    1.16        return processorThreads;
    1.17      }
    1.18  
    1.19 -    private static CPUID[][] GroupThreadsByCore(CPUID[] threads) {
    1.20 +    private static CPUID[][] GroupThreadsByCore(IEnumerable<CPUID> threads) {
    1.21  
    1.22        SortedDictionary<uint, List<CPUID>> cores = 
    1.23          new SortedDictionary<uint, List<CPUID>>();
    1.24 @@ -102,7 +102,7 @@
    1.25  
    1.26      public CPUGroup(ISettings settings) {
    1.27        // No implementation for cpuid on Unix systems
    1.28 -      int p = (int)System.Environment.OSVersion.Platform;
    1.29 +      int p = (int)Environment.OSVersion.Platform;
    1.30        if ((p == 4) || (p == 128)) 
    1.31          return;
    1.32