diff options
| author | Thomas Tanner <trtanner@btinternet.com> | 2015-11-24 09:45:45 +0000 |
|---|---|---|
| committer | Thomas Tanner <trtanner@btinternet.com> | 2015-11-24 09:45:45 +0000 |
| commit | a7ef08965097fb4b863c99de2d6291733b4bc3c0 (patch) | |
| tree | d84a3c9e3eaf3687aab6ce3dcc5c528036d659d9 /src/mainwindow.cpp | |
| parent | 37c3bea7dd5a562a97c00b740103cc2868b3013b (diff) | |
Use IPluginGame::getIniFiles throughout.
Also removed the default constructor from Profile class and stopped registering it as a QMetaObject (which it is the only reason it is there).
Diffstat (limited to 'src/mainwindow.cpp')
| -rw-r--r-- | src/mainwindow.cpp | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/src/mainwindow.cpp b/src/mainwindow.cpp index ceb118ea..c08993c1 100644 --- a/src/mainwindow.cpp +++ b/src/mainwindow.cpp @@ -1258,9 +1258,11 @@ QDir MainWindow::currentSavesDir() const savesDir.setPath(m_OrganizerCore.currentProfile()->absolutePath() + "/saves");
} else {
wchar_t path[MAX_PATH];
- ::GetPrivateProfileStringW(L"General", L"SLocalSavePath", L"Saves",
- path, MAX_PATH,
- (ToWString(m_OrganizerCore.currentProfile()->absolutePath()) + L"\\" + GameInfo::instance().getIniFileNames().at(0)).c_str());
+ ::GetPrivateProfileStringW(
+ L"General", L"SLocalSavePath", L"Saves",
+ path, MAX_PATH,
+ ToWString(m_OrganizerCore.currentProfile()->absolutePath() + "/" +
+ m_OrganizerCore.managedGame()->getIniFiles()[0]).c_str());
savesDir.setPath(m_OrganizerCore.managedGame()->documentsDirectory().absoluteFilePath(QString::fromWCharArray(path)));
}
|
