MCPcopy Create free account
hub / github.com/CalcProgrammer1/OpenRGB / OptionColor

Function OptionColor

cli.cpp:658–682  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

656}
657
658bool OptionColor(std::vector<DeviceOptions>* current_devices, std::string argument, Options* options)
659{
660 /*---------------------------------------------------------*\
661 | If a device is not selected i.e. size() == 0 |
662 | then add color to allDeviceOptions |
663 \*---------------------------------------------------------*/
664 bool found = false;
665 DeviceOptions* currentDevOpts = &options->allDeviceOptions;
666
667 if(current_devices->size() == 0)
668 {
669 found = CheckColor(argument, currentDevOpts);
670 }
671 else
672 {
673 for(size_t i = 0; i < current_devices->size(); i++)
674 {
675 currentDevOpts = &current_devices->at(i);
676
677 found = CheckColor(argument, currentDevOpts);
678 }
679 }
680
681 return found;
682}
683
684bool OptionMode(std::vector<DeviceOptions>* current_devices, std::string argument, Options* options)
685{

Callers 1

ProcessOptionsFunction · 0.85

Calls 2

CheckColorFunction · 0.85
sizeMethod · 0.45

Tested by

no test coverage detected