mirror of
https://github.com/SoftFever/OrcaSlicer.git
synced 2025-07-08 15:37:30 -06:00
FIX: STUDIO-1095 Prompt "import geometry data only" again
Prompt "import geometry data only" again when importing old or other 3mf Change-Id: If3edd3c36efa09925a9131e31567b0672f84f84b (cherry picked from commit 90eba8d55563997ceb1bc8feb1e110680c3b3678)
This commit is contained in:
parent
284154d053
commit
2ecb2fd22d
1 changed files with 18 additions and 13 deletions
|
@ -207,6 +207,14 @@ enum class LoadFilesType {
|
||||||
Multiple3MFOther,
|
Multiple3MFOther,
|
||||||
};
|
};
|
||||||
|
|
||||||
|
enum class LoadType : unsigned char
|
||||||
|
{
|
||||||
|
Unknown,
|
||||||
|
OpenProject,
|
||||||
|
LoadGeometry,
|
||||||
|
LoadConfig
|
||||||
|
};
|
||||||
|
|
||||||
class SlicedInfo : public wxStaticBoxSizer
|
class SlicedInfo : public wxStaticBoxSizer
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
|
@ -2940,11 +2948,14 @@ std::vector<size_t> Plater::priv::load_files(const std::vector<fs::path>& input_
|
||||||
wxGetApp().get_tab(Preset::TYPE_PRINT)->update();
|
wxGetApp().get_tab(Preset::TYPE_PRINT)->update();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
LoadType load_type = static_cast<LoadType>(std::stoi(wxGetApp().app_config->get("import_project_action")));
|
||||||
|
|
||||||
// BBS: version check
|
// BBS: version check
|
||||||
Semver app_version = *(Semver::parse(SLIC3R_VERSION));
|
Semver app_version = *(Semver::parse(SLIC3R_VERSION));
|
||||||
if (en_3mf_file_type == En3mfType::From_Prusa) {
|
if (en_3mf_file_type == En3mfType::From_Prusa) {
|
||||||
// do not reset the model config
|
// do not reset the model config
|
||||||
load_config = false;
|
load_config = false;
|
||||||
|
if(load_type != LoadType::LoadGeometry)
|
||||||
show_info(q, _L("The 3mf is not from Bambu Lab, load geometry data only."), _L("Load 3mf"));
|
show_info(q, _L("The 3mf is not from Bambu Lab, load geometry data only."), _L("Load 3mf"));
|
||||||
}
|
}
|
||||||
else if (load_config && (file_version.maj() != app_version.maj())) {
|
else if (load_config && (file_version.maj() != app_version.maj())) {
|
||||||
|
@ -2960,10 +2971,12 @@ std::vector<size_t> Plater::priv::load_files(const std::vector<fs::path>& input_
|
||||||
q->select_view_3D("3D");
|
q->select_view_3D("3D");
|
||||||
// select plate 0 as default
|
// select plate 0 as default
|
||||||
q->select_plate(0);
|
q->select_plate(0);
|
||||||
|
if (load_type != LoadType::LoadGeometry) {
|
||||||
if (en_3mf_file_type == En3mfType::From_BBS)
|
if (en_3mf_file_type == En3mfType::From_BBS)
|
||||||
show_info(q, _L("The 3mf is generated by old Bambu Studio, load geometry data only."), _L("Load 3mf"));
|
show_info(q, _L("The 3mf is generated by old Bambu Studio, load geometry data only."), _L("Load 3mf"));
|
||||||
else
|
else
|
||||||
show_info(q, _L("The 3mf is not from Bambu Lab, load geometry data only."), _L("Load 3mf"));
|
show_info(q, _L("The 3mf is not from Bambu Lab, load geometry data only."), _L("Load 3mf"));
|
||||||
|
}
|
||||||
for (ModelObject *model_object : model.objects) {
|
for (ModelObject *model_object : model.objects) {
|
||||||
model_object->config.reset();
|
model_object->config.reset();
|
||||||
// Is there any modifier or advanced config data?
|
// Is there any modifier or advanced config data?
|
||||||
|
@ -7823,14 +7836,6 @@ std::vector<size_t> Plater::load_files(const std::vector<std::string>& input_fil
|
||||||
return p->load_files(paths, strategy, ask_multi);
|
return p->load_files(paths, strategy, ask_multi);
|
||||||
}
|
}
|
||||||
|
|
||||||
enum class LoadType : unsigned char
|
|
||||||
{
|
|
||||||
Unknown,
|
|
||||||
OpenProject,
|
|
||||||
LoadGeometry,
|
|
||||||
LoadConfig
|
|
||||||
};
|
|
||||||
|
|
||||||
class RadioBox;
|
class RadioBox;
|
||||||
class RadioSelector
|
class RadioSelector
|
||||||
{
|
{
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue