diff options
author | Miikka Heikkinen <miikka.heikkinen@digia.com> | 2014-01-09 09:55:52 +0200 |
---|---|---|
committer | Miikka Heikkinen <miikka.heikkinen@digia.com> | 2014-01-09 11:02:27 +0200 |
commit | 450dc3e6d74ffe93a761a5e2491458935ecac7b7 (patch) | |
tree | 99184e6eddb3d8529733de2b273e93b8b96bb73b /src/datavisualization/engine/q3dsurface.cpp | |
parent | 466c03c4e560b875121090bf883d9aefa9d44616 (diff) |
Make active axes properties in C++
Also provide axis changed signals both C++ and QML.
Some other minor fixes, too.
Task-number: QTRD-2669
Change-Id: Ib797bffd6720382cf26359a9059e1809efdf58da
Reviewed-by: Mika Salmela <mika.salmela@digia.com>
Diffstat (limited to 'src/datavisualization/engine/q3dsurface.cpp')
-rw-r--r-- | src/datavisualization/engine/q3dsurface.cpp | 27 |
1 files changed, 24 insertions, 3 deletions
diff --git a/src/datavisualization/engine/q3dsurface.cpp b/src/datavisualization/engine/q3dsurface.cpp index 0b09aba4..ad236220 100644 --- a/src/datavisualization/engine/q3dsurface.cpp +++ b/src/datavisualization/engine/q3dsurface.cpp @@ -147,7 +147,9 @@ const Q3DSurfacePrivate *Q3DSurface::dptrc() const } /*! - * Sets a user-defined X-axis. Implicitly calls addAxis() to transfer ownership + * \property Q3DSurface::axisX + * + * The active X-axis. Implicitly calls addAxis() to transfer ownership * of the \a axis to this graph. * * If the \a axis is null, a temporary default axis with no labels and automatically adjusting @@ -170,7 +172,9 @@ QValue3DAxis *Q3DSurface::axisX() const } /*! - * Sets a user-defined Y-axis. Implicitly calls addAxis() to transfer ownership + * \property Q3DSurface::axisY + * + * The active Y-axis. Implicitly calls addAxis() to transfer ownership * of the \a axis to this graph. * * If the \a axis is null, a temporary default axis with no labels and automatically adjusting @@ -193,7 +197,9 @@ QValue3DAxis *Q3DSurface::axisY() const } /*! - * Sets a user-defined Z-axis. Implicitly calls addAxis() to transfer ownership + * \property Q3DSurface::axisZ + * + * The active Z-axis. Implicitly calls addAxis() to transfer ownership * of the \a axis to this graph. * * If the \a axis is null, a temporary default axis with no labels and automatically adjusting @@ -266,6 +272,21 @@ Q3DSurfacePrivate::~Q3DSurfacePrivate() { } +void Q3DSurfacePrivate::handleAxisXChanged(QAbstract3DAxis *axis) +{ + emit qptr()->axisXChanged(static_cast<QValue3DAxis *>(axis)); +} + +void Q3DSurfacePrivate::handleAxisYChanged(QAbstract3DAxis *axis) +{ + emit qptr()->axisYChanged(static_cast<QValue3DAxis *>(axis)); +} + +void Q3DSurfacePrivate::handleAxisZChanged(QAbstract3DAxis *axis) +{ + emit qptr()->axisZChanged(static_cast<QValue3DAxis *>(axis)); +} + Q3DSurface *Q3DSurfacePrivate::qptr() { return static_cast<Q3DSurface *>(q_ptr); |