From ba0cd0e10d381123234a2aa8fe0bf2bce5c8a861 Mon Sep 17 00:00:00 2001 From: Al12rs Date: Wed, 24 Jan 2018 13:43:53 +0100 Subject: Fixed customOverwrite setting for executables. The setting was not being passed to spawnBinary() and was left empty. Just added a couple lines to pass that too. If the setting is disabled cutomOverwrite should be empty and the normal overwrite folder will be used instead. --- src/mainwindow.cpp | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'src') diff --git a/src/mainwindow.cpp b/src/mainwindow.cpp index 6648f32e..bcc8fd06 100644 --- a/src/mainwindow.cpp +++ b/src/mainwindow.cpp @@ -1043,12 +1043,13 @@ void MainWindow::startExeAction() if (action != nullptr) { const Executable &selectedExecutable( m_OrganizerCore.executablesList()->find(action->text())); + QString customOverwrite= m_OrganizerCore.currentProfile()->setting("custom_overwrites", selectedExecutable.m_Title).toString(); m_OrganizerCore.spawnBinary( selectedExecutable.m_BinaryInfo, selectedExecutable.m_Arguments, selectedExecutable.m_WorkingDirectory.length() != 0 ? selectedExecutable.m_WorkingDirectory : selectedExecutable.m_BinaryInfo.absolutePath(), - selectedExecutable.m_SteamAppID); + selectedExecutable.m_SteamAppID, customOverwrite); } else { qCritical("not an action?"); } @@ -1709,13 +1710,13 @@ void MainWindow::installMod(QString fileName) void MainWindow::on_startButton_clicked() { const Executable &selectedExecutable(getSelectedExecutable()); - + QString customOverwrite = m_OrganizerCore.currentProfile()->setting("custom_overwrites", selectedExecutable.m_Title).toString(); m_OrganizerCore.spawnBinary( selectedExecutable.m_BinaryInfo, selectedExecutable.m_Arguments, selectedExecutable.m_WorkingDirectory.length() != 0 ? selectedExecutable.m_WorkingDirectory : selectedExecutable.m_BinaryInfo.absolutePath(), - selectedExecutable.m_SteamAppID); + selectedExecutable.m_SteamAppID, customOverwrite); } static HRESULT CreateShortcut(LPCWSTR targetFileName, LPCWSTR arguments, -- cgit v1.3.1