Basic_viewer_qt is no more templated

This commit is contained in:
Guillaume Damiand 2023-10-23 01:35:11 +02:00
parent 6daa2a0c3b
commit 1c6b1e4a12
4 changed files with 6 additions and 6 deletions

View File

@ -50,7 +50,7 @@ struct Default_color_generator {
// Viewer class for`< Polygon_2 // Viewer class for`< Polygon_2
template <typename ArrangementOnSurface_2, template <typename ArrangementOnSurface_2,
typename ColorGenerator = Default_color_generator> typename ColorGenerator = Default_color_generator>
class Aos_2_basic_viewer_qt : public Basic_viewer_qt<float> { class Aos_2_basic_viewer_qt : public Basic_viewer_qt {
using Aos = ArrangementOnSurface_2; using Aos = ArrangementOnSurface_2;
using Color_generator = ColorGenerator; using Color_generator = ColorGenerator;
using Base = Basic_viewer_qt; using Base = Basic_viewer_qt;

View File

@ -112,10 +112,10 @@ void compute_elements(const PWH& pwh,
#ifdef CGAL_USE_BASIC_VIEWER #ifdef CGAL_USE_BASIC_VIEWER
template <typename PolygonSet_2, typename BufferType=float, class GSOptions> template <typename PolygonSet_2, class GSOptions>
class Polygon_set_2_basic_viewer_qt : public Basic_viewer_qt<BufferType> class Polygon_set_2_basic_viewer_qt : public Basic_viewer_qt
{ {
using Base = Basic_viewer_qt<BufferType>; using Base = Basic_viewer_qt;
using Ps = PolygonSet_2; using Ps = PolygonSet_2;
using Pwh = typename Ps::Polygon_with_holes_2; using Pwh = typename Ps::Polygon_with_holes_2;
using Pgn = typename Ps::Polygon_2; using Pgn = typename Ps::Polygon_2;

View File

@ -247,7 +247,7 @@ void draw(const CGAL_P2T2_TYPE& ap2t2,
{ {
// Here we define the std::function to capture key pressed. // Here we define the std::function to capture key pressed.
app.basic_viewer().on_key_pressed= app.basic_viewer().on_key_pressed=
[&ap2t2, &gs_options] (QKeyEvent* e, CGAL::Basic_viewer_qt<float>* basic_viewer) -> bool [&ap2t2, &gs_options] (QKeyEvent* e, CGAL::Basic_viewer_qt* basic_viewer) -> bool
{ {
const ::Qt::KeyboardModifiers modifiers = e->modifiers(); const ::Qt::KeyboardModifiers modifiers = e->modifiers();
if ((e->key() == ::Qt::Key_D) && (modifiers == ::Qt::NoButton)) if ((e->key() == ::Qt::Key_D) && (modifiers == ::Qt::NoButton))

View File

@ -391,7 +391,7 @@ void draw(const CGAL_VORONOI_TYPE& av2,
{ {
// Here we define the std::function to capture key pressed. // Here we define the std::function to capture key pressed.
app.basic_viewer().on_key_pressed= app.basic_viewer().on_key_pressed=
[&av2, &gs_options] (QKeyEvent* e, CGAL::Basic_viewer_qt<float>* basic_viewer) -> bool [&av2, &gs_options] (QKeyEvent* e, CGAL::Basic_viewer_qt* basic_viewer) -> bool
{ {
const ::Qt::KeyboardModifiers modifiers = e->modifiers(); const ::Qt::KeyboardModifiers modifiers = e->modifiers();
if ((e->key() == ::Qt::Key_R) && (modifiers == ::Qt::NoButton)) if ((e->key() == ::Qt::Key_R) && (modifiers == ::Qt::NoButton))