FIX:fixed model import not in the latest list

fixed STUDIO-2986 STUDIO-2989

Change-Id: Ifc20a6dcfcd0cae305cc6c2844cb26656289925e
This commit is contained in:
tao wang 2023-06-09 16:36:18 +08:00 committed by Lane.Wei
parent 2e4cc06d0c
commit 87386c817c
3 changed files with 3 additions and 7 deletions

View file

@ -8052,7 +8052,7 @@ void Plater::import_model_id(wxString download_info)
if (download_ok) { if (download_ok) {
BOOST_LOG_TRIVIAL(trace) << "import_model_id: target_path = " << target_path.string(); BOOST_LOG_TRIVIAL(trace) << "import_model_id: target_path = " << target_path.string();
/* load project */ /* load project */
this->load_project(encode_path(target_path.string().c_str()), "<silence>"); this->load_project(encode_path(target_path.string().c_str()));
/*BBS set project info after load project, project info is reset in load project */ /*BBS set project info after load project, project info is reset in load project */
//p->project.project_model_id = model_id; //p->project.project_model_id = model_id;

View file

@ -3373,9 +3373,7 @@ void SelectMachineDialog::set_default()
if (filename.empty()) { if (filename.empty()) {
filename = m_plater->get_export_gcode_filename("", true); filename = m_plater->get_export_gcode_filename("", true);
if (std::strstr(filename.c_str(), _L("Untitled").c_str()) == NULL) { if (filename.empty()) filename = _L("Untitled");
filename = wxString::Format("Untitled%s", filename);
}
} }
fs::path filename_path(filename.c_str()); fs::path filename_path(filename.c_str());

View file

@ -1225,9 +1225,7 @@ void SendToPrinterDialog::set_default()
if (filename.empty()) { if (filename.empty()) {
filename = m_plater->get_export_gcode_filename("", true); filename = m_plater->get_export_gcode_filename("", true);
if (std::strstr(filename.c_str(), _L("Untitled").c_str()) == NULL) { if (filename.empty()) filename = _L("Untitled");
filename = wxString::Format("Untitled%s", filename);
}
} }
fs::path filename_path(filename.c_str()); fs::path filename_path(filename.c_str());