From 03152b88b5fb736accda47aee3221c6814b32201 Mon Sep 17 00:00:00 2001 From: Philippe Renon Date: Fri, 8 Apr 2016 09:22:12 +0200 Subject: [PATCH] LP-29 minor renaming in DirtySupport + silencing a warning --- ground/gcs/src/libs/osgearth/osgQtQuick/DirtySupport.cpp | 6 +++--- ground/gcs/src/libs/osgearth/osgQtQuick/DirtySupport.hpp | 2 +- ground/gcs/src/libs/osgearth/osgQtQuick/OSGNode.cpp | 2 +- .../libs/osgearth/osgQtQuick/ga/OSGCameraManipulator.cpp | 2 +- 4 files changed, 6 insertions(+), 6 deletions(-) diff --git a/ground/gcs/src/libs/osgearth/osgQtQuick/DirtySupport.cpp b/ground/gcs/src/libs/osgearth/osgQtQuick/DirtySupport.cpp index 1cb5108a4..c5d488159 100644 --- a/ground/gcs/src/libs/osgearth/osgQtQuick/DirtySupport.cpp +++ b/ground/gcs/src/libs/osgearth/osgQtQuick/DirtySupport.cpp @@ -72,7 +72,7 @@ public: { // qDebug() << "DirtySupport::setDirty" << mask; if (!dirtyFlags) { - osg::Node *node = self->hookNode(); + osg::Node *node = self->nodeToUpdate(); if (node) { if (!nodeUpdateCallback.valid()) { // lazy creation @@ -80,7 +80,7 @@ public: } node->addUpdateCallback(nodeUpdateCallback.get()); } else { - qWarning() << "DirtySupport::setDirty - node is null"; + // qWarning() << "DirtySupport::setDirty - node to update is null"; } } dirtyFlags |= mask; @@ -88,7 +88,7 @@ public: void clearDirty() { - osg::Node *node = self->hookNode(); + osg::Node *node = self->nodeToUpdate(); if (node && nodeUpdateCallback.valid()) { node->removeUpdateCallback(nodeUpdateCallback.get()); diff --git a/ground/gcs/src/libs/osgearth/osgQtQuick/DirtySupport.hpp b/ground/gcs/src/libs/osgearth/osgQtQuick/DirtySupport.hpp index 517daf55b..f802fc8c6 100644 --- a/ground/gcs/src/libs/osgearth/osgQtQuick/DirtySupport.hpp +++ b/ground/gcs/src/libs/osgearth/osgQtQuick/DirtySupport.hpp @@ -54,7 +54,7 @@ private: struct NodeUpdateCallback; Hidden *const h; - virtual osg::Node *hookNode() const = 0; + virtual osg::Node *nodeToUpdate() const = 0; virtual void update() = 0; }; diff --git a/ground/gcs/src/libs/osgearth/osgQtQuick/OSGNode.cpp b/ground/gcs/src/libs/osgearth/osgQtQuick/OSGNode.cpp index 14a0fa19c..7e78bb0bb 100644 --- a/ground/gcs/src/libs/osgearth/osgQtQuick/OSGNode.cpp +++ b/ground/gcs/src/libs/osgearth/osgQtQuick/OSGNode.cpp @@ -52,7 +52,7 @@ public: Hidden(OSGNode *self) : QObject(self), self(self), complete(false) /*, dirty(0)*/ {} - osg::Node *hookNode() const + osg::Node *nodeToUpdate() const { return self->node(); } diff --git a/ground/gcs/src/libs/osgearth/osgQtQuick/ga/OSGCameraManipulator.cpp b/ground/gcs/src/libs/osgearth/osgQtQuick/ga/OSGCameraManipulator.cpp index 361642552..22e97ec1a 100644 --- a/ground/gcs/src/libs/osgearth/osgQtQuick/ga/OSGCameraManipulator.cpp +++ b/ground/gcs/src/libs/osgearth/osgQtQuick/ga/OSGCameraManipulator.cpp @@ -55,7 +55,7 @@ public: ~Hidden() {} - osg::Node *hookNode() const + osg::Node *nodeToUpdate() const { return manipulator->getNode(); }