Ref T103, moved directory functions from CBuildConfig to CDirectoryUtils

getApplicationDir renamed to getBinDir() as it works different on MacOs
see https://dev.swift-project.org/w/dev/swiftpc/dirstructure/
This commit is contained in:
Klaus Basan
2017-07-06 22:35:55 +02:00
committed by Mathew Sutcliffe
parent eaac4dacd6
commit debd9c802f
23 changed files with 301 additions and 322 deletions

View File

@@ -7,12 +7,11 @@
* contained in the LICENSE file.
*/
#include "blackconfig/buildconfig.h"
#include "blackmisc/simulation/aircraftmodellist.h"
#include "blackmisc/simulation/aircraftmodelutils.h"
#include "blackmisc/directoryutils.h"
#include "blackmisc/verify.h"
using namespace BlackConfig;
namespace BlackMisc
{
namespace Simulation
@@ -133,7 +132,7 @@ namespace BlackMisc
BLACK_VERIFY_X(dir.exists(), Q_FUNC_INFO, "Directory does not exist");
if (!dir.exists()) { return ""; }
const QString htmlTemplate = CFileUtils::readFileToString(CBuildConfig::getHtmlTemplateFileName());
const QString htmlTemplate = CFileUtils::readFileToString(CDirectoryUtils::getHtmlTemplateFileName());
const QString fn("airlineAircraftMatrix.html");
const bool ok = CFileUtils::writeStringToFile(htmlTemplate.arg(html), dir.absoluteFilePath(fn));
return ok ? dir.absoluteFilePath(fn) : "";