GUI rework to provide more control over optional tabs to main.cpp, add TODO comments for client mode

This commit is contained in:
Adam Honse
2020-06-28 03:00:35 -05:00
parent 15ace9d094
commit a25f3ef2fc
3 changed files with 52 additions and 41 deletions

View File

@@ -70,14 +70,23 @@ int main(int argc, char* argv[])
QApplication::setAttribute(Qt::AA_EnableHighDpiScaling);
QApplication a(argc, argv);
bool show_i2c_tools = false;
Ui::OpenRGBDialog2 dlg(busses, rgb_controllers, &profile_manager, &server);
if(ret_flags & RET_FLAG_I2C_TOOLS)
{
//I2C Tools is enabled
show_i2c_tools = true;
dlg.AddI2CToolsPage();
}
Ui::OpenRGBDialog2 dlg(busses, rgb_controllers, &profile_manager, &server, show_i2c_tools);
//TODO:
// Determine whether or not to add server tab
// If application is open in client mode, do not show server tab
dlg.AddServerTab();
//TODO:
// Determine whether or not to add client tab
// Client tab should probably always show
// Implement client tab
//dlg.AddClientTab();
if(ret_flags & RET_FLAG_START_MINIMIZED)
{