First claimChildren3D implementation and Starting PartItem implementation

This commit is contained in:
jriegel
2012-04-01 21:47:24 +02:00
committed by Stefan Tröger
parent 8537926edc
commit 29507a44ed
11 changed files with 95 additions and 36 deletions

View File

@@ -252,8 +252,6 @@ public:
static void copyVisual(const char* to, const char* attr_to, const char* from, const char* attr_from);
/// Get Python tuple from object and sub-elements
static std::string getPythonTuple(const std::string& name, const std::vector<std::string>& subnames);
/// import an external module only once
//static void addModule(const char* sModuleName);
/// translate a string to a python string literal (needed e.g. in file names for windows...)
const std::string strToPython(const char* Str);
const std::string strToPython(const std::string &Str){return strToPython(Str.c_str());};

View File

@@ -423,6 +423,7 @@ void Document::slotNewObject(const App::DocumentObject& Obj)
Base::Console().Error("App::Document::_RecomputeFeature(): Unknown exception in Feature \"%s\" thrown\n",Obj.getNameInDocument());
}
#endif
std::list<Gui::BaseView*>::iterator vIt;
// cycling to all views of the document
for (vIt = d->baseViews.begin();vIt != d->baseViews.end();++vIt) {

View File

@@ -638,23 +638,6 @@ void TreeWidget::slotActiveDocument(const Gui::Document& Doc)
}
}
//void TreeWidget::markItem(const App::DocumentObject* Obj,bool mark)
//{
// // never call without Object!
// assert(Obj);
// Gui::Document* Doc = Gui::Application::Instance->getDocument(Obj->getDocument());
//
// std::map<const Gui::Document*, DocumentItem*>::iterator jt = DocumentMap.find(Doc);
// for (std::map<const Gui::Document*, DocumentItem*>::iterator it = DocumentMap.begin();
// it != DocumentMap.end(); ++it)
// {
// it->second->markItem(Obj,mark);
//
// QFont f = it->second->font(0);
// f.setBold(it == jt);
// it->second->setFont(0,f);
// }
//}
void TreeWidget::onTestStatus(void)
{
@@ -672,7 +655,7 @@ void TreeWidget::onTestStatus(void)
void TreeWidget::onItemEntered(QTreeWidgetItem * item)
{
// object item selected
if (item && item->type() == TreeWidget::ObjectType) {
if ( item && item->type() == TreeWidget::ObjectType ) {
DocumentObjectItem* obj = static_cast<DocumentObjectItem*>(item);
obj->displayStatusInfo();
}

View File

@@ -149,7 +149,6 @@ public:
void selectItems(void);
void testStatus(void);
void setData(int column, int role, const QVariant & value);
// void markItem(const App::DocumentObject* Obj,bool mark);
protected:
/** Adds a view provider to the document item.

View File

@@ -642,6 +642,7 @@ void View3DInventorViewer::removeViewProvider(ViewProvider* pcProvider)
_ViewProviderSet.erase(pcProvider);
}
SbBool View3DInventorViewer::setEditingViewProvider(Gui::ViewProvider* p, int ModNum)
{
if (this->editViewProvider)