From 46700422fd7f1280217c9f405bc96d672a4ed174 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Stefan=20Tr=C3=B6ger?= Date: Fri, 2 Aug 2013 18:37:19 +0000 Subject: [PATCH] make constaints and group not greyed in tree --- src/Mod/Assembly/Gui/ViewProviderConstraintAlignment.h | 3 +++ src/Mod/Assembly/Gui/ViewProviderConstraintAngle.h | 2 ++ src/Mod/Assembly/Gui/ViewProviderConstraintCoincidence.h | 2 ++ src/Mod/Assembly/Gui/ViewProviderConstraintDistance.h | 2 ++ src/Mod/Assembly/Gui/ViewProviderConstraintFix.h | 2 ++ src/Mod/Assembly/Gui/ViewProviderConstraintGroup.cpp | 2 +- src/Mod/Assembly/Gui/ViewProviderConstraintGroup.h | 4 +++- src/Mod/Assembly/Gui/ViewProviderConstraintOrientation.h | 2 ++ 8 files changed, 17 insertions(+), 2 deletions(-) diff --git a/src/Mod/Assembly/Gui/ViewProviderConstraintAlignment.h b/src/Mod/Assembly/Gui/ViewProviderConstraintAlignment.h index 38d2fadde..459206fd5 100644 --- a/src/Mod/Assembly/Gui/ViewProviderConstraintAlignment.h +++ b/src/Mod/Assembly/Gui/ViewProviderConstraintAlignment.h @@ -34,6 +34,9 @@ class AssemblyGuiExport ViewProviderConstraintAlignment : public Gui::ViewProvid public: ViewProviderConstraintAlignment(); + + /// checks whether the view provider is visible or not in tree + virtual bool isShow(void) const {return true;}; }; diff --git a/src/Mod/Assembly/Gui/ViewProviderConstraintAngle.h b/src/Mod/Assembly/Gui/ViewProviderConstraintAngle.h index cd68cbe8c..ed1097f4d 100644 --- a/src/Mod/Assembly/Gui/ViewProviderConstraintAngle.h +++ b/src/Mod/Assembly/Gui/ViewProviderConstraintAngle.h @@ -35,6 +35,8 @@ class AssemblyGuiExport ViewProviderConstraintAngle : public Gui::ViewProviderDo public: ViewProviderConstraintAngle(); + /// checks whether the view provider is visible or not in tree + virtual bool isShow(void) const {return true;}; }; }; diff --git a/src/Mod/Assembly/Gui/ViewProviderConstraintCoincidence.h b/src/Mod/Assembly/Gui/ViewProviderConstraintCoincidence.h index a4cbacd73..dee6ab0a2 100644 --- a/src/Mod/Assembly/Gui/ViewProviderConstraintCoincidence.h +++ b/src/Mod/Assembly/Gui/ViewProviderConstraintCoincidence.h @@ -35,6 +35,8 @@ class AssemblyGuiExport ViewProviderConstraintCoincidence : public Gui::ViewProv public: ViewProviderConstraintCoincidence(); + /// checks whether the view provider is visible or not in tree + virtual bool isShow(void) const {return true;}; }; }; diff --git a/src/Mod/Assembly/Gui/ViewProviderConstraintDistance.h b/src/Mod/Assembly/Gui/ViewProviderConstraintDistance.h index 1c1c1c364..9fbff5ba2 100644 --- a/src/Mod/Assembly/Gui/ViewProviderConstraintDistance.h +++ b/src/Mod/Assembly/Gui/ViewProviderConstraintDistance.h @@ -35,6 +35,8 @@ class AssemblyGuiExport ViewProviderConstraintDistance : public Gui::ViewProvide public: ViewProviderConstraintDistance(); + /// checks whether the view provider is visible or not in tree + virtual bool isShow(void) const {return true;}; }; }; diff --git a/src/Mod/Assembly/Gui/ViewProviderConstraintFix.h b/src/Mod/Assembly/Gui/ViewProviderConstraintFix.h index d4fabcc0c..66a1e158e 100644 --- a/src/Mod/Assembly/Gui/ViewProviderConstraintFix.h +++ b/src/Mod/Assembly/Gui/ViewProviderConstraintFix.h @@ -35,6 +35,8 @@ class AssemblyGuiExport ViewProviderConstraintFix : public Gui::ViewProviderDocu public: ViewProviderConstraintFix(); + /// checks whether the view provider is visible or not in tree + virtual bool isShow(void) const {return true;}; }; }; diff --git a/src/Mod/Assembly/Gui/ViewProviderConstraintGroup.cpp b/src/Mod/Assembly/Gui/ViewProviderConstraintGroup.cpp index a03662c2d..b8a7c2d4a 100644 --- a/src/Mod/Assembly/Gui/ViewProviderConstraintGroup.cpp +++ b/src/Mod/Assembly/Gui/ViewProviderConstraintGroup.cpp @@ -57,7 +57,7 @@ void ViewProviderConstraintGroup::attach(App::DocumentObject *pcFeat) // putting all together with the switch -// addDisplayMaskMode(getChildRoot(), "Main"); + //addDisplayMaskMode(getChildRoot(), "Main"); } void ViewProviderConstraintGroup::setDisplayMode(const char* ModeName) diff --git a/src/Mod/Assembly/Gui/ViewProviderConstraintGroup.h b/src/Mod/Assembly/Gui/ViewProviderConstraintGroup.h index dabcb2af9..2adb572ff 100644 --- a/src/Mod/Assembly/Gui/ViewProviderConstraintGroup.h +++ b/src/Mod/Assembly/Gui/ViewProviderConstraintGroup.h @@ -46,8 +46,10 @@ public: virtual std::vector getDisplayModes(void) const; virtual std::vector claimChildren(void)const; - virtual std::vector claimChildren3D(void)const; + + /// checks whether the view provider is visible or not in tree + virtual bool isShow(void) const {return true;}; }; diff --git a/src/Mod/Assembly/Gui/ViewProviderConstraintOrientation.h b/src/Mod/Assembly/Gui/ViewProviderConstraintOrientation.h index 1109d5d89..4276a46df 100644 --- a/src/Mod/Assembly/Gui/ViewProviderConstraintOrientation.h +++ b/src/Mod/Assembly/Gui/ViewProviderConstraintOrientation.h @@ -35,6 +35,8 @@ class AssemblyGuiExport ViewProviderConstraintOrientation : public Gui::ViewProv public: ViewProviderConstraintOrientation(); + /// checks whether the view provider is visible or not in tree + virtual bool isShow(void) const {return true;}; }; };