From cabffa23a9b1ec053a7a573ed71883c44d7a5b6a Mon Sep 17 00:00:00 2001 From: LePresidente Date: Sun, 29 Oct 2017 11:38:06 +0200 Subject: Use ScriptExtender PluginPath instead of appending "/plugin" to the old script extender name variable. --- src/loadmechanism.cpp | 4 ++-- src/modinforegular.cpp | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) (limited to 'src') diff --git a/src/loadmechanism.cpp b/src/loadmechanism.cpp index e476c56d..35aedfed 100644 --- a/src/loadmechanism.cpp +++ b/src/loadmechanism.cpp @@ -129,7 +129,7 @@ void LoadMechanism::deactivateScriptExtender() throw MyException(QObject::tr("game doesn't support a script extender")); } - QDir pluginsDir(game->gameDirectory().absolutePath() + "/data/" + extender->name() + "/plugins"); + QDir pluginsDir(game->gameDirectory().absolutePath() + "/data/" + extender->PluginPath()); #pragma message("implement this for usvfs") @@ -188,7 +188,7 @@ void LoadMechanism::activateScriptExtender() throw MyException(QObject::tr("game doesn't support a script extender")); } - QDir pluginsDir(game->gameDirectory().absolutePath() + "/data/" + extender->name() + "/plugins"); + QDir pluginsDir(game->gameDirectory().absolutePath() + "/data/" + extender->PluginPath()); if (!pluginsDir.exists()) { pluginsDir.mkpath("."); diff --git a/src/modinforegular.cpp b/src/modinforegular.cpp index bacc21f7..1194f604 100644 --- a/src/modinforegular.cpp +++ b/src/modinforegular.cpp @@ -442,7 +442,7 @@ std::vector ModInfoRegular::getContents() const ->feature(); if (extender != nullptr) { - QString sePluginPath = extender->name() + "/plugins"; + QString sePluginPath = extender->PluginPath(); if (dir.exists(sePluginPath)) m_CachedContent.push_back(CONTENT_SKSE); } -- cgit v1.3.1 From 701e6e4927ed887fc569aab97a1a6850e0f3dbdf Mon Sep 17 00:00:00 2001 From: LePresidente Date: Mon, 30 Oct 2017 15:30:28 +0200 Subject: Close the handle that is created by FindFirstFileW correctly. --- src/mainwindow.cpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'src') diff --git a/src/mainwindow.cpp b/src/mainwindow.cpp index 158e32d1..ace7dbd8 100644 --- a/src/mainwindow.cpp +++ b/src/mainwindow.cpp @@ -1944,9 +1944,10 @@ void MainWindow::fileMoved(const QString &filePath, const QString &oldOriginName QString fullNewPath = ToQString(newOrigin.getPath()) + "\\" + filePath; WIN32_FIND_DATAW findData; - ::FindFirstFileW(ToWString(fullNewPath).c_str(), &findData); - + HANDLE hFind; + hFind = ::FindFirstFileW(ToWString(fullNewPath).c_str(), &findData); filePtr->addOrigin(newOrigin.getID(), findData.ftCreationTime, L""); + FindClose(hFind); } if (m_OrganizerCore.directoryStructure()->originExists(ToWString(oldOriginName))) { FilesOrigin &oldOrigin = m_OrganizerCore.directoryStructure()->getOriginByName(ToWString(oldOriginName)); -- cgit v1.3.1 From d53591c6c9c2702d361a70417f37f4508fc43552 Mon Sep 17 00:00:00 2001 From: Al12rs Date: Mon, 30 Oct 2017 19:56:23 +0100 Subject: Changed segment of while condition in waitForProcessCompletion() from OR to AND as it alwais evaluated true. --- src/organizercore.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src') diff --git a/src/organizercore.cpp b/src/organizercore.cpp index 9ae8beae..4857590d 100644 --- a/src/organizercore.cpp +++ b/src/organizercore.cpp @@ -1254,7 +1254,7 @@ bool OrganizerCore::waitForProcessCompletion(HANDLE handle, LPDWORD exitCode) while ( res = ::MsgWaitForMultipleObjects(1, &handle, false, 500, QS_KEY | QS_MOUSE), - ((res != WAIT_FAILED) || (res != WAIT_OBJECT_0)) && + ((res != WAIT_FAILED) && (res != WAIT_OBJECT_0)) && ((m_UserInterface == nullptr) || !m_UserInterface->unlockClicked())) { if (!::GetVFSProcessList(&numProcesses, processes)) { -- cgit v1.3.1