Move Profile Manager to Resource Manager and rework size loading so that sizes are updated upon redetection

This commit is contained in:
Adam Honse 2020-10-08 17:07:39 -05:00
parent e767b3db90
commit e52619dbab
5 changed files with 62 additions and 13 deletions

View file

@ -146,8 +146,6 @@ int main(int argc, char* argv[])
std::vector<i2c_smbus_interface*> &busses = ResourceManager::get()->GetI2CBusses();
std::vector<RGBController*> &rgb_controllers = ResourceManager::get()->GetRGBControllers();
ProfileManager profile_manager(rgb_controllers);
if(!AttemptLocalConnection(rgb_controllers))
{
@ -160,7 +158,7 @@ int main(int argc, char* argv[])
unsigned int ret_flags = RET_FLAG_START_GUI;
if(argc > 1)
{
ret_flags = cli_main(argc, argv, rgb_controllers, &profile_manager);
ret_flags = cli_main(argc, argv, rgb_controllers, ResourceManager::get()->GetProfileManager());
}
/*---------------------------------------------------------*\
@ -173,7 +171,7 @@ int main(int argc, char* argv[])
QApplication::setAttribute(Qt::AA_EnableHighDpiScaling);
QApplication a(argc, argv);
Ui::OpenRGBDialog2 dlg(busses, rgb_controllers, &profile_manager);
Ui::OpenRGBDialog2 dlg(busses, rgb_controllers);
if(ret_flags & RET_FLAG_I2C_TOOLS)
{