Gui/ViewProviderOriginFeature: remove the "New" selection model stuff

The new selection model is not usable for the OriginFeature's view
provider due to from one side it doesn't really have any subfeatures, so
it won't be really needed, and on the other side we will have to use
SoFCSelection because in that case it isn't possible to implement
highlighting in any sane way (unless we will reimplement drawing ourselfs).
This commit is contained in:
Alexander Golubev 2015-09-04 02:27:26 +03:00 committed by Stefan Tröger
parent 9292ddfa1e
commit 15e998e07c
2 changed files with 2 additions and 37 deletions

View File

@ -115,7 +115,6 @@ void ViewProviderOriginFeature::attach(App::DocumentObject* pcObject)
}
highlight->objectName = getObject()->getNameInDocument();
highlight->documentName = getObject()->getDocument()->getName();
// highlight->subElementName = "Main";
highlight->style = SoFCSelection::EMISSIVE_DIFFUSE;
// Style for normal (visiable) lines
@ -177,29 +176,3 @@ void ViewProviderOriginFeature::setDisplayMode (const char* ModeName)
setDisplayMaskMode("Base");
ViewProviderGeometryObject::setDisplayMode(ModeName);
}
std::string ViewProviderOriginFeature::getElement ( const SoDetail *detail ) const {
// TODO Explain what the heck here is or delete (2015-09-02, Fat-Zer)
// if (detail) {
// if (detail->getTypeId() == SoLineDetail::getClassTypeId()) {
// const SoLineDetail* line_detail = static_cast<const SoLineDetail*>(detail);
// if (line_detail->getLineIndex() == 0)
// {
// return std::string("Main");
// }
// }
// }
return std::string("");
}
SoDetail* ViewProviderOriginFeature::getDetail ( const char* subelement ) const {
// TODO Explain what the heck here is or delete (2015-09-02, Fat-Zer)
// if ( strcmp(subelement, "Main") == 0 ) {
// SoLineDetail* detail = new SoLineDetail();
// detail->setPartIndex( 0 );
// return detail;
// }
return 0;
}

View File

@ -50,18 +50,10 @@ public:
/// Get pointer to the text label associated with the feature
SoAsciiText * getLabel () { return pLabel; }
/// indicates if the ViewProvider use the new Selection model
virtual bool useNewSelectionModel () const
{ return true; }
virtual void attach(App::DocumentObject *);
virtual void updateData(const App::Property *);
virtual std::vector<std::string> getDisplayModes() const;
virtual void setDisplayMode(const char *ModeName);
/// return a hit element to the selection path or 0
virtual std::string getElement ( const SoDetail *detail ) const;
virtual SoDetail* getDetail ( const char *subelement ) const;
virtual std::vector<std::string> getDisplayModes () const;
virtual void setDisplayMode (const char* ModeName);
/// @name Suppress ViewProviderGeometryObject's behaviour
///@{