mirror of https://github.com/CGAL/cgal
Merge commit 'c51c7792b84e1b0039d9fb4afc872a38fcfc14cb' from pull request #4481 from maxGimeno/Demo-Fixes-maxGimeno
3D Demo: Fixes
This commit is contained in:
commit
07bd217f43
|
|
@ -1493,6 +1493,7 @@ void MainWindow::showSceneContextMenu(int selectedItemIndex,
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
menu->addMenu(ui->menuOperations);
|
menu->addMenu(ui->menuOperations);
|
||||||
|
|
||||||
if(menu)
|
if(menu)
|
||||||
menu->exec(global_pos);
|
menu->exec(global_pos);
|
||||||
}
|
}
|
||||||
|
|
@ -1755,6 +1756,7 @@ void MainWindow::showSceneContextMenu(const QPoint& p) {
|
||||||
QAction* saveas = menu.addAction(tr("&Save as..."));
|
QAction* saveas = menu.addAction(tr("&Save as..."));
|
||||||
connect(saveas, SIGNAL(triggered()),
|
connect(saveas, SIGNAL(triggered()),
|
||||||
this, SLOT(on_actionSaveAs_triggered()));
|
this, SLOT(on_actionSaveAs_triggered()));
|
||||||
|
menu.addMenu(ui->menuOperations);
|
||||||
menu.exec(sender->mapToGlobal(p));
|
menu.exec(sender->mapToGlobal(p));
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
@ -2189,7 +2191,7 @@ void MainWindow::on_actionShowHide_triggered()
|
||||||
item->redraw();
|
item->redraw();
|
||||||
}
|
}
|
||||||
scene->setUpdatesEnabled(true);
|
scene->setUpdatesEnabled(true);
|
||||||
updateViewersBboxes(false);
|
// updateViewersBboxes(false); //Not usable :when the scene changes scale, smaller items disappear.
|
||||||
}
|
}
|
||||||
|
|
||||||
void MainWindow::on_actionSetPolyhedronA_triggered()
|
void MainWindow::on_actionSetPolyhedronA_triggered()
|
||||||
|
|
|
||||||
|
|
@ -766,7 +766,7 @@ struct Point_generator
|
||||||
{
|
{
|
||||||
return Point(bl.x() + i*(ur.x()-bl.x())/(w-1),
|
return Point(bl.x() + i*(ur.x()-bl.x())/(w-1),
|
||||||
bl.y() + j*(ur.y()-bl.y())/(h-1),
|
bl.y() + j*(ur.y()-bl.y())/(h-1),
|
||||||
0);
|
bl.z() + j*(ur.z()-bl.z())/(h-1));
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
template<class Facegraph_item>
|
template<class Facegraph_item>
|
||||||
|
|
|
||||||
|
|
@ -223,8 +223,8 @@ void Polyhedron_demo_orient_soup_plugin::apply_shuffle( Item* root_item,
|
||||||
item->load(root_item);
|
item->load(root_item);
|
||||||
item->shuffle_orientations();
|
item->shuffle_orientations();
|
||||||
item->setColor(root_item->color());
|
item->setColor(root_item->color());
|
||||||
scene->replaceItem(index, item);
|
scene->replaceItem(index, item, true);
|
||||||
delete root_item;
|
root_item->deleteLater();
|
||||||
QApplication::restoreOverrideCursor();
|
QApplication::restoreOverrideCursor();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -143,6 +143,7 @@ Scene::replaceItem(Scene::Item_id index, CGAL::Three::Scene_item* item, bool emi
|
||||||
|
|
||||||
if(emit_item_about_to_be_destroyed) {
|
if(emit_item_about_to_be_destroyed) {
|
||||||
Q_EMIT itemAboutToBeDestroyed(item);
|
Q_EMIT itemAboutToBeDestroyed(item);
|
||||||
|
item->aboutToBeDestroyed();
|
||||||
}
|
}
|
||||||
|
|
||||||
Q_EMIT updated();
|
Q_EMIT updated();
|
||||||
|
|
|
||||||
|
|
@ -1453,6 +1453,7 @@ void Scene_c3t3_item_priv::computeElements()
|
||||||
}
|
}
|
||||||
|
|
||||||
positions_poly.clear();
|
positions_poly.clear();
|
||||||
|
positions_grid.clear();
|
||||||
normals.clear();
|
normals.clear();
|
||||||
f_colors.clear();
|
f_colors.clear();
|
||||||
positions_lines.clear();
|
positions_lines.clear();
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue