ObjectList: Fixes

* Fixed update of a warning icon for multi-part object, when some part with errors was deleted
 * Fixed a crash when selecting non-Object and non-Volume item (in get_mesh_errors_info() was missed check of the obj_idx)

+ Follow-up 1cc7b4ba97 - some code refactoring:
  * fixed RepairedMeshErrors.merge()
  * get_mesh_errors_count() renamed to get_repaired_errors_count()
This commit is contained in:
YuSanka 2021-10-06 17:24:22 +02:00
parent dbad87fb42
commit 7340488aaf
11 changed files with 83 additions and 67 deletions

View file

@ -377,7 +377,7 @@ public:
// Get full stl statistics for all object's meshes
TriangleMeshStats get_object_stl_stats() const;
// Get count of errors in the mesh( or all object's meshes, if volume index isn't defined)
int get_mesh_errors_count(const int vol_idx = -1) const;
int get_repaired_errors_count(const int vol_idx = -1) const;
private:
friend class Model;
@ -682,7 +682,7 @@ public:
const TriangleMesh& get_convex_hull() const;
std::shared_ptr<const TriangleMesh> get_convex_hull_shared_ptr() const { return m_convex_hull; }
// Get count of errors in the mesh
int get_mesh_errors_count() const;
int get_repaired_errors_count() const;
// Helpers for loading / storing into AMF / 3MF files.
static ModelVolumeType type_from_string(const std::string &s);