debug input files

This commit is contained in:
David Kocik 2022-06-27 10:51:17 +02:00
parent c147d1769c
commit 67def89334
2 changed files with 10 additions and 4 deletions

View File

@ -177,11 +177,12 @@ int CLI::run(int argc, char **argv)
start_as_gcodeviewer = true;
break;
}
for (const std::string& file : m_input_files)
if (boost::starts_with(file, "open?file=")) {
for (const std::string& file : m_input_files) {
//if (boost::starts_with(file, "open?file=")) {
start_as_downloader = true;
break;
}
//}
}
if (!start_as_gcodeviewer && !start_as_downloader) {
for (const std::string& file : m_input_files) {
if (!boost::filesystem::exists(file)) {

View File

@ -742,7 +742,12 @@ void GUI_App::post_init()
this->plater()->load_gcode(wxString::FromUTF8(this->init_params->input_files[0].c_str()));
}
if (this->init_params->start_as_downloader) {
show_error(nullptr, "Got url msg.");
std::string msg;
for (int i = 0; i < this->init_params->input_files.size(); ++i)
{
msg += this->init_params->input_files[i];
}
show_error(nullptr, "Got url msg." + msg);
}
else {
if (! this->init_params->preset_substitutions.empty())