diff --git a/src/Gui/ViewProviderDatum.h b/src/Gui/ViewProviderDatum.h index 857037ae286c..e2c25559d0ff 100644 --- a/src/Gui/ViewProviderDatum.h +++ b/src/Gui/ViewProviderDatum.h @@ -44,10 +44,10 @@ namespace Gui ~ViewProviderDatum() override; /// Get point derived classes will add their specific stuff - SoSeparator* getRoot() { return pRoot; } + SoSeparator* getDatumRoot() const { return pRoot; } /// Get pointer to the text label associated with the feature - SoText2* getLabel() { return pLabel; } + SoText2* getLabel() const { return pLabel; } void attach(App::DocumentObject*) override; std::vector getDisplayModes() const override; diff --git a/src/Gui/ViewProviderLine.cpp b/src/Gui/ViewProviderLine.cpp index a3d99cf640fb..bcc464da5854 100644 --- a/src/Gui/ViewProviderLine.cpp +++ b/src/Gui/ViewProviderLine.cpp @@ -94,7 +94,7 @@ void ViewProviderLine::attach(App::DocumentObject *obj) { // indexes used to create the edges static const int32_t lines[4] = { 0, 1, -1 }; - SoSeparator *sep = getRoot(); + SoSeparator *sep = getDatumRoot(); auto pCoords = new SoCoordinate3 (); pCoords->point.setNum (2); diff --git a/src/Gui/ViewProviderPlane.cpp b/src/Gui/ViewProviderPlane.cpp index 7c567e4505de..25e6fe577f63 100644 --- a/src/Gui/ViewProviderPlane.cpp +++ b/src/Gui/ViewProviderPlane.cpp @@ -114,7 +114,7 @@ void ViewProviderPlane::attach(App::DocumentObject * obj) { // indexes used to create the edges static const int32_t lines[6] = { 0, 1, 2, 3, 0, -1 }; - SoSeparator* sep = getRoot(); + SoSeparator* sep = getDatumRoot(); auto pCoords = new SoCoordinate3(); pCoords->point.setNum(4); diff --git a/src/Gui/ViewProviderPoint.cpp b/src/Gui/ViewProviderPoint.cpp index edcde697261c..3e87d23bfc0a 100644 --- a/src/Gui/ViewProviderPoint.cpp +++ b/src/Gui/ViewProviderPoint.cpp @@ -52,7 +52,7 @@ void ViewProviderPoint::attach(App::DocumentObject * obj) { // The coordinates for the point (single vertex at the origin) static const SbVec3f point = SbVec3f(0, 0, 0); - SoSeparator* sep = getRoot(); + SoSeparator* sep = getDatumRoot(); auto pCoords = new SoCoordinate3(); pCoords->point.setNum(1);