]> git.mxchange.org Git - flightgear.git/commitdiff
Restore aircraft-manager location back to FG_HOME
authorJames Turner <zakalawe@mac.com>
Sat, 10 Jan 2015 14:18:32 +0000 (14:18 +0000)
committerJames Turner <zakalawe@mac.com>
Sat, 10 Jan 2015 14:18:32 +0000 (14:18 +0000)
src/Main/fg_init.cxx

index 6d16c8c94d7def56fc81fdd2b308b9301d97c82b..1d648a83a38c0d992cf6bb0a99feb79b7dde1227 100644 (file)
@@ -504,15 +504,16 @@ static void initAircraftDirsNasalSecurity()
 void fgInitAircraftPaths(bool reinit)
 {
   if (!reinit) {
-    SGPath userAircraftDir = SGPath::documents(globals->get_fg_home());
-    if (userAircraftDir != globals->get_fg_home()) {
-      userAircraftDir.append("FlightGear");
-    }
-    userAircraftDir.append("Aircraft");
-
-    SGSharedPtr<Root> pkgRoot(new Root(userAircraftDir, FLIGHTGEAR_VERSION));
-    // set the http client later (too early in startup right now)
-    globals->setPackageRoot(pkgRoot);
+      // there is some debate if we should be using FG_HOME here (hidden
+      // location) vs a user-visible location inside Documents (especially on
+      // Windows and Mac). Really this location should be managed by FG, not
+      // the user, but it can potentially grow large.
+      SGPath packageAircraftDir = globals->get_fg_home();
+      packageAircraftDir.append("Aircraft");
+
+      SGSharedPtr<Root> pkgRoot(new Root(packageAircraftDir, FLIGHTGEAR_VERSION));
+      // set the http client later (too early in startup right now)
+      globals->setPackageRoot(pkgRoot);
   }
 
   SGSharedPtr<Root> pkgRoot(globals->packageRoot());