Rework RGBControllers and detectors that set string fields other than name outside of the RGBController
This commit is contained in:
parent
6a472437bb
commit
abd34f1810
15 changed files with 40 additions and 27 deletions
|
|
@ -52,6 +52,7 @@ RGBController_ENESMBus::RGBController_ENESMBus(ENESMBusController * controller_p
|
|||
| the ENE controller's version string |
|
||||
\*---------------------------------------------------------*/
|
||||
version = controller->GetDeviceName();
|
||||
location = controller->GetDeviceLocation();
|
||||
|
||||
if((version.find("DIMM_LED") != std::string::npos) || (version.find("AUDA") != std::string::npos) )
|
||||
{
|
||||
|
|
@ -65,6 +66,12 @@ RGBController_ENESMBus::RGBController_ENESMBus(ENESMBusController * controller_p
|
|||
name = "ASUS ROG Strix Arion";
|
||||
vendor = "ASUS";
|
||||
}
|
||||
else if(location.find("NVMe:") != std::string::npos)
|
||||
{
|
||||
type = DEVICE_TYPE_STORAGE;
|
||||
name = "XPG Spectrix S40G";
|
||||
vendor = "XPG";
|
||||
}
|
||||
else
|
||||
{
|
||||
type = DEVICE_TYPE_MOTHERBOARD;
|
||||
|
|
@ -72,7 +79,6 @@ RGBController_ENESMBus::RGBController_ENESMBus(ENESMBusController * controller_p
|
|||
vendor = "ASUS";
|
||||
}
|
||||
|
||||
location = controller->GetDeviceLocation();
|
||||
description = "ENE SMBus Device";
|
||||
|
||||
mode Direct;
|
||||
|
|
|
|||
|
|
@ -82,10 +82,6 @@ void DetectSpectrixS40GControllers()
|
|||
ENESMBusController* controller = new ENESMBusController(interface, 0x67);
|
||||
RGBController_ENESMBus* rgb_controller = new RGBController_ENESMBus(controller);
|
||||
|
||||
rgb_controller->name = "XPG Spectrix S40G";
|
||||
rgb_controller->type = DEVICE_TYPE_STORAGE;
|
||||
rgb_controller->vendor = "XPG";
|
||||
|
||||
ResourceManager::get()->RegisterRGBController(rgb_controller);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -116,10 +116,6 @@ void DetectSpectrixS40GControllers()
|
|||
ENESMBusController* controller = new ENESMBusController(interface, 0x67);
|
||||
RGBController_ENESMBus* rgb_controller = new RGBController_ENESMBus(controller);
|
||||
|
||||
rgb_controller->name = "XPG Spectrix S40G";
|
||||
rgb_controller->type = DEVICE_TYPE_STORAGE;
|
||||
rgb_controller->vendor = "XPG";
|
||||
|
||||
ResourceManager::get()->RegisterRGBController(rgb_controller);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue