diff options
Diffstat (limited to 'src/settings.cpp')
| -rw-r--r-- | src/settings.cpp | 14 |
1 files changed, 5 insertions, 9 deletions
diff --git a/src/settings.cpp b/src/settings.cpp index 4c2a34c8..61d6aaa3 100644 --- a/src/settings.cpp +++ b/src/settings.cpp @@ -23,25 +23,21 @@ along with Mod Organizer. If not, see <http://www.gnu.org/licenses/>. #include "utility.h" #include "helper.h" #include "json.h" -#include <gameinfo.h> #include <appconfig.h> #include <utility.h> #include <iplugingame.h> #include <QCheckBox> -#include <QLineEdit> -#include <QDirIterator> -#include <QRegExp> #include <QCoreApplication> -#include <QMessageBox> #include <QDesktopServices> +#include <QDirIterator> +#include <QLineEdit> +#include <QMessageBox> +#include <QRegExp> #include <memory> - using namespace MOBase; -using namespace MOShared; - template <typename T> class QListWidgetItemEx : public QListWidgetItem { @@ -112,7 +108,7 @@ void Settings::registerAsNXMHandler(bool force) std::wstring nxmPath = ToWString(QCoreApplication::applicationDirPath() + "/nxmhandler.exe"); std::wstring executable = ToWString(QCoreApplication::applicationFilePath()); std::wstring mode = force ? L"forcereg" : L"reg"; - std::wstring parameters = mode + L" " + GameInfo::instance().getGameShortName() + L" \"" + executable + L"\""; + std::wstring parameters = mode + L" " + m_GamePlugin->getNexusName().toStdWString() + L" \"" + executable + L"\""; HINSTANCE res = ::ShellExecuteW(nullptr, L"open", nxmPath.c_str(), parameters.c_str(), nullptr, SW_SHOWNORMAL); if ((int)res <= 32) { QMessageBox::critical(nullptr, tr("Failed"), |
