summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/mainwindow.cpp32
-rw-r--r--src/mainwindow.h1
-rw-r--r--src/mainwindow.ui2
-rw-r--r--src/modlist.cpp5
-rw-r--r--src/resources/open-Folder-Icon.pngbin17646 -> 16927 bytes
5 files changed, 33 insertions, 7 deletions
diff --git a/src/mainwindow.cpp b/src/mainwindow.cpp
index fe93b546..f5be22f0 100644
--- a/src/mainwindow.cpp
+++ b/src/mainwindow.cpp
@@ -3035,6 +3035,12 @@ void MainWindow::openInstanceFolder()
::ShellExecuteW(nullptr, L"explore", ToWString(m_OrganizerCore.settings().getBaseDirectory()).c_str(), nullptr, nullptr, SW_SHOWNORMAL);
}
+void MainWindow::openLogsFolder()
+{
+ QString logsPath = qApp->property("dataPath").toString() + "/" + QString::fromStdWString(AppConfig::logPath());
+ ::ShellExecuteW(nullptr, L"explore", ToWString(logsPath).c_str(), nullptr, nullptr, SW_SHOWNORMAL);
+}
+
void MainWindow::openInstallFolder()
{
::ShellExecuteW(nullptr, L"explore", ToWString(qApp->applicationDirPath()).c_str(), nullptr, nullptr, SW_SHOWNORMAL);
@@ -3231,6 +3237,11 @@ QMenu *MainWindow::openFolderMenu()
QMenu *FolderMenu = new QMenu(this);
+ FolderMenu->addAction(tr("Open Game folder"), this, SLOT(openGameFolder()));
+
+ FolderMenu->addAction(tr("Open MyGames folder"), this, SLOT(openMyGamesFolder()));
+
+ FolderMenu->addSeparator();
FolderMenu->addAction(tr("Open Instance folder"), this, SLOT(openInstanceFolder()));
@@ -3238,13 +3249,19 @@ QMenu *MainWindow::openFolderMenu()
FolderMenu->addAction(tr("Open Downloads folder"), this, SLOT(openDownloadsFolder()));
- FolderMenu->addAction(tr("Open MO Install folder"), this, SLOT(openInstallFolder()));
-
FolderMenu->addSeparator();
- FolderMenu->addAction(tr("Open Game folder"), this, SLOT(openGameFolder()));
+ FolderMenu->addAction(tr("Open MO2 Install folder"), this, SLOT(openInstallFolder()));
- FolderMenu->addAction(tr("Open MyGames folder"), this, SLOT(openMyGamesFolder()));
+ FolderMenu->addAction(tr("Open MO2 Logs folder"), this, SLOT(openLogsFolder()));
+
+
+
+
+
+
+
+
return FolderMenu;
@@ -3304,15 +3321,18 @@ void MainWindow::on_modList_customContextMenuRequested(const QPoint &pos)
} else if (std::find(flags.begin(), flags.end(), ModInfo::FLAG_FOREIGN) != flags.end()) {
// nop, nothing to do with this mod
} else {
- QMenu *addRemoveCategoriesMenu = new QMenu(tr("Add/Remove Categories"));
+ QMenu *addRemoveCategoriesMenu = new QMenu(tr("Change Categories"));
populateMenuCategories(addRemoveCategoriesMenu, 0);
connect(addRemoveCategoriesMenu, SIGNAL(aboutToHide()), this, SLOT(addRemoveCategories_MenuHandler()));
addMenuAsPushButton(menu, addRemoveCategoriesMenu);
+ //Removed as it was redundant, just making the categories look more complicated.
+ /*
QMenu *replaceCategoriesMenu = new QMenu(tr("Replace Categories"));
populateMenuCategories(replaceCategoriesMenu, 0);
connect(replaceCategoriesMenu, SIGNAL(aboutToHide()), this, SLOT(replaceCategories_MenuHandler()));
addMenuAsPushButton(menu, replaceCategoriesMenu);
+ */
QMenu *primaryCategoryMenu = new QMenu(tr("Primary Category"));
connect(primaryCategoryMenu, SIGNAL(aboutToShow()), this, SLOT(addPrimaryCategoryCandidates()));
@@ -3332,8 +3352,8 @@ void MainWindow::on_modList_customContextMenuRequested(const QPoint &pos)
menu->addSeparator();
menu->addAction(tr("Rename Mod..."), this, SLOT(renameMod_clicked()));
- menu->addAction(tr("Remove Mod..."), this, SLOT(removeMod_clicked()));
menu->addAction(tr("Reinstall Mod"), this, SLOT(reinstallMod_clicked()));
+ menu->addAction(tr("Remove Mod..."), this, SLOT(removeMod_clicked()));
menu->addSeparator();
diff --git a/src/mainwindow.h b/src/mainwindow.h
index 2c2e2723..f84931ca 100644
--- a/src/mainwindow.h
+++ b/src/mainwindow.h
@@ -487,6 +487,7 @@ private slots:
void disableVisibleMods();
void exportModListCSV();
void openInstanceFolder();
+ void openLogsFolder();
void openInstallFolder();
void openDownloadsFolder();
void openProfileFolder();
diff --git a/src/mainwindow.ui b/src/mainwindow.ui
index 31522c03..451e3c87 100644
--- a/src/mainwindow.ui
+++ b/src/mainwindow.ui
@@ -253,7 +253,7 @@ p, li { white-space: pre-wrap; }
<item>
<widget class="QPushButton" name="openFolderMenu">
<property name="toolTip">
- <string>Quickly open in Explorer relevant Folders...</string>
+ <string>Show Open Folders menu...</string>
</property>
<property name="text">
<string/>
diff --git a/src/modlist.cpp b/src/modlist.cpp
index 4002a424..7b2ad1f9 100644
--- a/src/modlist.cpp
+++ b/src/modlist.cpp
@@ -424,6 +424,11 @@ bool ModList::renameMod(int index, const QString &newName)
return false;
}
+ if (ModList::allMods().contains(newName,Qt::CaseInsensitive)) {
+ MessageDialog::showMessage(tr("Name is already in use by another mod"), nullptr);
+ return false;
+ }
+
ModInfo::Ptr modInfo = ModInfo::getByIndex(index);
QString oldName = modInfo->name();
if (newName != oldName) {
diff --git a/src/resources/open-Folder-Icon.png b/src/resources/open-Folder-Icon.png
index 345671f7..c363be0f 100644
--- a/src/resources/open-Folder-Icon.png
+++ b/src/resources/open-Folder-Icon.png
Binary files differ