Hardware/RAM/RAMGroup.cs
author moel.mich
Tue, 24 Jul 2012 16:04:30 +0000
changeset 371 c1a0d321e646
child 372 2de3a3e5f0b5
permissions -rw-r--r--
Added a wrapper for the NotifyIconAdv to use the normal NotifyIcon class on Linux systems and the (fixed) custom implementation on Windows systems.
     1 /*
     2  
     3   This Source Code Form is subject to the terms of the Mozilla Public
     4   License, v. 2.0. If a copy of the MPL was not distributed with this
     5   file, You can obtain one at http://mozilla.org/MPL/2.0/.
     6  
     7   Copyright (C) 2012 Michael Möller <mmoeller@openhardwaremonitor.org>
     8 	
     9 */
    10 
    11 namespace OpenHardwareMonitor.Hardware.RAM {
    12   internal class RAMGroup : IGroup {
    13 
    14     private IHardware[] hardware;
    15 
    16     public RAMGroup(SMBIOS smbios, ISettings settings) {
    17       string name;
    18       if (smbios.MemoryDevices.Length > 0) {
    19         name = smbios.MemoryDevices[0].ManufacturerName + " " + 
    20           smbios.MemoryDevices[0].PartNumber;
    21       } else {
    22         name = "Generic Memory";
    23       }
    24 
    25       hardware = new IHardware[] { new GenericRAM(name, settings) };
    26     }
    27 
    28     public string GetReport() {
    29       return null;
    30     }
    31 
    32     public IHardware[] Hardware {
    33       get {
    34         return hardware;
    35       }
    36     }
    37 
    38     public void Close() {
    39 
    40     }
    41   }
    42 }