mirror of
https://github.com/OrcaSlicer/OrcaSlicer.git
synced 2026-05-19 19:33:47 +00:00
FIX: check filament type instead of filament id
jira: [STUDIO-12954] Change-Id: Iab008c698e6c71a6df2ac4a81801681eb4b94d6c (cherry picked from commit 295a6d51ab2f59bfeef84e9ff33dac3c0aea1d93)
This commit is contained in:
@@ -903,6 +903,10 @@ std::string MachineObject::get_filament_id(std::string ams_id, std::string tray_
|
|||||||
return this->get_tray(ams_id, tray_id).setting_id;
|
return this->get_tray(ams_id, tray_id).setting_id;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
std::string MachineObject::get_filament_type(const std::string& ams_id, const std::string& tray_id) const {
|
||||||
|
return this->get_tray(ams_id, tray_id).type;
|
||||||
|
}
|
||||||
|
|
||||||
void MachineObject::_parse_ams_status(int ams_status)
|
void MachineObject::_parse_ams_status(int ams_status)
|
||||||
{
|
{
|
||||||
ams_status_sub = ams_status & 0xFF;
|
ams_status_sub = ams_status & 0xFF;
|
||||||
|
|||||||
@@ -793,6 +793,7 @@ public:
|
|||||||
AmsTray *get_ams_tray(std::string ams_id, std::string tray_id);
|
AmsTray *get_ams_tray(std::string ams_id, std::string tray_id);
|
||||||
|
|
||||||
std::string get_filament_id(std::string ams_id, std::string tray_id) const;
|
std::string get_filament_id(std::string ams_id, std::string tray_id) const;
|
||||||
|
std::string get_filament_type(const std::string& ams_id, const std::string& tray_id) const;
|
||||||
|
|
||||||
// parse amsStatusMain and ams_status_sub
|
// parse amsStatusMain and ams_status_sub
|
||||||
void _parse_ams_status(int ams_status);
|
void _parse_ams_status(int ams_status);
|
||||||
|
|||||||
@@ -1892,8 +1892,8 @@ void SelectMachineDialog::on_ok_btn(wxCommandEvent &event)
|
|||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
|
||||||
const auto& mapped_fila_id = obj_->get_filament_id(mapping_info.ams_id, mapping_info.slot_id);
|
const auto& mapped_fila_type = obj_->get_filament_type(mapping_info.ams_id, mapping_info.slot_id);
|
||||||
if (!mapped_fila_id.empty() && (mapped_fila_id != mapping_info.filament_id)) {
|
if (!mapped_fila_type.empty() && (mapped_fila_type != mapping_info.type)) {
|
||||||
confirm_text.push_back(ConfirmBeforeSendInfo(_L("The filament type setting of external spool is different from the filament in the slicing file.")));
|
confirm_text.push_back(ConfirmBeforeSendInfo(_L("The filament type setting of external spool is different from the filament in the slicing file.")));
|
||||||
has_slice_warnings = true;
|
has_slice_warnings = true;
|
||||||
break;
|
break;
|
||||||
|
|||||||
Reference in New Issue
Block a user