mirror of
https://github.com/SoftFever/OrcaSlicer.git
synced 2025-07-13 01:37:53 -06:00
Fixed build when tech ENABLE_GCODE_VIEWER is disabled
This commit is contained in:
parent
0f85777a79
commit
ccd8e3644e
3 changed files with 11 additions and 7 deletions
|
@ -577,17 +577,17 @@ int CLI::run(int argc, char **argv)
|
|||
// #ifdef USE_WX
|
||||
#if ENABLE_GCODE_VIEWER
|
||||
GUI::GUI_App* gui = new GUI::GUI_App(start_as_gcodeviewer ? GUI::GUI_App::EAppMode::GCodeViewer : GUI::GUI_App::EAppMode::Editor);
|
||||
if (gui->get_app_mode() != GUI::GUI_App::EAppMode::GCodeViewer) { // gcode viewer is currently not performing instance check
|
||||
bool gui_single_instance_setting = gui->app_config->get("single_instance") == "1";
|
||||
if (Slic3r::instance_check(argc, argv, gui_single_instance_setting)) {
|
||||
//TODO: do we have delete gui and other stuff?
|
||||
return -1;
|
||||
}
|
||||
}
|
||||
#else
|
||||
GUI::GUI_App *gui = new GUI::GUI_App();
|
||||
#endif // ENABLE_GCODE_VIEWER
|
||||
|
||||
if(gui->get_app_mode() != GUI::GUI_App::EAppMode::GCodeViewer){ // gcode viewer is currently not performing instance check
|
||||
bool gui_single_instance_setting = gui->app_config->get("single_instance") == "1";
|
||||
if (Slic3r::instance_check(argc, argv, gui_single_instance_setting)) {
|
||||
//TODO: do we have delete gui and other stuff?
|
||||
return -1;
|
||||
}
|
||||
}
|
||||
// gui->autosave = m_config.opt_string("autosave");
|
||||
GUI::GUI_App::SetInstance(gui);
|
||||
#if ENABLE_GCODE_VIEWER
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue