Cleanup of Session loading, saving, embedding in source and added option

to make sessionSource the current Session.
This commit is contained in:
brunoherbelin
2020-05-21 10:20:40 +02:00
parent 8ad58ebeca
commit f16c1843c3
20 changed files with 295 additions and 267 deletions

View File

@@ -81,7 +81,7 @@ void tinyxml2::XMLElementToGLM(XMLElement *elem, glm::mat4 &matrix)
}
}
void tinyxml2::XMLSaveDoc(XMLDocument * const doc, std::string filename)
bool tinyxml2::XMLSaveDoc(XMLDocument * const doc, std::string filename)
{
XMLDeclaration *pDec = doc->NewDeclaration();
doc->InsertFirstChild(pDec);
@@ -92,7 +92,7 @@ void tinyxml2::XMLSaveDoc(XMLDocument * const doc, std::string filename)
// save session
XMLError eResult = doc->SaveFile(filename.c_str());
XMLResultError(eResult);
return !XMLResultError(eResult);
}
bool tinyxml2::XMLResultError(int result)