Quellcode durchsuchen

Refactor: Initialize members in declaration order; prefer initialization over assignment

Richard vor 10 Jahren
Ursprung
Commit
63520d562a
1 geänderte Dateien mit 1 neuen und 6 gelöschten Zeilen
  1. 1 6
      code/StepExporter.cpp

+ 1 - 6
code/StepExporter.cpp

@@ -152,7 +152,7 @@ namespace {
 
 // ------------------------------------------------------------------------------------------------
 // Constructor for a specific scene to export
-StepExporter::StepExporter(const aiScene* pScene, IOSystem* pIOSystem, const std::string& path, const std::string& file, const ExportProperties* pProperties) : mIOSystem(pIOSystem), mPath(path), mFile(file), mProperties(pProperties)
+StepExporter::StepExporter(const aiScene* pScene, IOSystem* pIOSystem, const std::string& path, const std::string& file, const ExportProperties* pProperties) : mProperties(pProperties), mIOSystem(pIOSystem), mFile(file), mPath(path), mScene(pScene), endstr(";\n")
 {
 	CollectTrafos(pScene->mRootNode, trafos);
 	CollectMeshes(pScene->mRootNode, meshes);
@@ -160,11 +160,6 @@ StepExporter::StepExporter(const aiScene* pScene, IOSystem* pIOSystem, const std
 	// make sure that all formatting happens using the standard, C locale and not the user's current locale
 	mOutput.imbue( std::locale("C") );
 
-	mScene = pScene;
-
-	// set up strings
-	endstr = ";\n";
-
 	// start writing
 	WriteFile();
 }