Add Inspection and Import WebAssembly probes
Some checks failed
FreeCAD master CI / Prepare (push) Has been cancelled
FreeCAD master CI / Pixi (push) Has been cancelled
FreeCAD master CI / Ubuntu (push) Has been cancelled
FreeCAD master CI / Windows (push) Has been cancelled
FreeCAD master CI / Lint (push) Has been cancelled
FreeCAD master CI / WrapUp (push) Has been cancelled
CodeQL Advanced / Analyze (actions) (push) Has been cancelled
CodeQL Advanced / Analyze (python) (push) Has been cancelled
Scorecard supply-chain security / Scorecard analysis (push) Has been cancelled
Stale Issues / stale (push) Has been cancelled
Some checks failed
FreeCAD master CI / Prepare (push) Has been cancelled
FreeCAD master CI / Pixi (push) Has been cancelled
FreeCAD master CI / Ubuntu (push) Has been cancelled
FreeCAD master CI / Windows (push) Has been cancelled
FreeCAD master CI / Lint (push) Has been cancelled
FreeCAD master CI / WrapUp (push) Has been cancelled
CodeQL Advanced / Analyze (actions) (push) Has been cancelled
CodeQL Advanced / Analyze (python) (push) Has been cancelled
Scorecard supply-chain security / Scorecard analysis (push) Has been cancelled
Stale Issues / stale (push) Has been cancelled
This commit is contained in:
@@ -1598,9 +1598,9 @@ std::vector<DocumentObject*> Document::readObjects(Base::XMLReader& reader)
|
||||
|
||||
long lastId = 0;
|
||||
for (int i = 0; i < Cnt; i++) {
|
||||
reader.readElement("Object");
|
||||
std::string type = reader.getAttribute<const char*>("type");
|
||||
std::string name = reader.getAttribute<const char*>("name");
|
||||
reader.readElement("Object");
|
||||
std::string type = reader.getAttribute<const char*>("type");
|
||||
std::string name = reader.getAttribute<const char*>("name");
|
||||
std::string viewType =
|
||||
reader.hasAttribute("ViewType") ? reader.getAttribute<const char*>("ViewType") : "";
|
||||
|
||||
@@ -2082,38 +2082,38 @@ bool Document::isAnyRestoring()
|
||||
|
||||
// Open the document
|
||||
void Document::restore(const char* filename,
|
||||
bool delaySignal,
|
||||
const std::vector<std::string>& objNames)
|
||||
bool delaySignal,
|
||||
const std::vector<std::string>& objNames)
|
||||
{
|
||||
clearUndos();
|
||||
d->activeObject = nullptr;
|
||||
|
||||
bool signal = false;
|
||||
Document* activeDoc = GetApplication().getActiveDocument();
|
||||
if (!d->objectArray.empty()) {
|
||||
signal = true;
|
||||
GetApplication().signalDeleteDocument(*this);
|
||||
d->clearDocument();
|
||||
}
|
||||
|
||||
Base::FlagToggler<> flag(globalIsRestoring, false);
|
||||
|
||||
setStatus(Document::PartialDoc, false);
|
||||
|
||||
d->clearRecomputeLog();
|
||||
d->objectLabelManager.clear();
|
||||
d->objectArray.clear();
|
||||
d->objectNameManager.clear();
|
||||
d->objectMap.clear();
|
||||
d->objectIdMap.clear();
|
||||
d->lastObjectId = 0;
|
||||
|
||||
if (signal) {
|
||||
GetApplication().signalNewDocument(*this, true);
|
||||
if (activeDoc == this) {
|
||||
GetApplication().setActiveDocument(this);
|
||||
}
|
||||
}
|
||||
clearUndos();
|
||||
d->activeObject = nullptr;
|
||||
|
||||
bool signal = false;
|
||||
Document* activeDoc = GetApplication().getActiveDocument();
|
||||
if (!d->objectArray.empty()) {
|
||||
signal = true;
|
||||
GetApplication().signalDeleteDocument(*this);
|
||||
d->clearDocument();
|
||||
}
|
||||
|
||||
Base::FlagToggler<> flag(globalIsRestoring, false);
|
||||
|
||||
setStatus(Document::PartialDoc, false);
|
||||
|
||||
d->clearRecomputeLog();
|
||||
d->objectLabelManager.clear();
|
||||
d->objectArray.clear();
|
||||
d->objectNameManager.clear();
|
||||
d->objectMap.clear();
|
||||
d->objectIdMap.clear();
|
||||
d->lastObjectId = 0;
|
||||
|
||||
if (signal) {
|
||||
GetApplication().signalNewDocument(*this, true);
|
||||
if (activeDoc == this) {
|
||||
GetApplication().setActiveDocument(this);
|
||||
}
|
||||
}
|
||||
|
||||
if (!filename) {
|
||||
filename = FileName.getValue();
|
||||
@@ -2178,7 +2178,7 @@ void Document::restore(const char* filename,
|
||||
throw Base::FileException("Error reading compression file", filename);
|
||||
}
|
||||
|
||||
GetApplication().signalStartRestoreDocument(*this);
|
||||
GetApplication().signalStartRestoreDocument(*this);
|
||||
setStatus(Document::Restoring, true);
|
||||
|
||||
d->partialLoadObjects.clear();
|
||||
|
||||
Reference in New Issue
Block a user