diff options
| author | Tannin <devnull@localhost> | 2015-03-09 12:34:34 +0100 |
|---|---|---|
| committer | Tannin <devnull@localhost> | 2015-03-09 12:34:34 +0100 |
| commit | 7a1ae9b0f1560c9eda32e032796fbb3fd56ff236 (patch) | |
| tree | dea71435ac1042cb008fcd9f7b1ec57e6ea91227 /src/categories.cpp | |
| parent | d45ebf134819e1559718681becca9c4139fb7151 (diff) | |
| parent | db2954e8eb41da715b9e7d79a72e225797401413 (diff) | |
Merge with branch1.2
Diffstat (limited to 'src/categories.cpp')
| -rw-r--r-- | src/categories.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/categories.cpp b/src/categories.cpp index dca6311d..1d5fdefe 100644 --- a/src/categories.cpp +++ b/src/categories.cpp @@ -32,12 +32,12 @@ using namespace MOBase; using namespace MOShared;
-CategoryFactory* CategoryFactory::s_Instance = NULL;
+CategoryFactory* CategoryFactory::s_Instance = nullptr;
QString CategoryFactory::categoriesFilePath()
{
- return QCoreApplication::applicationDirPath() + "/categories.dat";
+ return qApp->property("dataPath").toString() + "/categories.dat";
}
@@ -93,7 +93,7 @@ CategoryFactory::CategoryFactory() CategoryFactory &CategoryFactory::instance()
{
- if (s_Instance == NULL) {
+ if (s_Instance == nullptr) {
s_Instance = new CategoryFactory;
}
return *s_Instance;
@@ -133,7 +133,7 @@ void CategoryFactory::setParents() void CategoryFactory::cleanup()
{
delete s_Instance;
- s_Instance = NULL;
+ s_Instance = nullptr;
}
|
