Fixed warnings

This commit is contained in:
enricoturri1966 2023-04-27 08:55:59 +02:00 committed by Lukas Matena
parent 6944c30f87
commit efe00f310b
2 changed files with 2 additions and 3 deletions

View File

@ -32,7 +32,6 @@ inline Grids line_rasterization(const Line &line, int64_t xdist = RasteXDistance
Point rayStart = line.a; Point rayStart = line.a;
Point rayEnd = line.b; Point rayEnd = line.b;
IndexPair currentVoxel = point_map_grid_index(rayStart, xdist, ydist); IndexPair currentVoxel = point_map_grid_index(rayStart, xdist, ydist);
IndexPair firstVoxel = currentVoxel;
IndexPair lastVoxel = point_map_grid_index(rayEnd, xdist, ydist); IndexPair lastVoxel = point_map_grid_index(rayEnd, xdist, ydist);
Point ray = rayEnd - rayStart; Point ray = rayEnd - rayStart;

View File

@ -7493,12 +7493,12 @@ void GLCanvas3D::_set_warning_notification(EWarning warning, bool state)
const PrintObject* obj2 = reinterpret_cast<const PrintObject*>(conflict_result->_obj2); const PrintObject* obj2 = reinterpret_cast<const PrintObject*>(conflict_result->_obj2);
auto mo = obj2->model_object(); auto mo = obj2->model_object();
ObjectID id = mo->id(); ObjectID id = mo->id();
auto action_fn = [this, id](wxEvtHandler*) { auto action_fn = [id](wxEvtHandler*) {
auto& objects = wxGetApp().model().objects; auto& objects = wxGetApp().model().objects;
auto iter = id.id ? std::find_if(objects.begin(), objects.end(), [id](auto o) { return o->id() == id; }) : objects.end(); auto iter = id.id ? std::find_if(objects.begin(), objects.end(), [id](auto o) { return o->id() == id; }) : objects.end();
if (iter != objects.end()) { if (iter != objects.end()) {
const unsigned int obj_idx = std::distance(objects.begin(), iter); const unsigned int obj_idx = std::distance(objects.begin(), iter);
wxGetApp().CallAfter([this, obj_idx]() { wxGetApp().CallAfter([obj_idx]() {
wxGetApp().plater()->select_view_3D("3D"); wxGetApp().plater()->select_view_3D("3D");
wxGetApp().plater()->canvas3D()->get_selection().add_object(obj_idx, true); wxGetApp().plater()->canvas3D()->get_selection().add_object(obj_idx, true);
wxGetApp().obj_list()->update_selections(); wxGetApp().obj_list()->update_selections();