mirror of
https://github.com/OrcaSlicer/OrcaSlicer.git
synced 2026-09-12 11:37:42 +00:00
Fix filament syncing by fixing nozzle diameter guards (#13330)
* Remove unused `get_printer_preset` calls. * `Plater::check_printer_initialized` should skip nozzle flow type checks if nozzle is unknown. Also remove unnecessary `is_multi_extruders` check. * Remove unused `CalibUtils::is_same_nozzle_diameters()` fn. * Simplify `CalibUtils::check_printable_status_before_cali`. The single-arity can delegate to the vectorized arity. * Add `DevExtruderSystem::NozzleDiameterMatchesOrUnknown` to simply checks. * Update `CalibrationPresetPage::update_sync_button_status()` to use `NozzleDiameterMatchesOrUnknown`. Simplify logic by iterating over each extruder and checking for diameter and volume type match. The previous code had several mistakes (from what I could tell): - `curr_obj->is_multi_extruders()` doesn't imply exactly 2 extruders - the single/multi branch served no purpose - the single branch failed to check the volume type * Specify `std::fabs` and add explicit import. Ref: https://github.com/OrcaSlicer/OrcaSlicer/pull/13330#discussion_r3133613736 Not sure how idiomatic this is in C++ / OrcaSlicer codebase, but CoPilot suggested it and it seems reasonable. --------- Co-authored-by: SoftFever <softfeverever@gmail.com>
This commit is contained in:
@@ -265,6 +265,7 @@ protected:
|
||||
void update_combobox_filaments(MachineObject* obj);
|
||||
void update_show_status();
|
||||
void update_sync_button_status();
|
||||
bool is_nozzle_info_synced() const;
|
||||
void show_status(CaliPresetPageStatus status);
|
||||
void Enable_Send_Button(bool enable);
|
||||
bool is_blocking_printing();
|
||||
|
||||
Reference in New Issue
Block a user