mirror of
https://github.com/CalcProgrammer1/OpenRGB.git
synced 2025-12-23 23:37:48 -05:00
Fix a bunch of warnings
This commit is contained in:
@@ -266,7 +266,7 @@ void RGBController_DRGB::SetupZones()
|
||||
}
|
||||
else if(channel_idx<16)
|
||||
{
|
||||
snprintf(ch_idx_string, 2, "%d", channel_idx-5 );
|
||||
snprintf(ch_idx_string, 3, "%d", channel_idx-5 );
|
||||
zones[channel_idx].name = "ARGB ";
|
||||
}
|
||||
}
|
||||
|
||||
@@ -158,9 +158,8 @@ void init_packet(FeaturePacket_Zone_761 * packet)
|
||||
|
||||
MSIMysticLight761Controller::MSIMysticLight761Controller
|
||||
(
|
||||
hid_device* handle,
|
||||
const char* path,
|
||||
unsigned short pid,
|
||||
hid_device* handle,
|
||||
const char* path,
|
||||
std::string dev_name
|
||||
)
|
||||
{
|
||||
@@ -169,7 +168,7 @@ MSIMysticLight761Controller::MSIMysticLight761Controller
|
||||
name = dev_name;
|
||||
|
||||
const mystic_light_761_config * board_config = nullptr;
|
||||
for(int i = 0; i < NUM_CONFS; i++)
|
||||
for(std::size_t i = 0; i < NUM_CONFS; i++)
|
||||
{
|
||||
if(*(board_configs[i].name) == name)
|
||||
{
|
||||
@@ -405,7 +404,7 @@ void MSIMysticLight761Controller::SetZoneColor
|
||||
}
|
||||
}
|
||||
|
||||
void set_data_color(FeaturePacket_Zone_761 * packet, int index, unsigned char color_val )
|
||||
void set_data_color(FeaturePacket_Zone_761 * packet, std::size_t index, unsigned char color_val )
|
||||
{
|
||||
if(packet == nullptr)
|
||||
{
|
||||
@@ -417,13 +416,12 @@ void set_data_color(FeaturePacket_Zone_761 * packet, int index, unsigned char co
|
||||
void MSIMysticLight761Controller::SetLedColor
|
||||
(
|
||||
MSI_ZONE zone,
|
||||
int index,
|
||||
std::size_t index,
|
||||
unsigned char red,
|
||||
unsigned char grn,
|
||||
unsigned char blu
|
||||
)
|
||||
{
|
||||
|
||||
FeaturePacket_Zone_761 * ptr = nullptr;
|
||||
switch(zone)
|
||||
{
|
||||
|
||||
@@ -27,9 +27,8 @@ class MSIMysticLight761Controller
|
||||
public:
|
||||
MSIMysticLight761Controller
|
||||
(
|
||||
hid_device* handle,
|
||||
const char* path,
|
||||
unsigned short pid,
|
||||
hid_device* handle,
|
||||
const char* path,
|
||||
std::string dev_name
|
||||
);
|
||||
|
||||
@@ -70,7 +69,7 @@ public:
|
||||
void SetLedColor
|
||||
(
|
||||
MSI_ZONE zone,
|
||||
int index,
|
||||
std::size_t index,
|
||||
unsigned char red,
|
||||
unsigned char grn,
|
||||
unsigned char blu
|
||||
|
||||
@@ -63,7 +63,7 @@ RGBController_MSIMysticLight761::RGBController_MSIMysticLight761
|
||||
|
||||
for(std::size_t i = 0; i < supported_zones->size(); ++i)
|
||||
{
|
||||
for(int j = 0; j < NUMOF_ZONES; ++j)
|
||||
for(std::size_t j = 0; j < NUMOF_ZONES; ++j)
|
||||
{
|
||||
if(led_zones[j].zone_type == (*supported_zones)[i])
|
||||
{
|
||||
|
||||
@@ -102,7 +102,7 @@ void DetectMSIMysticLightControllers
|
||||
|
||||
try
|
||||
{
|
||||
MSIMysticLight761Controller* controller = new MSIMysticLight761Controller(dev, (const char *) info->path, info->product_id, dmi_name);
|
||||
MSIMysticLight761Controller* controller = new MSIMysticLight761Controller(dev, (const char *) info->path, dmi_name);
|
||||
RGBController_MSIMysticLight761* rgb_controller = new RGBController_MSIMysticLight761(controller);
|
||||
ResourceManager::get()->RegisterRGBController(rgb_controller);
|
||||
}
|
||||
|
||||
@@ -220,7 +220,7 @@ void RGBController_QMKVialRGB::SetupZones()
|
||||
SetupColors();
|
||||
}
|
||||
|
||||
void RGBController_QMKVialRGB::ResizeZone(int zone, int new_size)
|
||||
void RGBController_QMKVialRGB::ResizeZone(int /*zone*/, int /*new_size*/)
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
@@ -120,7 +120,6 @@ unsigned char RazerKrakenV4Controller::GetMaxBrightness()
|
||||
void RazerKrakenV4Controller::SetDirect(RGBColor* colors)
|
||||
{
|
||||
struct razer_kraken_v4_report report = razer_kraken_v4_create_report(0x0F, 0x03, (5 + (3 * device_list[device_index]->cols)));
|
||||
struct razer_kraken_v4_report response_report = razer_kraken_v4_create_response();
|
||||
|
||||
report.arguments[2] = 0;
|
||||
report.arguments[3] = 0;
|
||||
@@ -139,7 +138,6 @@ void RazerKrakenV4Controller::SetDirect(RGBColor* colors)
|
||||
void RazerKrakenV4Controller::SetBrightness(unsigned char brightness)
|
||||
{
|
||||
struct razer_kraken_v4_report report = razer_kraken_v4_create_report(0x00, 0x00, 0x05);
|
||||
struct razer_kraken_v4_report response_report = razer_kraken_v4_create_response();
|
||||
|
||||
report.arguments[0] = RAZER_KRAKEN_V4_CMD_LIGHTING_SET_BRIGHTNESS;
|
||||
report.arguments[2] = 0x01;
|
||||
@@ -151,7 +149,6 @@ void RazerKrakenV4Controller::SetBrightness(unsigned char brightness)
|
||||
void RazerKrakenV4Controller::SetModeWave()
|
||||
{
|
||||
struct razer_kraken_v4_report report = razer_kraken_v4_create_report(0x00, 0x00, 0x05);
|
||||
struct razer_kraken_v4_report response_report = razer_kraken_v4_create_response();
|
||||
|
||||
report.arguments[0] = RAZER_KRAKEN_V4_CMD_LIGHTING_SET_MODE;
|
||||
report.arguments[2] = 0x01;
|
||||
|
||||
Reference in New Issue
Block a user