From cebc5860c114d9e811643a3754c9735677ede515 Mon Sep 17 00:00:00 2001 From: Alexander Golubev Date: Wed, 2 Sep 2015 08:04:49 +0300 Subject: [PATCH] Gui/ViewProviderGeoFeatureGroup: suppress DocumentObjectGroup's hide/show behavior --- src/Gui/ViewProviderDocumentObjectGroup.h | 6 +++--- src/Gui/ViewProviderGeoFeatureGroup.h | 9 +++++++++ 2 files changed, 12 insertions(+), 3 deletions(-) diff --git a/src/Gui/ViewProviderDocumentObjectGroup.h b/src/Gui/ViewProviderDocumentObjectGroup.h index 31126501d..abbc5b3fb 100644 --- a/src/Gui/ViewProviderDocumentObjectGroup.h +++ b/src/Gui/ViewProviderDocumentObjectGroup.h @@ -52,13 +52,13 @@ public: QIcon getIcon(void) const; /// returns a list of all possible modes std::vector getDisplayModes(void) const; - void hide(void); - void show(void); + virtual void hide(void); + virtual void show(void); bool isShow(void) const; virtual bool onDelete(const std::vector &); - /// get called if the user hover over a object in the tree + /// get called if the user hover over a object in the tree virtual bool allowDrop(const std::vector &objList,Qt::KeyboardModifiers keys,Qt::MouseButtons mouseBts,const QPoint &pos); /// get called if the user drops some objects virtual void drop(const std::vector &objList,Qt::KeyboardModifiers keys,Qt::MouseButtons mouseBts,const QPoint &pos); diff --git a/src/Gui/ViewProviderGeoFeatureGroup.h b/src/Gui/ViewProviderGeoFeatureGroup.h index f1058451d..33a5e2c6a 100644 --- a/src/Gui/ViewProviderGeoFeatureGroup.h +++ b/src/Gui/ViewProviderGeoFeatureGroup.h @@ -48,6 +48,15 @@ public: virtual void setDisplayMode(const char* ModeName); virtual std::vector getDisplayModes(void) const; + /// Show the object in the view: suppresses behavior of DocumentObjectGroup + virtual void show(void) { + ViewProviderDocumentObject::show(); + } + /// Hide the object in the view: suppresses behavior of DocumentObjectGroup + virtual void hide(void) { + ViewProviderDocumentObject::hide(); + } + virtual void updateData(const App::Property*); protected: SoGroup *pcGroupChildren;