@@ -703,6 +703,9 @@ std::vector<Document*> Application::openDocuments(const std::vector<std::string>
|
||||
_pendingDocMap.clear();
|
||||
|
||||
Base::SequencerLauncher seq("Postprocessing...", newDocs.size());
|
||||
for (auto &v : newDocs)
|
||||
PropertyXLink::restoreDocument(*v.first);
|
||||
|
||||
for (auto &v : newDocs) {
|
||||
FC_TIME_INIT(t1);
|
||||
v.first->afterRestore(true);
|
||||
|
||||
@@ -2641,6 +2641,13 @@ public:
|
||||
}
|
||||
}
|
||||
|
||||
static void restoreDocument(const App::Document &doc) {
|
||||
auto it = _DocInfoMap.find(getFullPath(doc.FileName.getValue()));
|
||||
if(it==_DocInfoMap.end())
|
||||
return;
|
||||
it->second->slotFinishRestoreDocument(doc);
|
||||
}
|
||||
|
||||
void slotFinishRestoreDocument(const App::Document &doc) {
|
||||
if(pcDoc) return;
|
||||
QString fullpath(getFullPath());
|
||||
@@ -3423,6 +3430,10 @@ bool PropertyXLink::hasXLink(
|
||||
return ret;
|
||||
}
|
||||
|
||||
void PropertyXLink::restoreDocument(const App::Document &doc) {
|
||||
DocInfo::restoreDocument(doc);
|
||||
}
|
||||
|
||||
std::map<App::Document*,std::set<App::Document*> >
|
||||
PropertyXLink::getDocumentOutList(App::Document *doc) {
|
||||
std::map<App::Document*,std::set<App::Document*> > ret;
|
||||
|
||||
@@ -1107,6 +1107,7 @@ public:
|
||||
static bool hasXLink(const std::vector<App::DocumentObject*> &objs, std::vector<App::Document*> *unsaved=0);
|
||||
static std::map<App::Document*,std::set<App::Document*> > getDocumentOutList(App::Document *doc=0);
|
||||
static std::map<App::Document*,std::set<App::Document*> > getDocumentInList(App::Document *doc=0);
|
||||
static void restoreDocument(const App::Document &doc);
|
||||
|
||||
virtual void updateElementReference(
|
||||
DocumentObject *feature,bool reverse=false, bool notify=false) override;
|
||||
|
||||
Reference in New Issue
Block a user