summaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
-rw-r--r--qfunctionconfigurator/qfunctionconfigurator.cpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/qfunctionconfigurator/qfunctionconfigurator.cpp b/qfunctionconfigurator/qfunctionconfigurator.cpp
index afd6561b..a80e3b6b 100644
--- a/qfunctionconfigurator/qfunctionconfigurator.cpp
+++ b/qfunctionconfigurator/qfunctionconfigurator.cpp
@@ -337,6 +337,8 @@ void QFunctionConfigurator::drawLine(QPainter *painter, const QPointF &start, co
//
void QFunctionConfigurator::mousePressEvent(QMouseEvent *e)
{
+ if (!_config)
+ return;
QList<QPointF> points = _config->getPoints();
//
@@ -409,6 +411,8 @@ void QFunctionConfigurator::mousePressEvent(QMouseEvent *e)
//
void QFunctionConfigurator::mouseMoveEvent(QMouseEvent *e)
{
+ if (!_config)
+ return;
QList<QPointF> points = _config->getPoints();
const int refresh_delay = 50;
@@ -452,6 +456,8 @@ void QFunctionConfigurator::mouseMoveEvent(QMouseEvent *e)
void QFunctionConfigurator::mouseReleaseEvent(QMouseEvent *e)
{
+ if (!_config)
+ return;
QList<QPointF> points = _config->getPoints();
if (e->button() == Qt::LeftButton) {