Added an option to toggle the display of shape control points

This commit is contained in:
Tats
2014-04-10 18:27:40 -04:00
parent a02bb298c3
commit 4d3694fe28
6 changed files with 28 additions and 3 deletions
+8 -1
View File
@@ -23,7 +23,7 @@
#include "MainWindow.h"
MapperGLCanvas::MapperGLCanvas(MainWindow* mainWindow, QWidget* parent, const QGLWidget * shareWidget)
: QGLWidget(parent, shareWidget), _mainWindow(mainWindow), _mousepressed(false), _active_vertex(NO_VERTEX)
: QGLWidget(parent, shareWidget), _mainWindow(mainWindow), _mousepressed(false), _active_vertex(NO_VERTEX), _displayControls(true)
{
}
@@ -279,6 +279,13 @@ void MapperGLCanvas::updateCanvas()
update();
}
void MapperGLCanvas::enableDisplayControls(bool display)
{
_displayControls = display;
qDebug() << "Toggle display to " << display << endl;
updateCanvas();
}
/* Stick vertex p of Shape orig to another Shape's vertex, if the 2 vertices are
* close enough. The distance per coordinate is currently set in dist_stick
* variable. Perhaps the sticky-sensitivity should be configurable through GUI */