Remove SetCustomMode from all controllers beginning with the letter A

This commit is contained in:
Adam Honse 2022-08-09 22:58:40 -05:00
parent 58b1a29076
commit eab96d1b36
48 changed files with 67 additions and 221 deletions

View file

@ -168,11 +168,6 @@ void RGBController_BloodyMouse::UpdateSingleLED(int /*led*/)
DeviceUpdateLEDs();
}
void RGBController_BloodyMouse::SetCustomMode()
{
active_mode = 0;
}
void RGBController_BloodyMouse::DeviceUpdateMode()
{
/*---------------------------------------------------------*\

View file

@ -34,7 +34,6 @@ public:
void UpdateZoneLEDs(int zone);
void UpdateSingleLED(int led);
void SetCustomMode();
void DeviceUpdateMode();
private:

View file

@ -236,11 +236,6 @@ void RGBController_AMDWraithPrism::UpdateSingleLED(int led)
UpdateZoneLEDs(led);
}
void RGBController_AMDWraithPrism::SetCustomMode()
{
active_mode = 0;
}
void RGBController_AMDWraithPrism::DeviceUpdateMode()
{
bool random = (modes[active_mode].color_mode == MODE_COLORS_RANDOM);

View file

@ -25,7 +25,6 @@ public:
void UpdateZoneLEDs(int zone);
void UpdateSingleLED(int led);
void SetCustomMode();
void DeviceUpdateMode();
private:

View file

@ -336,11 +336,6 @@ unsigned char RGBController_PolychromeUSB::GetDeviceMode(unsigned char zone)
return(active_mode);
}
void RGBController_PolychromeUSB::SetCustomMode()
{
active_mode = POLYCHROME_USB_MODE_DIRECT;
}
void RGBController_PolychromeUSB::DeviceUpdateMode()
{
for(unsigned int zone_idx = 0; zone_idx < zones.size(); zone_idx++)

View file

@ -25,7 +25,6 @@ public:
void UpdateZoneLEDs(int zone);
void UpdateSingleLED(int led);
void SetCustomMode();
void DeviceUpdateMode();
private:

View file

@ -26,14 +26,14 @@
RGBController_ASRockASRRGBSMBus::RGBController_ASRockASRRGBSMBus(ASRockASRRGBSMBusController* controller_ptr)
{
controller = controller_ptr;
controller = controller_ptr;
name = controller->GetDeviceName();
vendor = "ASRock";
version = controller->GetFirmwareVersion();
type = DEVICE_TYPE_MOTHERBOARD;
description = "ASRock ASR RGB LED Device";
location = controller->GetDeviceLocation();
name = controller->GetDeviceName();
vendor = "ASRock";
version = controller->GetFirmwareVersion();
type = DEVICE_TYPE_MOTHERBOARD;
description = "ASRock ASR RGB LED Device";
location = controller->GetDeviceLocation();
mode Off;
Off.name = "Off";
@ -196,11 +196,6 @@ void RGBController_ASRockASRRGBSMBus::UpdateSingleLED(int led)
controller->SetColorsAndSpeed(led, red, grn, blu);
}
void RGBController_ASRockASRRGBSMBus::SetCustomMode()
{
active_mode = 1;
}
void RGBController_ASRockASRRGBSMBus::DeviceUpdateMode()
{

View file

@ -26,7 +26,6 @@ public:
void UpdateZoneLEDs(int zone);
void UpdateSingleLED(int led);
void SetCustomMode();
void DeviceUpdateMode();
private:

View file

@ -38,14 +38,14 @@ static const char* polychrome_v1_zone_names[] =
RGBController_ASRockPolychromeV1SMBus::RGBController_ASRockPolychromeV1SMBus(ASRockPolychromeV1SMBusController* controller_ptr)
{
controller = controller_ptr;
controller = controller_ptr;
name = controller->GetDeviceName();
vendor = "ASRock";
version = controller->GetFirmwareVersion();
type = DEVICE_TYPE_MOTHERBOARD;
description = "ASRock Polychrome v1 Device";
location = controller->GetDeviceLocation();
name = controller->GetDeviceName();
vendor = "ASRock";
version = controller->GetFirmwareVersion();
type = DEVICE_TYPE_MOTHERBOARD;
description = "ASRock Polychrome v1 Device";
location = controller->GetDeviceLocation();
mode Off;
@ -329,11 +329,6 @@ void RGBController_ASRockPolychromeV1SMBus::UpdateSingleLED(int zone)
controller->SetColorsAndSpeed(zoneIndexMap[zone], red, grn, blu);
}
void RGBController_ASRockPolychromeV1SMBus::SetCustomMode()
{
active_mode = getModeIndex(POLYCHROME_V1_MODE_STATIC);
}
void RGBController_ASRockPolychromeV1SMBus::DeviceUpdateMode()
{
LOG_TRACE("[%s] DeviceUpdateMode()", name.c_str());

View file

@ -26,7 +26,6 @@ public:
void UpdateZoneLEDs(int zone);
void UpdateSingleLED(int led);
void SetCustomMode();
void DeviceUpdateMode();
private:

View file

@ -33,14 +33,14 @@ static const char* polychrome_v2_zone_names[] =
RGBController_ASRockPolychromeV2SMBus::RGBController_ASRockPolychromeV2SMBus(ASRockPolychromeV2SMBusController* controller_ptr)
{
controller = controller_ptr;
controller = controller_ptr;
name = controller->GetDeviceName();
vendor = "ASRock";
version = controller->GetFirmwareVersion();
type = DEVICE_TYPE_MOTHERBOARD;
description = "ASRock Polychrome v2 Device";
location = controller->GetDeviceLocation();
name = controller->GetDeviceName();
vendor = "ASRock";
version = controller->GetFirmwareVersion();
type = DEVICE_TYPE_MOTHERBOARD;
description = "ASRock Polychrome v2 Device";
location = controller->GetDeviceLocation();
mode Off;
@ -316,11 +316,6 @@ void RGBController_ASRockPolychromeV2SMBus::UpdateSingleLED(int led)
controller->SetColorsAndSpeed(led, red, grn, blu);
}
void RGBController_ASRockPolychromeV2SMBus::SetCustomMode()
{
active_mode = 1;
}
void RGBController_ASRockPolychromeV2SMBus::DeviceUpdateMode()
{

View file

@ -26,7 +26,6 @@ public:
void UpdateZoneLEDs(int zone);
void UpdateSingleLED(int led);
void SetCustomMode();
void DeviceUpdateMode();
private:

View file

@ -179,11 +179,6 @@ void RGBController_Alienware::UpdateSingleLED(int led)
UpdateZoneLEDs(led);
}
void RGBController_Alienware::SetCustomMode()
{
active_mode = 0;
}
static bool modes_eq(const mode& mode1, const mode& mode2)
{
return( ( mode1.name == mode2.name )

View file

@ -29,8 +29,6 @@ public:
void DeviceUpdateMode();
void SetCustomMode();
private:
AlienwareController* controller;
std::chrono::steady_clock::time_point last_packet_ts;

View file

@ -171,21 +171,21 @@ static const led_type led_names[] =
RGBController_AlienwareAW510K::RGBController_AlienwareAW510K(AlienwareAW510KController* controller_ptr)
{
controller = controller_ptr;
controller = controller_ptr;
name = "Alienware AW510K Keyboard Device";
vendor = "Alienware";
type = DEVICE_TYPE_KEYBOARD;
description = "Alienware AW510K Keyboard Device";
location = controller->GetDeviceLocation();
serial = controller->GetSerialString();
name = "Alienware AW510K Keyboard Device";
vendor = "Alienware";
type = DEVICE_TYPE_KEYBOARD;
description = "Alienware AW510K Keyboard Device";
location = controller->GetDeviceLocation();
serial = controller->GetSerialString();
mode Direct_Per_LED;
Direct_Per_LED.name = "Direct";
Direct_Per_LED.value = ALIENWARE_AW510K_MODE_DIRECT_PER_LED;
Direct_Per_LED.flags = MODE_FLAG_HAS_PER_LED_COLOR;
Direct_Per_LED.color_mode = MODE_COLORS_PER_LED;
modes.push_back(Direct_Per_LED);
mode Direct;
Direct.name = "Direct";
Direct.value = ALIENWARE_AW510K_MODE_DIRECT_PER_LED;
Direct.flags = MODE_FLAG_HAS_PER_LED_COLOR;
Direct.color_mode = MODE_COLORS_PER_LED;
modes.push_back(Direct);
mode Static;
Static.name = "Static";
@ -403,11 +403,6 @@ void RGBController_AlienwareAW510K::UpdateSingleLED(int led)
controller->UpdateSingleLED(leds[led].value, RGBGetRValue(colors[led]), RGBGetGValue(colors[led]), RGBGetBValue(colors[led]));
}
void RGBController_AlienwareAW510K::SetCustomMode()
{
active_mode = 0;
}
void RGBController_AlienwareAW510K::DeviceUpdateMode()
{
if(active_mode == 0xFFFF)

View file

@ -26,7 +26,6 @@ public:
void UpdateZoneLEDs(int zone);
void UpdateSingleLED(int led);
void SetCustomMode();
void DeviceUpdateMode();
private:

View file

@ -236,11 +236,6 @@ void RGBController_AnnePro2::UpdateSingleLED(int /*led*/)
DeviceUpdateLEDs();
}
void RGBController_AnnePro2::SetCustomMode()
{
active_mode = 0;
}
void RGBController_AnnePro2::DeviceUpdateMode()
{

View file

@ -24,7 +24,6 @@ public:
void UpdateZoneLEDs(int zone);
void UpdateSingleLED(int led);
void SetCustomMode();
void DeviceUpdateMode();
private:

View file

@ -44,39 +44,39 @@ RGBController_AuraCore::RGBController_AuraCore(AuraCoreController* controller_pt
void RGBController_AuraCore::SetupKeyboard()
{
name = "ASUS Aura Keyboard";
vendor = "ASUS";
type = DEVICE_TYPE_KEYBOARD;
description = "ASUS Aura Core Device";
name = "ASUS Aura Keyboard";
vendor = "ASUS";
type = DEVICE_TYPE_KEYBOARD;
description = "ASUS Aura Core Device";
mode Static;
Static.name = "Static";
Static.value = AURA_CORE_MODE_STATIC;
Static.flags = MODE_FLAG_HAS_PER_LED_COLOR;
Static.color_mode = MODE_COLORS_PER_LED;
Static.name = "Static";
Static.value = AURA_CORE_MODE_STATIC;
Static.flags = MODE_FLAG_HAS_PER_LED_COLOR;
Static.color_mode = MODE_COLORS_PER_LED;
modes.push_back(Static);
mode Breathing;
Breathing.name = "Breathing";
Breathing.value = AURA_CORE_MODE_BREATHING;
Breathing.flags = MODE_FLAG_HAS_PER_LED_COLOR;
Breathing.color_mode = MODE_COLORS_PER_LED;
Breathing.name = "Breathing";
Breathing.value = AURA_CORE_MODE_BREATHING;
Breathing.flags = MODE_FLAG_HAS_PER_LED_COLOR;
Breathing.color_mode = MODE_COLORS_PER_LED;
modes.push_back(Breathing);
mode ColorCycle;
ColorCycle.name = "Color Cycle";
ColorCycle.value = AURA_CORE_MODE_SPECTRUM_CYCLE;
ColorCycle.flags = 0;
ColorCycle.color_mode = MODE_COLORS_NONE;
ColorCycle.name = "Color Cycle";
ColorCycle.value = AURA_CORE_MODE_SPECTRUM_CYCLE;
ColorCycle.flags = 0;
ColorCycle.color_mode = MODE_COLORS_NONE;
modes.push_back(ColorCycle);
}
void RGBController_AuraCore::SetupGA15DH()
{
name = "ASUS Aura GA15DH";
vendor = "ASUS";
type = DEVICE_TYPE_LEDSTRIP;
description = "ASUS Aura Core Device";
name = "ASUS Aura GA15DH";
vendor = "ASUS";
type = DEVICE_TYPE_LEDSTRIP;
description = "ASUS Aura Core Device";
mode Static;
Static.name = "Static";
@ -160,10 +160,10 @@ void RGBController_AuraCore::SetupGA15DH()
modes.push_back(Irradiation);
mode Direct;
Static.name = "Direct";
Static.value = AURA_CORE_MODE_DIRECT;
Static.flags = MODE_FLAG_HAS_PER_LED_COLOR;
Static.color_mode = MODE_COLORS_PER_LED;
Static.name = "Direct";
Static.value = AURA_CORE_MODE_DIRECT;
Static.flags = MODE_FLAG_HAS_PER_LED_COLOR;
Static.color_mode = MODE_COLORS_PER_LED;
modes.push_back(Static);
}
@ -312,11 +312,6 @@ void RGBController_AuraCore::UpdateSingleLED(int led)
controller->SendApply();
}
void RGBController_AuraCore::SetCustomMode()
{
active_mode = 0;
}
void RGBController_AuraCore::DeviceUpdateMode()
{
if(modes[active_mode].value == AURA_CORE_MODE_DIRECT)

View file

@ -27,7 +27,6 @@ public:
void UpdateZoneLEDs(int zone);
void UpdateSingleLED(int led);
void SetCustomMode();
void DeviceUpdateMode();
private:

View file

@ -475,11 +475,6 @@ void RGBController_AsusAuraCoreLaptop::UpdateSingleLED(int led)
controller->SetLedsDirect(colour);
}
void RGBController_AsusAuraCoreLaptop::SetCustomMode()
{
active_mode = 0;
}
void RGBController_AsusAuraCoreLaptop::DeviceUpdateMode()
{
mode set_mode = modes[active_mode];

View file

@ -26,7 +26,6 @@ public:
void UpdateZoneLEDs(int zone);
void UpdateSingleLED(int led);
void SetCustomMode();
void DeviceUpdateMode();
private:

View file

@ -183,11 +183,6 @@ void RGBController_AuraGPU::UpdateSingleLED(int /*led*/)
DeviceUpdateLEDs();
}
void RGBController_AuraGPU::SetCustomMode()
{
active_mode = 0;
}
void RGBController_AuraGPU::DeviceUpdateMode()
{
int new_mode = modes[active_mode].value;

View file

@ -25,7 +25,6 @@ public:
void UpdateZoneLEDs(int zone);
void UpdateSingleLED(int led);
void SetCustomMode();
void DeviceUpdateMode();
private:

View file

@ -177,12 +177,6 @@ void RGBController_AuraHeadsetStand::UpdateSingleLED(int /*led*/)
DeviceUpdateLEDs();
}
void RGBController_AuraHeadsetStand::SetCustomMode()
{
active_mode = 0;
}
void RGBController_AuraHeadsetStand::DeviceUpdateMode()
{
unsigned char red = 0;

View file

@ -35,7 +35,6 @@ public:
void UpdateZoneLEDs(int zone);
void UpdateSingleLED(int led);
void SetCustomMode();
void DeviceUpdateMode();
void DeviceSaveMode();

View file

@ -527,11 +527,6 @@ void RGBController_AuraKeyboard::UpdateSingleLED(int /*led*/)
DeviceUpdateLEDs();
}
void RGBController_AuraKeyboard::SetCustomMode()
{
active_mode = 0;
}
void RGBController_AuraKeyboard::DeviceUpdateMode()
{

View file

@ -48,7 +48,6 @@ public:
void UpdateZoneLEDs(int zone);
void UpdateSingleLED(int led);
void SetCustomMode();
void DeviceUpdateMode();
private:

View file

@ -112,12 +112,6 @@ void RGBController_AuraMonitor::UpdateSingleLED(int led)
controller->ApplyChanges();
}
void RGBController_AuraMonitor::SetCustomMode()
{
active_mode = 0;
}
void RGBController_AuraMonitor::DeviceUpdateMode()
{
/*---------------------------------------------------------*\

View file

@ -25,7 +25,6 @@ public:
void UpdateZoneLEDs(int zone);
void UpdateSingleLED(int led);
void SetCustomMode();
void DeviceUpdateMode();
void DeviceSaveMode();

View file

@ -221,11 +221,6 @@ void RGBController_AuraMouse::UpdateSingleLED(int led)
controller->SendUpdate(leds[led].value, modes[active_mode].value, red, grn, blu, 0, false, 0, modes[active_mode].brightness);
}
void RGBController_AuraMouse::SetCustomMode()
{
active_mode = 0;
}
void RGBController_AuraMouse::DeviceUpdateMode()
{
if(modes[active_mode].color_mode == MODE_COLORS_PER_LED)

View file

@ -25,7 +25,6 @@ public:
void UpdateZoneLEDs(int zone);
void UpdateSingleLED(int led);
void SetCustomMode();
void DeviceUpdateMode();
void DeviceSaveMode();

View file

@ -22,15 +22,15 @@
RGBController_AuraMousemat::RGBController_AuraMousemat(AuraMousematController* controller_ptr)
{
controller = controller_ptr;
controller = controller_ptr;
name = "ASUS Aura Mousemat";
vendor = "ASUS";
type = DEVICE_TYPE_MOUSEMAT;
description = "ASUS Aura Mousemat Device";
version = controller->GetVersion();
location = controller->GetDeviceLocation();
serial = controller->GetSerialString();
name = "ASUS Aura Mousemat";
vendor = "ASUS";
type = DEVICE_TYPE_MOUSEMAT;
description = "ASUS Aura Mousemat Device";
version = controller->GetVersion();
location = controller->GetDeviceLocation();
serial = controller->GetSerialString();
mode Direct;
Direct.name = "Direct";
@ -230,11 +230,6 @@ void RGBController_AuraMousemat::UpdateSingleLED(int /*led*/)
DeviceUpdateLEDs();
}
void RGBController_AuraMousemat::SetCustomMode()
{
active_mode = 0;
}
void RGBController_AuraMousemat::DeviceUpdateMode()
{
if(modes[active_mode].value == AURA_MOUSEMAT_MODE_DIRECT)

View file

@ -43,7 +43,6 @@ public:
void UpdateZoneLEDs(int zone);
void UpdateSingleLED(int led);
void SetCustomMode();
void DeviceUpdateMode();
void DeviceSaveMode();

View file

@ -194,11 +194,6 @@ void RGBController_AsusAuraRyuoAIO::UpdateSingleLED(int led)
UpdateZoneLEDs(GetLED_Zone(led));
}
void RGBController_AsusAuraRyuoAIO::SetCustomMode()
{
active_mode = 0;
}
void RGBController_AsusAuraRyuoAIO::DeviceUpdateMode()
{
RGBColor colour = (modes[active_mode].color_mode == MODE_COLORS_MODE_SPECIFIC) ? modes[active_mode].colors[0] : 0;

View file

@ -27,8 +27,8 @@ public:
void UpdateZoneLEDs(int zone);
void UpdateSingleLED(int led);
void SetCustomMode();
void DeviceUpdateMode();
private:
int GetDeviceMode();
int GetLED_Zone(int led_idx);

View file

@ -129,11 +129,6 @@ void RGBController_AuraStrixEvolve::UpdateSingleLED(int /*led*/)
DeviceUpdateLEDs();
}
void RGBController_AuraStrixEvolve::SetCustomMode()
{
active_mode = 0;
}
void RGBController_AuraStrixEvolve::DeviceUpdateMode()
{
unsigned char red = RGBGetRValue(colors[0]);

View file

@ -32,7 +32,6 @@ public:
void UpdateZoneLEDs(int zone);
void UpdateSingleLED(int led);
void SetCustomMode();
void DeviceUpdateMode();
void DeviceSaveMode();

View file

@ -271,11 +271,6 @@ void RGBController_AuraTUFKeyboard::UpdateSingleLED(int led)
controller->UpdateSingleLed(led, red, green, blue);
}
void RGBController_AuraTUFKeyboard::SetCustomMode()
{
active_mode = 0;
}
void RGBController_AuraTUFKeyboard::DeviceUpdateMode()
{
unsigned char color_mode;

View file

@ -35,7 +35,6 @@ public:
void UpdateZoneLEDs(int zone);
void UpdateSingleLED(int led);
void SetCustomMode();
void DeviceUpdateMode();
void DeviceSaveMode();

View file

@ -249,11 +249,6 @@ void RGBController_AuraUSB::UpdateSingleLED(int led)
controller->SetChannelLEDs(channel, zones[channel].colors, zones[channel].leds_count);
}
void RGBController_AuraUSB::SetCustomMode()
{
}
void RGBController_AuraUSB::DeviceUpdateMode()
{
initializedMode = true;

View file

@ -27,7 +27,6 @@ public:
void UpdateZoneLEDs(int zone);
void UpdateSingleLED(int led);
void SetCustomMode();
void DeviceUpdateMode();
private:

View file

@ -196,18 +196,6 @@ void RGBController_ROGStrixLC_Controller::UpdateSingleLED(int led)
UpdateZoneLEDs(GetLED_Zone(led));
}
void RGBController_ROGStrixLC_Controller::SetCustomMode()
{
for(std::size_t mode_idx = 0; mode_idx < modes.size() ; mode_idx++)
{
if (modes[mode_idx].value == ROGSTRIXLC_CONTROLLER_MODE_DIRECT)
{
active_mode = mode_idx;
break;
}
}
}
void RGBController_ROGStrixLC_Controller::DeviceUpdateMode()
{
RGBColor colour = (modes[active_mode].color_mode == MODE_COLORS_MODE_SPECIFIC) ? modes[active_mode].colors[0] : 0;

View file

@ -27,7 +27,6 @@ public:
void UpdateZoneLEDs(int zone);
void UpdateSingleLED(int led);
void SetCustomMode();
void DeviceUpdateMode();
private:
int GetDeviceMode();

View file

@ -115,11 +115,6 @@ void RGBController_StrixClaw::UpdateSingleLED(int /*led*/)
}
void RGBController_StrixClaw::SetCustomMode()
{
}
void RGBController_StrixClaw::DeviceUpdateMode()
{
if(modes[active_mode].value == 0)

View file

@ -26,7 +26,6 @@ public:
void UpdateZoneLEDs(int zone);
void UpdateSingleLED(int led);
void SetCustomMode();
void DeviceUpdateMode();
private:

View file

@ -141,11 +141,6 @@ void RGBController_AsusTUFLaptopWMI::UpdateSingleLED(int /*led*/)
DeviceUpdateLEDs();
}
void RGBController_AsusTUFLaptopWMI::SetCustomMode()
{
SetMode(0);
}
void RGBController_AsusTUFLaptopWMI::DeviceUpdateMode()
{
DeviceUpdateLEDs();

View file

@ -20,8 +20,6 @@ public:
void UpdateSingleLED(int led) override;
void DeviceUpdateMode() override;
void SetCustomMode() override;
};
#endif