mirror of
https://github.com/SoftFever/OrcaSlicer.git
synced 2025-07-07 23:17:35 -06:00
Fix: forbid the filament setting to negative/enforcer/blocker
Change-Id: I846ad591c9967af1df3e47c1d007958cf0846766
This commit is contained in:
parent
bb4d537991
commit
9f749b304c
2 changed files with 17 additions and 1 deletions
|
@ -1342,6 +1342,12 @@ void MenuFactory::append_menu_item_change_filament(wxMenu* menu)
|
|||
if (sels.IsEmpty())
|
||||
return;
|
||||
|
||||
if (sels.Count() == 1) {
|
||||
const auto sel_vol = obj_list()->get_selected_model_volume();
|
||||
if (sel_vol && sel_vol->type() != ModelVolumeType::MODEL_PART && sel_vol->type() != ModelVolumeType::PARAMETER_MODIFIER)
|
||||
return;
|
||||
}
|
||||
|
||||
std::vector<wxBitmap*> icons = get_extruder_color_icons(true);
|
||||
if (icons.size() < filaments_cnt) {
|
||||
BOOST_LOG_TRIVIAL(warning) << boost::format("Warning: icons size %1%, filaments_cnt=%2%")%icons.size()%filaments_cnt;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue