From dfca8be71b15bc13997110cc8777dd5a84a1fde7 Mon Sep 17 00:00:00 2001 From: Tannin Date: Sat, 21 Sep 2013 19:25:33 +0200 Subject: - esp reader now handles invalid files more gracefully - files moved will now also be treated as "deleted" in the old location so a newly created file with that same name is not created in overwrite - introduced a mechanism by which MO can recognize if it crashed before when attempting to load a plugin. That plugin can be blacklisted so it doesn't get loaded again - plugins can now programaticaly change their settings - plugins can now store data persistently without exposing that data as settings - requesting an unset-setting from a plugin is no longer treated as a bug - clarified warning message for when files are in overwrite directory - the proxyPython plugin will now discover if python initialization crashed MO on a previous session and give the user a chance to fix it or disable the plugin - bugfix: GetModuleFileName modified the buffer past the zero termination. While this doesn't violate the API documentation it is different from the regular windows implementation - bugfix: proxy plugins couldn't access the parent widget - bugfix: when moving a file from overwrite to a mod the in-memory file structure wasn't updated - bugfix: name input dialog for profiles allowed names that weren't valid directory names - bugfix: profile dialog wasn't able to delete profiles if the name started or ended in whitespaces - bugfix: The name-cells for plugin settings could be changed (without effect) - removed a few obsolete files from the repository --- src/modlist.cpp | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'src/modlist.cpp') diff --git a/src/modlist.cpp b/src/modlist.cpp index 5aa8fbb9..b5a7182e 100644 --- a/src/modlist.cpp +++ b/src/modlist.cpp @@ -477,6 +477,7 @@ Qt::ItemFlags ModList::flags(const QModelIndex &modelIndex) const return result; } + QStringList ModList::mimeTypes() const { QStringList result = QAbstractItemModel::mimeTypes(); @@ -544,6 +545,12 @@ bool ModList::dropURLs(const QMimeData *mimeData, int row, const QModelIndex &pa QDir modDirectory(modInfo->absolutePath()); QDir gameDirectory(QDir::fromNativeSeparators(ToQString(MOShared::GameInfo::instance().getOverwriteDir()))); + unsigned int overwriteIndex = ModInfo::findMod([](ModInfo::Ptr mod) -> bool { + std::vector flags = mod->getFlags(); + return std::find(flags.begin(), flags.end(), ModInfo::FLAG_OVERWRITE) != flags.end(); }); + + QString overwriteName = ModInfo::getByIndex(overwriteIndex)->name(); + foreach (const QUrl &url, mimeData->urls()) { QString relativePath = gameDirectory.relativeFilePath(url.toLocalFile()); if (relativePath.startsWith("..")) { @@ -552,6 +559,7 @@ bool ModList::dropURLs(const QMimeData *mimeData, int row, const QModelIndex &pa } source.append(url.toLocalFile()); target.append(modDirectory.absoluteFilePath(relativePath)); + emit fileMoved(relativePath, overwriteName, modInfo->name()); } if (source.count() != 0) { -- cgit v1.3.1 From cffd9eb4e21f0ddcddca68d8eb0f1c80c8ac6ae1 Mon Sep 17 00:00:00 2001 From: Tannin Date: Sat, 5 Oct 2013 14:20:48 +0200 Subject: - hook.dll now doesn't inject to certain applications (currently steam, chrome and firefox) - versioning system improved. Will now report "downgrades" for mods and support a different versioning system (requires manual switch) - updates can now be ignored until a new version is uploaded - new splash screen - bugfix: a few memory leaks (shouldn't account for much) - bugfix: result of GetModuleHandle wasn't zero-terminated in some cases --- src/categories.cpp | 7 ++++ src/categories.h | 4 ++ src/downloadmanager.cpp | 1 + src/installationmanager.cpp | 6 +-- src/main.cpp | 97 ++++++++++++++++++++++++-------------------- src/mainwindow.cpp | 87 +++++++++++++++++++++++++++------------ src/mainwindow.h | 4 ++ src/modinfo.cpp | 30 ++++++++++++-- src/modinfo.h | 49 ++++++++++++++++++++++ src/modinfodialog.cpp | 11 +---- src/modlist.cpp | 34 ++++++++++------ src/modlistsortproxy.cpp | 2 +- src/modlistview.cpp | 4 +- src/nexusinterface.cpp | 10 +++++ src/nexusinterface.h | 1 + src/nxmaccessmanager.cpp | 8 ++++ src/nxmaccessmanager.h | 2 + src/organizer.pro | 7 +++- src/pluginlist.cpp | 4 ++ src/pluginlist.h | 2 + src/profile.cpp | 3 +- src/selfupdater.cpp | 2 - src/shared/gameinfo.cpp | 7 ++++ src/shared/gameinfo.h | 4 +- src/shared/leaktrace.cpp | 1 + src/shared/shared.pro | 10 ++++- src/spawn.cpp | 4 +- src/spawn.h | 4 +- src/splash.png | Bin 103422 -> 260807 bytes 29 files changed, 296 insertions(+), 109 deletions(-) (limited to 'src/modlist.cpp') diff --git a/src/categories.cpp b/src/categories.cpp index 62ba3ca5..c084c238 100644 --- a/src/categories.cpp +++ b/src/categories.cpp @@ -43,6 +43,7 @@ QString CategoryFactory::categoriesFilePath() CategoryFactory::CategoryFactory() { + atexit(&cleanup); reset(); QFile categoryFile(categoriesFilePath()); @@ -124,6 +125,12 @@ void CategoryFactory::setParents() } } +void CategoryFactory::cleanup() +{ + delete s_Instance; + s_Instance = NULL; +} + void CategoryFactory::saveCategories() { diff --git a/src/categories.h b/src/categories.h index 75698149..31fccd6d 100644 --- a/src/categories.h +++ b/src/categories.h @@ -180,6 +180,8 @@ private: void setParents(); + static void cleanup(); + private: static CategoryFactory *s_Instance; @@ -188,6 +190,8 @@ private: std::map m_IDMap; std::map m_NexusMap; +private: + }; diff --git a/src/downloadmanager.cpp b/src/downloadmanager.cpp index bbb34ccc..b965d598 100644 --- a/src/downloadmanager.cpp +++ b/src/downloadmanager.cpp @@ -162,6 +162,7 @@ DownloadManager::~DownloadManager() for (QVector::iterator iter = m_ActiveDownloads.begin(); iter != m_ActiveDownloads.end(); ++iter) { delete *iter; } + m_ActiveDownloads.clear(); } diff --git a/src/installationmanager.cpp b/src/installationmanager.cpp index 378eb38a..87efecf1 100644 --- a/src/installationmanager.cpp +++ b/src/installationmanager.cpp @@ -46,6 +46,7 @@ along with Mod Organizer. If not, see . #include #include #include +#include using namespace MOBase; @@ -678,8 +679,7 @@ bool InstallationManager::install(const QString &fileName, GuessedValue this->m_CurrentArchive->close(); }); - DirectoryTree *filesTree = archiveOpen ? createFilesTree() : NULL; - + QScopedPointer filesTree(archiveOpen ? createFilesTree() : NULL); IPluginInstaller::EInstallResult installResult = IPluginInstaller::RESULT_NOTATTEMPTED; std::sort(m_Installers.begin(), m_Installers.end(), [] (IPluginInstaller *LHS, IPluginInstaller *RHS) { @@ -704,7 +704,7 @@ bool InstallationManager::install(const QString &fileName, GuessedValue (filesTree != NULL) && (installer->isArchiveSupported(*filesTree))) { installResult = installerSimple->install(modName, *filesTree, version, modID); if (installResult == IPluginInstaller::RESULT_SUCCESS) { - mapToArchive(filesTree); + mapToArchive(filesTree.data()); // the simple installer only prepares the installation, the rest works the same for all installers if (!doInstall(modName, modID, version, newestVersion, categoryID)) { installResult = IPluginInstaller::RESULT_FAILED; diff --git a/src/main.cpp b/src/main.cpp index 5a694121..c4431ac4 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -18,6 +18,11 @@ along with Mod Organizer. If not, see . */ +#ifdef LEAK_CHECK_WITH_VLD +#include +#include +#endif // LEAK_CHECK_WITH_VLD + #include #include #include @@ -430,61 +435,65 @@ int main(int argc, char *argv[]) application.setStyleFile(settings.value("Settings/style", "").toString()); - // set up main window and its data structures - MainWindow mainWindow(argv[0], settings); - QObject::connect(&mainWindow, SIGNAL(styleChanged(QString)), &application, SLOT(setStyleFile(QString))); - QObject::connect(&instance, SIGNAL(messageSent(QString)), &mainWindow, SLOT(externalMessage(QString))); + int res = 1; + { // scope to control lifetime of mainwindow + // set up main window and its data structures + MainWindow mainWindow(argv[0], settings); + QObject::connect(&mainWindow, SIGNAL(styleChanged(QString)), &application, SLOT(setStyleFile(QString))); + QObject::connect(&instance, SIGNAL(messageSent(QString)), &mainWindow, SLOT(externalMessage(QString))); - mainWindow.setExecutablesList(executablesList); - mainWindow.readSettings(); + mainWindow.setExecutablesList(executablesList); + mainWindow.readSettings(); - QString selectedProfileName = QString::fromUtf8(settings.value("selected_profile", "").toByteArray()); + QString selectedProfileName = QString::fromUtf8(settings.value("selected_profile", "").toByteArray()); - { // see if there is a profile on the command line - int profileIndex = arguments.indexOf("-p", 1); - if ((profileIndex != -1) && (profileIndex < arguments.size() - 1)) { - qDebug("profile overwritten on command line"); - selectedProfileName = arguments.at(profileIndex + 1); + { // see if there is a profile on the command line + int profileIndex = arguments.indexOf("-p", 1); + if ((profileIndex != -1) && (profileIndex < arguments.size() - 1)) { + qDebug("profile overwritten on command line"); + selectedProfileName = arguments.at(profileIndex + 1); + } + arguments.removeAt(profileIndex); + arguments.removeAt(profileIndex); + } + qDebug("configured profile: %s", qPrintable(selectedProfileName)); + + // if we have a command line parameter, it is either a nxm link or + // a binary to start + if ((arguments.size() > 1) && (!isNxmLink(arguments.at(1)))) { + QString exeName = arguments.at(1); + qDebug("starting %s from command line", qPrintable(exeName)); + arguments.removeFirst(); // remove application name (ModOrganizer.exe) + arguments.removeFirst(); // remove binary name + // pass the remaining parameters to the binary + mainWindow.spawnProgram(exeName, arguments.join(" "), selectedProfileName, QDir()); + return 0; } - arguments.removeAt(profileIndex); - arguments.removeAt(profileIndex); - } - qDebug("configured profile: %s", qPrintable(selectedProfileName)); - - // if we have a command line parameter, it is either a nxm link or - // a binary to start - if ((arguments.size() > 1) && (!isNxmLink(arguments.at(1)))) { - QString exeName = arguments.at(1); - qDebug("starting %s from command line", qPrintable(exeName)); - arguments.removeFirst(); // remove application name (ModOrganizer.exe) - arguments.removeFirst(); // remove binary name - // pass the remaining parameters to the binary - mainWindow.spawnProgram(exeName, arguments.join(" "), selectedProfileName, QDir()); - return 0; - } - mainWindow.createFirstProfile(); + mainWindow.createFirstProfile(); - if (selectedProfileName.length() != 0) { - if (!mainWindow.setCurrentProfile(selectedProfileName)) { + if (selectedProfileName.length() != 0) { + if (!mainWindow.setCurrentProfile(selectedProfileName)) { + mainWindow.setCurrentProfile(1); + qWarning("failed to set profile: %s", + selectedProfileName.toUtf8().constData()); + } + } else { mainWindow.setCurrentProfile(1); - qWarning("failed to set profile: %s", - selectedProfileName.toUtf8().constData()); } - } else { - mainWindow.setCurrentProfile(1); - } - qDebug("displaying main window"); - mainWindow.show(); + qDebug("displaying main window"); + mainWindow.show(); - if ((arguments.size() > 1) && - (isNxmLink(arguments.at(1)))) { - qDebug("starting download from command line: %s", qPrintable(arguments.at(1))); - mainWindow.externalMessage(arguments.at(1)); + if ((arguments.size() > 1) && + (isNxmLink(arguments.at(1)))) { + qDebug("starting download from command line: %s", qPrintable(arguments.at(1))); + mainWindow.externalMessage(arguments.at(1)); + } + splash.finish(&mainWindow); + res = application.exec(); } - splash.finish(&mainWindow); - return application.exec(); + return res; } catch (const std::exception &e) { reportError(e.what()); return 1; diff --git a/src/mainwindow.cpp b/src/mainwindow.cpp index 24772db1..1ea35d74 100644 --- a/src/mainwindow.cpp +++ b/src/mainwindow.cpp @@ -139,8 +139,8 @@ MainWindow::MainWindow(const QString &exeName, QSettings &initSettings, QWidget : QMainWindow(parent), ui(new Ui::MainWindow), m_Tutorial(this, "MainWindow"), m_ExeName(exeName), m_OldProfileIndex(-1), m_DirectoryStructure(new DirectoryEntry(L"data", NULL, 0)), - m_ModList(NexusInterface::instance()), m_ModListGroupingProxy(NULL), m_ModListSortProxy(NULL), - m_OldExecutableIndex(-1), m_GamePath(ToQString(GameInfo::instance().getGameDirectory())), + m_ModList(this), m_ModListGroupingProxy(NULL), m_ModListSortProxy(NULL), + m_PluginList(this), m_OldExecutableIndex(-1), m_GamePath(ToQString(GameInfo::instance().getGameDirectory())), m_DownloadManager(NexusInterface::instance(), this), m_InstallationManager(this), m_Translator(NULL), m_TranslatorQt(NULL), m_Updater(NexusInterface::instance(), this), m_CategoryFactory(CategoryFactory::instance()), @@ -149,7 +149,7 @@ MainWindow::MainWindow(const QString &exeName, QSettings &initSettings, QWidget m_GameInfo(new GameInfoImpl()) { ui->setupUi(this); - this->setWindowTitle(ToQString(GameInfo::instance().getGameName()).append(" Mod Organizer v").append(m_Updater.getVersion().canonicalString())); + this->setWindowTitle(ToQString(GameInfo::instance().getGameName()) + " Mod Organizer v" + m_Updater.getVersion().displayString()); m_RefreshProgress = new QProgressBar(statusBar()); m_RefreshProgress->setTextVisible(true); @@ -255,7 +255,7 @@ MainWindow::MainWindow(const QString &exeName, QSettings &initSettings, QWidget connect(&m_Updater, SIGNAL(updateAvailable()), this, SLOT(updateAvailable())); connect(&m_Updater, SIGNAL(motdAvailable(QString)), this, SLOT(motdReceived(QString))); - connect(ExitProxy::instance(), SIGNAL(exit()), this, SLOT(close())); +// connect(ExitProxy::instance(), SIGNAL(exit()), this, SLOT(close())); connect(NexusInterface::instance()->getAccessManager(), SIGNAL(loginSuccessful(bool)), this, SLOT(loginSuccessful(bool))); connect(NexusInterface::instance()->getAccessManager(), SIGNAL(loginFailed(QString)), this, SLOT(loginFailed(QString))); @@ -412,7 +412,7 @@ void MainWindow::actionToToolButton(QAction *&sourceAction) button->setToolButtonStyle(ui->toolBar->toolButtonStyle()); button->setToolTip(sourceAction->toolTip()); button->setShortcut(sourceAction->shortcut()); - QMenu *buttonMenu = new QMenu(sourceAction->text()); + QMenu *buttonMenu = new QMenu(sourceAction->text(), button); button->setMenu(buttonMenu); QAction *newAction = ui->toolBar->insertWidget(sourceAction, button); newAction->setObjectName(sourceAction->objectName()); @@ -1499,6 +1499,8 @@ void MainWindow::updateTo(QTreeWidgetItem *subTree, const std::wstring &director updateTo(directoryChild, temp.str(), **current, conflictsOnly); if (directoryChild->childCount() != 0) { subTree->addChild(directoryChild); + } else { + delete directoryChild; } } } @@ -3069,7 +3071,6 @@ void MainWindow::openExplorer_clicked() ::ShellExecuteW(NULL, L"explore", ToWString(modInfo->absolutePath()).c_str(), NULL, NULL, SW_SHOWNORMAL); } - void MainWindow::information_clicked() { try { @@ -3079,7 +3080,6 @@ void MainWindow::information_clicked() } } - void MainWindow::syncOverwrite() { ModInfo::Ptr modInfo = ModInfo::getByIndex(m_ContextRow); @@ -3091,7 +3091,6 @@ void MainWindow::syncOverwrite() } } - void MainWindow::createModFromOverwrite() { GuessedValue name; @@ -3125,14 +3124,12 @@ void MainWindow::createModFromOverwrite() refreshModList(); } - void MainWindow::cancelModListEditor() { ui->modList->setEnabled(false); ui->modList->setEnabled(true); } - void MainWindow::on_modList_doubleClicked(const QModelIndex &index) { if (!index.isValid()) { @@ -3155,7 +3152,6 @@ void MainWindow::on_modList_doubleClicked(const QModelIndex &index) } } - bool MainWindow::addCategories(QMenu *menu, int targetID) { ModInfo::Ptr modInfo = ModInfo::getByIndex(m_ContextRow); @@ -3210,7 +3206,6 @@ void MainWindow::saveCategoriesFromMenu(QMenu *menu, int modRow) } } - void MainWindow::saveCategories() { QMenu *menu = qobject_cast(sender()); @@ -3254,8 +3249,6 @@ void MainWindow::saveCategories() refreshFilters(); } - - void MainWindow::savePrimaryCategory() { QMenu *menu = qobject_cast(sender()); @@ -3280,7 +3273,6 @@ void MainWindow::savePrimaryCategory() } } - void MainWindow::checkModsForUpdates() { statusBar()->show(); @@ -3298,6 +3290,45 @@ void MainWindow::checkModsForUpdates() } } +void MainWindow::changeVersioningScheme() { + if (QMessageBox::question(this, tr("Continue?"), + tr("This will try to change the versioning scheme so that the newest version is interpreted as an update to " + "the installed version."), + QMessageBox::Yes | QMessageBox::Cancel) == QMessageBox::Yes) { + + ModInfo::Ptr info = ModInfo::getByIndex(m_ContextRow); + + bool success = false; + + static VersionInfo::VersionScheme schemes[] = { VersionInfo::SCHEME_REGULAR, VersionInfo::SCHEME_DECIMALMARK, VersionInfo::SCHEME_NUMBERSANDLETTERS }; + + for (int i = 0; i < sizeof(schemes) / sizeof(VersionInfo::VersionScheme) && !success; ++i) { + VersionInfo verOld(info->getVersion().canonicalString(), schemes[i]); + VersionInfo verNew(info->getNewestVersion().canonicalString(), schemes[i]); + if (verOld < verNew) { + info->setVersion(verOld); + info->setNewestVersion(verNew); + success = true; + } + } + if (!success) { + QMessageBox::information(this, tr("Sorry"), + tr("I don't know a versioning scheme where %1 is newer than %2.").arg(info->getNewestVersion().canonicalString()).arg(info->getVersion().canonicalString()), + QMessageBox::Ok); + } + } +} + +void MainWindow::ignoreUpdate() { + ModInfo::Ptr info = ModInfo::getByIndex(m_ContextRow); + info->ignoreUpdate(true); +} + +void MainWindow::unignoreUpdate() +{ + ModInfo::Ptr info = ModInfo::getByIndex(m_ContextRow); + info->ignoreUpdate(false); +} void MainWindow::addPrimaryCategoryCandidates(QMenu *primaryCategoryMenu, ModInfo::Ptr info) { @@ -3319,7 +3350,6 @@ void MainWindow::addPrimaryCategoryCandidates(QMenu *primaryCategoryMenu, ModInf } } - void MainWindow::addPrimaryCategoryCandidates() { QMenu *menu = qobject_cast(sender()); @@ -3333,7 +3363,6 @@ void MainWindow::addPrimaryCategoryCandidates() addPrimaryCategoryCandidates(menu, modInfo); } - void MainWindow::enableVisibleMods() { if (QMessageBox::question(NULL, tr("Confirm"), tr("Really enable all visible mods?"), @@ -3342,7 +3371,6 @@ void MainWindow::enableVisibleMods() } } - void MainWindow::disableVisibleMods() { if (QMessageBox::question(NULL, tr("Confirm"), tr("Really disable all visible mods?"), @@ -3351,7 +3379,6 @@ void MainWindow::disableVisibleMods() } } - void MainWindow::exportModListCSV() { SelectionDialog selection(tr("Choose what to export")); @@ -3406,7 +3433,6 @@ void MainWindow::exportModListCSV() } } - void addMenuAsPushButton(QMenu *menu, QMenu *subMenu) { QPushButton *pushBtn = new QPushButton(subMenu->title()); @@ -3416,13 +3442,13 @@ void addMenuAsPushButton(QMenu *menu, QMenu *subMenu) menu->addAction(action); } - void MainWindow::on_modList_customContextMenuRequested(const QPoint &pos) { try { QTreeView *modList = findChild("modList"); - m_ContextRow = mapToModel(&m_ModList, modList->indexAt(pos)).row(); + QModelIndex index = mapToModel(&m_ModList, modList->indexAt(pos)); + m_ContextRow = index.row(); QMenu menu; @@ -3461,6 +3487,17 @@ void MainWindow::on_modList_customContextMenuRequested(const QPoint &pos) connect(primaryCategoryMenu, SIGNAL(aboutToHide()), this, SLOT(savePrimaryCategory())); addMenuAsPushButton(&menu, primaryCategoryMenu); + menu.addSeparator(); + if (info->downgradeAvailable()) { + menu.addAction(tr("Change versioning scheme"), this, SLOT(changeVersioningScheme())); + } + if (info->updateIgnored()) { + menu.addAction(tr("Un-ignore update"), this, SLOT(unignoreUpdate())); + } else { + menu.addAction(tr("Ignore update"), this, SLOT(ignoreUpdate())); + } + 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())); @@ -4207,9 +4244,9 @@ void MainWindow::on_actionEndorseMO_triggered() void MainWindow::updateDownloadListDelegate() { if (ui->compactBox->isChecked()) { - ui->downloadView->setItemDelegate(new DownloadListWidgetCompactDelegate(&m_DownloadManager, ui->downloadView)); + ui->downloadView->setItemDelegate(new DownloadListWidgetCompactDelegate(&m_DownloadManager, ui->downloadView, ui->downloadView)); } else { - ui->downloadView->setItemDelegate(new DownloadListWidgetDelegate(&m_DownloadManager, ui->downloadView)); + ui->downloadView->setItemDelegate(new DownloadListWidgetDelegate(&m_DownloadManager, ui->downloadView, ui->downloadView)); } DownloadListSortProxy *sortProxy = new DownloadListSortProxy(&m_DownloadManager, ui->downloadView); @@ -4267,7 +4304,7 @@ void MainWindow::nxmUpdatesAvailable(const std::vector &modIDs, QVariant us } else { std::vector info = ModInfo::getByModID(result["id"].toInt()); for (auto iter = info.begin(); iter != info.end(); ++iter) { - (*iter)->setNewestVersion(VersionInfo(result["version"].toString())); + (*iter)->setNewestVersion(result["version"].toString()); (*iter)->setNexusDescription(result["description"].toString()); if (NexusInterface::instance()->getAccessManager()->loggedIn() && result.contains("voted_by_user")) { diff --git a/src/mainwindow.h b/src/mainwindow.h index 80dca172..dfec5f49 100644 --- a/src/mainwindow.h +++ b/src/mainwindow.h @@ -466,6 +466,10 @@ private slots: void removeFromToolbar(); void overwriteClosed(int); + void changeVersioningScheme(); + void ignoreUpdate(); + void unignoreUpdate(); + private slots: // ui slots // actions void on_actionAdd_Profile_triggered(); diff --git a/src/modinfo.cpp b/src/modinfo.cpp index 7632a86e..1479f7b4 100644 --- a/src/modinfo.cpp +++ b/src/modinfo.cpp @@ -303,10 +303,11 @@ ModInfoRegular::ModInfoRegular(const QDir &path, DirectoryEntry **directoryStruc QString metaFileName = path.absoluteFilePath("meta.ini"); QSettings metaFile(metaFileName, QSettings::IniFormat); - m_Notes = metaFile.value("notes", "").toString(); - m_NexusID = metaFile.value("modid", -1).toInt(); + m_Notes = metaFile.value("notes", "").toString(); + m_NexusID = metaFile.value("modid", -1).toInt(); m_Version.parse(metaFile.value("version", "").toString()); - m_NewestVersion = metaFile.value("newestVersion", "").toString(); + m_NewestVersion = metaFile.value("newestVersion", "").toString(); + m_IgnoredVersion = metaFile.value("ignoredVersion", "").toString(); m_InstallationFile = metaFile.value("installationFile", "").toString(); m_NexusDescription = metaFile.value("nexusDescription", "").toString(); m_LastNexusQuery = QDateTime::fromString(metaFile.value("lastNexusQuery", "").toString(), Qt::ISODate); @@ -377,6 +378,7 @@ void ModInfoRegular::saveMeta() temp.erase(m_PrimaryCategory); metaFile.setValue("category", QString("%1").arg(m_PrimaryCategory) + "," + SetJoin(temp, ",")); metaFile.setValue("newestVersion", m_NewestVersion.canonicalString()); + metaFile.setValue("ignoredVersion", m_IgnoredVersion.canonicalString()); metaFile.setValue("version", m_Version.canonicalString()); metaFile.setValue("modid", m_NexusID); metaFile.setValue("notes", m_Notes); @@ -396,10 +398,22 @@ void ModInfoRegular::saveMeta() bool ModInfoRegular::updateAvailable() const { + if (m_IgnoredVersion.isValid() && (m_IgnoredVersion == m_NewestVersion)) { + return false; + } return m_NewestVersion.isValid() && (m_Version < m_NewestVersion); } +bool ModInfoRegular::downgradeAvailable() const +{ + if (m_IgnoredVersion.isValid() && (m_IgnoredVersion == m_NewestVersion)) { + return false; + } + return m_NewestVersion.isValid() && (m_NewestVersion < m_Version); +} + + void ModInfoRegular::nxmDescriptionAvailable(int, QVariant, QVariant resultData) { QVariantMap result = resultData.toMap(); @@ -576,6 +590,16 @@ QString ModInfoRegular::absolutePath() const return m_Path; } +void ModInfoRegular::ignoreUpdate(bool ignore) +{ + if (ignore) { + m_IgnoredVersion = m_NewestVersion; + } else { + m_IgnoredVersion.clear(); + } + m_MetaInfoChanged = true; +} + std::vector ModInfoRegular::getFlags() const { diff --git a/src/modinfo.h b/src/modinfo.h index 7e217de7..3b83d207 100644 --- a/src/modinfo.h +++ b/src/modinfo.h @@ -192,6 +192,22 @@ public: **/ virtual bool updateAvailable() const = 0; + /** + * @return true if the update currently available is ignored + */ + virtual bool updateIgnored() const = 0; + + /** + * @brief test if the "newest" version of the mod is older than the installed version + * + * test if there is a newer version of the mod. This does NOT cause + * information to be retrieved from the nexus, it will only test version information already + * available locally. Use checkAllForUpdate() to update this version information + * + * @return true if the newest version is older than the installed one + **/ + virtual bool downgradeAvailable() const = 0; + /** * @brief request an update of nexus description for this mod. * @@ -309,6 +325,11 @@ public: **/ virtual MOBase::VersionInfo getNewestVersion() const = 0; + /** + * @brief ignore the newest version for updates + */ + virtual void ignoreUpdate(bool ignore) = 0; + /** * @brief getter for the nexus mod id * @@ -494,6 +515,22 @@ public: **/ bool updateAvailable() const; + /** + * @return true if the current update is being ignored + */ + virtual bool updateIgnored() const { return m_IgnoredVersion == m_NewestVersion; } + + /** + * @brief test if there is a newer version of the mod + * + * test if there is a newer version of the mod. This does NOT cause + * information to be retrieved from the nexus, it will only test version information already + * available locally. Use checkAllForUpdate() to update this version information + * + * @return true if there is a newer version + **/ + bool downgradeAvailable() const; + /** * @brief request an update of nexus description for this mod. * @@ -620,6 +657,11 @@ public: **/ MOBase::VersionInfo getNewestVersion() const { return m_NewestVersion; } + /** + * @brief ignore the newest version for updates + */ + void ignoreUpdate(bool ignore); + /** * @brief getter for the installation file * @@ -746,6 +788,7 @@ private: bool m_MetaInfoChanged; MOBase::VersionInfo m_NewestVersion; + MOBase::VersionInfo m_IgnoredVersion; EEndorsedState m_EndorsedState; @@ -767,10 +810,13 @@ class ModInfoBackup : public ModInfoRegular public: virtual bool updateAvailable() const { return false; } + virtual bool updateIgnored() const { return false; } + virtual bool downgradeAvailable() const { return false; } virtual bool updateNXMInfo() { return false; } virtual void setNexusID(int) {} virtual void endorse(bool) {} virtual int getFixedPriority() const { return -1; } + virtual void ignoreUpdate(bool) {} virtual bool canBeUpdated() const { return false; } virtual bool canBeEnabled() const { return false; } virtual std::vector getIniTweaks() const { return std::vector(); } @@ -798,12 +844,15 @@ class ModInfoOverwrite : public ModInfo public: virtual bool updateAvailable() const { return false; } + virtual bool updateIgnored() const { return false; } + virtual bool downgradeAvailable() const { return false; } virtual bool updateNXMInfo() { return false; } virtual void setCategory(int, bool) {} virtual bool setName(const QString&) { return false; } virtual void setNotes(const QString&) {} virtual void setNexusID(int) {} virtual void setNewestVersion(const MOBase::VersionInfo&) {} + virtual void ignoreUpdate(bool) {} virtual void setNexusDescription(const QString&) {} virtual void setIsEndorsed(bool) {} virtual void setNeverEndorse() {} diff --git a/src/modinfodialog.cpp b/src/modinfodialog.cpp index 75e7e499..b4ae57ea 100644 --- a/src/modinfodialog.cpp +++ b/src/modinfodialog.cpp @@ -76,7 +76,6 @@ ModInfoDialog::ModInfoDialog(ModInfo::Ptr modInfo, const DirectoryEntry *directo m_UTF8Codec = QTextCodec::codecForName("utf-8"); QListWidget *textFileList = findChild("textFileList"); - QListWidget *iniFileList = findChild("iniFileList"); QListWidget *iniTweaksList = findChild("iniTweaksList"); QListWidget *activeESPList = findChild("activeESPList"); QListWidget *inactiveESPList = findChild("inactiveESPList"); @@ -707,7 +706,7 @@ QString ModInfoDialog::getFileCategory(int categoryID) void ModInfoDialog::updateVersionColor() { // QPalette versionColor; - if (m_ModInfo->getVersion() < m_ModInfo->getNewestVersion()) { + if (m_ModInfo->getVersion() != m_ModInfo->getNewestVersion()) { ui->versionEdit->setStyleSheet("color: red"); // versionColor.setColor(QPalette::Text, Qt::red); ui->versionEdit->setToolTip(tr("Current Version: %1").arg(m_ModInfo->getNewestVersion().canonicalString())); @@ -758,13 +757,7 @@ void ModInfoDialog::modDetailsUpdated(bool success) ui->descriptionView->setHtml(tr("(description incomplete, please visit nexus)")); } - QString version = m_ModInfo->getNewestVersion().canonicalString(); - - if (!version.isEmpty()) { - m_ModInfo->setNewestVersion(version); - - updateVersionColor(); - } + updateVersionColor(); } } diff --git a/src/modlist.cpp b/src/modlist.cpp index b5a7182e..7367b2ae 100644 --- a/src/modlist.cpp +++ b/src/modlist.cpp @@ -143,13 +143,16 @@ QVariant ModList::data(const QModelIndex &modelIndex, int role) const } else if (column == COL_NAME) { return modInfo->name(); } else if (column == COL_VERSION) { - QString version = modInfo->getVersion().canonicalString(); - if (version.isEmpty() && modInfo->canBeUpdated()) { - version = "?"; - } else if (version[0] == 'd') { - version.remove(0, 1); + VersionInfo verInfo = modInfo->getVersion(); + if (role == Qt::EditRole) { + return verInfo.canonicalString(); + } else { + QString version = verInfo.displayString(); + if (version.isEmpty() && modInfo->canBeUpdated()) { + version = "?"; + } + return version; } - return version; } else if (column == COL_PRIORITY) { int priority = modInfo->getFixedPriority(); if (priority != INT_MIN) { @@ -241,17 +244,18 @@ QVariant ModList::data(const QModelIndex &modelIndex, int role) const result.setItalic(true); } } else if (column == COL_VERSION) { - if (modInfo->updateAvailable()) { + if (modInfo->updateAvailable() || modInfo->downgradeAvailable()) { result.setWeight(QFont::Bold); } } return result; } else if (role == Qt::DecorationRole) { if (column == COL_VERSION) { - if (modInfo->updateAvailable() && - modInfo->getNewestVersion().isValid()) { + if (modInfo->updateAvailable()) { return QIcon(":/MO/gui/update_available"); - } else if (modInfo->getVersion().isVersionDate()) { + } else if (modInfo->downgradeAvailable()) { + return QIcon(":/MO/gui/warning"); + } else if (modInfo->getVersion().scheme() == VersionInfo::SCHEME_DATE) { return QIcon(":/MO/gui/version_date"); } } @@ -264,7 +268,7 @@ QVariant ModList::data(const QModelIndex &modelIndex, int role) const } else if (column == COL_VERSION) { if (!modInfo->getNewestVersion().isValid()) { return QVariant(); - } else if (modInfo->updateAvailable()) { + } else if (modInfo->updateAvailable() || modInfo->downgradeAvailable()) { return QBrush(Qt::red); } else { return QBrush(Qt::darkGreen); @@ -291,7 +295,13 @@ QVariant ModList::data(const QModelIndex &modelIndex, int role) const return QString(); } } else if (column == COL_VERSION) { - return tr("installed version: %1, newest version: %2").arg(modInfo->getVersion().canonicalString()).arg(modInfo->getNewestVersion().canonicalString()); + QString text = tr("installed version: %1, newest version: %2").arg(modInfo->getVersion().displayString()).arg(modInfo->getNewestVersion().displayString()); + if (modInfo->downgradeAvailable()) { + text += "
" + tr("The newest version on Nexus seems to be older than the one you have installed. This could either mean the version you have has been withdrawn " + "(i.e. due to a bug) or the author uses a non-standard versioning scheme and that newest version is actually newer. " + "Either way you may want to \"upgrade\"."); + } + return text; } else if (column == COL_CATEGORY) { const std::set &categories = modInfo->getCategories(); std::wostringstream categoryString; diff --git a/src/modlistsortproxy.cpp b/src/modlistsortproxy.cpp index 53c03c6a..c7c3ab28 100644 --- a/src/modlistsortproxy.cpp +++ b/src/modlistsortproxy.cpp @@ -211,7 +211,7 @@ bool ModListSortProxy::filterMatches(ModInfo::Ptr info, bool enabled) const if (enabled) return false; } break; case CategoryFactory::CATEGORY_SPECIAL_UPDATEAVAILABLE: { - if (!info->updateAvailable()) return false; + if (!info->updateAvailable() && !info->downgradeAvailable()) return false; } break; case CategoryFactory::CATEGORY_SPECIAL_NOCATEGORY: { if (info->getCategories().size() > 0) return false; diff --git a/src/modlistview.cpp b/src/modlistview.cpp index 44228d5b..1a4f6266 100644 --- a/src/modlistview.cpp +++ b/src/modlistview.cpp @@ -4,7 +4,7 @@ #include -class ModListViewStyle: public QProxyStyle{ +class ModListViewStyle: public QProxyStyle { public: ModListViewStyle(QStyle *style, int indentation); @@ -37,7 +37,7 @@ void ModListViewStyle::drawPrimitive(PrimitiveElement element, const QStyleOptio ModListView::ModListView(QWidget *parent) : QTreeView(parent) { - setStyle(new ModListViewStyle(style(), indentation())); +// setStyle(new ModListViewStyle(style(), indentation())); } void ModListView::dragEnterEvent(QDragEnterEvent *event) diff --git a/src/nexusinterface.cpp b/src/nexusinterface.cpp index cd78ca4c..bee0bb44 100644 --- a/src/nexusinterface.cpp +++ b/src/nexusinterface.cpp @@ -68,6 +68,7 @@ void NexusBridge::nxmDescriptionAvailable(int modID, QVariant userData, QVariant std::set::iterator iter = m_RequestIDs.find(requestID); if (iter != m_RequestIDs.end()) { m_RequestIDs.erase(iter); + emit descriptionAvailable(modID, userData, resultData); } } @@ -142,6 +143,7 @@ QAtomicInt NexusInterface::NXMRequestInfo::s_NextID(0); NexusInterface::NexusInterface() : m_NMMVersion() { + atexit(&cleanup); m_AccessManager = new NXMAccessManager(this); m_DiskCache = new QNetworkDiskCache(this); @@ -149,6 +151,13 @@ NexusInterface::NexusInterface() } +void NexusInterface::cleanup() +{ + delete NexusInterface::s_Instance; + NexusInterface::s_Instance = NULL; +} + + NXMAccessManager *NexusInterface::getAccessManager() { return m_AccessManager; @@ -405,6 +414,7 @@ void NexusInterface::downloadRequestedNXM(const QString &url) emit requestNXMDownload(url); } +#include void NexusInterface::requestFinished(std::list::iterator iter) { diff --git a/src/nexusinterface.h b/src/nexusinterface.h index 0c304a71..0b53f9d0 100644 --- a/src/nexusinterface.h +++ b/src/nexusinterface.h @@ -294,6 +294,7 @@ private: NexusInterface(); void nextRequest(); void requestFinished(std::list::iterator iter); + static void cleanup(); private: diff --git a/src/nxmaccessmanager.cpp b/src/nxmaccessmanager.cpp index d83ffa61..a05b8a6c 100644 --- a/src/nxmaccessmanager.cpp +++ b/src/nxmaccessmanager.cpp @@ -44,6 +44,14 @@ NXMAccessManager::NXMAccessManager(QObject *parent) { } +NXMAccessManager::~NXMAccessManager() +{ + if (m_LoginReply != NULL) { + m_LoginReply->deleteLater(); + m_LoginReply = NULL; + } +} + QNetworkReply *NXMAccessManager::createRequest( QNetworkAccessManager::Operation operation, const QNetworkRequest &request, diff --git a/src/nxmaccessmanager.h b/src/nxmaccessmanager.h index b0c43978..1d8d36ab 100644 --- a/src/nxmaccessmanager.h +++ b/src/nxmaccessmanager.h @@ -37,6 +37,8 @@ public: explicit NXMAccessManager(QObject *parent); + ~NXMAccessManager(); + bool loggedIn() const; void login(const QString &username, const QString &password); diff --git a/src/organizer.pro b/src/organizer.pro index e89b6e99..a9353361 100644 --- a/src/organizer.pro +++ b/src/organizer.pro @@ -183,7 +183,6 @@ INCLUDEPATH += ../shared ../archive ../uibase ../bsatk ../esptk "$(BOOSTPATH)" LIBS += -L"$(BOOSTPATH)/stage/lib" - CONFIG(debug, debug|release) { OUTDIR = $$OUT_PWD/debug DSTDIR = $$PWD/../../outputd @@ -294,6 +293,12 @@ OTHER_FILES += \ INCLUDEPATH += "$(ZLIBPATH)" "$(ZLIBPATH)/build" "$(BOOSTPATH)" LIBS += -L"$(ZLIBPATH)/build" -lzlibstatic + +# leak detection with vld +#INCLUDEPATH += "E:/Visual Leak Detector/include" +#LIBS += -L"E:/Visual Leak Detector/lib/Win32" +#DEFINES += LEAK_CHECK_WITH_VLD + #SOURCES += modeltest.cpp #HEADERS += modeltest.h #DEFINES += TEST_MODELS diff --git a/src/pluginlist.cpp b/src/pluginlist.cpp index 39cca6af..e730d3f4 100644 --- a/src/pluginlist.cpp +++ b/src/pluginlist.cpp @@ -90,6 +90,10 @@ PluginList::PluginList(QObject *parent) } +PluginList::~PluginList() +{ +} + QString PluginList::getColumnName(int column) { diff --git a/src/pluginlist.h b/src/pluginlist.h index 3442a9f7..60c9be95 100644 --- a/src/pluginlist.h +++ b/src/pluginlist.h @@ -53,6 +53,8 @@ public: **/ PluginList(QObject *parent = NULL); + ~PluginList(); + /** * @brief does a complete refresh of the list * diff --git a/src/profile.cpp b/src/profile.cpp index 07f7010e..3da12d7d 100644 --- a/src/profile.cpp +++ b/src/profile.cpp @@ -185,7 +185,7 @@ void Profile::writeModlistNow(bool onlyOnTimer) const QString fileName = getModlistFileName(); if (QFile::exists(fileName)) { - shellDelete(QStringList(fileName)); + shellDelete(QStringList(fileName), false, QApplication::activeModalWidget()); } if (!file.copy(fileName)) { @@ -238,6 +238,7 @@ void Profile::createTweakedIniFile() if (error) { reportError(tr("failed to create tweaked ini: %1").arg(getCurrentErrorStringA().c_str())); } + qDebug("%s saved", qPrintable(QDir::toNativeSeparators(tweakedIni))); } diff --git a/src/selfupdater.cpp b/src/selfupdater.cpp index 421fbeab..bdace814 100644 --- a/src/selfupdater.cpp +++ b/src/selfupdater.cpp @@ -126,7 +126,6 @@ void SelfUpdater::startUpdate() void SelfUpdater::download(const QString &downloadLink, const QString &fileName) { - qDebug("download: %s", downloadLink.toUtf8().constData()); QNetworkAccessManager *accessManager = m_Interface->getAccessManager(); QUrl dlUrl(downloadLink); QNetworkRequest request(dlUrl); @@ -324,7 +323,6 @@ void SelfUpdater::nxmDescriptionAvailable(int, QVariant, QVariant resultData, in if (m_NewestVersion.isEmpty()) { QTimer::singleShot(5000, this, SLOT(testForUpdate())); } - VersionInfo currentVersion(m_MOVersion); VersionInfo newestVersion(m_NewestVersion); diff --git a/src/shared/gameinfo.cpp b/src/shared/gameinfo.cpp index 6b53450d..f74e52b4 100644 --- a/src/shared/gameinfo.cpp +++ b/src/shared/gameinfo.cpp @@ -40,6 +40,13 @@ GameInfo* GameInfo::s_Instance = NULL; GameInfo::GameInfo(const std::wstring &omoDirectory, const std::wstring &gameDirectory) : m_GameDirectory(gameDirectory), m_OrganizerDirectory(omoDirectory) { + atexit(&cleanup); +} + + +void GameInfo::cleanup() { + delete GameInfo::s_Instance; + GameInfo::s_Instance = NULL; } diff --git a/src/shared/gameinfo.h b/src/shared/gameinfo.h index 3e022ef4..14f52f05 100644 --- a/src/shared/gameinfo.h +++ b/src/shared/gameinfo.h @@ -176,9 +176,11 @@ private: static bool identifyGame(const std::wstring &omoDirectory, const std::wstring &searchPath); std::wstring getSpecialPath(LPCWSTR name) const; + static void cleanup(); + private: - static GameInfo* s_Instance; + static GameInfo *s_Instance; std::wstring m_MyGamesDirectory; diff --git a/src/shared/leaktrace.cpp b/src/shared/leaktrace.cpp index 83ed4fd0..c3721557 100644 --- a/src/shared/leaktrace.cpp +++ b/src/shared/leaktrace.cpp @@ -114,6 +114,7 @@ static struct __TraceData { } std::map m_Traces; + } __trace; diff --git a/src/shared/shared.pro b/src/shared/shared.pro index ab0bd8a0..992fd7f2 100644 --- a/src/shared/shared.pro +++ b/src/shared/shared.pro @@ -13,9 +13,17 @@ CONFIG += staticlib INCLUDEPATH += ../bsatk "$(BOOSTPATH)" + +# only for custom leak detection +#DEFINES += TRACE_LEAKS +#LIBS += -lDbgHelp + + CONFIG(debug, debug|release) { - LIBS += -L$$OUT_PWD/../bsatk/debug + LIBS += -L$$OUT_PWD/../bsatk/debug LIBS += -lDbgHelp + QMAKE_CXXFLAGS_DEBUG -= -Zi + QMAKE_CXXFLAGS += -Z7 } else { LIBS += -L$$OUT_PWD/../bsatk/release } diff --git a/src/spawn.cpp b/src/spawn.cpp index ab43b687..5639a78c 100644 --- a/src/spawn.cpp +++ b/src/spawn.cpp @@ -156,7 +156,7 @@ HANDLE startBinary(const QFileInfo &binary, const QString &arguments, const QStr return processHandle; } - +/* ExitProxy *ExitProxy::s_Instance = NULL; ExitProxy *ExitProxy::instance() @@ -170,4 +170,4 @@ ExitProxy *ExitProxy::instance() void ExitProxy::emitExit() { emit exit(); -} +}*/ diff --git a/src/spawn.h b/src/spawn.h index e0d1f958..48320fea 100644 --- a/src/spawn.h +++ b/src/spawn.h @@ -31,7 +31,7 @@ along with Mod Organizer. If not, see . * @brief a dirty little trick so we can issue a clean restart from startBinary * @note unused */ -class ExitProxy : public QObject { +/*class ExitProxy : public QObject { Q_OBJECT public: static ExitProxy *instance(); @@ -42,7 +42,7 @@ private: ExitProxy() {} private: static ExitProxy *s_Instance; -}; +};*/ /** diff --git a/src/splash.png b/src/splash.png index 45ace8f8..0137bf72 100644 Binary files a/src/splash.png and b/src/splash.png differ -- cgit v1.3.1 From 823dfd410b90407cf6a641226bc46291f23d0004 Mon Sep 17 00:00:00 2001 From: Tannin Date: Sun, 6 Oct 2013 13:34:34 +0200 Subject: - option to ignore/unignore updates is now only shown if there IS an update - window now shouldn't lose focus on win 8 2 seconds after mod information gets invalidated - small bugfix related to new version scheme parsing --- src/mainwindow.cpp | 14 ++++++++------ src/modlist.cpp | 11 +++++------ src/profile.cpp | 4 ++-- 3 files changed, 15 insertions(+), 14 deletions(-) (limited to 'src/modlist.cpp') diff --git a/src/mainwindow.cpp b/src/mainwindow.cpp index 9516f818..10985b0b 100644 --- a/src/mainwindow.cpp +++ b/src/mainwindow.cpp @@ -3293,8 +3293,8 @@ void MainWindow::checkModsForUpdates() void MainWindow::changeVersioningScheme() { if (QMessageBox::question(this, tr("Continue?"), - tr("This will try to change the versioning scheme so that the newest version is interpreted as an update to " - "the installed version."), + tr("The versioning scheme decides which version is considered newer than another.\n" + "This function will guess the versioning scheme under the assumption that the installed version is outdated."), QMessageBox::Yes | QMessageBox::Cancel) == QMessageBox::Yes) { ModInfo::Ptr info = ModInfo::getByIndex(m_ContextRow); @@ -3492,10 +3492,12 @@ void MainWindow::on_modList_customContextMenuRequested(const QPoint &pos) if (info->downgradeAvailable()) { menu.addAction(tr("Change versioning scheme"), this, SLOT(changeVersioningScheme())); } - if (info->updateIgnored()) { - menu.addAction(tr("Un-ignore update"), this, SLOT(unignoreUpdate())); - } else { - menu.addAction(tr("Ignore update"), this, SLOT(ignoreUpdate())); + if (info->updateAvailable() || info->downgradeAvailable()) { + if (info->updateIgnored()) { + menu.addAction(tr("Un-ignore update"), this, SLOT(unignoreUpdate())); + } else { + menu.addAction(tr("Ignore update"), this, SLOT(ignoreUpdate())); + } } menu.addSeparator(); diff --git a/src/modlist.cpp b/src/modlist.cpp index 7367b2ae..786f6f17 100644 --- a/src/modlist.cpp +++ b/src/modlist.cpp @@ -144,15 +144,13 @@ QVariant ModList::data(const QModelIndex &modelIndex, int role) const return modInfo->name(); } else if (column == COL_VERSION) { VersionInfo verInfo = modInfo->getVersion(); - if (role == Qt::EditRole) { - return verInfo.canonicalString(); - } else { - QString version = verInfo.displayString(); + QString version = verInfo.displayString(); + if (role != Qt::EditRole) { if (version.isEmpty() && modInfo->canBeUpdated()) { version = "?"; } - return version; } + return version; } else if (column == COL_PRIORITY) { int priority = modInfo->getFixedPriority(); if (priority != INT_MIN) { @@ -405,7 +403,8 @@ bool ModList::setData(const QModelIndex &index, const QVariant &value, int role) } break; case COL_VERSION: { ModInfo::Ptr info = ModInfo::getByIndex(modID); - VersionInfo version(value.toString()); + VersionInfo::VersionScheme scheme = info->getVersion().scheme(); + VersionInfo version(value.toString(), scheme); if (version.isValid()) { info->setVersion(version); return true; diff --git a/src/profile.cpp b/src/profile.cpp index 3da12d7d..e075a4e6 100644 --- a/src/profile.cpp +++ b/src/profile.cpp @@ -185,7 +185,7 @@ void Profile::writeModlistNow(bool onlyOnTimer) const QString fileName = getModlistFileName(); if (QFile::exists(fileName)) { - shellDelete(QStringList(fileName), false, QApplication::activeModalWidget()); + shellDeleteQuiet(fileName); } if (!file.copy(fileName)) { @@ -205,7 +205,7 @@ void Profile::createTweakedIniFile() { QString tweakedIni = m_Directory.absoluteFilePath("initweaks.ini"); - if (QFile::exists(tweakedIni) && !shellDelete(QStringList(tweakedIni))) { + if (QFile::exists(tweakedIni) && !shellDeleteQuiet(tweakedIni)) { reportError(tr("failed to update tweaked ini file, wrong settings may be used: %1").arg(windowsErrorString(::GetLastError()))); return; } -- cgit v1.3.1 From 9a03783f491505940a20d006055a5427bf364807 Mon Sep 17 00:00:00 2001 From: Tannin Date: Fri, 18 Oct 2013 23:35:38 +0200 Subject: - tooltip on download list now contains the file name - bugfix: when refreshing the directory tree conflict information wasn't immediately refreshed (including on start) - bugfix: dataChanged events wasn't emitted when user changed the modlist - bugfix: file patterns in checkfnis plugin weren't completely correct --- src/downloadlist.cpp | 6 ++++-- src/mainwindow.cpp | 7 ++++++- src/modinfo.cpp | 8 +++++++- src/modinfo.h | 10 ++++++++++ src/modlist.cpp | 21 +++++++++++++-------- 5 files changed, 40 insertions(+), 12 deletions(-) (limited to 'src/modlist.cpp') diff --git a/src/downloadlist.cpp b/src/downloadlist.cpp index 9ab48013..fe021a27 100644 --- a/src/downloadlist.cpp +++ b/src/downloadlist.cpp @@ -75,12 +75,14 @@ QVariant DownloadList::data(const QModelIndex &index, int role) const if (role == Qt::DisplayRole) { return index.row(); } else if (role == Qt::ToolTipRole) { + QString text = m_Manager->getFileName(index.row()) + "\n"; if (m_Manager->isInfoIncomplete(index.row())) { - return tr("Information missing, please select \"Query Info\" from the context menu to re-retrieve."); + text += tr("Information missing, please select \"Query Info\" from the context menu to re-retrieve."); } else { NexusInfo info = m_Manager->getNexusInfo(index.row()); - return QString("%1 (ID %2) %3").arg(info.m_ModName).arg(m_Manager->getModID(index.row())).arg(info.m_Version); + text += QString("%1 (ID %2) %3").arg(info.m_ModName).arg(m_Manager->getModID(index.row())).arg(info.m_Version); } + return text; } else { return QVariant(); } diff --git a/src/mainwindow.cpp b/src/mainwindow.cpp index de6f20cf..4c72ada3 100644 --- a/src/mainwindow.cpp +++ b/src/mainwindow.cpp @@ -2080,7 +2080,7 @@ QStringList MainWindow::findFiles(const QString &path, const std::function files = dir->getFiles(); foreach (FileEntry::Ptr file, files) { - if (filter(ToQString(file->getName()))) { + if (filter(ToQString(file->getFullPath()))) { result.append(ToQString(file->getFullPath())); } } @@ -2498,6 +2498,11 @@ void MainWindow::directory_refreshed() // some problem-reports may rely on the virtual directory tree so they need to be updated // now updateProblemsButton(); + + for (int i = 0; i < m_ModList.rowCount(); ++i) { + ModInfo::Ptr modInfo = ModInfo::getByIndex(i); + modInfo->clearCaches(); + } } diff --git a/src/modinfo.cpp b/src/modinfo.cpp index 9bc013f1..8d672675 100644 --- a/src/modinfo.cpp +++ b/src/modinfo.cpp @@ -324,6 +324,7 @@ ModInfoRegular::ModInfoRegular(const QDir &path, DirectoryEntry **directoryStruc } } + QString categoriesString = metaFile.value("category", "").toString(); QStringList categories = categoriesString.split(',', QString::SkipEmptyParts); @@ -589,6 +590,11 @@ void ModInfoRegular::endorse(bool doEndorse) } } +void ModInfoRegular::clearCaches() +{ + m_LastConflictCheck = QTime(); +} + QString ModInfoRegular::absolutePath() const { @@ -690,7 +696,7 @@ ModInfoRegular::EConflictType ModInfoRegular::isConflicted() const { // this is costy so cache the result QTime now = QTime::currentTime(); - if (abs(m_LastConflictCheck.secsTo(now)) > 10) { + if (m_LastConflictCheck.isNull() || (m_LastConflictCheck.secsTo(now) > 10)) { bool overwrite = false; bool overwritten = false; bool regular = false; diff --git a/src/modinfo.h b/src/modinfo.h index 59030350..71c8de55 100644 --- a/src/modinfo.h +++ b/src/modinfo.h @@ -282,6 +282,11 @@ public: */ virtual void endorse(bool doEndorse) = 0; + /** + * @brief clear all caches held for this mod + */ + virtual void clearCaches() {} + /** * @brief getter for the mod name * @@ -633,6 +638,11 @@ public: */ virtual void endorse(bool doEndorse); + /** + * @brief clear all caches held for this mod + */ + virtual void clearCaches(); + /** * @brief getter for the mod name * diff --git a/src/modlist.cpp b/src/modlist.cpp index 786f6f17..18bbfd5a 100644 --- a/src/modlist.cpp +++ b/src/modlist.cpp @@ -373,9 +373,10 @@ bool ModList::setData(const QModelIndex &index, const QVariant &value, int role) } return true; } else if (role == Qt::EditRole) { + bool res = false; switch (index.column()) { case COL_NAME: { - return renameMod(modID, value.toString()); + res = renameMod(modID, value.toString()); } break; case COL_PRIORITY: { bool ok = false; @@ -384,9 +385,9 @@ bool ModList::setData(const QModelIndex &index, const QVariant &value, int role) m_Profile->setModPriority(modID, newPriority); emit modlist_changed(index, role); - return true; + res = true; } else { - return false; + res = false; } } break; case COL_MODID: { @@ -396,9 +397,9 @@ bool ModList::setData(const QModelIndex &index, const QVariant &value, int role) if (ok) { info->setNexusID(newID); emit modlist_changed(index, role); - return true; + res = true; } else { - return false; + res = false; } } break; case COL_VERSION: { @@ -407,17 +408,21 @@ bool ModList::setData(const QModelIndex &index, const QVariant &value, int role) VersionInfo version(value.toString(), scheme); if (version.isValid()) { info->setVersion(version); - return true; + res = true; } else { - return false; + res = false; } } break; default: { qWarning("edit on column \"%s\" not supported", getColumnName(index.column()).toUtf8().constData()); - return false; + res = false; } break; } + if (res) { + emit dataChanged(index, index); + } + return res; } else { return false; } -- cgit v1.3.1 From 8c0b309bdee2527fab66b00b34171ef18f5055bf Mon Sep 17 00:00:00 2001 From: Tannin Date: Fri, 25 Oct 2013 14:49:42 +0200 Subject: - Option to choose edition of the game. Currently only relevant for FO3 because FO3 GOTY is its own app - applications that aren't in the executables list can again be started from the command line - references to missing categories are now removed from mods - bugfix: integrated fomod installer didn't update description and picture on some constellations of Windows version and theme --- src/ModOrganizer.pro | 20 ++++++++++---------- src/main.cpp | 21 +++++++++++++++++++++ src/mainwindow.cpp | 2 +- src/modinfo.cpp | 1 - src/modlist.cpp | 14 ++++++++++---- src/settings.cpp | 2 +- src/shared/fallout3info.cpp | 11 +++++++++-- src/shared/fallout3info.h | 3 ++- src/shared/falloutnvinfo.cpp | 2 +- src/shared/falloutnvinfo.h | 2 +- src/shared/gameinfo.cpp | 6 ++++++ src/shared/gameinfo.h | 3 ++- src/shared/oblivioninfo.cpp | 2 +- src/shared/oblivioninfo.h | 2 +- src/shared/skyriminfo.cpp | 2 +- src/shared/skyriminfo.h | 2 +- src/version.rc | 4 ++-- 17 files changed, 70 insertions(+), 29 deletions(-) (limited to 'src/modlist.cpp') diff --git a/src/ModOrganizer.pro b/src/ModOrganizer.pro index c8bfe6df..f35958f8 100644 --- a/src/ModOrganizer.pro +++ b/src/ModOrganizer.pro @@ -3,21 +3,21 @@ CONFIG += ordered SUBDIRS = bsatk \ - shared \ - uibase \ - organizer \ - hookdll \ - archive \ - helper \ + shared \ + uibase \ + organizer \ + hookdll \ + archive \ + helper \ plugins \ proxydll \ nxmhandler \ - BossDummy \ - pythonRunner \ - esptk + BossDummy \ + pythonRunner \ + esptk hookdll.depends = shared -organizer.depends = shared, uibase, plugins +organizer.depends = shared uibase plugins CONFIG(debug, debug|release) { DESTDIR = outputd diff --git a/src/main.cpp b/src/main.cpp index 59a4e837..90cf9e0e 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -400,6 +400,27 @@ int main(int argc, char *argv[]) settings.setValue("gamePath", gamePath.toUtf8().constData()); } + int edition = 0; + if (settings.contains("game_edition")) { + edition = settings.value("game_edition").toInt(); + } else { + std::vector editions = GameInfo::instance().getSteamVariants(); + if (editions.size() < 2) { + edition = 0; + } else { + SelectionDialog selection(QObject::tr("Please select the game edition you have (MO can't start the game correctly if this is set incorrectly!)"), NULL); + int index = 0; + for (auto iter = editions.begin(); iter != editions.end(); ++iter) { + selection.addChoice(ToQString(*iter), "", index++); + } + if (selection.exec() == QDialog::Rejected) { + return -1; + } else { + settings.setValue("game_edition", selection.getChoiceData().toInt()); + } + } + } + qDebug("managing game at %s", qPrintable(QDir::toNativeSeparators(gamePath))); ExecutablesList executablesList; diff --git a/src/mainwindow.cpp b/src/mainwindow.cpp index 14bb3b59..cf8e355f 100644 --- a/src/mainwindow.cpp +++ b/src/mainwindow.cpp @@ -2134,7 +2134,7 @@ HANDLE MainWindow::startApplication(const QString &executable, const QStringList } } catch (const std::runtime_error&) { qWarning("\"%s\" not set up as executable", executable.toUtf8().constData()); - return INVALID_HANDLE_VALUE; + binary = QFileInfo(executable); } } diff --git a/src/modinfo.cpp b/src/modinfo.cpp index 8d672675..faf8c95b 100644 --- a/src/modinfo.cpp +++ b/src/modinfo.cpp @@ -560,7 +560,6 @@ void ModInfoRegular::addNexusCategory(int categoryID) m_Categories.insert(CategoryFactory::instance().resolveNexusID(categoryID)); } - void ModInfoRegular::setIsEndorsed(bool endorsed) { if (m_EndorsedState != ENDORSED_NEVER) { diff --git a/src/modlist.cpp b/src/modlist.cpp index 18bbfd5a..0fdcf6fa 100644 --- a/src/modlist.cpp +++ b/src/modlist.cpp @@ -169,10 +169,16 @@ QVariant ModList::data(const QModelIndex &modelIndex, int role) const int category = modInfo->getPrimaryCategory(); if (category != -1) { CategoryFactory &categoryFactory = CategoryFactory::instance(); - try { - return categoryFactory.getCategoryName(categoryFactory.getCategoryIndex(category)); - } catch (const std::exception &e) { - qCritical("failed to retrieve category name: %s", e.what()); + if (categoryFactory.categoryExists(category)) { + try { + return categoryFactory.getCategoryName(categoryFactory.getCategoryIndex(category)); + } catch (const std::exception &e) { + qCritical("failed to retrieve category name: %s", e.what()); + return QString(); + } + } else { + qWarning("category %d doesn't exist (may have been removed)", category); + modInfo->setCategory(category, false); return QString(); } } else { diff --git a/src/settings.cpp b/src/settings.cpp index 4f301b0c..36a4f1f8 100644 --- a/src/settings.cpp +++ b/src/settings.cpp @@ -159,7 +159,7 @@ bool Settings::automaticLoginEnabled() const QString Settings::getSteamAppID() const { - return m_Settings.value("Settings/app_id", ToQString(GameInfo::instance().getSteamAPPId())).toString(); + return m_Settings.value("Settings/app_id", ToQString(GameInfo::instance().getSteamAPPId(m_Settings.value("game_edition", 0).toInt()))).toString(); } QString Settings::getDownloadDirectory() const diff --git a/src/shared/fallout3info.cpp b/src/shared/fallout3info.cpp index 79dd90c9..c673fa1b 100644 --- a/src/shared/fallout3info.cpp +++ b/src/shared/fallout3info.cpp @@ -133,10 +133,17 @@ std::wstring Fallout3Info::getOMODExt() return L"fomod"; } +std::vector Fallout3Info::getSteamVariants() const +{ + return boost::assign::list_of(L"Regular")(L"Game Of The Year"); +} -std::wstring Fallout3Info::getSteamAPPId() +std::wstring Fallout3Info::getSteamAPPId(int variant) const { - return L"22300"; + switch (variant) { + case 1: return L"22370"; + default: return L"22300"; + } } diff --git a/src/shared/fallout3info.h b/src/shared/fallout3info.h index 95a76471..0fa97d41 100644 --- a/src/shared/fallout3info.h +++ b/src/shared/fallout3info.h @@ -66,7 +66,8 @@ public: virtual std::wstring getReferenceDataFile(); virtual std::wstring getOMODExt(); - virtual std::wstring getSteamAPPId(); + virtual std::vector getSteamVariants() const; + virtual std::wstring getSteamAPPId(int variant = 0) const; virtual std::wstring getSEName(); diff --git a/src/shared/falloutnvinfo.cpp b/src/shared/falloutnvinfo.cpp index 6da454ee..7d7f0098 100644 --- a/src/shared/falloutnvinfo.cpp +++ b/src/shared/falloutnvinfo.cpp @@ -136,7 +136,7 @@ std::wstring FalloutNVInfo::getOMODExt() } -std::wstring FalloutNVInfo::getSteamAPPId() +std::wstring FalloutNVInfo::getSteamAPPId(int) const { return L"22380"; } diff --git a/src/shared/falloutnvinfo.h b/src/shared/falloutnvinfo.h index 2f6cba7b..3960c951 100644 --- a/src/shared/falloutnvinfo.h +++ b/src/shared/falloutnvinfo.h @@ -68,7 +68,7 @@ public: virtual std::wstring getReferenceDataFile(); virtual std::wstring getOMODExt(); - virtual std::wstring getSteamAPPId(); + virtual std::wstring getSteamAPPId(int variant = 0) const; virtual std::wstring getSEName(); diff --git a/src/shared/gameinfo.cpp b/src/shared/gameinfo.cpp index f74e52b4..00bb42fd 100644 --- a/src/shared/gameinfo.cpp +++ b/src/shared/gameinfo.cpp @@ -30,6 +30,7 @@ along with Mod Organizer. If not, see . #include #include #include +#include namespace MOShared { @@ -184,6 +185,11 @@ bool GameInfo::requiresSteam() const return FileExists(getGameDirectory().append(L"\\steam_api.dll")); } +std::vector GameInfo::getSteamVariants() const +{ + return boost::assign::list_of(L"Regular"); +} + std::wstring GameInfo::getLocalAppFolder() const { diff --git a/src/shared/gameinfo.h b/src/shared/gameinfo.h index 14f52f05..0221dd1b 100644 --- a/src/shared/gameinfo.h +++ b/src/shared/gameinfo.h @@ -137,7 +137,8 @@ public: virtual std::wstring getOMODExt() = 0; - virtual std::wstring getSteamAPPId() = 0; + virtual std::vector getSteamVariants() const; + virtual std::wstring getSteamAPPId(int variant = 0) const = 0; virtual std::wstring getSEName() = 0; diff --git a/src/shared/oblivioninfo.cpp b/src/shared/oblivioninfo.cpp index 7c6d5cbb..b3e65e59 100644 --- a/src/shared/oblivioninfo.cpp +++ b/src/shared/oblivioninfo.cpp @@ -243,7 +243,7 @@ std::wstring OblivionInfo::getOMODExt() } -std::wstring OblivionInfo::getSteamAPPId() +std::wstring OblivionInfo::getSteamAPPId(int) const { return L"22330"; } diff --git a/src/shared/oblivioninfo.h b/src/shared/oblivioninfo.h index 13374aa3..6a9f56ca 100644 --- a/src/shared/oblivioninfo.h +++ b/src/shared/oblivioninfo.h @@ -64,7 +64,7 @@ public: virtual std::wstring getReferenceDataFile(); virtual std::wstring getOMODExt(); - virtual std::wstring getSteamAPPId(); + virtual std::wstring getSteamAPPId(int variant = 0) const; virtual std::wstring getSEName(); diff --git a/src/shared/skyriminfo.cpp b/src/shared/skyriminfo.cpp index 71d791f5..0a0dd98d 100644 --- a/src/shared/skyriminfo.cpp +++ b/src/shared/skyriminfo.cpp @@ -169,7 +169,7 @@ std::wstring SkyrimInfo::getOMODExt() } -std::wstring SkyrimInfo::getSteamAPPId() +std::wstring SkyrimInfo::getSteamAPPId(int) const { return L"72850"; } diff --git a/src/shared/skyriminfo.h b/src/shared/skyriminfo.h index c5d31ff0..ae5ab81f 100644 --- a/src/shared/skyriminfo.h +++ b/src/shared/skyriminfo.h @@ -71,7 +71,7 @@ public: virtual std::wstring getReferenceDataFile(); virtual std::wstring getOMODExt(); - virtual std::wstring getSteamAPPId(); + virtual std::wstring getSteamAPPId(int variant = 0) const; virtual std::wstring getSEName(); diff --git a/src/version.rc b/src/version.rc index e71bc1b5..55de3798 100644 --- a/src/version.rc +++ b/src/version.rc @@ -1,7 +1,7 @@ #include "Winver.h" -#define VER_FILEVERSION 1,0,5,0 -#define VER_FILEVERSION_STR "1,0,5,0\0" +#define VER_FILEVERSION 1,0,7,0 +#define VER_FILEVERSION_STR "1,0,7,0\0" VS_VERSION_INFO VERSIONINFO FILEVERSION VER_FILEVERSION -- cgit v1.3.1 From d1594798e6e78bb329e744a72e92d3f292f38a20 Mon Sep 17 00:00:00 2001 From: Tannin Date: Fri, 1 Nov 2013 14:59:25 +0100 Subject: - added a new diagnosis to detect potential problems in regards to esp vs. asset ordering (not fully functional yet) - new plugin interfaces to the mod list - plugins can now query the origin (mod) of a esp/esm - bugfix: potential access to profile before one was activated - bugfix: regression in previous (not-yet-released) commit prevented changes to bsa list from being saved --- src/mainwindow.cpp | 18 +++++++++++++--- src/mainwindow.h | 4 +++- src/modlist.cpp | 40 +++++++++++++++++++++++++++++++++++ src/modlist.h | 15 ++++++++++++- src/pluginlist.cpp | 9 ++++++++ src/pluginlist.h | 1 + src/problemsdialog.ui | 58 +++++++++++++++++++++++++-------------------------- 7 files changed, 110 insertions(+), 35 deletions(-) (limited to 'src/modlist.cpp') diff --git a/src/mainwindow.cpp b/src/mainwindow.cpp index 967a3842..774c99f5 100644 --- a/src/mainwindow.cpp +++ b/src/mainwindow.cpp @@ -246,7 +246,7 @@ MainWindow::MainWindow(const QString &exeName, QSettings &initSettings, QWidget connect(ui->espFilterEdit, SIGNAL(textChanged(QString)), this, SLOT(espFilterChanged(QString))); connect(&m_PluginList, SIGNAL(saveTimer()), this, SLOT(savePluginList())); - connect(ui->bsaList, SIGNAL(itemsMoved()), this, SLOT(on_bsaList_itemMoved())); + connect(ui->bsaList, SIGNAL(itemsMoved()), this, SLOT(bsaList_itemMoved())); connect(ui->bsaWarning, SIGNAL(linkActivated(QString)), this, SLOT(linkClicked(QString))); @@ -1673,7 +1673,7 @@ void MainWindow::refreshSaveList() void MainWindow::refreshLists() { - if (m_DirectoryStructure->isPopulated()) { + if ((m_CurrentProfile != NULL) && m_DirectoryStructure->isPopulated()) { refreshESPList(); refreshBSAList(); } // no point in refreshing lists if no files have been added to the directory tree @@ -2104,6 +2104,11 @@ IPluginList *MainWindow::pluginList() return &m_PluginList; } +IModList *MainWindow::modList() +{ + return &m_ModList; +} + HANDLE MainWindow::startApplication(const QString &executable, const QStringList &args, const QString &cwd, const QString &profile) { QFileInfo binary; @@ -4650,13 +4655,19 @@ void MainWindow::on_bsaList_customContextMenuRequested(const QPoint &pos) menu.exec(ui->bsaList->mapToGlobal(pos)); } -void MainWindow::on_bsaList_itemMoved() +void MainWindow::bsaList_itemMoved() { saveArchiveList(); m_CheckBSATimer.start(500); } +void MainWindow::on_bsaList_itemChanged(QTreeWidgetItem*, int) +{ + saveArchiveList(); + m_CheckBSATimer.start(500); +} + void MainWindow::on_actionProblems_triggered() { // QString problemDescription; @@ -4836,3 +4847,4 @@ void MainWindow::on_showHiddenBox_toggled(bool checked) { m_DownloadManager.setShowHidden(checked); } + diff --git a/src/mainwindow.h b/src/mainwindow.h index 93a6af80..cf97d4f9 100644 --- a/src/mainwindow.h +++ b/src/mainwindow.h @@ -137,6 +137,7 @@ public: virtual QStringList findFiles(const QString &path, const std::function &filter) const; virtual MOBase::IDownloadManager *downloadManager(); virtual MOBase::IPluginList *pluginList(); + virtual MOBase::IModList *modList(); virtual HANDLE startApplication(const QString &executable, const QStringList &args = QStringList(), const QString &cwd = "", const QString &profile = ""); virtual bool onAboutToRun(const std::function &func); @@ -510,7 +511,7 @@ private slots: // ui slots void on_actionEndorseMO_triggered(); void on_bsaList_customContextMenuRequested(const QPoint &pos); - void on_bsaList_itemMoved(); + void bsaList_itemMoved(); void on_btnRefreshData_clicked(); void on_categoriesList_customContextMenuRequested(const QPoint &pos); void on_compactBox_toggled(bool checked); @@ -531,6 +532,7 @@ private slots: // ui slots void on_categoriesList_itemSelectionChanged(); void on_linkButton_pressed(); void on_showHiddenBox_toggled(bool checked); + void on_bsaList_itemChanged(QTreeWidgetItem *item, int column); }; #endif // MAINWINDOW_H diff --git a/src/modlist.cpp b/src/modlist.cpp index 0fdcf6fa..541e1e6e 100644 --- a/src/modlist.cpp +++ b/src/modlist.cpp @@ -551,6 +551,46 @@ void ModList::changeModPriority(int sourceIndex, int newPriority) emit modorder_changed(); } +IModList::ModState ModList::state(const QString &name) const +{ + unsigned int modIndex = ModInfo::getIndex(name); + if (modIndex == UINT_MAX) { + return IModList::STATE_MISSING; + } else { + ModInfo::Ptr modInfo = ModInfo::getByIndex(modIndex); + if (modInfo->canBeEnabled()) { + return m_Profile->modEnabled(modIndex) ? IModList::STATE_ACTIVE : IModList::STATE_INACTIVE; + } else { + return IModList::STATE_NOTOPTIONAL; + } + } +} + +int ModList::priority(const QString &name) const +{ + unsigned int modIndex = ModInfo::getIndex(name); + if (modIndex == UINT_MAX) { + return -1; + } else { + return m_Profile->getModPriority(modIndex); + } +} + +bool ModList::setPriority(const QString &name, int newPriority) +{ + if ((newPriority < 0) || (newPriority >= static_cast(m_Profile->numRegularMods()))) { + return false; + } + + unsigned int modIndex = ModInfo::getIndex(name); + if (modIndex == UINT_MAX) { + return false; + } else { + m_Profile->setModPriority(modIndex, newPriority); + notifyChange(modIndex); + return true; + } +} bool ModList::dropURLs(const QMimeData *mimeData, int row, const QModelIndex &parent) { diff --git a/src/modlist.h b/src/modlist.h index 7e76d677..cdaa24ca 100644 --- a/src/modlist.h +++ b/src/modlist.h @@ -26,6 +26,8 @@ along with Mod Organizer. If not, see . #include "modinfo.h" #include "profile.h" +#include + #include #include #include @@ -41,7 +43,7 @@ along with Mod Organizer. If not, see . * This is used in a view in the main window of MO. It combines general information about * the mods from ModInfo with status information from the Profile **/ -class ModList : public QAbstractItemModel +class ModList : public QAbstractItemModel, public MOBase::IModList { Q_OBJECT @@ -92,6 +94,17 @@ public: void changeModPriority(int sourceIndex, int newPriority); +public: + + /// \copydoc MOBase::IModList::state + virtual ModState state(const QString &name) const; + + /// \copydoc MOBase::IModList::priority + virtual int priority(const QString &name) const; + + /// \copydoc MOBase::IModList::setPriority + virtual bool setPriority(const QString &name, int newPriority); + public: // implementation of virtual functions of QAbstractItemModel virtual int rowCount(const QModelIndex &parent = QModelIndex()) const; diff --git a/src/pluginlist.cpp b/src/pluginlist.cpp index 74aa6ff3..456d29ee 100644 --- a/src/pluginlist.cpp +++ b/src/pluginlist.cpp @@ -611,6 +611,15 @@ bool PluginList::isMaster(const QString &name) const } } +QString PluginList::origin(const QString &name) const +{ + auto iter = m_ESPsByName.find(name.toLower()); + if (iter == m_ESPsByName.end()) { + return false; + } else { + return m_ESPs[iter->second].m_OriginName; + } +} void PluginList::updateIndices() { diff --git a/src/pluginlist.h b/src/pluginlist.h index 2ad54d6d..4da7be4b 100644 --- a/src/pluginlist.h +++ b/src/pluginlist.h @@ -140,6 +140,7 @@ public: virtual int priority(const QString &name) const; virtual int loadOrder(const QString &name) const; virtual bool isMaster(const QString &name) const; + virtual QString origin(const QString &name) const; public: // implementation of the QAbstractTableModel interface diff --git a/src/problemsdialog.ui b/src/problemsdialog.ui index b194bf31..d3a0d959 100644 --- a/src/problemsdialog.ui +++ b/src/problemsdialog.ui @@ -49,54 +49,52 @@ <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> <html><head><meta name="qrichtext" content="1" /><style type="text/css"> p, li { white-space: pre-wrap; } -</style></head><body style=" font-family:'MS Shell Dlg 2'; font-size:7.8pt; font-weight:400; font-style:normal;"> +</style></head><body style=" font-family:'MS Shell Dlg 2'; font-size:8.25pt; font-weight:400; font-style:normal;"> <p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:8pt;"><br /></p></body></html> - - - Qt::Horizontal - - - QDialogButtonBox::Cancel|QDialogButtonBox::Ok - - + + + + + Qt::Horizontal + + + + 40 + 20 + + + + + + + + Close + + + + - buttonBox - accepted() + closeButton + clicked() ProblemsDialog accept() - 248 - 254 - - - 157 - 274 - - - - - buttonBox - rejected() - ProblemsDialog - reject() - - - 316 - 260 + 526 + 354 286 - 274 + 187 -- cgit v1.3.1 From f010c22a3b2ec31bc4ebc3f577ac4455c5de5dfb Mon Sep 17 00:00:00 2001 From: Tannin Date: Wed, 6 Nov 2013 18:35:27 +0100 Subject: - diagnosis plugins can now request to be re-evaluated - main application now contains means for plugins to react on some changes (to be extended) - plugins can now retrieve more information about a mod - user-agent sent to nexus now automatically contains the current MO version - included updated russian translation - problems dialog now refreshes itself after a fix was applied - fixed new esp/asset ordering diagnosis. May be fully functional now - bugfix: restoring locked load order could leave MO in an endless loop (not sure if this fix is correct yet) - bugfix: plugin list was not visually updated after some changes - bugfix: nmm importer threw away mod ordering --- src/downloadlistwidget.ui | 4 +- src/main.cpp | 2 +- src/mainwindow.cpp | 9 +- src/mainwindow.ui | 57 +- src/modinfo.cpp | 9 + src/modinfo.h | 1 + src/modinfodialog.ui | 33 +- src/modlist.cpp | 49 +- src/modlist.h | 21 +- src/nexusinterface.cpp | 15 +- src/nexusinterface.h | 1 + src/organizer_ru.qm | Bin 53312 -> 188628 bytes src/organizer_ru.ts | 3256 ++++++++++++++++++++--------------------- src/overwriteinfodialog.cpp | 4 +- src/overwriteinfodialog.h | 100 +- src/pluginlist.cpp | 28 +- src/pluginlist.h | 10 +- src/problemsdialog.cpp | 31 +- src/problemsdialog.h | 4 + src/settingsdialog.ui | 2 +- src/shared/directoryentry.cpp | 2 +- src/version.rc | 4 +- 22 files changed, 1838 insertions(+), 1804 deletions(-) (limited to 'src/modlist.cpp') diff --git a/src/downloadlistwidget.ui b/src/downloadlistwidget.ui index 01b2ee07..106ac922 100644 --- a/src/downloadlistwidget.ui +++ b/src/downloadlistwidget.ui @@ -7,7 +7,7 @@ 0 0 315 - 75 + 81 @@ -78,7 +78,7 @@ - 0 + 0 diff --git a/src/main.cpp b/src/main.cpp index 90cf9e0e..5053d21d 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -140,7 +140,7 @@ bool bootstrap() QObject::tr("The current user account doesn't have the required access rights to run " "Mod Organizer. The neccessary changes can be made automatically (the MO directory " "will be made writable for the current user account). You will be asked to run " - "\"helper.exe\" with administrative rights)."), + "\"helper.exe\" with administrative rights."), QMessageBox::Yes | QMessageBox::Cancel) == QMessageBox::Yes) { if (!Helper::init(GameInfo::instance().getOrganizerDirectory())) { return false; diff --git a/src/mainwindow.cpp b/src/mainwindow.cpp index 774c99f5..f726757c 100644 --- a/src/mainwindow.cpp +++ b/src/mainwindow.cpp @@ -487,6 +487,7 @@ void MainWindow::updateProblemsButton() ui->actionProblems->setIconText(tr("Problems")); ui->actionProblems->setToolTip(tr("There are potential problems with your setup")); } else { + ui->actionProblems->setEnabled(false); ui->actionProblems->setIconText(tr("No Problems")); ui->actionProblems->setToolTip(tr("Everything seems to be in order")); } @@ -983,6 +984,7 @@ bool MainWindow::registerPlugin(QObject *plugin) IPluginDiagnose *diagnose = qobject_cast(plugin); if (diagnose != NULL) { m_DiagnosisPlugins.push_back(diagnose); + diagnose->onInvalidated([&] () { this->updateProblemsButton(); }); } } { // tool plugins @@ -2178,7 +2180,7 @@ QString MainWindow::fullDescription(unsigned int key) const { switch (key) { case PROBLEM_PLUGINSNOTLOADED: { - QString result = tr("The following Plugins could not be loaded. The reason may be missing dependencies (i.e. python) or an outdated version:
    "); + QString result = tr("The following plugins could not be loaded. The reason may be missing dependencies (i.e. python) or an outdated version:") + "
      "; foreach (const QString &plugin, m_UnloadedPlugins) { result += "
    • " + plugin + "
    • "; } @@ -2985,8 +2987,9 @@ void MainWindow::unendorse_clicked() void MainWindow::overwriteClosed(int) { - QDialog *dialog = this->findChild("__overwriteDialog"); + OverwriteInfoDialog *dialog = this->findChild("__overwriteDialog"); if (dialog != NULL) { + m_ModList.modInfoChanged(dialog->modInfo()); dialog->deleteLater(); } } @@ -2994,6 +2997,7 @@ void MainWindow::overwriteClosed(int) void MainWindow::displayModInformation(ModInfo::Ptr modInfo, unsigned int index, int tab) { + m_ModList.modInfoAboutToChange(modInfo); std::vector flags = modInfo->getFlags(); if (std::find(flags.begin(), flags.end(), ModInfo::FLAG_OVERWRITE) != flags.end()) { QDialog *dialog = this->findChild("__overwriteDialog"); @@ -3019,6 +3023,7 @@ void MainWindow::displayModInformation(ModInfo::Ptr modInfo, unsigned int index, dialog.exec(); modInfo->saveMeta(); emit modInfoDisplayed(); + m_ModList.modInfoChanged(modInfo); } if (m_CurrentProfile->modEnabled(index)) { diff --git a/src/mainwindow.ui b/src/mainwindow.ui index 73ca868e..bc7dc212 100644 --- a/src/mainwindow.ui +++ b/src/mainwindow.ui @@ -31,7 +31,16 @@ 4 - + + 6 + + + 6 + + + 6 + + 6 @@ -577,7 +586,7 @@ p, li { white-space: pre-wrap; } QTabWidget::Rounded - 1 + 0 @@ -721,7 +730,16 @@ p, li { white-space: pre-wrap; } Archives - + + 6 + + + 6 + + + 6 + + 6 @@ -801,7 +819,16 @@ BSAs checked here are loaded in such a way that your installation order is obeye Data - + + 6 + + + 6 + + + 6 + + 6 @@ -871,7 +898,16 @@ BSAs checked here are loaded in such a way that your installation order is obeye Saves - + + 6 + + + 6 + + + 6 + + 6 @@ -900,7 +936,16 @@ p, li { white-space: pre-wrap; } Downloads - + + 2 + + + 2 + + + 2 + + 2 diff --git a/src/modinfo.cpp b/src/modinfo.cpp index faf8c95b..f436eba8 100644 --- a/src/modinfo.cpp +++ b/src/modinfo.cpp @@ -827,6 +827,15 @@ ModInfoOverwrite::ModInfoOverwrite() } +bool ModInfoOverwrite::isEmpty() const +{ + QDirIterator iter(absolutePath(), QDir::NoDotAndDotDot | QDir::Files | QDir::Dirs); + if (!iter.hasNext()) return true; + iter.next(); + if ((iter.fileName() == "meta.ini") && !iter.hasNext()) return true; + return false; +} + QString ModInfoOverwrite::absolutePath() const { return QDir::fromNativeSeparators(ToQString(GameInfo::instance().getOverwriteDir())); diff --git a/src/modinfo.h b/src/modinfo.h index 71c8de55..6de0275b 100644 --- a/src/modinfo.h +++ b/src/modinfo.h @@ -866,6 +866,7 @@ public: virtual void setNeverEndorse() {} virtual bool remove() { return false; } virtual void endorse(bool) {} + virtual bool isEmpty() const; virtual QString name() const { return "Overwrite"; } virtual QString notes() const { return ""; } virtual QDateTime creationTime() const { return m_StartupTime; } diff --git a/src/modinfodialog.ui b/src/modinfodialog.ui index 7e06745d..2fdbe5f3 100644 --- a/src/modinfodialog.ui +++ b/src/modinfodialog.ui @@ -209,7 +209,7 @@ 0 0 - 676 + 668 126 @@ -217,17 +217,22 @@ Images located in the mod. - <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> -<html><head><meta name="qrichtext" content="1" /><style type="text/css"> -p, li { white-space: pre-wrap; } -</style></head><body style=" font-family:'MS Shell Dlg 2'; font-size:8.25pt; font-weight:400; font-style:normal;"> -<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">This lists all the images (.jpg and .png) in the mod directory, like screenshots and such. Click one to get a larger view.</span></p></body></html> + This lists all the images (.jpg and .png) in the mod directory, like screenshots and such. Click one to get a larger view. 0 - + + 0 + + + 0 + + + 0 + + 0 @@ -254,14 +259,10 @@ p, li { white-space: pre-wrap; } List of esps and esms that can not be loaded by the game. - <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> -<html><head><meta name="qrichtext" content="1" /><style type="text/css"> -p, li { white-space: pre-wrap; } -</style></head><body style=" font-family:'MS Shell Dlg 2'; font-size:8.25pt; font-weight:400; font-style:normal;"> -<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">List of esps and esms contained in this plugin that currently can not be loaded by the game. They will not even appear in the esp-list in the main MO-window.</span></p> -<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">They usually contain optional functionality, see the readme.</span></p> -<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:8pt;"></p> -<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">Most mods do not have optional esps, so chances are good you are looking at an empty list.</span></p></body></html> + List of esps and esms contained in this plugin that currently can not be loaded by the game. They will not even appear in the esp-list in the main MO-window. +They usually contain optional functionality, see the readme. + +Most mods do not have optional esps, so chances are good you are looking at an empty list. @@ -659,7 +660,7 @@ p, li { white-space: pre-wrap; } <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> <html><head><meta name="qrichtext" content="1" /><style type="text/css"> p, li { white-space: pre-wrap; } -</style></head><body style=" font-family:'MS Shell Dlg 2'; font-size:8.25pt; font-weight:400; font-style:normal;"> +</style></head><body style=" font-family:'MS Shell Dlg 2'; font-size:7.8pt; font-weight:400; font-style:normal;"> <p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:8pt;"><br /></p> <p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:8pt;"><br /></p></body></html> diff --git a/src/modlist.cpp b/src/modlist.cpp index 541e1e6e..446946dc 100644 --- a/src/modlist.cpp +++ b/src/modlist.cpp @@ -551,19 +551,49 @@ void ModList::changeModPriority(int sourceIndex, int newPriority) emit modorder_changed(); } -IModList::ModState ModList::state(const QString &name) const +void ModList::modInfoAboutToChange(ModInfo::Ptr info) { - unsigned int modIndex = ModInfo::getIndex(name); - if (modIndex == UINT_MAX) { - return IModList::STATE_MISSING; + m_ChangeInfo.name = info->name(); + m_ChangeInfo.state = state(info->name()); +} + +void ModList::modInfoChanged(ModInfo::Ptr info) +{ + if (info->name() == m_ChangeInfo.name) { + IModList::ModStates newState = state(info->name()); + if (m_ChangeInfo.state != newState) { + m_ModStateChanged(info->name(), newState); + } } else { + qCritical("modInfoChanged not called after modInfoAboutToChange"); + } +} + +IModList::ModStates ModList::state(const QString &name) const +{ + ModStates result; + unsigned int modIndex = ModInfo::getIndex(name); + if (modIndex != UINT_MAX) { + result |= IModList::STATE_EXISTS; ModInfo::Ptr modInfo = ModInfo::getByIndex(modIndex); + if (modInfo->isEmpty()) { + result |= IModList::STATE_EMPTY; + } + if (modInfo->endorsedState() == ModInfo::ENDORSED_TRUE) { + result |= IModList::STATE_ENDORSED; + } + if (modInfo->isValid()) { + result |= IModList::STATE_VALID; + } if (modInfo->canBeEnabled()) { - return m_Profile->modEnabled(modIndex) ? IModList::STATE_ACTIVE : IModList::STATE_INACTIVE; + if (m_Profile->modEnabled(modIndex)) { + result |= IModList::STATE_ACTIVE; + } } else { - return IModList::STATE_NOTOPTIONAL; + result |= IModList::STATE_ESSENTIAL; } } + return result; } int ModList::priority(const QString &name) const @@ -592,6 +622,13 @@ bool ModList::setPriority(const QString &name, int newPriority) } } + +bool ModList::onModStateChanged(const std::function &func) +{ + auto conn = m_ModStateChanged.connect(func); + return conn.connected(); +} + bool ModList::dropURLs(const QMimeData *mimeData, int row, const QModelIndex &parent) { QStringList source; diff --git a/src/modlist.h b/src/modlist.h index cdaa24ca..8cab7f3e 100644 --- a/src/modlist.h +++ b/src/modlist.h @@ -32,7 +32,7 @@ along with Mod Organizer. If not, see . #include #include #include - +#include #include #include #include @@ -61,6 +61,8 @@ public: COL_LASTCOLUMN = COL_PRIORITY }; + typedef boost::signals2::signal SignalModStateChanged; + public: /** @@ -94,10 +96,13 @@ public: void changeModPriority(int sourceIndex, int newPriority); + void modInfoAboutToChange(ModInfo::Ptr info); + void modInfoChanged(ModInfo::Ptr info); + public: /// \copydoc MOBase::IModList::state - virtual ModState state(const QString &name) const; + virtual ModStates state(const QString &name) const; /// \copydoc MOBase::IModList::priority virtual int priority(const QString &name) const; @@ -105,6 +110,9 @@ public: /// \copydoc MOBase::IModList::setPriority virtual bool setPriority(const QString &name, int newPriority); + /// \copydoc MOBase::IModList::onModStateChanged + virtual bool onModStateChanged(const std::function &func); + public: // implementation of virtual functions of QAbstractItemModel virtual int rowCount(const QModelIndex &parent = QModelIndex()) const; @@ -245,6 +253,11 @@ private: unsigned int categoryOrder; }; + struct TModInfoChange { + QString name; + QFlags state; + }; + private: Profile *m_Profile; @@ -258,6 +271,10 @@ private: bool m_DropOnItems; + TModInfoChange m_ChangeInfo; + + SignalModStateChanged m_ModStateChanged; + }; #endif // MODLIST_H diff --git a/src/nexusinterface.cpp b/src/nexusinterface.cpp index 936ff400..6a4ae046 100644 --- a/src/nexusinterface.cpp +++ b/src/nexusinterface.cpp @@ -22,8 +22,10 @@ along with Mod Organizer. If not, see . #include "utility.h" #include "json.h" #include "selectiondialog.h" +#include #include #include +#include using QtJson::Json; @@ -148,6 +150,13 @@ NexusInterface::NexusInterface() m_DiskCache = new QNetworkDiskCache(this); connect(m_AccessManager, SIGNAL(requestNXMDownload(QString)), this, SLOT(downloadRequestedNXM(QString))); + + + VS_FIXEDFILEINFO version = GetFileVersion(ToWString(QApplication::applicationFilePath())); + + m_MOVersion = VersionInfo(version.dwFileVersionMS >> 16, + version.dwFileVersionMS & 0xFFFF, + version.dwFileVersionLS >> 16); } @@ -396,8 +405,10 @@ void NexusInterface::nextRequest() QNetworkRequest request(url); request.setHeader(QNetworkRequest::ContentTypeHeader, "application/xml"); -#pragma message("automatically insert the correct version number") - request.setRawHeader("User-Agent", QString("Mod Organizer v1.0.5 (compatible to Nexus Client v%1)").arg(m_NMMVersion).toUtf8()); + request.setRawHeader("User-Agent", + QString("Mod Organizer v%1 (compatible to Nexus Client v%2)") + .arg(m_MOVersion.displayString()) + .arg(m_NMMVersion).toUtf8()); info.m_Reply = m_AccessManager->get(request); diff --git a/src/nexusinterface.h b/src/nexusinterface.h index 0b53f9d0..03226d8e 100644 --- a/src/nexusinterface.h +++ b/src/nexusinterface.h @@ -307,6 +307,7 @@ private: std::list m_ActiveRequest; QQueue m_RequestQueue; + MOBase::VersionInfo m_MOVersion; QString m_NMMVersion; }; diff --git a/src/organizer_ru.qm b/src/organizer_ru.qm index 1bae65a6..5921c2dc 100644 Binary files a/src/organizer_ru.qm and b/src/organizer_ru.qm differ diff --git a/src/organizer_ru.ts b/src/organizer_ru.ts index 2204198c..9b7b8101 100644 --- a/src/organizer_ru.ts +++ b/src/organizer_ru.ts @@ -1,4 +1,3 @@ - @@ -11,26 +10,26 @@ This is a list of esps and esms that were active when the save game was created. - Это список ESP и ESM, которые были активны во время создания сейва. + Это список esp и esm, которые были активны во время создания сохранения. - <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> -<html><head><meta name="qrichtext" content="1" /><style type="text/css"> + <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> +<html><head><meta name="qrichtext" content="1" /><style type="text/css"> p, li { white-space: pre-wrap; } -</style></head><body style=" font-family:'MS Shell Dlg 2'; font-size:8.25pt; font-weight:400; font-style:normal;"> -<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">This is a list of esps and esms that were active when the save game was created.</span></p> -<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">For each esp, the right column contains the mod (or mods) that can be enabled to make the missing esps/esms available.</span></p> -<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"></p> -<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">If you hit Ok, all the mods selected in the right columns and all missing esps that have become available will be activated.</span></p></body></html> - <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> -<html><head><meta name="qrichtext" content="1" /><style type="text/css"> +</style></head><body style=" font-family:'MS Shell Dlg 2'; font-size:8.25pt; font-weight:400; font-style:normal;"> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">This is a list of esps and esms that were active when the save game was created.</span></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">For each esp, the right column contains the mod (or mods) that can be enabled to make the missing esps/esms available.</span></p> +<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">If you hit Ok, all the mods selected in the right columns and all missing esps that have become available will be activated.</span></p></body></html> + <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> +<html><head><meta name="qrichtext" content="1" /><style type="text/css"> p, li { white-space: pre-wrap; } -</style></head><body style=" font-family:'MS Shell Dlg 2'; font-size:8.25pt; font-weight:400; font-style:normal;"> -<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">Это список ESP и ESM, которые были активны, когда сейв был создан..</span></p> -<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">Для каждого ESP, правый столбец содержит мод (или моды), которые могут быть включены, чтобы неактивные ESP / ESM стали активными.</span></p> -<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"></p> -<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">Если вы нажмете ОК, все моды, выбранные в правой колонке будут активированы..</span></p></body></html> +</style></head><body style=" font-family:'MS Shell Dlg 2'; font-size:8.25pt; font-weight:400; font-style:normal;"> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">Это список ESP и ESM, которые были активны, когда сейв был создан..</span></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">Для каждого ESP, правый столбец содержит мод (или моды), которые могут быть включены, чтобы неактивные ESP / ESM стали активными.</span></p> +<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">Если вы нажмете ОК, все моды, выбранные в правой колонке будут активированы..</span></p></body></html> @@ -45,7 +44,7 @@ p, li { white-space: pre-wrap; } not found - Не найдено + не найдено @@ -73,8 +72,9 @@ p, li { white-space: pre-wrap; } Components of this package. -If there is a component called "00 Core" it is usually required. Options are ordered by priority as set up by the author. - Компоненты этого пакета.Если есть компонент который называется "00 Core", значит так надо. Параметры отсортированы по приоритетности созданной автором. +If there is a component called "00 Core" it is usually required. Options are ordered by priority as set up by the author. + Компоненты этого пакета. +Если есть компонент, называемый "00 Core", то это обычно необходимо. Опции упорядочены по приоритету, установленному автором. @@ -91,7 +91,7 @@ If there is a component called "00 Core" it is usually required. Optio Opens a Dialog that allows custom modifications. - Открывает диалоговое окно, которое позволяет выбрать пользовательские модификации. + Открывает диалог, позволяющий выбрать пользовательские модификации. @@ -101,7 +101,7 @@ If there is a component called "00 Core" it is usually required. Optio Ok - ОК + Ок @@ -129,7 +129,7 @@ If there is a component called "00 Core" it is usually required. Optio Internal ID for the category. The categories a mod belongs to are stored by this ID. It is recommended you use new IDs for categories you add instead of re-using existing ones. - Внутренний ID категории. Категории мода хранятся в истории под этим ID. Это рекомендуется использовать при создании новых ID для категорий, чтобы повторно использовать уже существующие. + Внутренний ID категории. Категории мода хранятся в истории под этим ID. Рекомендуется использовать новые ID для добавляемых вами категорий, вместо повторного использования существующих. @@ -154,20 +154,20 @@ If there is a component called "00 Core" it is usually required. Optio - <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> -<html><head><meta name="qrichtext" content="1" /><style type="text/css"> + <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> +<html><head><meta name="qrichtext" content="1" /><style type="text/css"> p, li { white-space: pre-wrap; } -</style></head><body style=" font-family:'MS Shell Dlg 2'; font-size:8.25pt; font-weight:400; font-style:normal;"> -<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">You can match one or multiple nexus categories to a internal ID. Whenever you download a mod from a Nexus Page, Mod Organizer will try to resolve the category defined on the Nexus to one available in MO.</span></p> -<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:8pt;"></p> -<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">To find out a category id used by the nexus, visit the categories list of the nexus page and hover over the links there.</span></p></body></html> - <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> -<html><head><meta name="qrichtext" content="1" /><style type="text/css"> +</style></head><body style=" font-family:'MS Shell Dlg 2'; font-size:8.25pt; font-weight:400; font-style:normal;"> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">You can match one or multiple nexus categories to a internal ID. Whenever you download a mod from a Nexus Page, Mod Organizer will try to resolve the category defined on the Nexus to one available in MO.</span></p> +<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:8pt;"></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">To find out a category id used by the nexus, visit the categories list of the nexus page and hover over the links there.</span></p></body></html> + <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> +<html><head><meta name="qrichtext" content="1" /><style type="text/css"> p, li { white-space: pre-wrap; } -</style></head><body style=" font-family:'MS Shell Dlg 2'; font-size:8.25pt; font-weight:400; font-style:normal;"> -<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">Вы можете задать соответствие с одной или нескольким категориям с внутренними ID. Каждый раз, когда вы загружаете мод со страницы Nexus, МО автоматически постарается задать соответствие, как на Nexus.</span></p> -<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:8pt;"></p> -<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">Чтобы узнать идентификатор категории используемого соответствия, посетите список категорий на странице Связь и наведите курсор мыши на нужную ссылку.</span></p></body></html> +</style></head><body style=" font-family:'MS Shell Dlg 2'; font-size:8.25pt; font-weight:400; font-style:normal;"> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">Вы можете задать одну или несколько категорий Nexus внутреннему ID. Каждый раз, когда вы загружаете мод со страницы Nexus, МО постарается автоматически задать моду категорию, присвоенную ему на Nexus.</span></p> +<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:8pt;"></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">Чтобы узнать ID категории, используемой на Nexus, перейдите в список категорий Nexus и наведите курсор мыши на нужную ссылку.</span></p></body></html> @@ -199,7 +199,7 @@ p, li { white-space: pre-wrap; } - This feature may not work unless you're logged in with Nexus + This feature may not work unless you're logged in with Nexus Эта функция может не работать, если вход выполнен с Nexus @@ -225,14 +225,10 @@ p, li { white-space: pre-wrap; } DirectoryRefresher - - failed to read %1: %2 - Не удалось прочитать %1: %2 - failed to read bsa: %1 - + не удалось прочитать bsa: %1 @@ -245,73 +241,63 @@ p, li { white-space: pre-wrap; } Filetime - Ждите + Дата модификации Done - Готово + Выполнено - Information missing, please select "Query Info" from the context menu to re-retrieve. - Информация отсутствует, пожалуйста, выберите пункт "Справочная информация" из контекстного меню. + Information missing, please select "Query Info" from the context menu to re-retrieve. + Информация отсутствует, пожалуйста, выберите пункт "Справочная информация" из контекстного меню. DownloadListWidget - + Placeholder Заполнитель - - 0 - - - - - KB - - - - + + - Done - Double Click to install Готово - двойной щелчок для установки. + - Paused - Double Click to resume - + Пауза - двойной клик для продолжения + - Installed - Double Click to re-install Установлено - двойной клик для переустановки + - Uninstalled - Double Click to re-install - + Удалено - двойной клик для переустановки DownloadListWidgetCompact - + Placeholder Заполнитель - + Done Готово @@ -319,120 +305,120 @@ p, li { white-space: pre-wrap; } DownloadListWidgetCompactDelegate - + + Paused + Приостановлено + + + + Fetching Info 1 + Извлечение информации 1 + + + + Fetching Info 2 + Извлечение информации 2 + + + Installed Установлено - + Uninstalled - + Удалено - + Done Готово - - - - + + + + Are you sure? Вы уверены? - + This will remove all finished downloads from this list and from disk. Это удалит все готовые загрузки из этого списка и с диска. - + This will remove all installed downloads from this list and from disk. Это удалит все установленные загрузки из этого списка и с диска. - + This will permanently remove all finished downloads from this list (but NOT from disk). - + Это полностью удалит все завершенные загрузки из этого списка (но НЕ с диска). - + This will permanently remove all installed downloads from this list (but NOT from disk). - + Это полностью удалит все установленные загрузки из этого списка (но НЕ с диска). - + Install Установка - + Query Info Справочная информация - + Delete - + Удалить - + Remove from View - - - - - Remove - Удаление + Скрыть от просмотра - + Cancel Отмена - - Paused - - - - - Fetching Info 1 - - - - - Fetching Info 2 - - - - + Pause Пауза - + + Remove + Удаление + + + Resume Возобновить - + Delete Installed... - + Удалить установленное... - + Delete All... - + Удалить все... - + Remove Installed... Отменить установку - + Remove All... Удалить все @@ -440,100 +426,100 @@ p, li { white-space: pre-wrap; } DownloadListWidgetDelegate - - - - + + Fetching Info 1 + Извлечение информации 1 + + + + Fetching Info 2 + Извлечение информации 2 + + + + + + Are you sure? Вы уверены? - + This will remove all finished downloads from this list and from disk. Это удалит все готовые загрузки из этого списка и с диска. - + This will remove all installed downloads from this list and from disk. Это удалит все установленные загрузки из этого листа и с диска. - + This will remove all finished downloads from this list (but NOT from disk). - + Это удалит все готовые загрузки из этого списка (но НЕ с диска). - + This will remove all installed downloads from this list (but NOT from disk). - + Это удалит все установленные загрузки из этого списка (но НЕ с диска). - + Install Установить - + Query Info Справочная информация - + Delete - + Удалить - + Remove from View - - - - - Remove - Удалить + Скрыть от просмотра - + Cancel Отмена - - Fetching Info 1 - - - - - Fetching Info 2 - + + Pause + Пауза - Pause - Пауза + Remove + Удалить - + Resume Возобновить - + Delete Installed... - + Удалить установленное... - + Delete All... - + Удалить все... - + Remove Installed... Удалить установленные - + Remove All... Удалить все @@ -541,109 +527,103 @@ p, li { white-space: pre-wrap; } DownloadManager - - failed to rename "%1" to "%2" - Не удалось переименовать "%1" в "%2" + + failed to rename "%1" to "%2" + не удалось переименовать "%1" в "%2" - + Download again? Скачать снова - + A file with the same name has already been downloaded. Do you want to download it again? The new file will receive a different name. Файл с таким именем загружен. Вы хотите загрузить его снова? У него будет другое имя. - + failed to download %1: could not open output file: %2 - Ошибка загрузки %1: не удалось открыть входящий файл: %2 - - - - - - - - - - - - - + не удалось загрузить %1: не удалось открыть выходной файл: %2 + + + + + + + + + + + + invalid index - Неверный индекс + неверный индекс - + failed to delete %1 - Не удалось удалить %1 + не удалось удалить %1 - + failed to delete meta file for %1 - Не удалось удалить мета файл %1 + не удалось удалить мета-файл %1 - - - - - - + + + + + invalid index %1 - Неверный индекс %1 + неверный индекс %1 - + Please enter the nexus mod id - Выберите ID мода с Nexus + Пожалуйста, введите ID мода на Nexus - + Mod ID: ID мода: - invalid alphabetical index %1 - Недействительный алфавитный указатель %1 - - - + Information updated Информация обновлена - - + + No matching file found on Nexus! Maybe this file is no longer available or it was renamed? Нет соответствующих модов на Nexus! Возможно фал был удален или переименован? - + No file on Nexus matches the selected file by name. Please manually choose the correct one. Нет соответствующих фалов на Nexus. Выберите файл вручную. - + No download server available. Please try again later. Сервер недоступен. Попробуйте позже. - + Failed to request file info from nexus: %1 Не удалось получить информацию о файле: %1 - + Download failed: %1 (%2) Загрузка не удалась: %1 (%2) - + failed to re-open %1 - Не удалось открыть %1 + не удалось повторно открыть %1 @@ -720,14 +700,16 @@ p, li { white-space: pre-wrap; } Allow the Steam AppID to be used for this executable to be changed. - Разрешить Steam AppID. Для использования исполняемый файл будет изменен. + Разрешить изменение Steam AppID, используемого для этого исполняемого файла. Allow the Steam AppID to be used for this executable to be changed. Every game/tool distributed through Steam has a unique ID. MO needs to know this ID to start those programs directly, otherwise the program is started by steam and then MO will not work. By default, MO will use the AppID for the game. Right now the only case I know of where this needs to be overwritten is for the Skyrim Creation Kit which has its own AppID. This overwrite is already preconfigured. - Разрешить Steam AppID, который будет использоваться для изменения исполняемого файла. Каждая игра\инструмент раcпространяется через Steam и имеет уникальный ID. MO необходимо знать этот ID, что бы активировать игру\инструмент, иначе придется запускать через Steam. По умолчанию MO будет использовать AppID для игры\инструмента.Возможны проблемы с ID создаваемыми в Skyrim Creation Kit. + Разрешить изменение Steam AppID, который будет использоваться для исполняемого файла. +Каждая игра/инструмент распространяемые через Steam имеют свой уникальный ID. MO необходимо знать этот ID для прямого запуска этих программ, иначе они будут запущены через Steam и MO работать не будет. По умолчанию MO будет использовать AppID для игры. +В данный момент единственный случай, где это должно быть перезаписано это Skyrim Creation Kit, который имеет свой собственный AppID. Эта замена уже предварительно сконфигурирована. @@ -744,7 +726,9 @@ Right now the only case I know of where this needs to be overwritten is for the Steam AppID to use for this executable that differs from the games AppID. Every game/tool distributed through Steam has a unique ID. MO needs to know this ID to start those programs directly, otherwise the program is started by steam and then MO will not work. By default, MO will use the AppID for the game (usually 72850). Right now the only case I know of where this needs to be overwritten is for the Skyrim Creation Kit which has its own AppID (usually 202480). This overwrite is already preconfigured. - Steam AppID, который будет использоваться для изменения исполняемого файла. Каждая игра\инструмент раcпространяется через Steam и имеет уникальный ID. MO необходимо знать этот ID, что бы активировать игру\инструмент, иначе придется запускать через Steam. По умолчанию MO будет использовать AppID для игры\инструмента.Возможны проблемы с ID создаваемыми в Skyrim Creation Kit. + Steam AppID, используемый для этого исполняемого файла, отличающийся от AppID других игр. +Каждая игра/инструмент распространяемые через Steam имеют свой уникальный ID. MO необходимо знать этот ID для прямого запуска этих программ, иначе они будут запущены через Steam и MO работать не будет. По умолчанию MO будет использовать AppID для игры (обычно 72850). +В данный момент единственный случай, где он должен быть перезаписан, это для Skyrim Creation Kit, который имеет свой собственный AppID (обычно 202480). Эта замена уже предварительно сконфигурирована. @@ -794,12 +778,12 @@ Right now the only case I know of where this needs to be overwritten is for the Java (32-bit) required - + Требуется Java (32-bit) MO requires 32-bit java to run this application. If you already have it installed, select javaw.exe from that installation as the binary. - + MO требует 32-bit java для запуска этого приложения. Если он у вас уже установлен, выберете javaw.exe для этой установки как исполняемый файл. @@ -813,8 +797,8 @@ Right now the only case I know of where this needs to be overwritten is for the - Really remove "%1" from executables? - Действительно удалить "%1" исполняемых? + Really remove "%1" from executables? + Действительно удалить "%1" исполняемых? @@ -843,7 +827,7 @@ Right now the only case I know of where this needs to be overwritten is for the Search term - Поиск терминала + Поиск термина @@ -893,8 +877,8 @@ Right now the only case I know of where this needs to be overwritten is for the - <a href="#">Link</a> - <a href="#">ссылка</a> + <a href="#">Link</a> + <a href="#">Ссылка</a> @@ -916,58 +900,6 @@ Right now the only case I know of where this needs to be overwritten is for the Cancel Отмена - - ModuleConfig.xml missing - ModuleConfig.xml отсутствует - - - failed to parse info.xml: %1 (%2) (line %3, column %4) - не удалось проанализировать info.xml: %1 (%2) (строка %3, столбец %4) - - - unsupported order type %1 - не поддерживаемый тип порядка %1 - - - unsupported group type %1 - не поддерживаемый тип группы %1 - - - This component is required - Этот компонент необходим - - - It is recommended you enable this component - Рекомендуется включить этот компонент - - - Optional component - Дополнительный компонент - - - This component is not usable in combination with other installed plugins - Этот компонент не может сочетаться с другими установленными плагинами. - - - You may be experiencing instability in combination with other installed plugins - Могут наблюдаться нестабильность в сочетании с другими установленными плагинами. - - - None - Ни один - - - Select one or more of these options: - Выберите один или несколько из следующих вариантов: - - - failed to parse ModuleConfig.xml: %1 - не удается проанализировать ModuleConfig.xml: %1 - - - Install - Установить - InstallDialog @@ -993,7 +925,7 @@ Right now the only case I know of where this needs to be overwritten is for the - Pick a name for the mod. This is also used as a directory name, so please don't use characters that are illegal in file names. + Pick a name for the mod. This is also used as a directory name, so please don't use characters that are illegal in file names. Выбери имя для мода. Это также используется в качестве имени каталога, поэтому, пожалуйста, не используйте символы, которые запрещены в именах файлов. @@ -1008,16 +940,16 @@ Right now the only case I know of where this needs to be overwritten is for the - <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> -<html><head><meta name="qrichtext" content="1" /><style type="text/css"> + <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> +<html><head><meta name="qrichtext" content="1" /><style type="text/css"> p, li { white-space: pre-wrap; } -</style></head><body style=" font-family:'MS Shell Dlg 2'; font-size:8.25pt; font-weight:400; font-style:normal;"> -<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">This displays the content of the archive. &lt;data&gt; represents the base directory which will map to the game's data directory. You can change the base directory via the right-click context menu and you can move around files via drag&amp;drop</span></p></body></html> - <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> -<html><head><meta name="qrichtext" content="1" /><style type="text/css"> +</style></head><body style=" font-family:'MS Shell Dlg 2'; font-size:8.25pt; font-weight:400; font-style:normal;"> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">This displays the content of the archive. &lt;data&gt; represents the base directory which will map to the game's data directory. You can change the base directory via the right-click context menu and you can move around files via drag&amp;drop</span></p></body></html> + <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> +<html><head><meta name="qrichtext" content="1" /><style type="text/css"> p, li { white-space: pre-wrap; } -</style></head><body style=" font-family:'MS Shell Dlg 2'; font-size:8.25pt; font-weight:400; font-style:normal;"> -<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">Это показывает содержимое архива. <data> представляет базовый каталог, в котором будут сопоставлены с данными каталога игры. Вы можете изменить базовый каталог с помощью правой кнопкой мыши через контекстное меню, и можете перемещаться по файлам с помощью drag&drop.</span></p></body></html> +</style></head><body style=" font-family:'MS Shell Dlg 2'; font-size:8.25pt; font-weight:400; font-style:normal;"> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">Отображает содержимое архива. &lt;data&gt; представляет базовый каталог, данные в котором будут сопоставлены с данными каталога игры. Вы можете изменить базовый каталог нажатием правой кнопки мыши, через контекстное меню, а также можете перемещаться по файлам с помощью drag&amp;drop</span></p></body></html> @@ -1027,59 +959,20 @@ p, li { white-space: pre-wrap; } OK - + OK Cancel Отмена - - Looks good - Выглядит хорошо - - - No problem detected - Проблем не обнаружено - - - No game data on top level - Нет данных игры уровнем выше - - - There is no esp/esm file or asset directory (textures, meshes, interface, ...) on the top level. - Существующий ESP / ESM файла или каталога не имеет текстуры textures, meshes, interface, ... уровнем выше. - - - Enter a directory name - Введите имя каталога - - - A directory with that name exists - Каталог с таким именем не существует - - - Set data directory - Набор данных каталога - - - Unset data directory - Отключенный каталог данных - - - Create directory... - Создать директорию... - - - &Open - &Открыть - InstallationManager - mo_archive.dll not loaded: "%1" - mo_archive.dll не загружен: "%1" + + archive.dll not loaded: "%1" + archive.dll не загружен: "%1" @@ -1092,158 +985,91 @@ p, li { white-space: pre-wrap; } Пароль - Directory exists - Каталог существует - - - This mod seems to be installed already. Do you want to add files from this archive (overwriting existing ones) or do you want to completely replace the existing files (old files are deleted)? - Этот мод, кажется, уже установлен. Вы хотите перезаписать существующие или вы хотите полностью заменить существующие файлы (старые файлы удаляются)? - - - Add Files - Добавить файлы - - - Replace - Заменить - - - - - + + + Extracting files Извлечение файлов - Preparing installer - Подготовка к установке - - - Installation as fomod failed: %1 - Установка в fomod не удалась: %1 - - - failed to start %1 - Не удалось начать %1 - - - Running external installer. -Note: This installer will not be aware of other installed mods! - Запуск внешней установки. -Внимание: Других запущенных программ установки не должно быть! - - - Force Close - Закрыть принудительно - - - Confirm - Подтвердить - - - installation failed (errorcode %1) - Установка не удалась (errorcode %1) - - - - File format "%1" not supported - Формат файла "%1" не поддерживается - - - failed to open archive "%1": %2 - Не удалось открыть архив "%1": %2 - - - - archive.dll not loaded: "%1" - - - - + failed to create backup - + не удалось создать резервную копию - + Mod Name - + Имя мода - + Name Имя - + Invalid name - + Недопустимое имя - + The name you entered is invalid, please enter a different one. - - - - Installer missing - Установщик отсутствует - - - This package contains a scripted installer. To use this installer you need the optional "NCC"-package and the .net runtime. Do you want to continue, treating this as a manual installer? - Этот пакет содержит сценарии установки. Для использования этой установки необходимо дополнительно «NCC» пакет и .net runtime. Вы хотите использовать это в качестве установки? + Введенное вами имя недопустимо, пожалуйста введите другое. - Please install NCC - Установите NCC + + File format "%1" not supported + Формат файла "%1" не поддерживается - + None of the available installer plugins were able to handle that archive - + Не один из доступных плагинов-установщиков не смог просмотреть этот архив - + no error - Ошибки отсутствуют + ошибки отсутствуют - + 7z.dll not found 7z.dll не найден - - 7z.dll isn't valid + + 7z.dll isn't valid 7z.dll поврежден - + archive not found - Архив не найден + архив не найден - + failed to open archive - Ошибка открытия архива + не удалось открыть архив - + unsupported archive type - Не поддерживаемый тип архива + не поддерживаемый тип архива - + internal library error - Внутренняя ошибка библиотеки + внутренняя ошибка библиотеки - + archive invalid - Архив поврежден + архив поврежден - + unknown archive error - Неизвестная ошибка архива + неизвестная ошибка архива @@ -1255,8 +1081,8 @@ Note: This installer will not be aware of other installed mods! - This dialog should disappear automatically if the application/game is done. Click unlock if it didn't. - Это окно должно закрыться автоматически если игра запущена. Нажмите кнопку "Разблокировать" если этого не произошло. + This dialog should disappear automatically if the application/game is done. Click unlock if it didn't. + Этот диалог должен закрыться автоматически если игра/приложение запущены. Нажмите разблокировать, если этого не произошло. @@ -1274,7 +1100,7 @@ Note: This installer will not be aware of other installed mods! failed to write log to %1: %2 - Не удалось произвести запись в журнал %1: %2 + не удалось произвести запись в журнал %1: %2 @@ -1282,12 +1108,12 @@ Note: This installer will not be aware of other installed mods! an error occured: %1 - + произошла ошибка: %1 an error occured - + произошла ошибка @@ -1301,148 +1127,169 @@ Note: This installer will not be aware of other installed mods! Profile - + Профиль Pick a module collection - + Выберете набор модулей - <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> -<html><head><meta name="qrichtext" content="1" /><style type="text/css"> + <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> +<html><head><meta name="qrichtext" content="1" /><style type="text/css"> p, li { white-space: pre-wrap; } -</style></head><body style=" font-family:'MS Shell Dlg 2'; font-size:8.25pt; font-weight:400; font-style:normal;"> -<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">Create profiles here. Each profile contains its own list of active mods and esps. This way you can quickly switch between setups for different play throughs.</span></p> -<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">Please note that right now your esp load order is not kept seperate for different profiles.</span></p></body></html> - +</style></head><body style=" font-family:'MS Shell Dlg 2'; font-size:8.25pt; font-weight:400; font-style:normal;"> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">Create profiles here. Each profile contains its own list of active mods and esps. This way you can quickly switch between setups for different play throughs.</span></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">Please note that right now your esp load order is not kept seperate for different profiles.</span></p></body></html> + <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> +<html><head><meta name="qrichtext" content="1" /><style type="text/css"> +p, li { white-space: pre-wrap; } +</style></head><body style=" font-family:'MS Shell Dlg 2'; font-size:8.25pt; font-weight:400; font-style:normal;"> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">Создать профили здесь. Каждый профиль включает свой собственный список активных модов и esp. Таким образом, вы можете быстро переключаться между установками для различных прохождений игры.</span></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">Обратите внимание, что порядок загрузки esp одинаков для всех профилей.</span></p></body></html> Refresh list - + Обновить список Refresh list. This is usually not necessary unless you modified data outside the program. - + Обновить список. Обычно в этом нет необходимости, пока вы не измените данные вне программы. List of available mods. - + Список доступных модов. - This is a list of installed mods. Use the checkboxes to activate/deactivate mods and drag & drop mods to change their "installation" orders. - + This is a list of installed mods. Use the checkboxes to activate/deactivate mods and drag & drop mods to change their "installation" orders. + Это список установленных модов. Используйте флажки, для включения/отключения модов и перетаскивание модов, для изменения их порядка установки. Filter - + Фильтр No groups - + Без группировки Nexus IDs - Nexus IDs + Nexus IDs - + Namefilter - + Фильтр по имени Pick a program to run. - + Выберете программу для запуска. - <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> -<html><head><meta name="qrichtext" content="1" /><style type="text/css"> + <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> +<html><head><meta name="qrichtext" content="1" /><style type="text/css"> p, li { white-space: pre-wrap; } -</style></head><body style=" font-family:'MS Shell Dlg 2'; font-size:8.25pt; font-weight:400; font-style:normal;"> -<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">Choose the program to run. Once you start using ModOrganizer, you should always run your game and tools from here or through shortcuts created here, otherwise mods installed through MO will not be visible.</span></p> -<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">You can add new Tools to this list, but I can't promise tools I haven't tested will work.</span></p></body></html> - +</style></head><body style=" font-family:'MS Shell Dlg 2'; font-size:8.25pt; font-weight:400; font-style:normal;"> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">Choose the program to run. Once you start using ModOrganizer, you should always run your game and tools from here or through shortcuts created here, otherwise mods installed through MO will not be visible.</span></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">You can add new Tools to this list, but I can't promise tools I haven't tested will work.</span></p></body></html> + <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> +<html><head><meta name="qrichtext" content="1" /><style type="text/css"> +p, li { white-space: pre-wrap; } +</style></head><body style=" font-family:'MS Shell Dlg 2'; font-size:8.25pt; font-weight:400; font-style:normal;"> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">Выберете программу для запуска. Как только вы начинаете использовать ModOrganizer, вы всегда должны запускать игры и инструменты из него или через созданные в нем ярлыки, в противном случае, установленные через MO моды отображаться не будут.</span></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">Вы можете добавить новые инструменты в этот список, но работоспособность их всех не гарантированна.</span></p></body></html> Run program - + Запустить программу - <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> -<html><head><meta name="qrichtext" content="1" /><style type="text/css"> + <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> +<html><head><meta name="qrichtext" content="1" /><style type="text/css"> +p, li { white-space: pre-wrap; } +</style></head><body style=" font-family:'MS Shell Dlg 2'; font-size:8.25pt; font-weight:400; font-style:normal;"> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">Run the selected program with ModOrganizer enabled.</span></p></body></html> + <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> +<html><head><meta name="qrichtext" content="1" /><style type="text/css"> p, li { white-space: pre-wrap; } -</style></head><body style=" font-family:'MS Shell Dlg 2'; font-size:8.25pt; font-weight:400; font-style:normal;"> -<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">Run the selected program with ModOrganizer enabled.</span></p></body></html> - +</style></head><body style=" font-family:'MS Shell Dlg 2'; font-size:8.25pt; font-weight:400; font-style:normal;"> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">Запустить выбранную программу с поддержкой ModOrganizer.</span></p></body></html> Run - + Запустить Create a shortcut in your start menu or on the desktop to the specified program - + Создать ярлык для выбранной программы, в меню Пуск или на рабочем столе. - <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> -<html><head><meta name="qrichtext" content="1" /><style type="text/css"> + <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> +<html><head><meta name="qrichtext" content="1" /><style type="text/css"> p, li { white-space: pre-wrap; } -</style></head><body style=" font-family:'MS Shell Dlg 2'; font-size:8.25pt; font-weight:400; font-style:normal;"> -<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">This creates a start menu shortcut that directly starts the selected program with the MO active.</span></p></body></html> - +</style></head><body style=" font-family:'MS Shell Dlg 2'; font-size:8.25pt; font-weight:400; font-style:normal;"> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">This creates a start menu shortcut that directly starts the selected program with the MO active.</span></p></body></html> + <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> +<html><head><meta name="qrichtext" content="1" /><style type="text/css"> +p, li { white-space: pre-wrap; } +</style></head><body style=" font-family:'MS Shell Dlg 2'; font-size:8.25pt; font-weight:400; font-style:normal;"> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">Создает ярлык в меню Пуск, который запускает выбранную программу с активным MO.</span></p></body></html> Shortcut - - - - Save - Сохранить + Ярлык List of available esp/esm files - + Список доступных esp/esm файлов - <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> -<html><head><meta name="qrichtext" content="1" /><style type="text/css"> + <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> +<html><head><meta name="qrichtext" content="1" /><style type="text/css"> p, li { white-space: pre-wrap; } -</style></head><body style=" font-family:'MS Shell Dlg 2'; font-size:8.25pt; font-weight:400; font-style:normal;"> -<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">This list contains the esps and esms contained in the active mods. These require their own load order. Use drag&amp;drop to modify this load order. Please note that MO will only save the load order for mods that are active/checked.<br />There is a great tool named &quot;BOSS&quot; to automatically sort these files.</span></p></body></html> - +</style></head><body style=" font-family:'MS Shell Dlg 2'; font-size:8.25pt; font-weight:400; font-style:normal;"> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">This list contains the esps and esms contained in the active mods. These require their own load order. Use drag&amp;drop to modify this load order. Please note that MO will only save the load order for mods that are active/checked.<br />There is a great tool named &quot;BOSS&quot; to automatically sort these files.</span></p></body></html> + <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> +<html><head><meta name="qrichtext" content="1" /><style type="text/css"> +p, li { white-space: pre-wrap; } +</style></head><body style=" font-family:'MS Shell Dlg 2'; font-size:8.25pt; font-weight:400; font-style:normal;"> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">Этот список содержит esp и esm файлы активных модов. Для них требуется определенный порядок загрузки. Используйте перетаскивание для изменения порядка загрузки. Обратите внимание, что MO сохранит порядок загрузки только для активными/проверенных модов.<br />Существует замечательная утилита, называющаяся &quot;BOSS&quot; , которая автоматически сортирует эти файлы.</span></p></body></html> List of available BS Archives. Archives not checked here are not managed by MO and ignore installation order. - + Список доступных BSA. Они не отмечены здесь, не управляются с помощью MO и игнорируют порядок установки. - BSA files are archives (comparable to .zip files) that contain data assets (meshes, textures, ...) to be used by the game. As such they "compete" with loose files in your data directory over which is loaded. + BSA files are archives (comparable to .zip files) that contain data assets (meshes, textures, ...) to be used by the game. As such they "compete" with loose files in your data directory over which is loaded. By default, BSAs that share their base name with an enabled ESP (i.e. plugin.esp and plugin.bsa) are automatically loaded and will have precedence over all loose files, the installation order you set up to the left is then ignored! BSAs checked here are loaded in such a way that your installation order is obeyed properly. - + BSA файлы - архивы (сопоставимы с файлами .zip) которые содержат используемые игрой данные (meshes, textures, ...). Как таковые они "конкурируют" с отдельными файлами в папке Data, поверх которых загружены. +По умолчанию, BSA, у которых имя совпадает с именем ESP (т.е. plugin.esp и plugin.bsa) будут автоматически загружены и будут иметь приоритет над всеми отдельными файлами и установленный вами слева порядок установки будет проигнорирован! + +BSA, отмеченные здесь, загружаются так, чтобы порядок установки соблюдался должным образом. @@ -1458,1030 +1305,1035 @@ BSAs checked here are loaded in such a way that your installation order is obeye - <html><head/><body><p>Marked Archives (<img src=":/MO/gui/resources/dialog-warning_16.png"/>) are still loaded on Skyrim but the <a href="http://forums.bethsoft.com/topic/1354395-update-bsas-and-you/"><span style=" text-decoration: underline; color:#0000ff;">regular file override</span></a> mechanism will apply: Loose files override BSAs, no matter the mod/plugin priority.</p></body></html> - + <html><head/><body><p>Marked Archives (<img src=":/MO/gui/resources/dialog-warning_16.png"/>) are still loaded on Skyrim but the <a href="http://forums.bethsoft.com/topic/1354395-update-bsas-and-you/"><span style=" text-decoration: underline; color:#0000ff;">regular file override</span></a> mechanism will apply: Loose files override BSAs, no matter the mod/plugin priority.</p></body></html> + <html><head/><body><p>Помеченые архивы (<img src=":/MO/gui/resources/dialog-warning_16.png"/>) все еще загружаются в Skyrim, но <a href="http://forums.bethsoft.com/topic/1354395-update-bsas-and-you/"><span style=" text-decoration: underline; color:#0000ff;">применяется обычный</span></a> механизм: Отдельные файлы перезаписывают BSAs, вне зависимости от приоритета мода/плагина.</p></body></html> Data - + Данные refresh data-directory overview - + обновить обзор каталога Data Refresh the overview. This may take a moment. - + Обновление обзора. Это может занять некоторое время. - - + + Refresh - + Обновить This is an overview of your data directory as visible to the game (and tools). - + Это обзор вашего каталога данных так, как он будет видим игре (и инструментам). Filter the above list so that only conflicts are displayed. - + Отфильтровать вышеприведенный список так, чтобы отображались только конфликты. Show only conflicts - + Показать только конфликты Saves - + Сохранения - <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> -<html><head><meta name="qrichtext" content="1" /><style type="text/css"> + <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> +<html><head><meta name="qrichtext" content="1" /><style type="text/css"> p, li { white-space: pre-wrap; } -</style></head><body style=" font-family:'MS Shell Dlg 2'; font-size:8.25pt; font-weight:400; font-style:normal;"> -<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">This is a list of all savegames for this game. Hover over a list entry to get detailed information about the save including a list of esps/esms that were used at the time this save was created but aren't active now.</span></p> -<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:8pt;"></p> -<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">If you click &quot;Fix Mods...&quot; in the context menu, MO will try to activate all mods and esps to fix those missing esps. It will not disable anything!</span></p></body></html> - +</style></head><body style=" font-family:'MS Shell Dlg 2'; font-size:8.25pt; font-weight:400; font-style:normal;"> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">This is a list of all savegames for this game. Hover over a list entry to get detailed information about the save including a list of esps/esms that were used at the time this save was created but aren't active now.</span></p> +<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:8pt;"></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">If you click &quot;Fix Mods...&quot; in the context menu, MO will try to activate all mods and esps to fix those missing esps. It will not disable anything!</span></p></body></html> + <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> +<html><head><meta name="qrichtext" content="1" /><style type="text/css"> +p, li { white-space: pre-wrap; } +</style></head><body style=" font-family:'MS Shell Dlg 2'; font-size:8.25pt; font-weight:400; font-style:normal;"> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">Список всех сохранений игры. Наведите указатель мыши на элемент списка, чтобы получить подробную информацию о сохранении, включающем список esp/esm, которые использовались во время создания сохранения, но не активны в настоящее время.</span></p> +<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:8pt;"></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">Если вы выберете в контекстном меню пункт &quot;Исправить моды...&quot;, MO попытается подключить все моды и esp, чтобы исправить эти отсутствующие esp. Это ничего не отключит!</span></p></body></html> Downloads - + Загрузки This is a list of mods you downloaded from Nexus. Double click one to install it. - + Список модов, загруженных с Nexus. Двойной клик для установки. - + Compact - + Упаковать - + Tool Bar - + Панель инструментов - + Install Mod - + Установить мод - + Install &Mod - + Установить &мод - + Install a new mod from an archive - + Установить новый мод из архива - + Ctrl+M - + Ctrl+M - + Profiles - + Профили - + &Profiles - + &Профили - + Configure Profiles - + Настройка профилей - + Ctrl+P - + Ctrl+P - + Executables - + Программы - + &Executables - + &Программы - + Configure the executables that can be started through Mod Organizer - + Настройка программ, которые могут быть запущены через Mod Organizer - + Ctrl+E - + Ctrl+E + - Tools - + Инструменты - + &Tools - + &Инструменты - + Ctrl+I - + Ctrl+I - + Settings - + Настройки - + &Settings - + &Настройки - + Configure settings and workarounds - + Настройка параметров и способов обхода - + Ctrl+S - + Ctrl+S - + Nexus - + Nexus - + Search nexus network for more mods - + Поиск дополнительных модов на Nexus - + Ctrl+N - + Ctrl+N - - + + Update - + Обновление - + Mod Organizer is up-to-date - + Mod Organizer обновлен - - + + No Problems - + Проблем не обнаружено - + This button will be highlighted if MO discovered potential problems in your setup and provide tips on how to fix them. !Work in progress! Right now this has very limited functionality - + Эта кнопка будет подсвечена, если MO обнарул возможные проблемы в вашей установке и имеются советы по их исправлению. + +!В разработке! +Прямо сейчас этот функционал сильно ограничен - - + + Help - + Справка - + Ctrl+H - + Ctrl+H - + Endorse MO - + Одобрить MO - - + + Endorse Mod Organizer - + Одобрить Mod Organizer - + Toolbar - + Панель инструментов - + Desktop - + Рабочий стол - + Start Menu - + Меню Пуск - + Problems - + Проблемы - + There are potential problems with your setup - + Есть возможные проблемы с вашей установкой - + Everything seems to be in order - + Кажется всё в порядке - + Help on UI - + Справка по интерфейсу - + Documentation Wiki - + Wiki-документация - + Report Issue - + Сообщить о проблеме - + Tutorials - + Уроки - - failed to save load order: %1 - + + failed to save archives order, do you have write access to "%1"? + не удалось сохранить порядок архивов, у вас имеется доступ на запись к "%1"? - - failed to save archives order, do you have write access to "%1"? - + + failed to save load order: %1 + не удалось сохранить порядок загрузки: %1 - + Name Имя - + Please enter a name for the new profile - + Введите имя нового профиля - + failed to create profile: %1 - + не удалось создать профиль: %1 - + Show tutorial? - + Показать урок? - - You are starting Mod Organizer for the first time. Do you want to show a tutorial of its basic features? If you choose no you can always start the tutorial from the "Help"-menu. - + + You are starting Mod Organizer for the first time. Do you want to show a tutorial of its basic features? If you choose no you can always start the tutorial from the "Help"-menu. + Вы запустили Mod Organizer впервые. Вы хотите просмотреть уроки по основным возможностям? В случае отказа вы всегда можете открыть уроки из меню "Помощь". - + Downloads in progress - + Загрузки в процессе - + There are still downloads in progress, do you really want to quit? - + Загрузки всё ещё в процессе, вы правда хотите выйти? - + failed to read savegame: %1 - + не удалось прочесть сохранение: %1 + + + + Plugin "%1" failed: %2 + Плагин "%1" не удалось: %2 - - Plugin "%1" failed: %2 - + + Plugin "%1" failed + Плагин "%1" не удалось - - Failed to start "%1" - + + failed to init plugin %1: %2 + не удалось инициализировать плагин %1: %2 + + + + Failed to start "%1" + Не удалось запустить "%1" - + Waiting - + Ожидание - - Please press OK once you're logged into steam. - + + Please press OK once you're logged into steam. + Нажмите OK как только вы войдете в Steam. - - "%1" not found - + + "%1" not found + "%1" не найден - + Start Steam? - + Запустить Steam? - + Steam is required to be running already to correctly start the game. Should MO try to start steam now? - + Требуется запущенный Steam, для корректного запуска игры. Должен ли MO попытаться запустить Steam сейчас? - + Also in: <br> - + Также в: <br> - + No conflict - + Конфликтов нет - + <Edit...> - + <Правка...> - + This bsa is enabled in the ini file so it may be required! - + Этот bsa подключен через ini, так что он может быть необходим! - + This archive will still be loaded since there is a plugin of the same name but its files will not follow installation order! - + Этот архив все равно будет загружен, так как есть плагин с одноименным названием, но его файлы не будут следовать порядку установки! - + Activating Network Proxy - + Подключение сетевого прокси - - + + Installation successful - + Установка завершена - - + + Configure Mod - + Настройка мода - - + + This mod contains ini tweaks. Do you want to configure them now? - + Этот мод включает настройки ini. Вы хотите настроить их сейчас? - - - mod "%1" not found - + + + mod "%1" not found + мод "%1" не найден - - + + Installation cancelled - + Установка отменена - - + + The mod was not installed completely. - + Мод не был установлен полностью. - + Some plugins could not be loaded - + Некоторые плагины не могут быть загружены - + The following Plugins could not be loaded. The reason may be missing dependencies (i.e. python) or an outdated version:<ul> - + Следующие плагины не могут быть загружены. Причина может быть в отсутствующих зависимостях (таких как python) или в устаревшей версии:<ul> - + Choose Mod - + Выберете мод - + Mod Archive - + Архив мода - + Start Tutorial? - + Начать обучение? - - You're about to start a tutorial. For technical reasons it's not possible to end the tutorial early. Continue? - + + You're about to start a tutorial. For technical reasons it's not possible to end the tutorial early. Continue? + Вы собираетесь открыть обучение. По техническим причинам будет невозможно досрочно закончить обучение. Продолжить? - - + + Download started - + Загрузка начата - + failed to update mod list: %1 - + не удалось обновить список модов: %1 - + failed to spawn notepad.exe: %1 - + не удалось вызвать notepad.exe: %1 - + failed to open %1 - + не удалось открыть %1 - + failed to change origin name: %1 - - - - - Multiple esps activated, please check that they don't conflict. - + не удалось изменить оригинальное имя: %1 - - - Create Mod... - - - - - This will move all files from overwrite into a new, regular mod. -Please enter a name: - - - - - A mod with this name already exists - - - - - <All> - - - - + <Checked> - - - - - Plugin "%1" failed - + <Подключен> - - failed to init plugin %1: %2 - - - - - - Description missing - - - - + <Unchecked> - + <Отключен> - + <Update> - + <Обновлен> - + <No category> - + <Без категории> - + <Conflicted> - + <Конфликтует> - + failed to rename mod: %1 - + не удалось переименовать мод: %1 - + Overwrite? - + Перезаписать? - - This will replace the existing mod "%1". Continue? - + + This will replace the existing mod "%1". Continue? + Это заменит существующий мод "%1". Продолжить? - - failed to remove mod "%1" - + + failed to remove mod "%1" + не удалось удалить мод "%1" - - - - failed to rename "%1" to "%2" - Не удалось переименовать "%1" в "%2" + + + + failed to rename "%1" to "%2" + не удалось переименовать "%1" в "%2" - - - + + Multiple esps activated, please check that they don't conflict. + Подключено несколько esp, выберете из них не конфликтующие. + + + + + Confirm - Подтвердить + Подтверждение - + Remove the following mods?<br><ul>%1</ul> - + Удалить следующие моды?<br><ul>%1</ul> - + failed to remove mod: %1 - + не удалось удалить мод: %1 - - + + Failed - + Неудача - + Installation file no longer exists - + Установочный файл больше не существует - - Mods installed with old versions of MO can't be reinstalled in this way. - + + Mods installed with old versions of MO can't be reinstalled in this way. + Моды, установленные с использованием старых версий MO не могут быть перестановленны таким образом. - - + + You need to be logged in with Nexus to endorse - + Вы должны быть авторизированы на Nexus, чтобы одобрять. - - + + Extract BSA - + Извлечь BSA - + This mod contains at least one BSA. Do you want to unpack it? -(This removes the BSA after completion. If you don't know about BSAs, just select no) - +(This removes the BSA after completion. If you don't know about BSAs, just select no) + Этот мод включает как минимум один BSA. Вы хотите распаковать их? +(Это удалит BSA после завершения. Если вы не знаете ничего о BSAs, просто откажитесь) - - - + + + failed to read %1: %2 - Не удалось прочитать %1: %2 + не удалось прочесть %1: %2 - - + + This archive contains invalid hashes. Some files may be broken. - + Архив содержит неверные хеши. Некоторые файлы могут быть испорчены. - + Nexus ID for this Mod is unknown - + Nexus ID для этого мода неизвестен + + + + + Create Mod... + Создать мод... + + + + This will move all files from overwrite into a new, regular mod. +Please enter a name: + Это переместит все файлы от перезаписи в новый, отдельный мод. +Пожалуйста, введите имя: + + + + A mod with this name already exists + Мод с таким именем уже существует - + Really enable all visible mods? - + Действительно подключить все видимые моды? - + Really disable all visible mods? - + Действительно отключить все видимые моды? - + Choose what to export - + Выберете, что экспортировать - + Everything - + Всё - + All installed mods are included in the list - + Все установленные моды, включенные в список - + Active Mods - + Активные моды - + Only active (checked) mods from your current profile are included - + Включены все активные (подключенные) моды вашего текущего профиля - + Visible - + Видимые - + All mods visible in the mod list are included - + Включены все моды, видимые в списке модов - + export failed: %1 - + экспорт не удался: %1 - + Install Mod... - + Установить мод... - + Enable all visible - + Включить все видимые - + Disable all visible - + Отключить все видимые - + Check all for update - + Проверить все на обновления - + Export to csv... - + Экспорт в csv... - + Sync to Mods... - + Синхронизировать с модами... - + Restore Backup - + Восстановить из резервной копии - + Remove Backup... - + Удалить резервную копию... - + Set Category - + Задать категорию - + Primary Category - + Основная категория - + Rename Mod... - + Переименовать мод... - + Remove Mod... - + Удалить мод... - + Reinstall Mod - + Переустановить мод - + Un-Endorse - + Отменить одобрение - - + + Endorse - + Одобрить - - Won't endorse - + + Won't endorse + Не одобрять - + Endorsement state unknown - + Статус одобрения неизвестен - + Ignore missing data - + Игнорировать отсутствующие данные - + Visit on Nexus - + Перейти на Nexus - + Open in explorer - + Открыть в проводнике - + Information... - + Информация... - - + + Exception: - + Исключение: - - + + Unknown exception - + Неизвестное исключение - + + <All> + <Все> + + + <Multiple> - + <Несколько> - + Fix Mods... - + Исправить моды... - - + + failed to remove %1 - + не удалось удалить %1 - - + + failed to create %1 - + не удалось создать %1 - - Can't change download directory while downloads are in progress! - + + Can't change download directory while downloads are in progress! + Нельзя изменить каталог для загрузок, когда загрузки ещё не завершены! - + Download failed - + Загрузка не удалась - + failed to write to file %1 - + ошибка записи в файл %1 - + %1 written - + %1 записан - + Select binary - + Выбрать исполняемый файл - + Binary - Двоичный + Исполняемый файл - + Enter Name - + Введите имя - + Please enter a name for the executable - + Введите название для программы - + Not an executable - + Не является исполняемым - + This is not a recognized executable. - + Это неверный исполняемый файл. - - + + Replace file? - + Заменить файл? - + There already is a hidden version of this file. Replace it? - + Уже существует скрытая версия этого файла. Заменить? - - + + File operation failed - + Операция с файлом не удалась - - - Failed to remove "%1". Maybe you lack the required file permissions? - + + + Failed to remove "%1". Maybe you lack the required file permissions? + Не удалось удалить "%1". Может быть, вам не хватает необходимых прав доступа к файлу? - + There already is a visible version of this file. Replace it? - + Видимая версия этого файла уже существует. Заменить? - + Update available - + Доступно обновление - + Open/Execute - + Открыть/Выполнить - + Add as Executable - + Добавить как исполняемый - + Un-Hide - + Показать - + Hide - + Скрыть - + Write To File... - + Записать в файл... - + Do you want to endorse Mod Organizer on %1 now? - + Вы хотите одобрить Mod Organizer на %1 сейчас? - - Unlock load order - - - - - Lock load order - - - - + Request to Nexus failed: %1 - + Запрос на Nexus не удался: %1 - - + + login successful - + успешный вход - + login failed: %1. Trying to download anyway - + вход не удался: %1. Пытаюсь загрузить всё равно - + login failed: %1 - + войти не удалось: %1 - + login failed: %1. You need to log-in with Nexus to update MO. - + войти не удалось: %1. Вам нужно войти на Nexus, чтобы обновить MO. - + Error - + Ошибка - + failed to extract %1 (errorcode %2) - + не удалось извлечь %1 (код ошибки %2) - + Extract... - + Распаковка... - + Edit Categories... - + Изменить категории... - + Enable all - + Включить все - + Disable all - + Отключить все + + + + Unlock load order + Разблокировать порядок загрузки + + + + Lock load order + Заблокировать порядок загрузки @@ -2492,10 +2344,6 @@ Please enter a name: Placeholder Заполнитель - - Please install NCC - Установите NCC - ModInfo @@ -2503,11 +2351,7 @@ Please enter a name: invalid index %1 - Неверный индекс %1 - - - invalid mod id %1 - неверный ID мода %1 + неверный индекс %1 @@ -2515,7 +2359,7 @@ Please enter a name: This is the backup of a mod - + Это резервная копия мода @@ -2538,7 +2382,7 @@ Please enter a name: A list of text-files in the mod directory like readmes. - Список текстовых файлов в каталоге мода, ознакомительных. + Список текстовых файлов в каталоге мода, таких как ридми. @@ -2554,7 +2398,7 @@ Please enter a name: This is a list of .ini files in the mod. - Это список INI - фалов мода. + Это список .ini-файлов мода. @@ -2583,16 +2427,16 @@ Please enter a name: - <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> -<html><head><meta name="qrichtext" content="1" /><style type="text/css"> + <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> +<html><head><meta name="qrichtext" content="1" /><style type="text/css"> p, li { white-space: pre-wrap; } -</style></head><body style=" font-family:'MS Shell Dlg 2'; font-size:8.25pt; font-weight:400; font-style:normal;"> -<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">This lists all the images (.jpg and .png) in the mod directory, like screenshots and such. Click one to get a larger view.</span></p></body></html> - <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> -<html><head><meta name="qrichtext" content="1" /><style type="text/css"> +</style></head><body style=" font-family:'MS Shell Dlg 2'; font-size:8.25pt; font-weight:400; font-style:normal;"> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">This lists all the images (.jpg and .png) in the mod directory, like screenshots and such. Click one to get a larger view.</span></p></body></html> + <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> +<html><head><meta name="qrichtext" content="1" /><style type="text/css"> p, li { white-space: pre-wrap; } -</style></head><body style=" font-family:'MS Shell Dlg 2'; font-size:8.25pt; font-weight:400; font-style:normal;"> -<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">Это список всех изображений (. JPG и. PNG) в каталоге мода, такие как скриншоты и т.п. Нажмите на один из них, что бы увеличить.</span></p></body></html> +</style></head><body style=" font-family:'MS Shell Dlg 2'; font-size:8.25pt; font-weight:400; font-style:normal;"> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">Это список всех изображений (.jpg и .png) в каталоге мода, таких как скриншоты и т.п. Нажмите на любое, для увеличения.</span></p></body></html> @@ -2603,26 +2447,26 @@ p, li { white-space: pre-wrap; } List of esps and esms that can not be loaded by the game. - Список ESP и ESM которые не могут быть включены в игру. + Список esp и esm, которые не могут быть загружены игрой. - <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> -<html><head><meta name="qrichtext" content="1" /><style type="text/css"> + <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> +<html><head><meta name="qrichtext" content="1" /><style type="text/css"> p, li { white-space: pre-wrap; } -</style></head><body style=" font-family:'MS Shell Dlg 2'; font-size:8.25pt; font-weight:400; font-style:normal;"> -<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">List of esps and esms contained in this plugin that currently can not be loaded by the game. They will not even appear in the esp-list in the main MO-window.</span></p> -<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">They usually contain optional functionality, see the readme.</span></p> -<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:8pt;"></p> -<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">Most mods do not have optional esps, so chances are good you are looking at an empty list.</span></p></body></html> - <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> -<html><head><meta name="qrichtext" content="1" /><style type="text/css"> +</style></head><body style=" font-family:'MS Shell Dlg 2'; font-size:8.25pt; font-weight:400; font-style:normal;"> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">List of esps and esms contained in this plugin that currently can not be loaded by the game. They will not even appear in the esp-list in the main MO-window.</span></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">They usually contain optional functionality, see the readme.</span></p> +<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:8pt;"></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">Most mods do not have optional esps, so chances are good you are looking at an empty list.</span></p></body></html> + <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> +<html><head><meta name="qrichtext" content="1" /><style type="text/css"> p, li { white-space: pre-wrap; } -</style></head><body style=" font-family:'MS Shell Dlg 2'; font-size:8.25pt; font-weight:400; font-style:normal;"> -<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">Список ESP и ESM содержащие в паллагине, которые не могут быть включены в игру. они так же не будут отображены в списке ESP и ESM мода.</span></p> -<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">Они обычно содержат дополнительные функции. См. ReadME.</span></p> -<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:8pt;"></p> -<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">Большинство модов не имеют дополнительные ESP. Поэтому вы можете увидеть пустой список</span></p></body></html> +</style></head><body style=" font-family:'MS Shell Dlg 2'; font-size:8.25pt; font-weight:400; font-style:normal;"> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">Список esp и esm, содержащихся в плагине, которые не могут быть загружены в игру. Они так же не будут отображены в списке esp, в главном окне MO.</span></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">Они обычно содержат опциональный функционал, смотрите документацию.</span></p> +<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:8pt;"></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">Большинство модов не содержат дополнительных esp, поэтому вы можете увидеть пустой список</span></p></body></html> @@ -2631,8 +2475,8 @@ p, li { white-space: pre-wrap; } - The selected esp (in the lower list) will be pushed into a subdirectory of the mod and will thus become "invisible" to the game. It can then no longer be activated. - Выбранный ESP (в нижнем списке) будет перемещены в подкаталог мода и, таким образом, станут "невидимыми" для игры. Затем они больше не будут активированы. + The selected esp (in the lower list) will be pushed into a subdirectory of the mod and will thus become "invisible" to the game. It can then no longer be activated. + Выбранный ESP (в нижнем списке) будет перемещены в подкаталог мода и, таким образом, станут "невидимыми" для игры. Затем они больше не будут активированы. @@ -2641,8 +2485,8 @@ p, li { white-space: pre-wrap; } - This moves a esp to the esp directory so it can be enabled in the main window. Please note that the ESP merely becomes "available", it will not necessarily be loaded! That is configured in the main window of omo. - Перемещает ESP в каталог Data. Он может быть включен в главном окне. Обратите внимание, что ESP просто становится "доступным", это не обязательно будет включен! Это настраивается в главном окне OMO. + This moves a esp to the esp directory so it can be enabled in the main window. Please note that the ESP merely becomes "available", it will not necessarily be loaded! That is configured in the main window of omo. + Перемещает esp в каталог с другими esp так, что он может быть подключен в главном окне. Обратите внимание, что ESP просто становится "доступным", но не будет загружен! Это настраивается в главном окне MO. @@ -2652,7 +2496,7 @@ p, li { white-space: pre-wrap; } These are the mod files that are in the (virtual) data directory of your game and will thus be selecteable in the esp list in the main window. - Это моды который находятся в каталоге игры (виртуальном). Они могут быть включены в главном окне. + Это файлы модов которые находятся в (виртуальном)каталоге данных вашей игры и могут быть выбираемыми в списке esp, в главном окне. @@ -2703,7 +2547,7 @@ p, li { white-space: pre-wrap; } Primary Category - + Основная категория @@ -2722,29 +2566,29 @@ p, li { white-space: pre-wrap; } - <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> -<html><head><meta name="qrichtext" content="1" /><style type="text/css"> + <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> +<html><head><meta name="qrichtext" content="1" /><style type="text/css"> p, li { white-space: pre-wrap; } -</style></head><body style=" font-family:'MS Shell Dlg 2'; font-size:8.25pt; font-weight:400; font-style:normal;"> -<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">Mod ID for this mod on Nexus. This is filled in automatically if you downloaded and installed the mod from inside MO. Otherwise you can enter it manually. To find the correct id, find the mod on nexus. The URL will look like this: </span><a href=" http://www.skyrimnexus.com/downloads/file.php?id=1334"><span style=" font-size:8pt; text-decoration: underline; color:#0000ff;">http://skyrim.nexusmods.com/downloads/file.php?id=1334</span></a><a href="http://www.skyrimnexus.com/downloads/file.php?id=1334"><span style=" font-size:8pt; color:#000000;">. In this example, 1334 is the id you're looking for. Besides: The above is the link to Mod Organizer on the Nexus. Why not go there now and endorse?</span></a></p></body></html> - <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> -<html><head><meta name="qrichtext" content="1" /><style type="text/css"> +</style></head><body style=" font-family:'MS Shell Dlg 2'; font-size:8.25pt; font-weight:400; font-style:normal;"> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">Mod ID for this mod on Nexus. This is filled in automatically if you downloaded and installed the mod from inside MO. Otherwise you can enter it manually. To find the correct id, find the mod on nexus. The URL will look like this: </span><a href=" http://www.skyrimnexus.com/downloads/file.php?id=1334"><span style=" font-size:8pt; text-decoration: underline; color:#0000ff;">http://skyrim.nexusmods.com/downloads/file.php?id=1334</span></a><a href="http://www.skyrimnexus.com/downloads/file.php?id=1334"><span style=" font-size:8pt; color:#000000;">. In this example, 1334 is the id you're looking for. Besides: The above is the link to Mod Organizer on the Nexus. Why not go there now and endorse?</span></a></p></body></html> + <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> +<html><head><meta name="qrichtext" content="1" /><style type="text/css"> p, li { white-space: pre-wrap; } -</style></head><body style=" font-family:'MS Shell Dlg 2'; font-size:8.25pt; font-weight:400; font-style:normal;"> -<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">ID этого мода на Nexus. Заполняется автоматически, если скачали и установили мод МО. Иначе вы можете ввести его вручную. Чтобы найти правильный ID, нужно найти источник. URL будет выглядеть следующим образом: </span><a href=" http://www.skyrimnexus.com/downloads/file.php?id=1334"><span style=" font-size:8pt; text-decoration: underline; color:#0000ff;">http://skyrim.nexusmods.com/downloads/file.php?id=1334</span></a><a href="http://www.skyrimnexus.com/downloads/file.php?id=1334"><span style=" font-size:8pt; color:#000000;">. В этом примере, вы ищите ID 1334. Кроме того: выше есть ссылка на Mod Organizer на Nexus. Почему бы не пойти туда b yt ghjdthbnm?</span></a></p></body></html> +</style></head><body style=" font-family:'MS Shell Dlg 2'; font-size:8.25pt; font-weight:400; font-style:normal;"> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">ID этого мода на Nexus. Заполняется автоматически, если скачали и установили мод из МО. В противном случае вы можете ввести его вручную. Чтобы найти правильный ID, нужно найти мод на Nexus. URL будет выглядеть следующим образом: </span><a href=" http://www.skyrimnexus.com/downloads/file.php?id=1334"><span style=" font-size:8pt; text-decoration: underline; color:#0000ff;">http://skyrim.nexusmods.com/downloads/file.php?id=1334</span></a><a href="http://www.skyrimnexus.com/downloads/file.php?id=1334"><span style=" font-size:8pt; color:#000000;">. В этом примере, 1334 - ID, который вы ищете. Кроме того: Выше есть ссылка на Mod Organizer на Nexus. Почему бы не перейти по ней и не одобрить?</span></a></p></body></html> - <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> -<html><head><meta name="qrichtext" content="1" /><style type="text/css"> + <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> +<html><head><meta name="qrichtext" content="1" /><style type="text/css"> p, li { white-space: pre-wrap; } -</style></head><body style=" font-family:'MS Shell Dlg 2'; font-size:8.25pt; font-weight:400; font-style:normal;"> -<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">Installed Version of the Mod. The tooltip will contain the current version available on nexus. The installed version is only set if you installed the mod through MO.</span></p></body></html> - <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> -<html><head><meta name="qrichtext" content="1" /><style type="text/css"> +</style></head><body style=" font-family:'MS Shell Dlg 2'; font-size:8.25pt; font-weight:400; font-style:normal;"> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">Installed Version of the Mod. The tooltip will contain the current version available on nexus. The installed version is only set if you installed the mod through MO.</span></p></body></html> + <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> +<html><head><meta name="qrichtext" content="1" /><style type="text/css"> p, li { white-space: pre-wrap; } -</style></head><body style=" font-family:'MS Shell Dlg 2'; font-size:8.25pt; font-weight:400; font-style:normal;"> -<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">Установленная версия мода. В подсказке будет содержаться текущая версия ссылка. Установленная версия устанавливается только если вы установили мод через МО</span></p></body></html> +</style></head><body style=" font-family:'MS Shell Dlg 2'; font-size:8.25pt; font-weight:400; font-style:normal;"> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">Установленная версия мода. Подсказка будет содержать текущую версию, доступную на Nexus. Установленная версия установится только если вы установили мод через МО.</span></p></body></html> @@ -2754,12 +2598,12 @@ p, li { white-space: pre-wrap; } Refresh - + Обновить информацию Refresh all information from Nexus. - + Обновить всю информацию с Nexus @@ -2768,51 +2612,28 @@ p, li { white-space: pre-wrap; } - <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> -<html><head><meta name="qrichtext" content="1" /><style type="text/css"> + <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> +<html><head><meta name="qrichtext" content="1" /><style type="text/css"> p, li { white-space: pre-wrap; } -</style></head><body style=" font-family:'MS Shell Dlg 2'; font-size:8.25pt; font-weight:400; font-style:normal;"> -<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:8pt;"><br /></p> -<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:8pt;"><br /></p></body></html> - - - - Files - Файлы - - - List of files currently uploaded on nexus. Double click to download. - Список файлов загружаемых с Nexus. Двойной клик для загрузки - - - Type - Тип - - - Name - Имя - - - Size (kB) - Размер (KB) +</style></head><body style=" font-family:'MS Shell Dlg 2'; font-size:8.25pt; font-weight:400; font-style:normal;"> +<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:8pt;"><br /></p> +<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:8pt;"><br /></p></body></html> + <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> +<html><head><meta name="qrichtext" content="1" /><style type="text/css"> +p, li { white-space: pre-wrap; } +</style></head><body style=" font-family:'MS Shell Dlg 2'; font-size:8.25pt; font-weight:400; font-style:normal;"> +<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:8pt;"><br /></p> +<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:8pt;"><br /></p></body></html> Endorse - + Одобрить Notes - - - - Endorsements are an important motivation for authors. Please don't forget to endorse mods you like. - Не забудте поблагодарить автора. - - - Have you endorsed this yet? - Поблагодарить? + Примечания @@ -2826,23 +2647,28 @@ p, li { white-space: pre-wrap; } - <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> -<html><head><meta name="qrichtext" content="1" /><style type="text/css"> + <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> +<html><head><meta name="qrichtext" content="1" /><style type="text/css"> +p, li { white-space: pre-wrap; } +</style></head><body style=" font-family:'MS Shell Dlg 2'; font-size:8.25pt; font-weight:400; font-style:normal;"> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">This is a modifiable directory view of the mod directory. You can move around files using drag &amp; drop and rename them (double click).</span></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">Changes happen immediately on disc, so do</span><span style=" font-size:8pt; font-weight:600;"> be careful</span><span style=" font-size:8pt;">.</span></p></body></html> + <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> +<html><head><meta name="qrichtext" content="1" /><style type="text/css"> p, li { white-space: pre-wrap; } -</style></head><body style=" font-family:'MS Shell Dlg 2'; font-size:8.25pt; font-weight:400; font-style:normal;"> -<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">This is a modifiable directory view of the mod directory. You can move around files using drag &amp; drop and rename them (double click).</span></p> -<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">Changes happen immediately on disc, so do</span><span style=" font-size:8pt; font-weight:600;"> be careful</span><span style=" font-size:8pt;">.</span></p></body></html> - +</style></head><body style=" font-family:'MS Shell Dlg 2'; font-size:8.25pt; font-weight:400; font-style:normal;"> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">Это обзор модифицируемого каталога папки мода. Вы можете перемещать файлы, используя перетаскивание и переименовывать их двойным кликом.</span></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">Изменения происходят непосредственно на диске, так что</span><span style=" font-size:8pt; font-weight:600;"> будьте осторожныl</span><span style=" font-size:8pt;">.</span></p></body></html> Previous - + Предыдущий Next - Вперед + Вперед @@ -2852,22 +2678,22 @@ p, li { white-space: pre-wrap; } &Delete - + &Удалить &Rename - + &Переименовать &Hide - + &Скрыть &Unhide - + &Показать @@ -2877,184 +2703,184 @@ p, li { white-space: pre-wrap; } &New Folder - + &Новая папка Save changes? - + Сохранить изменения? + + + + + Save changes to "%1"? + Сохранить изменения в "%1"? File Exists - + Файл уже существует A file with that name exists, please enter a new one - + Файл с таким именем уже существует, укажите другое failed to move file - + не удалось переместить файл - failed to create directory "optional" - + failed to create directory "optional" + не удалось создать папку "optional" Info requested, please wait - - - - - (description incomplete, please visit nexus) - - - - - Current Version: %1 - - - - - No update available - + Информация запрошена, пожалуйста, подождите Main - - - - - - Save changes to "%1"? - + Главное Update - + Обновление Optional - + Опционально Old - + Старые Misc - + Разное Unknown - + Неизвестно - - <a href="%1">Visit on Nexus</a> - + + Current Version: %1 + Текущая версия: %1 - - - Confirm - Подтвердить + + No update available + Нет доступных обновлений + + + + (description incomplete, please visit nexus) + (описание не завершено, смотрите на nexus) + + + + <a href="%1">Visit on Nexus</a> + <a href="%1">Перейти на Nexus</a> Failed to delete %1 - + Не удалось удалить %1 - Are sure you want to delete "%1"? - + + Confirm + Подтверждение + + + + Are sure you want to delete "%1"? + Вы уверены, что хотите удалить "%1"? Are sure you want to delete the selected files? - + Вы уверены, что хотите удалить выбранные файлы? New Folder - + Новая папка - Failed to create "%1" - + Failed to create "%1" + Не удалось создать "%1" Replace file? - + Заменить файл? There already is a hidden version of this file. Replace it? - + Скрытая версия этого файла уже существует. Заменить? File operation failed - + Не удалась операция с файлом - Failed to remove "%1". Maybe you lack the required file permissions? - + Failed to remove "%1". Maybe you lack the required file permissions? + Не удалось удалить "%1". Может быть, вам не хватает необходимых прав доступа к файлу? failed to rename %1 to %2 - + не удалось переименовать %1 в %2 There already is a visible version of this file. Replace it? - + Видимая версия этого файла уже существует. Заменить? Un-Hide - + Показать Hide - + Скрыть ModInfoOverwrite - - - Overwrite - - This pseudo mod contains files from the virtual data tree that got modified (i.e. by the construction kit) - + Этот псевдо-мод содержит файлы из виртуального древа данных, которые были изменены (в Construction Kit и других программах) + + + + Overwrite + Замена @@ -3062,180 +2888,176 @@ p, li { white-space: pre-wrap; } failed to write %1/meta.ini: %2 - + не удалось записать %1/meta.ini: %2 %1 contains no esp/esm and no asset (textures, meshes, interface, ...) directory - + %1 не содержит ни esp/esm, ни папок ресурсов (textures, meshes, interface, ...) Categories: <br> - + Категории: <br> ModList - - - Confirm - Подтвердить - Overwrite - + Замена This entry contains files that have been created inside the virtual data tree (i.e. by the construction kit) - + Эта запись включает файлы, которые были созданы внутри виртуального древа (с помощью Construction Kit и др. программ) Backup - + Резервная копия No valid game data - + Неверные игровые данные Not endorsed yet - + Еще не одобрено Overwrites files - + Заменяет файлы Overwritten files - + Замененные файлы Overwrites & Overwritten - + Заменяет и заменяется Redundant - - - - - Category of the mod. - - - - - Id of the mod as used on Nexus. - - - - - Emblemes to highlight things that might require attention. - + Избыточные - - Categories: <br> - + + invalid + неверные installed version: %1, newest version: %2 - - - - Name - Имя - - - - Version - Версия - - - - Version of the mod (if available) - + установленная версия: %1, новейшая версия: %2 - - Priority - - - - - invalid - + + Categories: <br> + Категории: <br> Invalid name - + Недопустимое имя drag&drop failed: %1 - + перетаскивание не удалось: %1 + + + + Confirm + Подтверждение + + + + Are you sure you want to remove "%1"? + Вы действительно хотите удалить "%1"? Flags - + Флаги Mod Name - + Имя мода + + + + Version + Версия + + + + Priority + Приоритет Category - + Категория Nexus ID - + Nexus ID Installation - + Установка unknown - + неизвестный Name of your mods - + Имя ваших модов + + + + Version of the mod (if available) + Версия мода (если доступно) - Installation priority of your mod. The higher, the more "important" it is and thus overwrites files from mods with lower priority. - + Installation priority of your mod. The higher, the more "important" it is and thus overwrites files from mods with lower priority. + Приоритет установки для ваших модов. Файлы модов с большим приоритетом перезапишут файлы модов с меньшим приоритетом. - - Time this mod was installed - + + Category of the mod. + Категория мода. - - Are you sure you want to remove "%1"? - + + Id of the mod as used on Nexus. + ID мода, используемый на Nexus. + + + + Emblemes to highlight things that might require attention. + Выделяет подсветкой вещи, которые могут потребовать внимания. + + + + Time this mod was installed + Время, когда мод был установлен. @@ -3243,12 +3065,12 @@ p, li { white-space: pre-wrap; } Message of the Day - + Сообщение дня OK - + OK @@ -3256,12 +3078,12 @@ p, li { white-space: pre-wrap; } Overwrites - + Заменяет not implemented - + не реализовано @@ -3269,37 +3091,30 @@ p, li { white-space: pre-wrap; } timeout - + задержка Please check your password - - - - - NexusDialog - - Mod ID - ID мода + Проверьте ваш пароль NexusInterface - Failed to guess mod id for "%1", please pick the correct one - + Failed to guess mod id for "%1", please pick the correct one + Не удалось опознать id мода "%1", пожалуйста, выберете правильный empty response - + пустой ответ invalid response - + неверный ответ @@ -3307,22 +3122,22 @@ p, li { white-space: pre-wrap; } Overwrite - + Замена You can use drag&drop to move files and directories to regular mods. - + Вы можете использовать перетаскивание, для перемещения папок и файлов в распакованные моды. &Delete - + &Удалить &Rename - + &Переименовать @@ -3332,130 +3147,114 @@ p, li { white-space: pre-wrap; } &New Folder - + &Новая папка - Failed to delete "%1" - + Failed to delete "%1" + Не удалось удалить "%1" Confirm - Подтвердить + Подтверждение - Are sure you want to delete "%1"? - + Are sure you want to delete "%1"? + Вы уверены, что хотите удалить "%1"? Are sure you want to delete the selected files? - + Вы действительно хотите удалить выбранные файлы? New Folder - + Новая папка - Failed to create "%1" - + Failed to create "%1" + Не удалось создать "%1" PluginList - + + Name + Имя + + + + Priority + Приоритет + + + Mod Index - + Индекс мода - - + + unknown - + неизвестно - + Name of your mods - + Имена ваших модов - - Load priority of your mod. The higher, the more "important" it is and thus overwrites data from plugins with lower priority. - + + Load priority of your mod. The higher, the more "important" it is and thus overwrites data from plugins with lower priority. + Приоритет загрузки ваших модов. Моды с большим приоритетом перезапишут данные модов с меньшим приоритетом. - + The modindex determins the formids of objects originating from this mods. - + Индекс мода определяющий id форм объектов, происходящих из этих модов. - + esp not found: %1 - + esp не найден: %1 - - - Confirm - Подтвердить - - - - Really enable all plugins? - - - - - Really disable all plugins? - - - - + The file containing locked plugin indices is broken - + Файл, содержащий индексы заблокированного плагина, не работает. - + failed to open output file: %1 - + не удалось открыть выходной файл: %1 Some of your plugins have invalid names! These plugins can not be loaded by the game. Please see mo_interface.log for a list of affected plugins and rename them. - - - - - failed to restore load order for %1 - + Некоторые из ваших плагинов имеют неверные имена. Эти плагины не могут быть загружены игрой. Смотрите mo_interface.log для получения списка таких плагинов и переименуйте их. - This plugin can't be disabled (enforced by the game) - + This plugin can't be disabled (enforced by the game) + Этот плагин не может быть отключен (грузится игрой принудительно) Origin: %1 - + Источник: %1 - - Name - Имя - - - - Priority - + + failed to restore load order for %1 + не удалось восстановить порядок загрузки для %1 @@ -3463,31 +3262,35 @@ p, li { white-space: pre-wrap; } Problems - + Проблемы - <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> -<html><head><meta name="qrichtext" content="1" /><style type="text/css"> + <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> +<html><head><meta name="qrichtext" content="1" /><style type="text/css"> +p, li { white-space: pre-wrap; } +</style></head><body style=" font-family:'MS Shell Dlg 2'; font-size:7.8pt; font-weight:400; font-style:normal;"> +<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:8pt;"><br /></p></body></html> + <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> +<html><head><meta name="qrichtext" content="1" /><style type="text/css"> p, li { white-space: pre-wrap; } -</style></head><body style=" font-family:'MS Shell Dlg 2'; font-size:7.8pt; font-weight:400; font-style:normal;"> -<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:8pt;"><br /></p></body></html> - +</style></head><body style=" font-family:'MS Shell Dlg 2'; font-size:7.8pt; font-weight:400; font-style:normal;"> +<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:8pt;"><br /></p></body></html> fix - + исправить Fix - + Исправить No guided fix - + Не управляемое исправление @@ -3495,27 +3298,27 @@ p, li { white-space: pre-wrap; } invalid profile name %1 - + неверное имя профиля %1 failed to create %1 - + не удалось создать %1 - failed to open "%1" for writing - + failed to open "%1" for writing + не удалось открыть "%1" для записи failed to update tweaked ini file, wrong settings may be used: %1 - + не удалось обновить настроенный ini-файл, вероятно используются ошибочные настройки: %1 failed to create tweaked ini: %1 - + не удалось создать настроенный ini: %1 @@ -3524,43 +3327,43 @@ p, li { white-space: pre-wrap; } invalid index %1 - Неверный индекс %1 + неверный индекс %1 - Overwrite directory couldn't be parsed - + Overwrite directory couldn't be parsed + Замена каталога не может быть обработана invalid priority %1 - + неверный приоритет %1 failed to parse ini file (%1) - + не удалось обработать ini файл (%1) failed to parse ini file (%1): %2 - + не удалось обработать ini файл (%1): %2 - failed to modify "%1" - + failed to modify "%1" + не удалось изменить "%1" - + Delete savegames? - + Удалить сохранения? - - Do you want to delete local savegames? (If you select "No", the save games will show up again if you re-enable local savegames) - + + Do you want to delete local savegames? (If you select "No", the save games will show up again if you re-enable local savegames) + Вы хотите удалить локальные сохранения? (При отрицательном выборе сохранения отобразятся снова, если повторно включить локальные сохранения) @@ -3568,27 +3371,27 @@ p, li { white-space: pre-wrap; } Dialog - + Диалог Please enter a name for the new profile - + Введите имя нового профиля If checked, the new profile will use the default game settings. - + Если отмечено, новый профиль будет использовать настройки игры по умолчанию. - If checked, the new profile will use the default game settings instead of the "global" settings. Global settings are the settings you configure when running the game launcher directly, without MO. - + If checked, the new profile will use the default game settings instead of the "global" settings. Global settings are the settings you configure when running the game launcher directly, without MO. + Если отмечено, новый профиль будет использовать настройки игры по умолчанию, вместо общих настроек. Общие настройки, это настройки, которые вы установили, когда запустили лаунчер игры напрямую, без MO. Default Game Settings - + Настройки игры по умолчанию @@ -3596,109 +3399,122 @@ p, li { white-space: pre-wrap; } Profiles - + Профили List of Profiles - + Список профилей - <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> -<html><head><meta name="qrichtext" content="1" /><style type="text/css"> + <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> +<html><head><meta name="qrichtext" content="1" /><style type="text/css"> +p, li { white-space: pre-wrap; } +</style></head><body style=" font-family:'MS Shell Dlg 2'; font-size:8.25pt; font-weight:400; font-style:normal;"> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">This is the list of profiles. Each Profile contains its own list and installation order of enabled mods (from a shared pool), a configuration of enabled esps/esms, a copy of the games ini-file and an optional savegame filter.</p> +<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-weight:600;">Note</span> For technical reasons it's currently not possible to have seperate load-orders for esps. This means you can't load moda.esp before modb.esp in one profile and the other way around in another.</p></body></html> + <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> +<html><head><meta name="qrichtext" content="1" /><style type="text/css"> p, li { white-space: pre-wrap; } -</style></head><body style=" font-family:'MS Shell Dlg 2'; font-size:8.25pt; font-weight:400; font-style:normal;"> -<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">This is the list of profiles. Each Profile contains its own list and installation order of enabled mods (from a shared pool), a configuration of enabled esps/esms, a copy of the games ini-file and an optional savegame filter.</p> -<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"></p> -<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-weight:600;">Note</span> For technical reasons it's currently not possible to have seperate load-orders for esps. This means you can't load moda.esp before modb.esp in one profile and the other way around in another.</p></body></html> - +</style></head><body style=" font-family:'MS Shell Dlg 2'; font-size:8.25pt; font-weight:400; font-style:normal;"> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">Это список профилей. Каждый профиль содержит свой собственный список и порядок установки подключенных модов (из общего пула), настройки подключенных esps/esms, копии игровых ini-файлов и опциональный фильтр сохранений.</p> +<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-weight:600;">Примечание</span> По техническим причинам невозможно иметь отдельные порядки загрузки для esp. Это означает, что вы не сможете загрузить moda.esp пере modb.esp в одном профиле и иным образом в другом профиле.</p></body></html> If checked, savegames are local to this profile and will not appear when starting with a different profile. - + Если отмечено, сохранения будут локальными для этого профиля и не будут отображены для других профилей. Local Savegames - + Локальные сохранения This ensures data files from mods are actually used. You want to enable this unless you use a different tool for Archive Invalidation. - + Это гарантирует использование файлов данных из модов. Вам нужно включить это, если вы не используете других инструментов для инвалидации. - <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> -<html><head><meta name="qrichtext" content="1" /><style type="text/css"> + <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> +<html><head><meta name="qrichtext" content="1" /><style type="text/css"> +p, li { white-space: pre-wrap; } +</style></head><body style=" font-family:'MS Shell Dlg 2'; font-size:8.25pt; font-weight:400; font-style:normal;"> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">The games Oblivion, Fallout 3 and Fallout NV contain a bug which prevents texture and mesh replacers (that is: all modifications to meshes and textures already in game) from working.</span></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">The Mod Organizer uses a workaround called &quot;BSA redirection&quot; (google is your friend) to fix this issue reliably and without further work. Simply activate and forget.</span></p> +<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:8pt;"></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">With Skyrim this bug seems to be fixed to a degree but whether a mod becomes active still depends on file dates. Therefore, it still makes sense to activate this.</span></p></body></html> + <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> +<html><head><meta name="qrichtext" content="1" /><style type="text/css"> p, li { white-space: pre-wrap; } -</style></head><body style=" font-family:'MS Shell Dlg 2'; font-size:8.25pt; font-weight:400; font-style:normal;"> -<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">The games Oblivion, Fallout 3 and Fallout NV contain a bug which prevents texture and mesh replacers (that is: all modifications to meshes and textures already in game) from working.</span></p> -<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">The Mod Organizer uses a workaround called &quot;BSA redirection&quot; (google is your friend) to fix this issue reliably and without further work. Simply activate and forget.</span></p> -<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:8pt;"></p> -<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">With Skyrim this bug seems to be fixed to a degree but whether a mod becomes active still depends on file dates. Therefore, it still makes sense to activate this.</span></p></body></html> - +</style></head><body style=" font-family:'MS Shell Dlg 2'; font-size:8.25pt; font-weight:400; font-style:normal;"> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">Игры Oblivion, Fallout 3 и Fallout NV содержат баг, который делает неработоспособными текстуры и модели реплейсеров (то есть: все изменения моделей и текстур в игре).</span></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">Mod Organizer использует способ обхода, называемый &quot;BSA redirection&quot; (google в помощь), чтобы решить эту проблему надежно и без дальнейшей возни. Просто подключить и забыть.</span></p> +<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:8pt;"></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">В Скайрим, кажется, этот баг исправлен в известной степени, но будет ли мод активным, зависит по прежнему от даты модификации файлов. Поэтому всё ещё есть смысл включить это.</span></p></body></html> Automatic Archive Invalidation - + Автоматическая инвалидадция Create a new profile from scratch - + Создать новый профиль «с нуля» Create - + Создать Clone the selected profile - + Клонировать выбранный профиль This creates a new profile with the same settings and active mods as the selected one. - + Это создаст новый профиль с такими же настройками и активными модами, как у выбранного. Copy - + Копировать Delete the selected Profile. This can not be un-done! - + Удалить выбранный профиль. Это нельзя будет отменить! Remove - + Удалить Rename - + Переименовать Transfer save games to the selected profile. - + Передать сохранения в выбранный профиль. Transfer Saves - + Передать сохранения @@ -3707,14 +3523,14 @@ p, li { white-space: pre-wrap; } - Archive invalidation isn't required for this game. - + Archive invalidation isn't required for this game. + Инвалидация не требуется для этой игры. failed to create profile: %1 - + не удалось создать профиль: %1 @@ -3724,42 +3540,42 @@ p, li { white-space: pre-wrap; } Please enter a name for the new profile - + Введите имя нового профиля failed to copy profile: %1 - + не удалось скопировать профиль: %1 Confirm - Подтвердить + Подтверждение Are you sure you want to remove this profile? - + Вы действительно хотите удалить этот профиль? Rename Profile - + Переименовать профиль New Name - + Новое имя failed to change archive invalidation state: %1 - + не удалось изменить режим инвалидации: %1 failed to determine if invalidation is active: %1 - + не удалось определить активность инвалидации: %1 @@ -3767,7 +3583,7 @@ p, li { white-space: pre-wrap; } Failed to save custom categories - + Не удалось сохранить пользовательские категории @@ -3775,301 +3591,311 @@ p, li { white-space: pre-wrap; } invalid index %1 - Неверный индекс %1 + неверный индекс %1 invalid category id %1 - + неверный id категории %1 + + + + invalid field name "%1" + неверное имя поля "%1" + + + + invalid type for "%1" (should be integer) + неверный тип для "%1" (должно быть целое) + + + + invalid type for "%1" (should be string) + неверный тип для "%1" (должна быть строка) + + + + invalid type for "%1" (should be float) + неверный тип для "%1" (должно быть с плавающей запятой) + + + + no fields set up yet! + установленных полей ещё нет! + + + + field not set "%1" + поле не установлено "%1" + + + + invalid character in field "%1" + неверный символ в поле "%1" + + + + empty field name + пустое имя поля + + + + invalid game type %1 + неверный тип игры %1 helper failed - + сбой помощника failed to determine account name - + не удалось определить имя аккаунта invalid 7-zip32.dll: %1 - + неверный 7-zip32.dll: %1 failed to open %1: %2 - + не удалось открыть %1: %2 %1 not found - + %1 не найден Failed to delete %1 - + Не удалось удалить %1 Failed to deactivate script extender loading - + Не удалось отключить загрузку расширителя скриптов Failed to remove %1: %2 - + Не удалось удалить %1: %2 Failed to rename %1 to %2 - + Не удалось переименовать %1 в %2 Failed to deactivate proxy-dll loading - + Не удалось отключить загрузку proxy-dll Failed to copy %1 to %2 - + Не удалось скопировать %1 в %2 Failed to set up script extender loading - + Не удалось установить загрузку расширителя скриптов Failed to delete old proxy-dll %1 - + Не удалось удалить старый proxy-dll %1 Failed to overwrite %1 - + Не удалось заменить %1 Failed to set up proxy-dll loading - - - - - "%1" is missing - + Не удалось установить загрузку proxy-dll Permissions required - + Требуются права доступа + + + + The current user account doesn't have the required access rights to run Mod Organizer. The neccessary changes can be made automatically (the MO directory will be made writable for the current user account). You will be asked to run "helper.exe" with administrative rights). + Текущий аккаунт пользователя не имеет необходимых прав для запуска Mod Organizer. Необходимые изменения могут быть сделаны автоматически (каталог MO будет установлен записываемым для текущего аккаунта пользователя). Вам будет предложено запустить "helper.exe" с правами администратора. Woops - - - - - The current user account doesn't have the required access rights to run Mod Organizer. The neccessary changes can be made automatically (the MO directory will be made writable for the current user account). You will be asked to run "helper.exe" with administrative rights). - + Упс ModOrganizer has crashed! Should a diagnostic file be created? If you send me this file (%1) to sherb@gmx.net, the bug is a lot more likely to be fixed. Please include a short description of what you were doing when the crash happened - + Mod Organizer вышел из строя! Нужно ли создать диагностический файл? Если вы вышлите файл (%1) по адресу sherb@gmx.net, ошибка с намного большей вероятностью будет исправлена. Пожалуйста, добавьте краткое описание своих действий, перед тем, как произошла ошибка ModOrganizer has crashed! Unfortunately I was not able to write a diagnostic file: %1 - + ModOrganizer вышел из строя! К сожалению не удалось записать диагностический файл: %1 - + Mod Organizer - + Mod Organizer An instance of Mod Organizer is already running - + Другой экземпляр Mod Organizer уже запущен - No game identified in "%1". The directory is required to contain the game binary and its launcher. - + No game identified in "%1". The directory is required to contain the game binary and its launcher. + Игра не обнаружена в "%1". Требуется, чтобы папка содержала исполняемые файлы игры. Please select the game to manage - + Выберете игру для управления - - Please use "Help" from the toolbar to get usage instructions to all elements - + + Please use "Help" from the toolbar to get usage instructions to all elements + Используйте пункт "Справка" на панели инструментов, чтобы получить инструкции по использованию всех элементов. - - + + <Manage...> - + <Управлять...> - + failed to parse profile %1: %2 - + не удалось обработать профиль %1: %2 - + - failed to find "%1" - + failed to find "%1" + не удалось найти "%1" + + + + encoding error, please report this as a bug and include the file mo_interface.log! + ошибка кодирования, пожалуйста сообщите об этом баге, включив файл mo_interface.log! failed to access %1 - + не удалось получить доступ к %1 failed to set file time %1 - + не удалось изменить дату модификации для %1 failed to create %1 - + не удалось создать %1 + + + + "%1" is missing + "%1" отсутствует Before you can use ModOrganizer, you need to create at least one profile. ATTENTION: Run the game at least once before creating a profile! - + Перед тем, как использовать Mod Organizer, вам нужно создать хотя бы один профиль. ВНИМАНИЕ: Перед созданием профиля запустите игру хотя бы один раз! Error - + Ошибка wrong file format - + неверный формат файла failed to open %1 - + не удалось открыть %1 - + Script Extender - + Script Extender - + Proxy DLL - + Proxy DLL - failed to spawn "%1" - + failed to spawn "%1" + не удалось вызвать "%1" Elevation required - + Требуется повышение прав This process requires elevation to run. This is a potential security risk so I highly advice you to investigate if -"%1" +"%1" can be installed to work without elevation. Start elevated anyway? (you will be asked if you want to allow ModOrganizer.exe to make changes to the system) - + Этот процесс требует повышения прав на запуск. +Это потенциальный риск для безопасности, поэтому настоятельно рекомендуется изучить +"%1" + на возможность установки без повышения прав. + +Запустить с повышенными правами в любом случае? (будет выведен запрос о разрешении ModOrganizer.exe сделать изменения в системе) - failed to spawn "%1": %2 - + failed to spawn "%1": %2 + не удалось вызвать "%1": %2 - "%1" doesn't exist - + "%1" doesn't exist + "%1" не существует - failed to inject dll into "%1": %2 - + failed to inject dll into "%1": %2 + не удалось подключить dll к "%1": %2 - failed to run "%1" - - - - - invalid field name "%1" - - - - - invalid type for "%1" (should be integer) - - - - - invalid type for "%1" (should be string) - - - - - invalid type for "%1" (should be float) - - - - - no fields set up yet! - - - - - field not set "%1" - - - - - invalid character in field "%1" - - - - - empty field name - - - - - invalid game type %1 - + failed to run "%1" + не удалось запустить "%1" @@ -4077,22 +3903,22 @@ Start elevated anyway? (you will be asked if you want to allow ModOrganizer.exe Mod Exists - + Мод существует This mod seems to be installed already. Do you want to add files from this archive (overwriting existing ones) or do you want to completely replace the existing files (old files are deleted)? Alternatively you can install this mod under a different name. - + Кажется, что этот мод уже установлен. Вы хотите добавить файлы из архива (с перезаписью уже существующих) или вам нужно полностью заменить существующие файлы (старые будут удалены)? Как вариант, вы можете установить этот мод под другим именем. Keep Backup - + Оставить резервную копию Merge - + Объединить @@ -4102,7 +3928,7 @@ Start elevated anyway? (you will be asked if you want to allow ModOrganizer.exe Rename - + Переименовать @@ -4115,7 +3941,7 @@ Start elevated anyway? (you will be asked if you want to allow ModOrganizer.exe Remember selection - + Запомнить выбор @@ -4123,27 +3949,27 @@ Start elevated anyway? (you will be asked if you want to allow ModOrganizer.exe Save # - + Сохранение № Character - + Персонаж Level - + Уровень Location - + Местоположение Date - + Дата @@ -4151,7 +3977,7 @@ Start elevated anyway? (you will be asked if you want to allow ModOrganizer.exe Missing ESPs - + Отсутствующие ESP @@ -4159,17 +3985,17 @@ Start elevated anyway? (you will be asked if you want to allow ModOrganizer.exe Dialog - + Диалог Copy To Clipboard - + Копировать в буфер обмена Save As... - + Сохранить как... @@ -4179,17 +4005,17 @@ Start elevated anyway? (you will be asked if you want to allow ModOrganizer.exe Save CSV - + Сохранить CSV Text Files - + Текстовые файлы - failed to open "%1" for writing - + failed to open "%1" for writing + не удалось открыть "%1" для записи @@ -4197,7 +4023,7 @@ Start elevated anyway? (you will be asked if you want to allow ModOrganizer.exe Select - + Выбрать @@ -4214,8 +4040,8 @@ Start elevated anyway? (you will be asked if you want to allow ModOrganizer.exe SelfUpdater - archive.dll not loaded: "%1" - + archive.dll not loaded: "%1" + archive.dll не загружен: "%1" @@ -4223,95 +4049,95 @@ Start elevated anyway? (you will be asked if you want to allow ModOrganizer.exe Update - + Обновление An update is available (newest version: %1), do you want to install it? - + Доступно обновление (последняя версия: %1). Вы хотите установить его? Download in progress - + Загрузка в процессе Download failed: %1 - + Загрузка не удалась: %1 Failed to install update: %1 - + Не удалось установить обновление: %1 - failed to open archive "%1": %2 - Не удалось открыть архив "%1": %2 + failed to open archive "%1": %2 + не удалось открыть архив "%1": %2 failed to move outdated files: %1. Please update manually. - + не удалось переместить устаревшие файлы: %1. Пожалуйста, обновите вручную. Update installed, Mod Organizer will now be restarted. - + Обновление установлено, Mod Organizer будет перезапущен. Error - + Ошибка Failed to parse response. Please report this as a bug and include the file mo_interface.log. - + Не удалось обработать запрос. Пожалуйста, сообщите об этом баге, включив в сообщение файл mo_interface.log. No incremental update available for this version, the complete package needs to be downloaded (%1 kB) - + Нет дополнительных обновлений для этой версии, необходимо загрузить полный пакет (%1 kB) no file for update found. Please update manually. - - - - - No download server available. Please try again later. - Сервер недоступен. Попробуйте позже. + не найдено файла для обновления. Пожалуйста, обновите вручную. Failed to retrieve update information: %1 - + Не удалось получить сведения об обновлении: %1 + + + + No download server available. Please try again later. + Нет доступных для загрузки серверов. Пожалуйста, попробуйте позже. Settings - - setting for invalid plugin "%1" requested - + + setting for invalid plugin "%1" requested + запрошена настройка для недействительного плагина "%1" - - invalid setting "%1" requested for plugin "%2" - + + invalid setting "%1" requested for plugin "%2" + неверная настройка "%1" запрошена для плагина "%2" - + Confirm - Подтвердить + Подтверждение - + Changing the mod directory affects all your profiles! Mods not present (or named differently) in the new location will be disabled in all profiles. There is no way to undo this unless you backed up your profiles manually. Proceed? - + Изменение каталога для модов отразится на всех ваших профилях. Нельзя будет отменить это, если только вы не сохранили резервные копии ваших профилей вручную. Продолжить? @@ -4319,169 +4145,178 @@ Start elevated anyway? (you will be asked if you want to allow ModOrganizer.exe Settings - + Настройки General - + Общие Language - + Язык The display language - + Используемый язык - <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> -<html><head><meta name="qrichtext" content="1" /><style type="text/css"> + <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> +<html><head><meta name="qrichtext" content="1" /><style type="text/css"> p, li { white-space: pre-wrap; } -</style></head><body style=" font-family:'MS Shell Dlg 2'; font-size:8.25pt; font-weight:400; font-style:normal;"> -<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">The display language. This will only displaye languages for which you have a translation installed.</span></p></body></html> - +</style></head><body style=" font-family:'MS Shell Dlg 2'; font-size:8.25pt; font-weight:400; font-style:normal;"> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">The display language. This will only displaye languages for which you have a translation installed.</span></p></body></html> + <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> +<html><head><meta name="qrichtext" content="1" /><style type="text/css"> +p, li { white-space: pre-wrap; } +</style></head><body style=" font-family:'MS Shell Dlg 2'; font-size:8.25pt; font-weight:400; font-style:normal;"> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">Используемый язык. Будут отображены языки, локализация на которые имеется.</span></p></body></html> Style - + Стиль graphical style - + графический стиль graphical style of the MO user interface - + графический стиль пользовательского интерфейса MO Log Level - + Уровень журналирования - Decides the amount of data printed to "ModOrganizer.log" - + Decides the amount of data printed to "ModOrganizer.log" + Определяет количество данных, выводимых в "ModOrganizer.log" - Decides the amount of data printed to "ModOrganizer.log". -"Debug" produces very useful information for finding problems. There is usually no noteworthy performance impact but the file may become rather large. If this is a problem you may prefer the "Info" level for regluar use. On the "Error" level the log file usually remains empty. - + Decides the amount of data printed to "ModOrganizer.log". +"Debug" produces very useful information for finding problems. There is usually no noteworthy performance impact but the file may become rather large. If this is a problem you may prefer the "Info" level for regluar use. On the "Error" level the log file usually remains empty. + Определяет количество данных, выводимых в "ModOrganizer.log". +"Отладка" позволяет получить очень полезную для поиска проблем информацию. Влияния на производительность не замечено, однако размер лога может быть довольно большим. Если это проблема, то вы можете предпочесть для обычного использования уровень "Информация". На уровне "Ошибка" лог обычно остается пустым. Debug - + Отладка Info - + Информация Error - + Ошибка Advanced - + Продвинутый Directory where downloads are stored. - + Каталог, в котором хранятся загрузки. Mod Directory - + Каталог модов Directory where mods are stored. - + Каталог, в котором хранятся моды. - Directory where mods are stored. Please note that changing this will break all associations of profiles with mods that don't exist in the new location (with the same name). - + Directory where mods are stored. Please note that changing this will break all associations of profiles with mods that don't exist in the new location (with the same name). + Каталог, в котором хранятся моды. Имейте ввиду, эти изменения нарушат все ассоциации профилей с несуществующими в новом расположении модами (с тем же именем). Download Directory - + Каталог для загрузки Cache Directory - + Каталог кэша Reset stored information from dialogs. - + Сброс хранимой информации о диалогах. - This will make all dialogs show up again where you checked the "Remember selection"-box. - + This will make all dialogs show up again where you checked the "Remember selection"-box. + Заставит снова появиться все диалоги, в которых вы ранее отмечали флажок "Запомнить выбор". Reset Dialogs - + Сбросить диалоги Modify the categories available to arrange your mods. - + Изменение категорий, доступных для упорядочивания ваших модов. Configure Mod Categories - + Настроить категории модов Nexus - + Nexus Allows automatic log-in when the Nexus-Page for the game is clicked. - + Позволяет автоматически входить, кликнув на Nexus-страницу игры. - <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> -<html><head><meta name="qrichtext" content="1" /><style type="text/css"> + <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> +<html><head><meta name="qrichtext" content="1" /><style type="text/css"> +p, li { white-space: pre-wrap; } +</style></head><body style=" font-family:'MS Shell Dlg 2'; font-size:8.25pt; font-weight:400; font-style:normal;"> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">Allows automatic log-in when the Nexus-Page for the game is clicked. Please note that the obfuscation with which the password is stored in modorganizer.ini is not very strong. If you're worried someone might steal your password, don't store it here.</span></p></body></html> + <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> +<html><head><meta name="qrichtext" content="1" /><style type="text/css"> p, li { white-space: pre-wrap; } -</style></head><body style=" font-family:'MS Shell Dlg 2'; font-size:8.25pt; font-weight:400; font-style:normal;"> -<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">Allows automatic log-in when the Nexus-Page for the game is clicked. Please note that the obfuscation with which the password is stored in modorganizer.ini is not very strong. If you're worried someone might steal your password, don't store it here.</span></p></body></html> - +</style></head><body style=" font-family:'MS Shell Dlg 2'; font-size:8.25pt; font-weight:400; font-style:normal;"> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">Позволяет автоматически входить, кликнув на Nexus-страницу игры. Обратите внимание, что шифрование с которым пароль хранится в файле modorganizer.ini не очень сильное. Если вы беспокоитесь, что кто-нибудь может украсть ваш пароль, не храните его здесь.</span></p></body></html> If checked and if correct credentials are entered below, log-in to Nexus (for browsing and downloading) is automatic. - + Если отмечено и данные ниже введены правильно, входит на Nexus (для просмотра и загрузки) автоматически. Automatically Log-In to Nexus - + Автоматический вход на Nexus @@ -4493,220 +4328,244 @@ p, li { white-space: pre-wrap; } Password Пароль + + + Disable automatic internet features + Отключить автоматические возможности интернет + + + + Disable automatic internet features. This does not affect features that are explicitly invoked by the user (like checking mods for updates, endorsing, opening the web browser) + Отключает автоматические возможности интернет. Это не подействует на функции, которые явно вызваны пользователем (проверка модов на обновления, одобрение, открытие в браузере) + + + + Offline Mode + Автономный режим + + + + Use a proxy for network connections. + Использовать прокси для соединения с сетью + + + + Use a proxy for network connections. This uses the system-wide settings which can be configured in Internet Explorer. Please note that MO will start up a few seconds slower on some systems when using a proxy. + Использовать прокси для соединения с сетью. Используются системные параметры, настраиваемые в Internet Explorer. Обратите внимание, что MO запустится на несколько секунд медленнее на некоторых системах, когда используется прокси. + + + + Use HTTP Proxy (Uses System Settings) + Использовать HTTP Proxy (Используются системные настройки) + + + + Known Servers (Dynamically updated every download) + Известные серверы (Динамически обновляется при каждой загрузке) + + + + Preferred Servers (Drag & Drop) + Предпочитаемые серверы (Используйте перетаскивание) + Plugins - + Плагины Author: - + Автор: Version: - + Версия: Description: - + Описание: Key - + Клавиша Value - + Значение Workarounds - + Способы обхода Steam App ID - + ID приложения Steam The Steam AppID for your game - + ID в Steam для вашей игры - <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> -<html><head><meta name="qrichtext" content="1" /><style type="text/css"> + <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> +<html><head><meta name="qrichtext" content="1" /><style type="text/css"> +p, li { white-space: pre-wrap; } +</style></head><body style=" font-family:'MS Shell Dlg 2'; font-size:8.25pt; font-weight:400; font-style:normal;"> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">The Steam App ID is required to directly start some games. For Skyrim, if this is not set or wrong, the &quot;Mod Organizer&quot; load mechanism may not work properly.</span></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">The preset for this is the App ID of the &quot;regular&quot; version so in most cases, you should be set.</span></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">If you think you have a different version (GotY or something), follow these steps to get to the id:</span></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">1. Navigate to the game library in steam</span></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">2. right-click on the game you need the id for and choose </span><span style=" font-size:8pt; font-weight:600;">Create desktop shortcut</span></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">3. right-click on the newly created shortcut on your desktop and select </span><span style=" font-size:8pt; font-weight:600;">Properties</span></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">4. in the URL-field you should see something like this: </span><span style=" font-size:8pt; font-style:italic;">steam://rungameid/22380</span></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">22380 is the id you're looking for.</span></p></body></html> + <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> +<html><head><meta name="qrichtext" content="1" /><style type="text/css"> p, li { white-space: pre-wrap; } -</style></head><body style=" font-family:'MS Shell Dlg 2'; font-size:8.25pt; font-weight:400; font-style:normal;"> -<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">The Steam App ID is required to directly start some games. For Skyrim, if this is not set or wrong, the &quot;Mod Organizer&quot; load mechanism may not work properly.</span></p> -<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">The preset for this is the App ID of the &quot;regular&quot; version so in most cases, you should be set.</span></p> -<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">If you think you have a different version (GotY or something), follow these steps to get to the id:</span></p> -<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">1. Navigate to the game library in steam</span></p> -<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">2. right-click on the game you need the id for and choose </span><span style=" font-size:8pt; font-weight:600;">Create desktop shortcut</span></p> -<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">3. right-click on the newly created shortcut on your desktop and select </span><span style=" font-size:8pt; font-weight:600;">Properties</span></p> -<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">4. in the URL-field you should see something like this: </span><span style=" font-size:8pt; font-style:italic;">steam://rungameid/22380</span></p> -<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">22380 is the id you're looking for.</span></p></body></html> - +</style></head><body style=" font-family:'MS Shell Dlg 2'; font-size:8.25pt; font-weight:400; font-style:normal;"> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">ID приложения в Steam необходим для прямого запуска некоторых игр. Для Skyrim, если он не установлен или неверен, механизм загрузки &quot;Mod Organizer&quot; может работать неправильно.</span></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">Предустановленный ID в большинстве случаев должен быть установлен.</span></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">Если вы думаете, что у вас другая версия (GotY или другое), следуйте следующей инструкции по установке id:</span></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">1. Перейдите в библиотеку игр Steam.</span></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">2. Сделайте правый клик по игре, id которой нужен и выберете </span><span style=" font-size:8pt; font-weight:600;">Создать ярлык на рабочем столе</span></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">3. Сделайте правый клик на созданном на рабочем столе ярлыке и выберете </span><span style=" font-size:8pt; font-weight:600;">Свойства</span></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">4. в поле URL вы должны увидеть что-то вроде: </span><span style=" font-size:8pt; font-style:italic;">steam://rungameid/22380</span></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:8pt;">22380 это и есть id, который вам нужен.</span></p></body></html> Load Mechanism - + Механизм загрузки Select loading mechanism. See help for details. - + Выберете механизм загрузки. Смотрите справку для подробностей. + + + + Mod Organizer needs a dll to be injected into the game so all mods are visible to it. +There are several means to do this: +*Mod Organizer* (default) In this mode the Mod Organizer itself injects the dll. The disadvantage is that you always have to start the game through MO or a link created by it. +*Script Extender* In this mode, MO is installed as a Script Extender (obse, fose, nvse, skse) plugin. +*Proxy DLL* In this mode, MO replaces one of the game's dlls with one that loads MO (and the original dll of course). This will ONLY work with Steam games and it has only been tested with Skyrim. Please use this only if the other mechanisms don't work. + +If you use the Steam version of Oblivion the default will NOT work. In this case, please install obse and use "Script Extender" as the load mechanism. Also you can then not start Oblivion from MO. Instead, use MO only to set up your mods, then quit and start Oblivion through Steam. + Mod Organizer необходимо подключить dll к игре, чтобы все моды были видны в ней. +Есть несколько способов сделать это: +*Mod Organizer* (по умолчанию) В этом режиме Mod Organizer сам подключает dll. Недостатком этого является то, что вам необходимо всегда начинать игру через MO или созданный им ярлык. +*Script Extender* В этом режиме, MO установлен как плагин Script Extender (obse, fose, nvse, skse). +*Proxy DLL* В этом режиме MO заменяет одну из игровых dll игры своей, которая загружает MO и оригинальную игру. Это работает только с играми Steam и тестировалось только на Skyrim. Используйте этот способ только если другие не работают. + +Если вы используете Steam-версию Oblivion , способ по умолчанию не работает. В этом случае установите obse и используйте "Script Extender" как механизм загрузки. Также после этого вы не сможете запустить Oblivion из MO, вместо этого используйте MO только для настройки модов и запускайте игру через Steam. NMM Version - + Версия NMM The Version of Nexus Mod Manager to impersonate. - + Версия Nexus Mod Manager для представления. Mod Organizer uses an API provided by the Nexus to provide features like checking for updates and downloading files. Unfortunately this API has not been made available officially to third party tools like MO so we have to impersonate the Nexus Mod Manager to be allowed in. -On top of this Nexus has used the client identification to lock out outdated versions of NMM to force users to update. This means that MO also needs to impersonate the new version of NMM even if MO doesn't need an update. Therefore you can configure the version to identify as here. -Please note that MO does identify itself as MO to the webserver, it's not lying about what it is. It is merely adding a "compatible" NMM version to the user agent. +On top of this Nexus has used the client identification to lock out outdated versions of NMM to force users to update. This means that MO also needs to impersonate the new version of NMM even if MO doesn't need an update. Therefore you can configure the version to identify as here. +Please note that MO does identify itself as MO to the webserver, it's not lying about what it is. It is merely adding a "compatible" NMM version to the user agent. -tl;dr-version: If Nexus-features don't work, insert the current version number of NMM here and try again. - - - - - These are workarounds for problems with Mod Organizer. Please make sure you read the help text before changing anything here. - +tl;dr-version: If Nexus-features don't work, insert the current version number of NMM here and try again. + Mod Organizer использует API Nexus , для предоставления таких возможностей, как проверка обновлений и загрузка файлов. К сожалению этот API не был сделан официально доступным прочим утилитам, вроде MO, так что нужно представляться как Nexus Mod Manager, чтобы получить доступ. +Помимо этого Nexus использует идентификатор версий, чтобы блокировать устаревшии версии NMM и принудительно заставить пользователей обновиться. Это значит, что MO также нужно представляться последней версией NMM, даже если MO не нуждается в обновлении. Поэтому вы можете настроить здесь также и версию для идентификации. +Обратите внимание, что MO идентифицирует себя вебсерверу как MO, он не подделывает данные о себе. Он всего лишь добавляется как "совместимая" с NMM версия, в поле user agent. + +tl;dr-версия: Если возможности Nexus не работают, вставьте здесь текущую версию NMM и повторите попытку. Enforces that inactive ESPs and ESMs are never loaded. - - - - - Disable automatic internet features - - - - - Disable automatic internet features. This does not affect features that are explicitly invoked by the user (like checking mods for updates, endorsing, opening the web browser) - - - - - Offline Mode - - - - - Use a proxy for network connections. - - - - - Use a proxy for network connections. This uses the system-wide settings which can be configured in Internet Explorer. Please note that MO will start up a few seconds slower on some systems when using a proxy. - - - - - Use HTTP Proxy (Uses System Settings) - - - - - Known Servers (Dynamically updated every download) - - - - - Preferred Servers (Drag & Drop) - - - - - Mod Organizer needs a dll to be injected into the game so all mods are visible to it. -There are several means to do this: -*Mod Organizer* (default) In this mode the Mod Organizer itself injects the dll. The disadvantage is that you always have to start the game through MO or a link created by it. -*Script Extender* In this mode, MO is installed as a Script Extender (obse, fose, nvse, skse) plugin. -*Proxy DLL* In this mode, MO replaces one of the game's dlls with one that loads MO (and the original dll of course). This will ONLY work with Steam games and it has only been tested with Skyrim. Please use this only if the other mechanisms don't work. - -If you use the Steam version of Oblivion the default will NOT work. In this case, please install obse and use "Script Extender" as the load mechanism. Also you can then not start Oblivion from MO. Instead, use MO only to set up your mods, then quit and start Oblivion through Steam. - + Обеспечивает то, что неактивные ESP и ESM не будут загружены. - It seems that the Games occasionally load ESP or ESM files even if they haven't been activated as plugins. -I don't yet know what the circumstances are, but user reports imply it is in some cases unwanted. If this is checked, ESPs and ESMs not checked in the List are invisible to the game and can not be loaded. - + It seems that the Games occasionally load ESP or ESM files even if they haven't been activated as plugins. +I don't yet know what the circumstances are, but user reports imply it is in some cases unwanted. If this is checked, ESPs and ESMs not checked in the List are invisible to the game and can not be loaded. + Кажется, что иногда игры загружают ESP и ESM файлы, даже если они не были не подключены как плагины +Обстоятельства этого пока не известны, но отчеты пользователей подразумевают, что это в ряде случаев нежелательно. Если этот флажок отмечен, не отмеченные в списке ESP и ESM не будут видимы в списке и не будут загружены. Hide inactive ESPs/ESMs - + Скрыть неактивные ESPs/ESMs If checked, files (i.e. esps, esms and bsas) belonging to the core game can not be disabled in the UI. (default: on) - + Если отмечено, файлы (т.е. esp, esm и bsa) принадлежащие основной игре не смогут быть отключены из интерфейса. (по умолчанию: вкл) If checked, files (i.e. esps, esms and bsas) belonging to the core game can not be disabled in the UI. (default: on) Uncheck this if you want to use Mod Organizer with total conversions (like Nehrim) but be aware that the game will crash if required files are not enabled. - + Если отмечено, файлы (т.е. esp, esm и bsa) принадлежащие основной игре не смогут быть отключены из интерфейса. (по умолчанию: вкл) +Снимите флажок, если вы собираетесь использовать Mod Organizer с тотальными конверсиями (как Nehrim) , но будьте осторожны, игра может вылететь, если требуемые файлы будут отключены. Force-enable game files - + Принудительно подключить файлы игры For Skyrim, this can be used instead of Archive Invalidation. It should make AI redundant for all Profiles. For the other games this is not a sufficient replacement for AI! - + Для Скайрим это может быть использовано вместо инвалидации. Это должно сделать AI избыточным для всех профилей. +Для других игр недостаточно замены для AI! Back-date BSAs - + Back-date BSAs + + + + These are workarounds for problems with Mod Organizer. Please make sure you read the help text before changing anything here. + Это способы обхода проблем с Mod Organizer. Убедитесь, что вы прочли справку, перед тем, как делать какие-либо изменения здесь. Select download directory - + Выберете каталог для загрузок Select mod directory - + Выберете каталог для модов Select cache directory - + Выберете каталог для кеша Confirm? - + Подтвердить? - This will make all dialogs show up again where you checked the "Remember selection"-box. Continue? - + This will make all dialogs show up again where you checked the "Remember selection"-box. Continue? + Это позволить снова отобразить все диалоги, для которых вы ранее выбрали флажок "Запомнить выбор". @@ -4714,7 +4573,7 @@ For the other games this is not a sufficient replacement for AI! Quick Install - + Быстрая установка @@ -4725,17 +4584,17 @@ For the other games this is not a sufficient replacement for AI! Opens a Dialog that allows custom modifications. - Открывает диалоговое окно, которое позволяет выбрать пользовательские модификации. + Открывает диалог, позволяющий выбрать пользовательские модификации. Manual - + Руководство OK - + OK @@ -4748,18 +4607,18 @@ For the other games this is not a sufficient replacement for AI! SHM error: %1 - + Ошибка SHM: %1 failed to connect to running instance: %1 - + не удалось подключиться к запущенному экземпляру: %1 failed to receive data from secondary instance: %1 - + не удалось получить данные из вторичного экземпляра: %1 @@ -4767,7 +4626,7 @@ For the other games this is not a sufficient replacement for AI! Sync Overwrite - + Синхронизация замены @@ -4777,22 +4636,22 @@ For the other games this is not a sufficient replacement for AI! Sync To - + Синхронизация с - <don't sync> - + <don't sync> + <не синхронизировать> failed to remove %1 - + не удалось удалить %1 failed to move %1 to %2 - + не удалось переместить %1 в %2 @@ -4800,17 +4659,17 @@ For the other games this is not a sufficient replacement for AI! Dialog - + Диалог Global Characters - + Общие символы This is a list of characters in the global location. - + Это список персонажей в общем месторасположении. @@ -4822,7 +4681,14 @@ On Windows Vista/Windows 7: On Windows XP: C:\Documents and Settings[UserName]\My Documents\My Games\Skyrim\Saves - + Список персонажей в общем месторасположении. + +На Windows Vista/Windows 7: +C:\Users\[UserName]\Documents\My Games\Skyrim\Saves + +На Windows XP: +C:\Documents and Settings[UserName]\My Documents\My Games\Skyrim\Saves + @@ -4835,27 +4701,35 @@ On Windows XP: C:\Documents and Settings[UserName]\My Documents\My Games\Skyrim\Saves - + Список сохранений с выбранным персонажем в общем месторасположении. + +На Windows Vista/Windows 7: +C:\Users\[UserName]\Documents\My Games\Skyrim\Saves + +На Windows XP: +C:\Documents and Settings[UserName]\My Documents\My Games\Skyrim\Saves + + Move -> - + Переместить -> Copy -> - + Скопировать -> <- Move - + <- Переместить <- Copy - + <- Скопировать @@ -4865,17 +4739,17 @@ On Windows XP: Profile Characters - + Персонажи профиля Overwrite - + Переписать - Overwrite the file "%1" - + Overwrite the file "%1" + Перезаписать файл "%1" @@ -4883,23 +4757,23 @@ On Windows XP: Confirm - Подтвердить + Подтверждение - Copy all save games of character "%1" to the profile? - + Copy all save games of character "%1" to the profile? + Скопировать все игры с персонажем "%1" в профиль? - Move all save games of character "%1" to the global location? Please be aware that this will mess up the running number of save games. - + Move all save games of character "%1" to the global location? Please be aware that this will mess up the running number of save games. + Переместить все сохранения с персонажем "%1" в общее месторасположение? Имейте ввиду, что это запутает текущую нумерацию сохранений. - Copy all save games of character "%1" to the global location? Please be aware that this will mess up the running number of save games. - + Copy all save games of character "%1" to the global location? Please be aware that this will mess up the running number of save games. + Скопировать все сохранения с персонажем "%1" в общее месторасположение? Имейте ввиду, что это запутает текущую нумерацию сохранений. diff --git a/src/overwriteinfodialog.cpp b/src/overwriteinfodialog.cpp index e215146f..2ba81633 100644 --- a/src/overwriteinfodialog.cpp +++ b/src/overwriteinfodialog.cpp @@ -72,7 +72,8 @@ private: OverwriteInfoDialog::OverwriteInfoDialog(ModInfo::Ptr modInfo, QWidget *parent) : QDialog(parent), ui(new Ui::OverwriteInfoDialog), m_FileSystemModel(NULL), - m_DeleteAction(NULL), m_RenameAction(NULL), m_OpenAction(NULL) + m_DeleteAction(NULL), m_RenameAction(NULL), m_OpenAction(NULL), + m_ModInfo(modInfo) { ui->setupUi(this); @@ -101,7 +102,6 @@ OverwriteInfoDialog::~OverwriteInfoDialog() delete ui; } - bool OverwriteInfoDialog::recursiveDelete(const QModelIndex &index) { for (int childRow = 0; childRow < m_FileSystemModel->rowCount(index); ++childRow) { diff --git a/src/overwriteinfodialog.h b/src/overwriteinfodialog.h index a60e0571..34e86219 100644 --- a/src/overwriteinfodialog.h +++ b/src/overwriteinfodialog.h @@ -17,51 +17,55 @@ You should have received a copy of the GNU General Public License along with Mod Organizer. If not, see . */ -#ifndef OVERWRITEINFODIALOG_H -#define OVERWRITEINFODIALOG_H - -#include "modinfo.h" -#include -#include - -namespace Ui { -class OverwriteInfoDialog; -} - -class OverwriteInfoDialog : public QDialog -{ - Q_OBJECT - -public: - - explicit OverwriteInfoDialog(ModInfo::Ptr modInfo, QWidget *parent = 0); - ~OverwriteInfoDialog(); - -private: - - void openFile(const QModelIndex &index); - bool recursiveDelete(const QModelIndex &index); - void deleteFile(const QModelIndex &index); - -private slots: - - void deleteTriggered(); - void renameTriggered(); - void openTriggered(); - void createDirectoryTriggered(); - - void on_filesView_customContextMenuRequested(const QPoint &pos); - -private: - - Ui::OverwriteInfoDialog *ui; - QFileSystemModel *m_FileSystemModel; - QModelIndexList m_FileSelection; - QAction *m_DeleteAction; - QAction *m_RenameAction; - QAction *m_OpenAction; - QAction *m_NewFolderAction; - -}; - -#endif // OVERWRITEINFODIALOG_H +#ifndef OVERWRITEINFODIALOG_H +#define OVERWRITEINFODIALOG_H + +#include "modinfo.h" +#include +#include + +namespace Ui { +class OverwriteInfoDialog; +} + +class OverwriteInfoDialog : public QDialog +{ + Q_OBJECT + +public: + + explicit OverwriteInfoDialog(ModInfo::Ptr modInfo, QWidget *parent = 0); + ~OverwriteInfoDialog(); + + ModInfo::Ptr modInfo() const { return m_ModInfo; } + +private: + + void openFile(const QModelIndex &index); + bool recursiveDelete(const QModelIndex &index); + void deleteFile(const QModelIndex &index); + +private slots: + + void deleteTriggered(); + void renameTriggered(); + void openTriggered(); + void createDirectoryTriggered(); + + void on_filesView_customContextMenuRequested(const QPoint &pos); + +private: + + Ui::OverwriteInfoDialog *ui; + QFileSystemModel *m_FileSystemModel; + QModelIndexList m_FileSelection; + QAction *m_DeleteAction; + QAction *m_RenameAction; + QAction *m_OpenAction; + QAction *m_NewFolderAction; + + ModInfo::Ptr m_ModInfo; + +}; + +#endif // OVERWRITEINFODIALOG_H diff --git a/src/pluginlist.cpp b/src/pluginlist.cpp index 456d29ee..b0228849 100644 --- a/src/pluginlist.cpp +++ b/src/pluginlist.cpp @@ -199,10 +199,11 @@ void PluginList::refresh(const QString &profileName, const DirectoryEntry &baseD readLockedOrderFrom(lockedOrderFile); - refreshLoadOrder(); - emit layoutChanged(); + refreshLoadOrder(); emit dataChanged(this->index(0, 0), this->index(m_ESPs.size(), 1)); + + m_Refreshed(); } @@ -534,6 +535,7 @@ void PluginList::syncLoadOrder() void PluginList::refreshLoadOrder() { + emit layoutAboutToBeChanged(); syncLoadOrder(); // set priorities according to locked load order std::map lockedLoadOrder; @@ -550,9 +552,9 @@ void PluginList::refreshLoadOrder() // find the location to insert at while ((targetPrio < static_cast(m_ESPs.size() - 1)) && (m_ESPs[m_ESPsByPriority[targetPrio]].m_LoadOrder < iter->first)) { - if (QString::compare(m_ESPs[m_ESPsByPriority[targetPrio]].m_Name, iter->second) != 0) { +// if (QString::compare(m_ESPs[m_ESPsByPriority[targetPrio]].m_Name, iter->second) != 0) { ++targetPrio; - } +// } } if (static_cast(targetPrio) >= m_ESPs.size()) { @@ -569,6 +571,7 @@ void PluginList::refreshLoadOrder() } } } + emit layoutChanged(); } IPluginList::PluginState PluginList::state(const QString &name) const @@ -621,6 +624,12 @@ QString PluginList::origin(const QString &name) const } } +bool PluginList::onRefreshed(const std::function &callback) +{ + auto conn = m_Refreshed.connect(callback); + return conn.connected(); +} + void PluginList::updateIndices() { m_ESPsByName.clear(); @@ -743,10 +752,11 @@ QVariant PluginList::data(const QModelIndex &modelIndex, int role) const } -bool PluginList::setData(const QModelIndex &index, const QVariant &value, int role) +bool PluginList::setData(const QModelIndex &modIndex, const QVariant &value, int role) { if (role == Qt::CheckStateRole) { - m_ESPs[index.row()].m_Enabled = value.toInt() == Qt::Checked; + m_ESPs[modIndex.row()].m_Enabled = value.toInt() == Qt::Checked; + emit dataChanged(modIndex, modIndex); refreshLoadOrder(); startSaveTime(); @@ -829,14 +839,17 @@ void PluginList::setPluginPriority(int row, int &newPriority) for (int i = oldPriority + 1; i <= newPriorityTemp; ++i) { --m_ESPs.at(m_ESPsByPriority.at(i)).m_Priority; } + emit dataChanged(index(oldPriority + 1, 0), index(newPriorityTemp, columnCount())); } else { for (int i = newPriorityTemp; i < oldPriority; ++i) { ++m_ESPs.at(m_ESPsByPriority.at(i)).m_Priority; } + emit dataChanged(index(newPriorityTemp, 0), index(oldPriority - 1, columnCount())); ++newPriority; } m_ESPs.at(row).m_Priority = newPriorityTemp; + emit dataChanged(index(row, 0), index(row, columnCount())); } catch (const std::out_of_range&) { reportError(tr("failed to restore load order for %1").arg(m_ESPs[row].m_Name)); } @@ -868,9 +881,9 @@ void PluginList::changePluginPriority(std::vector rows, int newPriority) for (std::vector::const_iterator iter = rows.begin(); iter != rows.end(); ++iter) { setPluginPriority(*iter, newPriority); } - refreshLoadOrder(); emit layoutChanged(); + refreshLoadOrder(); startSaveTime(); } @@ -958,7 +971,6 @@ bool PluginList::eventFilter(QObject *obj, QEvent *event) int newPriority = m_ESPs[idx.row()].m_Priority + diff; if ((newPriority >= 0) && (newPriority < rowCount())) { setPluginPriority(idx.row(), newPriority); - emit dataChanged(this->index(idx.row(), 0), this->index(idx.row(), this->columnCount() - 1)); } } refreshLoadOrder(); diff --git a/src/pluginlist.h b/src/pluginlist.h index 4da7be4b..2af5a0df 100644 --- a/src/pluginlist.h +++ b/src/pluginlist.h @@ -20,12 +20,13 @@ along with Mod Organizer. If not, see . #ifndef PLUGINLIST_H #define PLUGINLIST_H +#include +#include #include #include #include +#include #include -#include -#include /** @@ -45,6 +46,8 @@ public: COL_LASTCOLUMN = COL_MODINDEX }; + typedef boost::signals2::signal SignalRefreshed; + public: /** @@ -141,6 +144,7 @@ public: virtual int loadOrder(const QString &name) const; virtual bool isMaster(const QString &name) const; virtual QString origin(const QString &name) const; + virtual bool onRefreshed(const std::function &callback); public: // implementation of the QAbstractTableModel interface @@ -240,6 +244,8 @@ private: mutable QTimer m_SaveTimer; + SignalRefreshed m_Refreshed; + }; #endif // PLUGINLIST_H diff --git a/src/problemsdialog.cpp b/src/problemsdialog.cpp index d5700381..edb34f39 100644 --- a/src/problemsdialog.cpp +++ b/src/problemsdialog.cpp @@ -10,11 +10,26 @@ using namespace MOBase; ProblemsDialog::ProblemsDialog(std::vector diagnosePlugins, QWidget *parent) - : QDialog(parent), ui(new Ui::ProblemsDialog) + : QDialog(parent), ui(new Ui::ProblemsDialog), m_DiagnosePlugins(diagnosePlugins) { ui->setupUi(this); - foreach (IPluginDiagnose *diagnose, diagnosePlugins) { + runDiagnosis(); + + connect(ui->problemsWidget, SIGNAL(itemSelectionChanged()), this, SLOT(selectionChanged())); + connect(ui->descriptionText, SIGNAL(anchorClicked(QUrl)), this, SLOT(urlClicked(QUrl))); +} + + +ProblemsDialog::~ProblemsDialog() +{ + delete ui; +} + +void ProblemsDialog::runDiagnosis() +{ + ui->problemsWidget->clear(); + foreach (IPluginDiagnose *diagnose, m_DiagnosePlugins) { std::vector activeProblems = diagnose->activeProblems(); foreach (unsigned int key, activeProblems) { QTreeWidgetItem *newItem = new QTreeWidgetItem(); @@ -26,7 +41,7 @@ ProblemsDialog::ProblemsDialog(std::vector diagnosePl ui->problemsWidget->addTopLevelItem(newItem); if (diagnose->hasGuidedFix(key)) { - newItem->setText(1, tr("fix")); + newItem->setText(1, tr("Fix")); QPushButton *fixButton = new QPushButton(tr("Fix")); connect(fixButton, SIGNAL(clicked()), this, SLOT(startFix())); ui->problemsWidget->setItemWidget(newItem, 1, fixButton); @@ -35,17 +50,8 @@ ProblemsDialog::ProblemsDialog(std::vector diagnosePl } } } - connect(ui->problemsWidget, SIGNAL(itemSelectionChanged()), this, SLOT(selectionChanged())); - connect(ui->descriptionText, SIGNAL(anchorClicked(QUrl)), this, SLOT(urlClicked(QUrl))); -} - - -ProblemsDialog::~ProblemsDialog() -{ - delete ui; } - bool ProblemsDialog::hasProblems() const { return ui->problemsWidget->topLevelItemCount() != 0; @@ -62,6 +68,7 @@ void ProblemsDialog::startFix() { IPluginDiagnose *plugin = reinterpret_cast(ui->problemsWidget->currentItem()->data(1, Qt::UserRole).value()); plugin->startGuidedFix(ui->problemsWidget->currentItem()->data(1, Qt::UserRole + 1).toUInt()); + runDiagnosis(); } void ProblemsDialog::urlClicked(const QUrl &url) diff --git a/src/problemsdialog.h b/src/problemsdialog.h index 050785f4..24a69cdf 100644 --- a/src/problemsdialog.h +++ b/src/problemsdialog.h @@ -21,6 +21,9 @@ public: ~ProblemsDialog(); bool hasProblems() const; +private: + + void runDiagnosis(); private slots: @@ -31,6 +34,7 @@ private slots: private: Ui::ProblemsDialog *ui; + std::vector m_DiagnosePlugins; }; #endif // PROBLEMSDIALOG_H diff --git a/src/settingsdialog.ui b/src/settingsdialog.ui index e7bd0fa3..39d49a39 100644 --- a/src/settingsdialog.ui +++ b/src/settingsdialog.ui @@ -652,7 +652,7 @@ Please note that MO does identify itself as MO to the webserver, it's not lying tl;dr-version: If Nexus-features don't work, insert the current version number of NMM here and try again. - 009.009.009; + 009.009.009 Qt::AlignCenter diff --git a/src/shared/directoryentry.cpp b/src/shared/directoryentry.cpp index dde8a69e..685e14a9 100644 --- a/src/shared/directoryentry.cpp +++ b/src/shared/directoryentry.cpp @@ -494,7 +494,7 @@ static bool SupportOptimizedFind() static bool DirCompareByName(const DirectoryEntry *lhs, const DirectoryEntry *rhs) { - return wcsicmp(lhs->getName().c_str(), rhs->getName().c_str()) < 0; + return _wcsicmp(lhs->getName().c_str(), rhs->getName().c_str()) < 0; } diff --git a/src/version.rc b/src/version.rc index 55de3798..ab144909 100644 --- a/src/version.rc +++ b/src/version.rc @@ -1,7 +1,7 @@ #include "Winver.h" -#define VER_FILEVERSION 1,0,7,0 -#define VER_FILEVERSION_STR "1,0,7,0\0" +#define VER_FILEVERSION 1,0,8,0 +#define VER_FILEVERSION_STR "1,0,8,0\0" VS_VERSION_INFO VERSIONINFO FILEVERSION VER_FILEVERSION -- cgit v1.3.1 From 75475a7984466afd1cf77f2e4a9f722c0a859404 Mon Sep 17 00:00:00 2001 From: Tannin Date: Mon, 11 Nov 2013 23:19:54 +0100 Subject: - started qbs based project files (not functional yet) - modlist will now updated immediately after a change throw the modinfo dialog - bugfix: configurator wasn't able to save after revision 137 --- src/moapplication.cpp | 2 +- src/modlist.cpp | 3 +++ src/nexusinterface.h | 2 +- src/organizer.qbs | 23 +++++++++++++++++++++++ src/shared/shared.qbs | 16 ++++++++++++++++ 5 files changed, 44 insertions(+), 2 deletions(-) create mode 100644 src/organizer.qbs create mode 100644 src/shared/shared.qbs (limited to 'src/modlist.cpp') diff --git a/src/moapplication.cpp b/src/moapplication.cpp index ac660c6c..ba23808b 100644 --- a/src/moapplication.cpp +++ b/src/moapplication.cpp @@ -19,7 +19,7 @@ along with Mod Organizer. If not, see . #include "moapplication.h" #include "report.h" -#include "utility.h" +#include #include #include #include diff --git a/src/modlist.cpp b/src/modlist.cpp index 446946dc..eac02372 100644 --- a/src/modlist.cpp +++ b/src/modlist.cpp @@ -564,6 +564,9 @@ void ModList::modInfoChanged(ModInfo::Ptr info) if (m_ChangeInfo.state != newState) { m_ModStateChanged(info->name(), newState); } + int row = ModInfo::getIndex(info->name()); + info->testValid(); + emit dataChanged(index(row, 0), index(row, columnCount())); } else { qCritical("modInfoChanged not called after modInfoAboutToChange"); } diff --git a/src/nexusinterface.h b/src/nexusinterface.h index 03226d8e..da5fe02a 100644 --- a/src/nexusinterface.h +++ b/src/nexusinterface.h @@ -23,7 +23,7 @@ along with Mod Organizer. If not, see . #include "nxmaccessmanager.h" -#include "utility.h" +#include #include #include #include diff --git a/src/organizer.qbs b/src/organizer.qbs new file mode 100644 index 00000000..fdfb914c --- /dev/null +++ b/src/organizer.qbs @@ -0,0 +1,23 @@ +import qbs.base 1.0 + +Application { + name: 'Organizer' + + Depends { name: 'Qt.core' } + Depends { name: 'Qt.gui' } + Depends { name: 'Qt.network' } + Depends { name: 'Qt.declarative' } + Depends { name: 'UIBase' } + Depends { name: 'Shared' } + Depends { name: 'cpp' } + + cpp.defines: [] + cpp.includePaths: [ '../shared', '../archive', '../uibase', qbs.getenv("BOOSTPATH") ] + // '../bsatk', '../esptk', + + files: [ + '*.cpp', + '*.h', + '*.ui' + ] +} diff --git a/src/shared/shared.qbs b/src/shared/shared.qbs new file mode 100644 index 00000000..44b7539f --- /dev/null +++ b/src/shared/shared.qbs @@ -0,0 +1,16 @@ +import qbs.base 1.0 + +Application { + name: 'Shared' + + Depends { name: 'cpp' } + Depends { name: 'BSAToolkit' } + + cpp.defines: [] + cpp.libraryPaths: [ qbs.getenv("BOOSTPATH") ] + cpp.includePaths: [ 'bsatk', qbs.getenv("BOOSTPATH") ] + files: [ + '*.h', + '*.cpp' + ] +} -- cgit v1.3.1 From c6101e34e1e142a3442c3a4543ea22dabd31fa33 Mon Sep 17 00:00:00 2001 From: Tannin Date: Mon, 18 Nov 2013 20:17:14 +0100 Subject: - archive.dll now supports querying the crc value of files - esptk now determines if a esp is a dummy (without records) - hook.dll no longer creates a log file if noone wrote to it - nexus id and installtime columns are now hidden by default - modlist can now be refreshed without saving first (so plugins can replace the modlist.txt as a whole) - plugins can now query more details about virtualised files - added style options "plastique" and "cleanlooks" - "overwrite" is no longer listed with a creation time - a warning will now be displayed if the user has too many plugins active - a warning will now be displayed if mods with scripts have an installation order that doesn't match the corresponding esp load order - nmm importer now has select all/deselect all buttons - nmm importer no longer tries to unpack missing files from archives (won't work anyway) - initial support for importing from nmm 0.5 alpha - removed some broken warning suppresions - python runner now works with bundled python - extended qbs build system (still fails to build the main gui application) - implemented a nsis-based installer --- src/installationmanager.cpp | 2 -- src/main.cpp | 2 +- src/mainwindow.cpp | 50 ++++++++++++++++++++++++++++++++++++++++++--- src/mainwindow.h | 5 ++++- src/moapplication.cpp | 29 ++++++++++++++++++-------- src/moapplication.h | 2 ++ src/modinfodialog.ui | 33 ++++++++++-------------------- src/modlist.cpp | 7 ++++++- src/modlist.h | 4 ++++ src/organizer.qbs | 44 ++++++++++++++++++++++++++++----------- src/pluginlist.cpp | 21 +++++++++++++++++++ src/pluginlist.h | 7 +++++++ src/settings.cpp | 3 +++ src/shared/shared.qbs | 14 ++++++++----- 14 files changed, 167 insertions(+), 56 deletions(-) (limited to 'src/modlist.cpp') diff --git a/src/installationmanager.cpp b/src/installationmanager.cpp index 6b430eea..a8571ec9 100644 --- a/src/installationmanager.cpp +++ b/src/installationmanager.cpp @@ -506,7 +506,6 @@ bool InstallationManager::ensureValidModName(GuessedValue &name) const return true; } - bool InstallationManager::doInstall(GuessedValue &modName, int modID, const QString &version, const QString &newestVersion, int categoryID) { @@ -528,7 +527,6 @@ bool InstallationManager::doInstall(GuessedValue &modName, int modID, m_InstallationProgress.setValue(0); m_InstallationProgress.setWindowModality(Qt::WindowModal); m_InstallationProgress.show(); - if (!m_CurrentArchive->extract(ToWString(QDir::toNativeSeparators(targetDirectory)).c_str(), new MethodCallback(this, &InstallationManager::updateProgress), new MethodCallback(this, &InstallationManager::updateProgressFile), diff --git a/src/main.cpp b/src/main.cpp index 5053d21d..8b74ba83 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -60,7 +60,6 @@ along with Mod Organizer. If not, see . #include "selectiondialog.h" #include "moapplication.h" #include "tutorialmanager.h" -#include #include #include #include @@ -156,6 +155,7 @@ bool bootstrap() // verify the hook-dll exists QString dllName = qApp->applicationDirPath() + "/" + ToQString(AppConfig::hookDLLName()); + HMODULE dllMod = ::LoadLibraryW(ToWString(dllName).c_str()); if (dllMod == NULL) { throw windows_error("hook.dll is missing or invalid"); diff --git a/src/mainwindow.cpp b/src/mainwindow.cpp index f726757c..a8026b68 100644 --- a/src/mainwindow.cpp +++ b/src/mainwindow.cpp @@ -188,8 +188,13 @@ MainWindow::MainWindow(const QString &exeName, QSettings &initSettings, QWidget ui->modList->header()->installEventFilter(&m_ModList); if (initSettings.contains("mod_list_state")) { ui->modList->header()->restoreState(initSettings.value("mod_list_state").toByteArray()); + } else { + // hide these columns by default + ui->modList->header()->setSectionHidden(ModList::COL_MODID, true); + ui->modList->header()->setSectionHidden(ModList::COL_INSTALLTIME, true); } - ui->modList->header()->setSectionHidden(0, false); // prevent the name-column from being hidden + + ui->modList->header()->setSectionHidden(ModList::COL_NAME, false); // prevent the name-column from being hidden ui->modList->installEventFilter(&m_ModList); // set up plugin list @@ -1364,10 +1369,12 @@ void MainWindow::startExeAction() } -void MainWindow::refreshModList() +void MainWindow::refreshModList(bool saveChanges) { // don't lose changes! - m_CurrentProfile->writeModlistNow(true); + if (saveChanges) { + m_CurrentProfile->writeModlistNow(true); + } ModInfo::updateFromDisc(m_Settings.getModDirectory(), &m_DirectoryStructure); m_CurrentProfile->refreshModStatus(); @@ -2096,6 +2103,32 @@ QStringList MainWindow::findFiles(const QString &path, const std::function MainWindow::findFileInfos(const QString &path, const std::function &filter) const +{ + QList result; + DirectoryEntry *dir = m_DirectoryStructure->findSubDirectoryRecursive(ToWString(path)); + if (dir != NULL) { + std::vector files = dir->getFiles(); + foreach (FileEntry::Ptr file, files) { + FileInfo info; + info.filePath = ToQString(file->getFullPath()); + bool fromArchive = false; + info.origins.append(ToQString(m_DirectoryStructure->getOriginByID(file->getOrigin(fromArchive)).getName())); + info.archive = fromArchive ? ToQString(file->getArchive()) : ""; + foreach (int idx, file->getAlternatives()) { + info.origins.append(ToQString(m_DirectoryStructure->getOriginByID(idx).getName())); + } + + if (filter(info)) { + result.append(info); + } + } + } else { + qWarning("directory %s not found", qPrintable(path)); + } + return result; +} + IDownloadManager *MainWindow::downloadManager() { return &m_DownloadManager; @@ -2161,6 +2194,9 @@ std::vector MainWindow::activeProblems() const if (m_UnloadedPlugins.size() != 0) { problems.push_back(PROBLEM_PLUGINSNOTLOADED); } + if (m_PluginList.enabledCount() > 256) { + problems.push_back(PROBLEM_TOOMANYPLUGINS); + } return problems; } @@ -2170,6 +2206,9 @@ QString MainWindow::shortDescription(unsigned int key) const case PROBLEM_PLUGINSNOTLOADED: { return tr("Some plugins could not be loaded"); } break; + case PROBLEM_TOOMANYPLUGINS: { + return tr("Too many esps and esms enabled"); + } break; default: { return tr("Description missing"); } break; @@ -2187,6 +2226,10 @@ QString MainWindow::fullDescription(unsigned int key) const result += "
        "; return result; } break; + case PROBLEM_TOOMANYPLUGINS: { + return tr("The game doesn't allow more than 256 active plugins (including the official ones) to be loaded. You have to disable some unused plugins or " + "merge some plugins into one. You can find a guide here: http://wiki.step-project.com/Guide:Merging_Plugins"); + } break; default: { return tr("Description missing"); } break; @@ -3195,6 +3238,7 @@ void MainWindow::syncOverwrite() modInfo->testValid(); refreshDirectoryStructure(); } + } void MainWindow::createModFromOverwrite() diff --git a/src/mainwindow.h b/src/mainwindow.h index cf97d4f9..dfd2e571 100644 --- a/src/mainwindow.h +++ b/src/mainwindow.h @@ -98,7 +98,6 @@ public: void refreshBSAList(); void refreshDataTree(); void refreshSaveList(); - void refreshModList(); void setExecutablesList(const ExecutablesList &executablesList); @@ -135,11 +134,14 @@ public: virtual QString resolvePath(const QString &fileName) const; virtual QStringList listDirectories(const QString &directoryName) const; virtual QStringList findFiles(const QString &path, const std::function &filter) const; + virtual QList findFileInfos(const QString &path, const std::function &filter) const; + virtual MOBase::IDownloadManager *downloadManager(); virtual MOBase::IPluginList *pluginList(); virtual MOBase::IModList *modList(); virtual HANDLE startApplication(const QString &executable, const QStringList &args = QStringList(), const QString &cwd = "", const QString &profile = ""); virtual bool onAboutToRun(const std::function &func); + virtual void refreshModList(bool saveChanges = true); virtual std::vector activeProblems() const; virtual QString shortDescription(unsigned int key) const; @@ -274,6 +276,7 @@ private: private: static const unsigned int PROBLEM_PLUGINSNOTLOADED = 1; + static const unsigned int PROBLEM_TOOMANYPLUGINS = 2; private: diff --git a/src/moapplication.cpp b/src/moapplication.cpp index ba23808b..7e3104db 100644 --- a/src/moapplication.cpp +++ b/src/moapplication.cpp @@ -23,12 +23,15 @@ along with Mod Organizer. If not, see . #include #include #include +#include +#include MOApplication::MOApplication(int argc, char **argv) : QApplication(argc, argv) { connect(&m_StyleWatcher, SIGNAL(fileChanged(QString)), SLOT(updateStyle(QString))); + m_DefaultStyle = style()->objectName(); } @@ -42,11 +45,12 @@ bool MOApplication::setStyleFile(const QString &styleName) // set new stylesheet or clear it if (styleName.length() != 0) { QString styleSheetName = applicationDirPath() + "/" + MOBase::ToQString(AppConfig::stylesheetsPath()) + "/" + styleName; - if (!QFile::exists(styleSheetName)) { - return false; + if (QFile::exists(styleSheetName)) { + m_StyleWatcher.addPath(styleSheetName); + updateStyle(styleSheetName); + } else { + updateStyle(styleName); } - m_StyleWatcher.addPath(styleSheetName); - updateStyle(styleSheetName); } else { setStyleSheet(""); } @@ -74,11 +78,18 @@ bool MOApplication::notify(QObject *receiver, QEvent *event) void MOApplication::updateStyle(const QString &fileName) { - QFile file(fileName); - if (file.open(QFile::ReadOnly)) { - setStyleSheet(file.readAll()); + if (fileName == "Plastique") { + setStyle(new QPlastiqueStyle); + setStyleSheet(""); + } else if (fileName == "Cleanlooks") { + setStyle(new QCleanlooksStyle); + setStyleSheet(""); } else { - qDebug("no stylesheet"); + setStyle(m_DefaultStyle); + if (QFile::exists(fileName)) { + setStyleSheet(QString("file:///%1").arg(fileName)); + } else { + qWarning("invalid stylesheet: %s", qPrintable(fileName)); + } } - file.close(); } diff --git a/src/moapplication.h b/src/moapplication.h index dd7f5eab..645b9144 100644 --- a/src/moapplication.h +++ b/src/moapplication.h @@ -43,6 +43,8 @@ private slots: private: QFileSystemWatcher m_StyleWatcher; + QString m_DefaultStyle; + }; diff --git a/src/modinfodialog.ui b/src/modinfodialog.ui index 2fdbe5f3..d0039a95 100644 --- a/src/modinfodialog.ui +++ b/src/modinfodialog.ui @@ -209,7 +209,7 @@ 0 0 - 668 + 676 126 @@ -223,16 +223,7 @@ 0 - - 0 - - - 0 - - - 0 - - + 0 @@ -293,7 +284,7 @@ Most mods do not have optional esps, so chances are good you are looking at an e - + :/MO/gui/resources/go-up.png:/MO/gui/resources/go-up.png @@ -322,7 +313,7 @@ Most mods do not have optional esps, so chances are good you are looking at an e - + :/MO/gui/resources/go-down.png:/MO/gui/resources/go-down.png @@ -525,9 +516,9 @@ Most mods do not have optional esps, so chances are good you are looking at an e - + - + Primary Category @@ -542,7 +533,7 @@ Most mods do not have optional esps, so chances are good you are looking at an e - + :/MO/gui/resources/internet-web-browser.png:/MO/gui/resources/internet-web-browser.png @@ -634,7 +625,7 @@ p, li { white-space: pre-wrap; } - + :/MO/gui/refresh:/MO/gui/refresh @@ -660,7 +651,7 @@ p, li { white-space: pre-wrap; } <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> <html><head><meta name="qrichtext" content="1" /><style type="text/css"> p, li { white-space: pre-wrap; } -</style></head><body style=" font-family:'MS Shell Dlg 2'; font-size:7.8pt; font-weight:400; font-style:normal;"> +</style></head><body style=" font-family:'MS Shell Dlg 2'; font-size:8.25pt; font-weight:400; font-style:normal;"> <p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:8pt;"><br /></p> <p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:8pt;"><br /></p></body></html> @@ -696,7 +687,7 @@ p, li { white-space: pre-wrap; } Endorse - + :/MO/gui/icon_favorite:/MO/gui/icon_favorite @@ -791,8 +782,6 @@ p, li { white-space: pre-wrap; } - - - + diff --git a/src/modlist.cpp b/src/modlist.cpp index eac02372..b35d6ad2 100644 --- a/src/modlist.cpp +++ b/src/modlist.cpp @@ -186,7 +186,12 @@ QVariant ModList::data(const QModelIndex &modelIndex, int role) const return QVariant(); } } else if (column == COL_INSTALLTIME) { - return modInfo->creationTime(); + // display installation time for mods that can be updated + if (modInfo->canBeUpdated()) { + return modInfo->creationTime(); + } else { + return QVariant(); + } } else { return tr("invalid"); } diff --git a/src/modlist.h b/src/modlist.h index 8cab7f3e..cc5955d0 100644 --- a/src/modlist.h +++ b/src/modlist.h @@ -275,6 +275,10 @@ private: SignalModStateChanged m_ModStateChanged; + + // QAbstractItemModel interface + + // IModList interface }; #endif // MODLIST_H diff --git a/src/organizer.qbs b/src/organizer.qbs index fdfb914c..2b7f45fc 100644 --- a/src/organizer.qbs +++ b/src/organizer.qbs @@ -3,21 +3,41 @@ import qbs.base 1.0 Application { name: 'Organizer' - Depends { name: 'Qt.core' } - Depends { name: 'Qt.gui' } - Depends { name: 'Qt.network' } - Depends { name: 'Qt.declarative' } - Depends { name: 'UIBase' } + Depends { name: "Qt"; submodules: ["core", "gui", "network", "declarative"] } Depends { name: 'Shared' } + Depends { name: 'UIBase' } Depends { name: 'cpp' } - cpp.defines: [] - cpp.includePaths: [ '../shared', '../archive', '../uibase', qbs.getenv("BOOSTPATH") ] + cpp.defines: [ 'UNICODE', '_UNICODE' ] + cpp.libraryPaths: [ qbs.getenv('BOOSTPATH') + '/stage/lib' ] + cpp.includePaths: [ '../shared', '../archive', '../bsatk', '../esptk', '../uibase', qbs.getenv("BOOSTPATH") ] // '../bsatk', '../esptk', - files: [ - '*.cpp', - '*.h', - '*.ui' - ] + cpp.staticLibraries: [ 'shell32', 'user32', 'Version', 'shlwapi' ] + //LIBS += -lmo_shared -luibase -lshell32 -lole32 -luser32 -ladvapi32 -lgdi32 -lPsapi -lVersion -lbsatk -lshlwapi + + Group { + name: 'Headers' + files: [ '*.h' ] + } + + Group { + name: 'Sources' + files: [ '*.cpp' ] + } + + Group { + name: 'UI Files' + files: [ '*.ui' ] + } + + Group { + name: 'ESP Toolkit' + files: [ '../esptk/*.h', '../esptk/*.cpp' ] + } } + +// /nologo /c + + +// /Zi -GR -W3 diff --git a/src/pluginlist.cpp b/src/pluginlist.cpp index b0228849..8eeed76e 100644 --- a/src/pluginlist.cpp +++ b/src/pluginlist.cpp @@ -499,6 +499,17 @@ bool PluginList::saveLoadOrder(DirectoryEntry &directoryStructure) return true; } +int PluginList::enabledCount() const +{ + int enabled = 0; + foreach (auto info, m_ESPs) { + if (info.m_Enabled) { + ++enabled; + } + } + return enabled; +} + bool PluginList::isESPLocked(int index) const { return m_LockedOrder.find(m_ESPs.at(index).m_Name.toLower()) != m_LockedOrder.end(); @@ -713,6 +724,8 @@ QVariant PluginList::data(const QModelIndex &modelIndex, int role) const return QIcon(":/MO/gui/warning"); } else if (m_LockedOrder.find(m_ESPs[index].m_Name.toLower()) != m_LockedOrder.end()) { return QIcon(":/MO/gui/locked"); + } else if (m_ESPs[index].m_IsDummy && m_ESPs[index].m_Enabled) { + return QIcon(":/MO/gui/edit_clear"); } else { return QVariant(); } @@ -723,6 +736,8 @@ QVariant PluginList::data(const QModelIndex &modelIndex, int role) const if (m_ESPs[index].m_IsMaster) { result.setItalic(true); result.setWeight(QFont::Bold); + } else if (m_ESPs[index].m_IsDummy) { + result.setItalic(true); } return result; } else if (role == Qt::TextAlignmentRole) { @@ -744,6 +759,10 @@ QVariant PluginList::data(const QModelIndex &modelIndex, int role) const m_ESPs[index].m_MasterUnset.begin(), m_ESPs[index].m_MasterUnset.end(), std::inserter(enabledMasters, enabledMasters.end())); text += "
        " + tr("Enabled Masters") + ": " + SetJoin(enabledMasters, ", "); + if (m_ESPs[index].m_IsDummy) { + text += "
        This file is a dummy! It exists only so the bsa with the same name gets loaded. With MO you don't need this: " + "If you enable the archive with the same name in the \"Archive\" tab you can disable this plugin."; + } return text; } } else { @@ -1009,6 +1028,7 @@ PluginList::ESPInfo::ESPInfo(const QString &name, bool enabled, FILETIME time, c try { ESP::File file(ToWString(fullPath)); m_IsMaster = file.isMaster(); + m_IsDummy = file.isDummy(); std::set masters = file.masters(); for (auto iter = masters.begin(); iter != masters.end(); ++iter) { m_Masters.insert(QString(iter->c_str())); @@ -1016,5 +1036,6 @@ PluginList::ESPInfo::ESPInfo(const QString &name, bool enabled, FILETIME time, c } catch (const std::exception &e) { qCritical("failed to parse esp file %s: %s", qPrintable(fullPath), e.what()); m_IsMaster = false; + m_IsDummy = false; } } diff --git a/src/pluginlist.h b/src/pluginlist.h index 2af5a0df..2f1a3f5f 100644 --- a/src/pluginlist.h +++ b/src/pluginlist.h @@ -126,6 +126,12 @@ public: **/ bool saveLoadOrder(MOShared::DirectoryEntry &directoryStructure); + /** + * @return number of enabled plugins in the list + */ + int enabledCount() const; + + QString getName(int index) const { return m_ESPs.at(index).m_Name; } int getPriority(int index) const { return m_ESPs.at(index).m_Priority; } bool isESPLocked(int index) const; @@ -198,6 +204,7 @@ private: FILETIME m_Time; QString m_OriginName; bool m_IsMaster; + bool m_IsDummy; std::set m_Masters; mutable std::set m_MasterUnset; }; diff --git a/src/settings.cpp b/src/settings.cpp index 36a4f1f8..144049aa 100644 --- a/src/settings.cpp +++ b/src/settings.cpp @@ -422,6 +422,9 @@ void Settings::addLanguages(QComboBox *languageBox) void Settings::addStyles(QComboBox *styleBox) { styleBox->addItem("None", ""); + styleBox->addItem("Plastique", "Plastique"); + styleBox->addItem("Cleanlooks", "Cleanlooks"); + QDirIterator langIter(QCoreApplication::applicationDirPath() + "/" + ToQString(AppConfig::stylesheetsPath()), QStringList("*.qss"), QDir::Files); while (langIter.hasNext()) { langIter.next(); diff --git a/src/shared/shared.qbs b/src/shared/shared.qbs index 44b7539f..1fa471a0 100644 --- a/src/shared/shared.qbs +++ b/src/shared/shared.qbs @@ -1,16 +1,20 @@ import qbs.base 1.0 -Application { - name: 'Shared' +StaticLibrary { + name: { + print(qbs.getenv("BOOSTPATH") + "/stage/lib") + return 'Shared' + } Depends { name: 'cpp' } Depends { name: 'BSAToolkit' } cpp.defines: [] - cpp.libraryPaths: [ qbs.getenv("BOOSTPATH") ] - cpp.includePaths: [ 'bsatk', qbs.getenv("BOOSTPATH") ] + cpp.libraryPaths: [ qbs.getenv("BOOSTPATH") + "/stage/lib" ] + cpp.includePaths: [ '../bsatk', qbs.getenv("BOOSTPATH") ] files: [ '*.h', - '*.cpp' + '*.cpp', + '*.inc' ] } -- cgit v1.3.1 From 35c9fe3e98cd4a81b114b0d9acb24727465d94b3 Mon Sep 17 00:00:00 2001 From: Tannin Date: Thu, 19 Dec 2013 19:40:59 +0100 Subject: - bugfix: archive.dll could cause a crash, attempting to close an archive that failed to open - bugfix: upon changing categories the mappings of deleted categories wasn't cleaned up which could cause an error message - bugfix: the number of esps/esms that can be loaded is actually 255 not 256 since the save game counts too - bugfix: "visit on nexus" from the modinfo dialog also lead to the wrong url --- src/categories.cpp | 1 + src/mainwindow.cpp | 4 ++-- src/modinfodialog.cpp | 2 +- src/modlist.cpp | 3 ++- src/version.rc | 4 ++-- 5 files changed, 8 insertions(+), 6 deletions(-) (limited to 'src/modlist.cpp') diff --git a/src/categories.cpp b/src/categories.cpp index c084c238..27720829 100644 --- a/src/categories.cpp +++ b/src/categories.cpp @@ -103,6 +103,7 @@ CategoryFactory &CategoryFactory::instance() void CategoryFactory::reset() { m_Categories.clear(); + m_IDMap.clear(); addCategory(0, "None", MakeVector(2, 28, 87), 0); } diff --git a/src/mainwindow.cpp b/src/mainwindow.cpp index 3a543e0b..b9300d00 100644 --- a/src/mainwindow.cpp +++ b/src/mainwindow.cpp @@ -2203,7 +2203,7 @@ std::vector MainWindow::activeProblems() const if (m_UnloadedPlugins.size() != 0) { problems.push_back(PROBLEM_PLUGINSNOTLOADED); } - if (m_PluginList.enabledCount() > 256) { + if (m_PluginList.enabledCount() > 255) { problems.push_back(PROBLEM_TOOMANYPLUGINS); } return problems; @@ -2236,7 +2236,7 @@ QString MainWindow::fullDescription(unsigned int key) const return result; } break; case PROBLEM_TOOMANYPLUGINS: { - return tr("The game doesn't allow more than 256 active plugins (including the official ones) to be loaded. You have to disable some unused plugins or " + return tr("The game doesn't allow more than 255 active plugins (including the official ones) to be loaded. You have to disable some unused plugins or " "merge some plugins into one. You can find a guide here: http://wiki.step-project.com/Guide:Merging_Plugins"); } break; default: { diff --git a/src/modinfodialog.cpp b/src/modinfodialog.cpp index 521eea24..1da050ed 100644 --- a/src/modinfodialog.cpp +++ b/src/modinfodialog.cpp @@ -631,7 +631,7 @@ void ModInfoDialog::on_visitNexusLabel_linkActivated(const QString &link) void ModInfoDialog::linkClicked(const QUrl &url) { - if (url.toString().startsWith(ToQString(GameInfo::instance().getNexusPage()))) { + if (url.toString().startsWith(ToQString(GameInfo::instance().getNexusPage(false)))) { this->close(); emit nexusLinkActivated(url.toString()); } else { diff --git a/src/modlist.cpp b/src/modlist.cpp index b35d6ad2..7f09654d 100644 --- a/src/modlist.cpp +++ b/src/modlist.cpp @@ -171,7 +171,8 @@ QVariant ModList::data(const QModelIndex &modelIndex, int role) const CategoryFactory &categoryFactory = CategoryFactory::instance(); if (categoryFactory.categoryExists(category)) { try { - return categoryFactory.getCategoryName(categoryFactory.getCategoryIndex(category)); + int categoryIdx = categoryFactory.getCategoryIndex(category); + return categoryFactory.getCategoryName(categoryIdx); } catch (const std::exception &e) { qCritical("failed to retrieve category name: %s", e.what()); return QString(); diff --git a/src/version.rc b/src/version.rc index 811ee7ca..35ac56a4 100644 --- a/src/version.rc +++ b/src/version.rc @@ -1,7 +1,7 @@ #include "Winver.h" -#define VER_FILEVERSION 1,0,11,0 -#define VER_FILEVERSION_STR "1,0,11,0\0" +#define VER_FILEVERSION 1,0,12,0 +#define VER_FILEVERSION_STR "1,0,12,0\0" VS_VERSION_INFO VERSIONINFO FILEVERSION VER_FILEVERSION -- cgit v1.3.1 From 40d20ab294ad7afd4b5747b306e45d0f8712a386 Mon Sep 17 00:00:00 2001 From: Tannin Date: Thu, 16 Jan 2014 20:43:42 +0100 Subject: - added an about dialog - updated json library --- src/aboutdialog.cpp | 82 +++ src/aboutdialog.h | 69 ++ src/aboutdialog.ui | 295 +++++++++ src/downloadmanager.cpp | 1 - src/json.cpp | 1110 +++++++++++++++----------------- src/json.h | 298 +++------ src/logbuffer.cpp | 1 + src/mainwindow.cpp | 9 + src/mainwindow.h | 1 + src/modinfodialog.cpp | 3 - src/modlist.cpp | 2 +- src/nexusinterface.cpp | 5 +- src/organizer.pro | 16 +- src/resources/emblem-favorite - 64.png | Bin 0 -> 3710 bytes 14 files changed, 1087 insertions(+), 805 deletions(-) create mode 100644 src/aboutdialog.cpp create mode 100644 src/aboutdialog.h create mode 100644 src/aboutdialog.ui create mode 100644 src/resources/emblem-favorite - 64.png (limited to 'src/modlist.cpp') diff --git a/src/aboutdialog.cpp b/src/aboutdialog.cpp new file mode 100644 index 00000000..94e4e54c --- /dev/null +++ b/src/aboutdialog.cpp @@ -0,0 +1,82 @@ +/* +Copyright (C) 2014 Sebastian Herbord. All rights reserved. + +This file is part of Mod Organizer. + +Mod Organizer is free software: you can redistribute it and/or modify +it under the terms of the GNU General Public License as published by +the Free Software Foundation, either version 3 of the License, or +(at your option) any later version. + +Mod Organizer is distributed in the hope that it will be useful, +but WITHOUT ANY WARRANTY; without even the implied warranty of +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +GNU General Public License for more details. + +You should have received a copy of the GNU General Public License +along with Mod Organizer. If not, see . +*/ + + +#include "aboutdialog.h" +#include "ui_aboutdialog.h" +#include + + +AboutDialog::AboutDialog(const QString &version, QWidget *parent) + : QDialog(parent) + , ui(new Ui::AboutDialog) +{ + ui->setupUi(this); + + m_LicenseFiles[LICENSE_LGPL3] = "lgpl-3.0.txt"; + m_LicenseFiles[LICENSE_GPL3] = "gpl-3.0.txt"; + m_LicenseFiles[LICENSE_BSD3] = "bsd3.txt"; + m_LicenseFiles[LICENSE_BOOST] = "boost.txt"; + m_LicenseFiles[LICENSE_CCBY3] = "by-sa3.txt"; + m_LicenseFiles[LICENSE_ZLIB] = "zlib.txt"; + + addLicense("Qt 4.8.5", LICENSE_LGPL3); + addLicense("Qt Json", LICENSE_GPL3); + addLicense("Boost Library", LICENSE_BOOST); + addLicense("Tango Icon Theme", LICENSE_NONE); + addLicense("RRZE Icon Set", LICENSE_CCBY3); + addLicense("7-zip", LICENSE_LGPL3); + addLicense("ZLib", LICENSE_ZLIB); + addLicense("NIF File Format Library", LICENSE_BSD3); + + ui->nameLabel->setText(QString("%1 %2").arg(ui->nameLabel->text()).arg(version)); +#ifdef HGID + ui->revisionLabel->setText(ui->revisionLabel->text() + " " + HGID); +#else + ui->revisionLabel->setText(ui->revisionLabel->text() + " unknown"); +#endif +} + + +AboutDialog::~AboutDialog() +{ + delete ui; +} + + +void AboutDialog::addLicense(const QString &name, Licenses license) +{ + QListWidgetItem *item = new QListWidgetItem(name); + item->setData(Qt::UserRole, license); + ui->creditsList->addItem(item); +} + + +void AboutDialog::on_creditsList_currentItemChanged(QListWidgetItem *current, QListWidgetItem*) +{ + auto iter = m_LicenseFiles.find(current->data(Qt::UserRole).toInt()); + if (iter != m_LicenseFiles.end()) { + QString filePath = qApp->applicationDirPath() + "/license/" + iter->second; +qDebug("%s", qPrintable(filePath)); + QString text = MOBase::readFileText(filePath); + ui->licenseText->setText(text); + } else { + ui->licenseText->setText(tr("No license")); + } +} diff --git a/src/aboutdialog.h b/src/aboutdialog.h new file mode 100644 index 00000000..9c0901a8 --- /dev/null +++ b/src/aboutdialog.h @@ -0,0 +1,69 @@ +#ifndef ABOUTDIALOG_H +/* +Copyright (C) 2014 Sebastian Herbord. All rights reserved. + +This file is part of Mod Organizer. + +Mod Organizer is free software: you can redistribute it and/or modify +it under the terms of the GNU General Public License as published by +the Free Software Foundation, either version 3 of the License, or +(at your option) any later version. + +Mod Organizer is distributed in the hope that it will be useful, +but WITHOUT ANY WARRANTY; without even the implied warranty of +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +GNU General Public License for more details. + +You should have received a copy of the GNU General Public License +along with Mod Organizer. If not, see . +*/ + + +#define ABOUTDIALOG_H + +#include +#include +#include +#include +#include + +namespace Ui { + class AboutDialog; +} + +class AboutDialog : public QDialog +{ + Q_OBJECT + +public: + explicit AboutDialog(const QString &version, QWidget *parent = 0); + ~AboutDialog(); + +private: + + enum Licenses { + LICENSE_NONE, + LICENSE_LGPL3, + LICENSE_GPL3, + LICENSE_BSD3, + LICENSE_BOOST, + LICENSE_CCBY3, + LICENSE_ZLIB + }; + +private: + + void addLicense(const QString &name, Licenses license); + +private slots: + void on_creditsList_currentItemChanged(QListWidgetItem *current, QListWidgetItem *previous); + +private: + + Ui::AboutDialog *ui; + + std::map m_LicenseFiles; + +}; + +#endif // ABOUTDIALOG_H diff --git a/src/aboutdialog.ui b/src/aboutdialog.ui new file mode 100644 index 00000000..985700db --- /dev/null +++ b/src/aboutdialog.ui @@ -0,0 +1,295 @@ + + + AboutDialog + + + + 0 + 0 + 508 + 335 + + + + About + + + + + + + + + + + + + :/MO/gui/mo_icon.ico + + + + + + + Qt::Vertical + + + + 20 + 40 + + + + + + + + + + 0 + + + + About + + + + + + Mod Organizer + + + + + + + Revision: + + + + + + + Qt::Vertical + + + + 20 + 40 + + + + + + + + Copyright 2011-2014 Sebastian Herbord + + + + + + + <html><head/><body><p>This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.</p><p>See the GNU General Public License for more details.</p></body></html> + + + true + + + + + + + + Used Software + + + + + + + + + + + + + Credits + + + + + + Translators + + + + + + QAbstractItemView::NoSelection + + + + pndrev (German) + + + + + DaWul (Spanish) + + + + + Fiama (Spanish) + + + + + Alyndiar (French) + + + + + Jlkawaii (French) + + + + + Rigoletto (French) + + + + + Scythe1912 (Chinese) + + + + + yc0620shen (Chinese) + + + + + miraclefreak (Czech) + + + + + tokcdk (Russian) + + + + + + + + + + + Others + + + + + + QAbstractItemView::NoSelection + + + + blacksol + + + + + DoubleYou + + + + + deathneko11 + + + + + Bridger + + + + + GSDFan + + + + + Uhuru + + + + + Wolverine2710 + + + + + z929669 + + + + + + + + + + + + + + + + + + + Qt::Horizontal + + + + 40 + 20 + + + + + + + + Close + + + + + + + + + + + + + closeButton + clicked() + AboutDialog + accept() + + + 460 + 313 + + + 253 + 167 + + + + + diff --git a/src/downloadmanager.cpp b/src/downloadmanager.cpp index fdc825f1..dd320f70 100644 --- a/src/downloadmanager.cpp +++ b/src/downloadmanager.cpp @@ -37,7 +37,6 @@ along with Mod Organizer. If not, see . #include -using QtJson::Json; using namespace MOBase; diff --git a/src/json.cpp b/src/json.cpp index 7bfaed39..ca2d728f 100644 --- a/src/json.cpp +++ b/src/json.cpp @@ -1,588 +1,522 @@ -/* Copyright 2011 Eeli Reilin. All rights reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions are met: - * - * 1. Redistributions of source code must retain the above copyright notice, - * this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright notice, - * this list of conditions and the following disclaimer in the documentation - * and/or other materials provided with the distribution. - * - * THIS SOFTWARE IS PROVIDED BY ''AS IS'' AND ANY EXPRESS OR - * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF - * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO - * EVENT SHALL EELI REILIN OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, - * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, - * OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF - * LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING - * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, - * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - * - * The views and conclusions contained in the software and documentation - * are those of the authors and should not be interpreted as representing - * official policies, either expressed or implied, of Eeli Reilin. - */ - -/** - * \file json.cpp - */ - -#include "json.h" -#include - -namespace QtJson -{ - - -static QString sanitizeString(QString str) -{ - str.replace(QLatin1String("\\"), QLatin1String("\\\\")); - str.replace(QLatin1String("\""), QLatin1String("\\\"")); - str.replace(QLatin1String("\b"), QLatin1String("\\b")); - str.replace(QLatin1String("\f"), QLatin1String("\\f")); - str.replace(QLatin1String("\n"), QLatin1String("\\n")); - str.replace(QLatin1String("\r"), QLatin1String("\\r")); - str.replace(QLatin1String("\t"), QLatin1String("\\t")); - return QString(QLatin1String("\"%1\"")).arg(str); -} - -static QByteArray join(const QList &list, const QByteArray &sep) -{ - QByteArray res; - Q_FOREACH(const QByteArray &i, list) - { - if(!res.isEmpty()) - { - res += sep; - } - res += i; - } - return res; -} - -/** - * parse - */ -QVariant Json::parse(const QString &json) -{ - bool success = true; - return Json::parse(json, success); -} - -/** - * parse - */ -QVariant Json::parse(const QString &json, bool &success) -{ - success = true; - - //Return an empty QVariant if the JSON data is either null or empty - if(!json.isNull() || !json.isEmpty()) - { - QString data = json; - //We'll start from index 0 - int index = 0; - - //Parse the first value - QVariant value = Json::parseValue(data, index, success); - - //Return the parsed value - return value; - } - else - { - //Return the empty QVariant - return QVariant(); - } -} - -QByteArray Json::serialize(const QVariant &data) -{ - bool success = true; - return Json::serialize(data, success); -} - -QByteArray Json::serialize(const QVariant &data, bool &success) -{ - QByteArray str; - success = true; - - if(!data.isValid()) // invalid or null? - { - str = "null"; - } - else if((data.type() == QVariant::List) || (data.type() == QVariant::StringList)) // variant is a list? - { - QList values; - const QVariantList list = data.toList(); - Q_FOREACH(const QVariant& v, list) - { - QByteArray serializedValue = serialize(v); - if(serializedValue.isNull()) - { - success = false; - break; - } - values << serializedValue; - } - - str = "[ " + join( values, ", " ) + " ]"; - } - else if(data.type() == QVariant::Map) // variant is a map? - { - const QVariantMap vmap = data.toMap(); - QMapIterator it( vmap ); - str = "{ "; - QList pairs; - while(it.hasNext()) - { - it.next(); - QByteArray serializedValue = serialize(it.value()); - if(serializedValue.isNull()) - { - success = false; - break; - } - pairs << sanitizeString(it.key()).toUtf8() + " : " + serializedValue; - } - str += join(pairs, ", "); - str += " }"; - } - else if((data.type() == QVariant::String) || (data.type() == QVariant::ByteArray)) // a string or a byte array? - { - str = sanitizeString(data.toString()).toUtf8(); - } - else if(data.type() == QVariant::Double) // double? - { - str = QByteArray::number(data.toDouble()); - if(!str.contains(".") && ! str.contains("e")) - { - str += ".0"; - } - } - else if (data.type() == QVariant::Bool) // boolean value? - { - str = data.toBool() ? "true" : "false"; - } - else if (data.type() == QVariant::ULongLong) // large unsigned number? - { - str = QByteArray::number(data.value()); - } - else if ( data.canConvert() ) // any signed number? - { - str = QByteArray::number(data.value()); - } - else if (data.canConvert()) - { - str = sanitizeString(QString::number(data.value())).toUtf8(); - } - else if (data.canConvert()) // can value be converted to string? - { - // this will catch QDate, QDateTime, QUrl, ... - str = sanitizeString(data.toString()).toUtf8(); - } - else - { - success = false; - } - if (success) - { - return str; - } - else - { - return QByteArray(); - } -} - -/** - * parseValue - */ -QVariant Json::parseValue(const QString &json, int &index, bool &success) -{ - //Determine what kind of data we should parse by - //checking out the upcoming token - switch(Json::lookAhead(json, index)) - { - case JsonTokenString: - return Json::parseString(json, index, success); - case JsonTokenNumber: - return Json::parseNumber(json, index); - case JsonTokenCurlyOpen: - return Json::parseObject(json, index, success); - case JsonTokenSquaredOpen: - return Json::parseArray(json, index, success); - case JsonTokenTrue: - Json::nextToken(json, index); - return QVariant(true); - case JsonTokenFalse: - Json::nextToken(json, index); - return QVariant(false); - case JsonTokenNull: - Json::nextToken(json, index); - return QVariant(); - case JsonTokenNone: - break; - } - - //If there were no tokens, flag the failure and return an empty QVariant - success = false; - return QVariant(); -} - -/** - * parseObject - */ -QVariant Json::parseObject(const QString &json, int &index, bool &success) -{ - QVariantMap map; - int token; - - //Get rid of the whitespace and increment index - Json::nextToken(json, index); - - //Loop through all of the key/value pairs of the object - bool done = false; - while(!done) - { - //Get the upcoming token - token = Json::lookAhead(json, index); - - if(token == JsonTokenNone) - { - success = false; - return QVariantMap(); - } - else if(token == JsonTokenComma) - { - Json::nextToken(json, index); - } - else if(token == JsonTokenCurlyClose) - { - Json::nextToken(json, index); - return map; - } - else - { - //Parse the key/value pair's name - QString name = Json::parseString(json, index, success).toString(); - - if(!success) - { - return QVariantMap(); - } - - //Get the next token - token = Json::nextToken(json, index); - - //If the next token is not a colon, flag the failure - //return an empty QVariant - if(token != JsonTokenColon) - { - success = false; - return QVariant(QVariantMap()); - } - - //Parse the key/value pair's value - QVariant value = Json::parseValue(json, index, success); - - if(!success) - { - return QVariantMap(); - } - - //Assign the value to the key in the map - map[name] = value; - } - } - - //Return the map successfully - return QVariant(map); -} - -/** - * parseArray - */ -QVariant Json::parseArray(const QString &json, int &index, bool &success) -{ - QVariantList list; - - Json::nextToken(json, index); - - bool done = false; - while(!done) - { - int token = Json::lookAhead(json, index); - - if(token == JsonTokenNone) - { - success = false; - return QVariantList(); - } - else if(token == JsonTokenComma) - { - Json::nextToken(json, index); - } - else if(token == JsonTokenSquaredClose) - { - Json::nextToken(json, index); - break; - } - else - { - QVariant value = Json::parseValue(json, index, success); - - if(!success) - { - return QVariantList(); - } - - list.push_back(value); - } - } - - return QVariant(list); -} - -/** - * parseString - */ -QVariant Json::parseString(const QString &json, int &index, bool &success) -{ - QString s; - QChar c; - - Json::eatWhitespace(json, index); - - c = json[index++]; - - bool complete = false; - while(!complete) - { - if(index == json.size()) - { - break; - } - - c = json[index++]; - - if(c == '\"') - { - complete = true; - break; - } - else if(c == '\\') - { - if(index == json.size()) - { - break; - } - - c = json[index++]; - - if(c == '\"') - { - s.append('\"'); - } - else if(c == '\\') - { - s.append('\\'); - } - else if(c == '/') - { - s.append('/'); - } - else if(c == 'b') - { - s.append('\b'); - } - else if(c == 'f') - { - s.append('\f'); - } - else if(c == 'n') - { - s.append('\n'); - } - else if(c == 'r') - { - s.append('\r'); - } - else if(c == 't') - { - s.append('\t'); - } - else if(c == 'u') - { - int remainingLength = json.size() - index; - - if(remainingLength >= 4) - { - QString unicodeStr = json.mid(index, 4); - - int symbol = unicodeStr.toInt(0, 16); - - s.append(QChar(symbol)); - - index += 4; - } - else - { - break; - } - } - } - else - { - s.append(c); - } - } - - if(!complete) - { - success = false; - return QVariant(); - } - - return QVariant(s); -} - -/** - * parseNumber - */ -QVariant Json::parseNumber(const QString &json, int &index) -{ - Json::eatWhitespace(json, index); - - int lastIndex = Json::lastIndexOfNumber(json, index); - int charLength = (lastIndex - index) + 1; - QString numberStr; - - numberStr = json.mid(index, charLength); - - index = lastIndex + 1; - - if (numberStr.contains('.')) { - return QVariant(numberStr.toDouble(NULL)); - } else if (numberStr.startsWith('-')) { - return QVariant(numberStr.toLongLong(NULL)); - } else { - return QVariant(numberStr.toULongLong(NULL)); - } -} - -/** - * lastIndexOfNumber - */ -int Json::lastIndexOfNumber(const QString &json, int index) -{ - int lastIndex; - - for(lastIndex = index; lastIndex < json.size(); lastIndex++) - { - if(QString("0123456789+-.eE").indexOf(json[lastIndex]) == -1) - { - break; - } - } - - return lastIndex -1; -} - -/** - * eatWhitespace - */ -void Json::eatWhitespace(const QString &json, int &index) -{ - for(; index < json.size(); index++) - { - if(QString(" \t\n\r").indexOf(json[index]) == -1) - { - break; - } - } -} - -/** - * lookAhead - */ -int Json::lookAhead(const QString &json, int index) -{ - int saveIndex = index; - return Json::nextToken(json, saveIndex); -} - -/** - * nextToken - */ -int Json::nextToken(const QString &json, int &index) -{ - Json::eatWhitespace(json, index); - - if(index == json.size()) - { - return JsonTokenNone; - } - - QChar c = json[index]; - index++; - switch(c.toLatin1()) - { - case '{': return JsonTokenCurlyOpen; - case '}': return JsonTokenCurlyClose; - case '[': return JsonTokenSquaredOpen; - case ']': return JsonTokenSquaredClose; - case ',': return JsonTokenComma; - case '"': return JsonTokenString; - case '0': case '1': case '2': case '3': case '4': - case '5': case '6': case '7': case '8': case '9': - case '-': return JsonTokenNumber; - case ':': return JsonTokenColon; - } - - index--; - - int remainingLength = json.size() - index; - - //True - if(remainingLength >= 4) - { - if (json[index] == 't' && json[index + 1] == 'r' && - json[index + 2] == 'u' && json[index + 3] == 'e') - { - index += 4; - return JsonTokenTrue; - } - } - - //False - if (remainingLength >= 5) - { - if (json[index] == 'f' && json[index + 1] == 'a' && - json[index + 2] == 'l' && json[index + 3] == 's' && - json[index + 4] == 'e') - { - index += 5; - return JsonTokenFalse; - } - } - - //Null - if (remainingLength >= 4) - { - if (json[index] == 'n' && json[index + 1] == 'u' && - json[index + 2] == 'l' && json[index + 3] == 'l') - { - index += 4; - return JsonTokenNull; - } - } - - return JsonTokenNone; -} - - -} //end namespace +/** + * QtJson - A simple class for parsing JSON data into a QVariant hierarchies and vice-versa. + * Copyright (C) 2011 Eeli Reilin + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 3 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +/** + * \file json.cpp + */ + +#include "json.h" + +namespace QtJson { + static QString sanitizeString(QString str); + static QByteArray join(const QList &list, const QByteArray &sep); + static QVariant parseValue(const QString &json, int &index, bool &success); + static QVariant parseObject(const QString &json, int &index, bool &success); + static QVariant parseArray(const QString &json, int &index, bool &success); + static QVariant parseString(const QString &json, int &index, bool &success); + static QVariant parseNumber(const QString &json, int &index); + static int lastIndexOfNumber(const QString &json, int index); + static void eatWhitespace(const QString &json, int &index); + static int lookAhead(const QString &json, int index); + static int nextToken(const QString &json, int &index); + + template + QByteArray serializeMap(const T &map, bool &success) { + QByteArray str = "{ "; + QList pairs; + for (typename T::const_iterator it = map.begin(), itend = map.end(); it != itend; ++it) { + QByteArray serializedValue = serialize(it.value()); + if (serializedValue.isNull()) { + success = false; + break; + } + pairs << sanitizeString(it.key()).toUtf8() + " : " + serializedValue; + } + + str += join(pairs, ", "); + str += " }"; + return str; + } + + + /** + * parse + */ + QVariant parse(const QString &json) { + bool success = true; + return parse(json, success); + } + + /** + * parse + */ + QVariant parse(const QString &json, bool &success) { + success = true; + + // Return an empty QVariant if the JSON data is either null or empty + if (!json.isNull() || !json.isEmpty()) { + QString data = json; + // We'll start from index 0 + int index = 0; + + // Parse the first value + QVariant value = parseValue(data, index, success); + + // Return the parsed value + return value; + } else { + // Return the empty QVariant + return QVariant(); + } + } + + QByteArray serialize(const QVariant &data) { + bool success = true; + return serialize(data, success); + } + + QByteArray serialize(const QVariant &data, bool &success) { + QByteArray str; + success = true; + + if (!data.isValid()) { // invalid or null? + str = "null"; + } else if ((data.type() == QVariant::List) || + (data.type() == QVariant::StringList)) { // variant is a list? + QList values; + const QVariantList list = data.toList(); + Q_FOREACH(const QVariant& v, list) { + QByteArray serializedValue = serialize(v); + if (serializedValue.isNull()) { + success = false; + break; + } + values << serializedValue; + } + + str = "[ " + join( values, ", " ) + " ]"; + } else if (data.type() == QVariant::Hash) { // variant is a hash? + str = serializeMap<>(data.toHash(), success); + } else if (data.type() == QVariant::Map) { // variant is a map? + str = serializeMap<>(data.toMap(), success); + } else if ((data.type() == QVariant::String) || + (data.type() == QVariant::ByteArray)) {// a string or a byte array? + str = sanitizeString(data.toString()).toUtf8(); + } else if (data.type() == QVariant::Double) { // double? + double value = data.toDouble(); + if ((value - value) == 0.0) { + str = QByteArray::number(value, 'g'); + if (!str.contains(".") && ! str.contains("e")) { + str += ".0"; + } + } else { + success = false; + } + } else if (data.type() == QVariant::Bool) { // boolean value? + str = data.toBool() ? "true" : "false"; + } else if (data.type() == QVariant::ULongLong) { // large unsigned number? + str = QByteArray::number(data.value()); + } else if (data.canConvert()) { // any signed number? + str = QByteArray::number(data.value()); + } else if (data.canConvert()) { //TODO: this code is never executed + str = QString::number(data.value()).toUtf8(); + } else if (data.canConvert()) { // can value be converted to string? + // this will catch QDate, QDateTime, QUrl, ... + str = sanitizeString(data.toString()).toUtf8(); + } else { + success = false; + } + + if (success) { + return str; + } else { + return QByteArray(); + } + } + + QString serializeStr(const QVariant &data) { + return QString::fromUtf8(serialize(data)); + } + + QString serializeStr(const QVariant &data, bool &success) { + return QString::fromUtf8(serialize(data, success)); + } + + + /** + * \enum JsonToken + */ + enum JsonToken { + JsonTokenNone = 0, + JsonTokenCurlyOpen = 1, + JsonTokenCurlyClose = 2, + JsonTokenSquaredOpen = 3, + JsonTokenSquaredClose = 4, + JsonTokenColon = 5, + JsonTokenComma = 6, + JsonTokenString = 7, + JsonTokenNumber = 8, + JsonTokenTrue = 9, + JsonTokenFalse = 10, + JsonTokenNull = 11 + }; + + static QString sanitizeString(QString str) { + str.replace(QLatin1String("\\"), QLatin1String("\\\\")); + str.replace(QLatin1String("\""), QLatin1String("\\\"")); + str.replace(QLatin1String("\b"), QLatin1String("\\b")); + str.replace(QLatin1String("\f"), QLatin1String("\\f")); + str.replace(QLatin1String("\n"), QLatin1String("\\n")); + str.replace(QLatin1String("\r"), QLatin1String("\\r")); + str.replace(QLatin1String("\t"), QLatin1String("\\t")); + return QString(QLatin1String("\"%1\"")).arg(str); + } + + static QByteArray join(const QList &list, const QByteArray &sep) { + QByteArray res; + Q_FOREACH(const QByteArray &i, list) { + if (!res.isEmpty()) { + res += sep; + } + res += i; + } + return res; + } + + /** + * parseValue + */ + static QVariant parseValue(const QString &json, int &index, bool &success) { + // Determine what kind of data we should parse by + // checking out the upcoming token + switch(lookAhead(json, index)) { + case JsonTokenString: + return parseString(json, index, success); + case JsonTokenNumber: + return parseNumber(json, index); + case JsonTokenCurlyOpen: + return parseObject(json, index, success); + case JsonTokenSquaredOpen: + return parseArray(json, index, success); + case JsonTokenTrue: + nextToken(json, index); + return QVariant(true); + case JsonTokenFalse: + nextToken(json, index); + return QVariant(false); + case JsonTokenNull: + nextToken(json, index); + return QVariant(); + case JsonTokenNone: + break; + } + + // If there were no tokens, flag the failure and return an empty QVariant + success = false; + return QVariant(); + } + + /** + * parseObject + */ + static QVariant parseObject(const QString &json, int &index, bool &success) { + QVariantMap map; + int token; + + // Get rid of the whitespace and increment index + nextToken(json, index); + + // Loop through all of the key/value pairs of the object + bool done = false; + while (!done) { + // Get the upcoming token + token = lookAhead(json, index); + + if (token == JsonTokenNone) { + success = false; + return QVariantMap(); + } else if (token == JsonTokenComma) { + nextToken(json, index); + } else if (token == JsonTokenCurlyClose) { + nextToken(json, index); + return map; + } else { + // Parse the key/value pair's name + QString name = parseString(json, index, success).toString(); + + if (!success) { + return QVariantMap(); + } + + // Get the next token + token = nextToken(json, index); + + // If the next token is not a colon, flag the failure + // return an empty QVariant + if (token != JsonTokenColon) { + success = false; + return QVariant(QVariantMap()); + } + + // Parse the key/value pair's value + QVariant value = parseValue(json, index, success); + + if (!success) { + return QVariantMap(); + } + + // Assign the value to the key in the map + map[name] = value; + } + } + + // Return the map successfully + return QVariant(map); + } + + /** + * parseArray + */ + static QVariant parseArray(const QString &json, int &index, bool &success) { + QVariantList list; + + nextToken(json, index); + + bool done = false; + while(!done) { + int token = lookAhead(json, index); + + if (token == JsonTokenNone) { + success = false; + return QVariantList(); + } else if (token == JsonTokenComma) { + nextToken(json, index); + } else if (token == JsonTokenSquaredClose) { + nextToken(json, index); + break; + } else { + QVariant value = parseValue(json, index, success); + if (!success) { + return QVariantList(); + } + list.push_back(value); + } + } + + return QVariant(list); + } + + /** + * parseString + */ + static QVariant parseString(const QString &json, int &index, bool &success) { + QString s; + QChar c; + + eatWhitespace(json, index); + + c = json[index++]; + + bool complete = false; + while(!complete) { + if (index == json.size()) { + break; + } + + c = json[index++]; + + if (c == '\"') { + complete = true; + break; + } else if (c == '\\') { + if (index == json.size()) { + break; + } + + c = json[index++]; + + if (c == '\"') { + s.append('\"'); + } else if (c == '\\') { + s.append('\\'); + } else if (c == '/') { + s.append('/'); + } else if (c == 'b') { + s.append('\b'); + } else if (c == 'f') { + s.append('\f'); + } else if (c == 'n') { + s.append('\n'); + } else if (c == 'r') { + s.append('\r'); + } else if (c == 't') { + s.append('\t'); + } else if (c == 'u') { + int remainingLength = json.size() - index; + if (remainingLength >= 4) { + QString unicodeStr = json.mid(index, 4); + + int symbol = unicodeStr.toInt(0, 16); + + s.append(QChar(symbol)); + + index += 4; + } else { + break; + } + } + } else { + s.append(c); + } + } + + if (!complete) { + success = false; + return QVariant(); + } + + return QVariant(s); + } + + /** + * parseNumber + */ + static QVariant parseNumber(const QString &json, int &index) { + eatWhitespace(json, index); + + int lastIndex = lastIndexOfNumber(json, index); + int charLength = (lastIndex - index) + 1; + QString numberStr; + + numberStr = json.mid(index, charLength); + + index = lastIndex + 1; + bool ok; + + if (numberStr.contains('.')) { + return QVariant(numberStr.toDouble(NULL)); + } else if (numberStr.startsWith('-')) { + int i = numberStr.toInt(&ok); + if (!ok) { + qlonglong ll = numberStr.toLongLong(&ok); + return ok ? ll : QVariant(numberStr); + } + return i; + } else { + uint u = numberStr.toUInt(&ok); + if (!ok) { + qulonglong ull = numberStr.toULongLong(&ok); + return ok ? ull : QVariant(numberStr); + } + return u; + } + } + + /** + * lastIndexOfNumber + */ + static int lastIndexOfNumber(const QString &json, int index) { + int lastIndex; + + for(lastIndex = index; lastIndex < json.size(); lastIndex++) { + if (QString("0123456789+-.eE").indexOf(json[lastIndex]) == -1) { + break; + } + } + + return lastIndex -1; + } + + /** + * eatWhitespace + */ + static void eatWhitespace(const QString &json, int &index) { + for(; index < json.size(); index++) { + if (QString(" \t\n\r").indexOf(json[index]) == -1) { + break; + } + } + } + + /** + * lookAhead + */ + static int lookAhead(const QString &json, int index) { + int saveIndex = index; + return nextToken(json, saveIndex); + } + + /** + * nextToken + */ + static int nextToken(const QString &json, int &index) { + eatWhitespace(json, index); + + if (index == json.size()) { + return JsonTokenNone; + } + + QChar c = json[index]; + index++; + switch(c.toLatin1()) { + case '{': return JsonTokenCurlyOpen; + case '}': return JsonTokenCurlyClose; + case '[': return JsonTokenSquaredOpen; + case ']': return JsonTokenSquaredClose; + case ',': return JsonTokenComma; + case '"': return JsonTokenString; + case '0': case '1': case '2': case '3': case '4': + case '5': case '6': case '7': case '8': case '9': + case '-': return JsonTokenNumber; + case ':': return JsonTokenColon; + } + index--; // ^ WTF? + + int remainingLength = json.size() - index; + + // True + if (remainingLength >= 4) { + if (json[index] == 't' && json[index + 1] == 'r' && + json[index + 2] == 'u' && json[index + 3] == 'e') { + index += 4; + return JsonTokenTrue; + } + } + + // False + if (remainingLength >= 5) { + if (json[index] == 'f' && json[index + 1] == 'a' && + json[index + 2] == 'l' && json[index + 3] == 's' && + json[index + 4] == 'e') { + index += 5; + return JsonTokenFalse; + } + } + + // Null + if (remainingLength >= 4) { + if (json[index] == 'n' && json[index + 1] == 'u' && + json[index + 2] == 'l' && json[index + 3] == 'l') { + index += 4; + return JsonTokenNull; + } + } + + return JsonTokenNone; + } +} //end namespace diff --git a/src/json.h b/src/json.h index d2cfa9a8..a61f6c85 100644 --- a/src/json.h +++ b/src/json.h @@ -1,204 +1,94 @@ -/* Copyright 2011 Eeli Reilin. All rights reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions are met: - * - * 1. Redistributions of source code must retain the above copyright notice, - * this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright notice, - * this list of conditions and the following disclaimer in the documentation - * and/or other materials provided with the distribution. - * - * THIS SOFTWARE IS PROVIDED BY ''AS IS'' AND ANY EXPRESS OR - * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF - * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO - * EVENT SHALL EELI REILIN OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, - * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, - * OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF - * LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING - * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, - * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - * - * The views and conclusions contained in the software and documentation - * are those of the authors and should not be interpreted as representing - * official policies, either expressed or implied, of Eeli Reilin. - */ - -/** - * \file json.h - */ - -#ifndef JSON_H -#define JSON_H - -#include -#include - -namespace QtJson -{ - -/** - * \enum JsonToken - */ -enum JsonToken -{ - JsonTokenNone = 0, - JsonTokenCurlyOpen = 1, - JsonTokenCurlyClose = 2, - JsonTokenSquaredOpen = 3, - JsonTokenSquaredClose = 4, - JsonTokenColon = 5, - JsonTokenComma = 6, - JsonTokenString = 7, - JsonTokenNumber = 8, - JsonTokenTrue = 9, - JsonTokenFalse = 10, - JsonTokenNull = 11 -}; - -/** - * \class Json - * \brief A JSON data parser - * - * Json parses a JSON data into a QVariant hierarchy. - */ -class Json -{ - public: - /** - * Parse a JSON string - * - * \param json The JSON data - */ - static QVariant parse(const QString &json); - - /** - * Parse a JSON string - * - * \param json The JSON data - * \param success The success of the parsing - */ - static QVariant parse(const QString &json, bool &success); - - /** - * This method generates a textual JSON representation - * - * \param data The JSON data generated by the parser. - * \param success The success of the serialization - */ - static QByteArray serialize(const QVariant &data); - - /** - * This method generates a textual JSON representation - * - * \param data The JSON data generated by the parser. - * \param success The success of the serialization - * - * \return QByteArray Textual JSON representation - */ - static QByteArray serialize(const QVariant &data, bool &success); - - private: - /** - * Parses a value starting from index - * - * \param json The JSON data - * \param index The start index - * \param success The success of the parse process - * - * \return QVariant The parsed value - */ - static QVariant parseValue(const QString &json, int &index, - bool &success); - - /** - * Parses an object starting from index - * - * \param json The JSON data - * \param index The start index - * \param success The success of the object parse - * - * \return QVariant The parsed object map - */ - static QVariant parseObject(const QString &json, int &index, - bool &success); - - /** - * Parses an array starting from index - * - * \param json The JSON data - * \param index The starting index - * \param success The success of the array parse - * - * \return QVariant The parsed variant array - */ - static QVariant parseArray(const QString &json, int &index, - bool &success); - - /** - * Parses a string starting from index - * - * \param json The JSON data - * \param index The starting index - * \param success The success of the string parse - * - * \return QVariant The parsed string - */ - static QVariant parseString(const QString &json, int &index, - bool &success); - - /** - * Parses a number starting from index - * - * \param json The JSON data - * \param index The starting index - * - * \return QVariant The parsed number - */ - static QVariant parseNumber(const QString &json, int &index); - - /** - * Get the last index of a number starting from index - * - * \param json The JSON data - * \param index The starting index - * - * \return The last index of the number - */ - static int lastIndexOfNumber(const QString &json, int index); - - /** - * Skip unwanted whitespace symbols starting from index - * - * \param json The JSON data - * \param index The start index - */ - static void eatWhitespace(const QString &json, int &index); - - /** - * Check what token lies ahead - * - * \param json The JSON data - * \param index The starting index - * - * \return int The upcoming token - */ - static int lookAhead(const QString &json, int index); - - /** - * Get the next JSON token - * - * \param json The JSON data - * \param index The starting index - * - * \return int The next JSON token - */ - static int nextToken(const QString &json, int &index); -}; - - -} //end namespace - -#endif //JSON_H +/** + * QtJson - A simple class for parsing JSON data into a QVariant hierarchies and vice-versa. + * Copyright (C) 2011 Eeli Reilin + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 3 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +/** + * \file json.h + */ + +#ifndef JSON_H +#define JSON_H + +#include +#include + + +/** + * \namespace QtJson + * \brief A JSON data parser + * + * Json parses a JSON data into a QVariant hierarchy. + */ +namespace QtJson { + typedef QVariantMap JsonObject; + typedef QVariantList JsonArray; + + /** + * Parse a JSON string + * + * \param json The JSON data + */ + QVariant parse(const QString &json); + + /** + * Parse a JSON string + * + * \param json The JSON data + * \param success The success of the parsing + */ + QVariant parse(const QString &json, bool &success); + + /** + * This method generates a textual JSON representation + * + * \param data The JSON data generated by the parser. + * + * \return QByteArray Textual JSON representation in UTF-8 + */ + QByteArray serialize(const QVariant &data); + + /** + * This method generates a textual JSON representation + * + * \param data The JSON data generated by the parser. + * \param success The success of the serialization + * + * \return QByteArray Textual JSON representation in UTF-8 + */ + QByteArray serialize(const QVariant &data, bool &success); + + /** + * This method generates a textual JSON representation + * + * \param data The JSON data generated by the parser. + * + * \return QString Textual JSON representation + */ + QString serializeStr(const QVariant &data); + + /** + * This method generates a textual JSON representation + * + * \param data The JSON data generated by the parser. + * \param success The success of the serialization + * + * \return QString Textual JSON representation + */ + QString serializeStr(const QVariant &data, bool &success); +} + +#endif //JSON_H diff --git a/src/logbuffer.cpp b/src/logbuffer.cpp index 6f3f640f..4f72e551 100644 --- a/src/logbuffer.cpp +++ b/src/logbuffer.cpp @@ -120,6 +120,7 @@ char LogBuffer::msgTypeID(QtMsgType type) case QtWarningMsg: return 'W'; case QtCriticalMsg: return 'C'; case QtFatalMsg: return 'F'; + default: return '?'; } } diff --git a/src/mainwindow.cpp b/src/mainwindow.cpp index 76bff3a0..14e27e76 100644 --- a/src/mainwindow.cpp +++ b/src/mainwindow.cpp @@ -56,6 +56,7 @@ along with Mod Organizer. If not, see . #include "savetextasdialog.h" #include "problemsdialog.h" #include "previewdialog.h" +#include "aboutdialog.h" #include #include #include @@ -547,6 +548,12 @@ bool MainWindow::checkForProblems() return false; } +void MainWindow::about() +{ + AboutDialog dialog(m_Updater.getVersion().displayString(), this); + dialog.exec(); +} + void MainWindow::createHelpWidget() { @@ -604,6 +611,8 @@ void MainWindow::createHelpWidget() } buttonMenu->addMenu(tutorialMenu); + buttonMenu->addAction(tr("About"), this, SLOT(about())); + buttonMenu->addAction(tr("About Qt"), qApp, SLOT(aboutQt())); } diff --git a/src/mainwindow.h b/src/mainwindow.h index 59bee7bb..e7b3f7e1 100644 --- a/src/mainwindow.h +++ b/src/mainwindow.h @@ -527,6 +527,7 @@ private slots: void refreshSavesIfOpen(); void expandDataTreeItem(QTreeWidgetItem *item); + void about(); private slots: // ui slots // actions diff --git a/src/modinfodialog.cpp b/src/modinfodialog.cpp index 7f221bdc..3657d48a 100644 --- a/src/modinfodialog.cpp +++ b/src/modinfodialog.cpp @@ -22,7 +22,6 @@ along with Mod Organizer. If not, see . #include "report.h" #include "utility.h" -#include "json.h" #include "messagedialog.h" #include "bbcode.h" #include "questionboxmemory.h" @@ -41,8 +40,6 @@ along with Mod Organizer. If not, see . #include -using QtJson::Json; - using namespace MOBase; using namespace MOShared; diff --git a/src/modlist.cpp b/src/modlist.cpp index 7f09654d..e2cb7cf0 100644 --- a/src/modlist.cpp +++ b/src/modlist.cpp @@ -305,7 +305,7 @@ QVariant ModList::data(const QModelIndex &modelIndex, int role) const return QString(); } } else if (column == COL_VERSION) { - QString text = tr("installed version: %1, newest version: %2").arg(modInfo->getVersion().displayString()).arg(modInfo->getNewestVersion().displayString()); + QString text = tr("installed version: \"%1\", newest version: \"%2\"").arg(modInfo->getVersion().displayString()).arg(modInfo->getNewestVersion().displayString()); if (modInfo->downgradeAvailable()) { text += "
        " + tr("The newest version on Nexus seems to be older than the one you have installed. This could either mean the version you have has been withdrawn " "(i.e. due to a bug) or the author uses a non-standard versioning scheme and that newest version is actually newer. " diff --git a/src/nexusinterface.cpp b/src/nexusinterface.cpp index 309915aa..6b87822a 100644 --- a/src/nexusinterface.cpp +++ b/src/nexusinterface.cpp @@ -20,14 +20,13 @@ along with Mod Organizer. If not, see . #include "nexusinterface.h" #include "nxmaccessmanager.h" #include "utility.h" -#include "json.h" +#include #include "selectiondialog.h" #include #include #include #include -using QtJson::Json; using namespace MOBase; using namespace MOShared; @@ -458,7 +457,7 @@ void NexusInterface::requestFinished(std::list::iterator iter) emit nxmRequestFailed(iter->m_ModID, iter->m_UserData, iter->m_ID, nexusError); } else { bool ok; - QVariant result = Json::parse(data, ok); + QVariant result = QtJson::parse(data, ok); if (result.isValid() && ok) { switch (iter->m_Type) { case NXMRequestInfo::TYPE_DESCRIPTION: { diff --git a/src/organizer.pro b/src/organizer.pro index dd745edb..fd72dea3 100644 --- a/src/organizer.pro +++ b/src/organizer.pro @@ -47,7 +47,6 @@ SOURCES += \ logbuffer.cpp \ lockeddialog.cpp \ loadmechanism.cpp \ - json.cpp \ installationmanager.cpp \ helper.cpp \ filedialogmemory.cpp \ @@ -80,7 +79,9 @@ SOURCES += \ ../esptk/subrecord.cpp \ noeditdelegate.cpp \ previewgenerator.cpp \ - previewdialog.cpp + previewdialog.cpp \ + aboutdialog.cpp \ + json.cpp HEADERS += \ @@ -116,7 +117,6 @@ HEADERS += \ logbuffer.h \ lockeddialog.h \ loadmechanism.h \ - json.h \ installationmanager.h \ helper.h \ filedialogmemory.h \ @@ -150,7 +150,9 @@ HEADERS += \ ../esptk/espexceptions.h \ noeditdelegate.h \ previewgenerator.h \ - previewdialog.h + previewdialog.h \ + aboutdialog.h \ + json.h FORMS += \ transfersavesdialog.ui \ @@ -180,7 +182,8 @@ FORMS += \ profileinputdialog.ui \ savetextasdialog.ui \ problemsdialog.ui \ - previewdialog.ui + previewdialog.ui \ + aboutdialog.ui INCLUDEPATH += ../shared ../archive ../uibase ../bsatk ../esptk "$(BOOSTPATH)" @@ -246,6 +249,9 @@ DEFINES += UNICODE _UNICODE _CRT_SECURE_NO_WARNINGS NOMINMAX DEFINES += BOOST_DISABLE_ASSERTS NDEBUG #DEFINES += QMLJSDEBUGGER +HGID = $$system(hg id -i) +DEFINES += HGID=\\\"$${HGID}\\\" + SRCDIR = $$PWD SRCDIR ~= s,/,$$QMAKE_DIR_SEP,g OUTDIR ~= s,/,$$QMAKE_DIR_SEP,g diff --git a/src/resources/emblem-favorite - 64.png b/src/resources/emblem-favorite - 64.png new file mode 100644 index 00000000..97b507ed Binary files /dev/null and b/src/resources/emblem-favorite - 64.png differ -- cgit v1.3.1 From c017f4a0d50b67a44e276bd5ae8929ed3990c62c Mon Sep 17 00:00:00 2001 From: Tannin Date: Sat, 5 Apr 2014 15:14:37 +0200 Subject: - added buttons to backup and restore the modlist and pluginlist - replaced boss integration with loot --- src/ModOrganizer.pro | 3 +- src/main.cpp | 23 +--- src/mainwindow.cpp | 204 ++++++++++++++++++++++++++++++++- src/mainwindow.h | 16 ++- src/mainwindow.ui | 112 +++++++++++++++++-- src/modlist.cpp | 2 +- src/pluginlist.cpp | 224 +------------------------------------ src/pluginlist.h | 83 +------------- src/profile.h | 6 +- src/resources.qrc | 3 + src/resources/arrange-boxes.png | Bin 0 -> 1634 bytes src/resources/document-save_32.png | Bin 0 -> 1971 bytes src/resources/edit-undo.png | Bin 0 -> 1601 bytes src/selectiondialog.cpp | 123 ++++++++++---------- src/selectiondialog.h | 96 ++++++++-------- src/shared/gameinfo.cpp | 8 ++ src/shared/gameinfo.h | 1 + src/spawn.cpp | 29 ++++- src/spawn.h | 8 +- 19 files changed, 486 insertions(+), 455 deletions(-) create mode 100644 src/resources/arrange-boxes.png create mode 100644 src/resources/document-save_32.png create mode 100644 src/resources/edit-undo.png (limited to 'src/modlist.cpp') diff --git a/src/ModOrganizer.pro b/src/ModOrganizer.pro index 05b05855..62de3f66 100644 --- a/src/ModOrganizer.pro +++ b/src/ModOrganizer.pro @@ -14,7 +14,8 @@ SUBDIRS = bsatk \ BossDummy \ pythonRunner \ boss_modified \ - esptk + esptk \ + loot_cli plugins.depends = pythonRunner hookdll.depends = shared diff --git a/src/main.cpp b/src/main.cpp index ac903615..d1c5e263 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -80,24 +80,6 @@ using namespace MOBase; using namespace MOShared; -void removeOldLogfiles() -{ - QFileInfoList files = QDir(ToQString(GameInfo::instance().getLogDir())).entryInfoList(QStringList("ModOrganizer*.log"), - QDir::Files, QDir::Name); - - if (files.count() > 5) { - QStringList deleteFiles; - for (int i = 0; i < files.count() - 5; ++i) { - deleteFiles.append(files.at(i).absoluteFilePath()); - } - - if (!shellDelete(deleteFiles)) { - qWarning("failed to remove log files: %s", qPrintable(windowsErrorString(::GetLastError()))); - } - } -} - - // set up required folders (for a first install or after an update or to fix a broken installation) bool bootstrap() { @@ -111,7 +93,7 @@ bool bootstrap() } // cycle logfile - removeOldLogfiles(); + removeOldFiles(ToQString(GameInfo::instance().getLogDir()), "ModOrganizer*.log", 5, QDir::Name); // create organizer directories QString dirNames[] = { @@ -120,8 +102,7 @@ bool bootstrap() QDir::fromNativeSeparators(ToQString(gameInfo.getDownloadDir())), QDir::fromNativeSeparators(ToQString(gameInfo.getOverwriteDir())), QDir::fromNativeSeparators(ToQString(gameInfo.getLogDir())), - QDir::fromNativeSeparators(ToQString(gameInfo.getTutorialDir())), - QDir::fromNativeSeparators(ToQString(gameInfo.getOrganizerDirectory()) + "/boss") + QDir::fromNativeSeparators(ToQString(gameInfo.getTutorialDir())) }; static const int NUM_DIRECTORIES = sizeof(dirNames) / sizeof(QString); diff --git a/src/mainwindow.cpp b/src/mainwindow.cpp index bf5ea7f0..87360f3c 100644 --- a/src/mainwindow.cpp +++ b/src/mainwindow.cpp @@ -109,8 +109,10 @@ along with Mod Organizer. If not, see . #include #endif #include +#include #include #include +#include #ifdef TEST_MODELS @@ -2649,7 +2651,6 @@ void MainWindow::directory_refreshed() delete oldStructure; refreshDataTree(); - refreshLists(); } else { // TODO: don't know why this happens, this slot seems to get called twice with only one emit return; @@ -5155,20 +5156,213 @@ void MainWindow::on_showHiddenBox_toggled(bool checked) m_DownloadManager.setShowHidden(checked); } + +void MainWindow::createStdoutPipe(HANDLE *stdOutRead, HANDLE *stdOutWrite) +{ + SECURITY_ATTRIBUTES secAttributes; + secAttributes.nLength = sizeof(SECURITY_ATTRIBUTES); + secAttributes.bInheritHandle = TRUE; + secAttributes.lpSecurityDescriptor = NULL; + + if (!::CreatePipe(stdOutRead, stdOutWrite, &secAttributes, 0)) { + qCritical("failed to create stdout reroute"); + } + + if (!::SetHandleInformation(*stdOutRead, HANDLE_FLAG_INHERIT, 0)) { + qCritical("failed to correctly set up the stdout reroute"); + *stdOutWrite = *stdOutRead = INVALID_HANDLE_VALUE; + } +} + +std::string MainWindow::readFromPipe(HANDLE stdOutRead) +{ + static const int chunkSize = 128; + std::string result; + + char buffer[chunkSize + 1]; + buffer[chunkSize] = '\0'; + + DWORD read = 1; + while (read > 0) { + if (!::ReadFile(stdOutRead, buffer, chunkSize, &read, NULL)) { + break; + } + if (read > 0) { + result.append(buffer, read); + if (read < chunkSize) { + break; + } + } + } + return result; +} + void MainWindow::on_bossButton_clicked() { try { this->setEnabled(false); ON_BLOCK_EXIT([&] () { this->setEnabled(true); }); - LockedDialog dialog(this, tr("BOSS working"), false); + QProgressDialog dialog(this); + dialog.setLabelText(tr("LOOT working")); + dialog.setMaximum(0); dialog.show(); - qApp->processEvents(); - m_PluginList.bossSort(); - savePluginList(); + QStringList parameters; + parameters << "--game" << ToQString(GameInfo::instance().getGameName()) + << "--gamePath" << ToQString(GameInfo::instance().getGameDirectory()); + + HANDLE stdOutWrite = INVALID_HANDLE_VALUE; + HANDLE stdOutRead = INVALID_HANDLE_VALUE; + createStdoutPipe(&stdOutRead, &stdOutWrite); + + HANDLE loot = startBinary(QFileInfo(qApp->applicationDirPath() + "/lootcli.exe"), + parameters.join(" "), + m_CurrentProfile->getName(), + m_Settings.logLevel(), + qApp->applicationDirPath(), + true, + stdOutWrite); + + // we don't use the write end + ::CloseHandle(stdOutWrite); + + if (loot != INVALID_HANDLE_VALUE) { + while (::WaitForSingleObject(loot, 100) == WAIT_TIMEOUT) { + // keep processing events so the app doesn't appear dead + QCoreApplication::processEvents(); + if (dialog.wasCanceled()) { + ::TerminateProcess(loot, 1); + } + std::string lootOut = readFromPipe(stdOutRead); + std::vector lines; + boost::split(lines, lootOut, boost::is_any_of("\r\n")); + foreach (const std::string &line, lines) { + if (line.length() > 0) { + size_t progidx = line.find("[progress]"); + size_t reportidx = line.find("[report]"); + if (progidx != std::string::npos) { + dialog.setLabelText(line.substr(progidx + 11).c_str()); + } else if (reportidx != std::string::npos) { + qDebug("report at %s", line.substr(reportidx + 9).c_str()); + } else { + qDebug("%s", line.c_str()); + } + } + } + } + std::string remainder = readFromPipe(stdOutRead).c_str(); + if (remainder.length() > 0) { + qDebug("%s", remainder.c_str()); + } + + refreshESPList(); + + if (GameInfo::instance().getLoadOrderMechanism() == GameInfo::TYPE_FILETIME) { + QFile::remove(m_CurrentProfile->getLoadOrderFileName()); + } + } + dialog.hide(); } catch (const std::exception &e) { reportError(tr("failed to run boss: %1").arg(e.what())); ui->bossButton->setEnabled(false); } } + + +const char *MainWindow::PATTERN_BACKUP_GLOB = ".????_??_??_??_??_??"; +const char *MainWindow::PATTERN_BACKUP_REGEX = "\\.(\\d\\d\\d\\d_\\d\\d_\\d\\d_\\d\\d_\\d\\d_\\d\\d)"; +const char *MainWindow::PATTERN_BACKUP_DATE = "yyyy_MM_dd_hh_mm_ss"; + + +bool MainWindow::createBackup(const QString &filePath, const QDateTime &time) +{ + QString outPath = filePath + "." + time.toString(PATTERN_BACKUP_DATE); + if (shellCopy(QStringList(filePath), QStringList(outPath), this)) { + QFileInfo fileInfo(filePath); + removeOldFiles(fileInfo.absolutePath(), fileInfo.fileName() + PATTERN_BACKUP_GLOB, 3, QDir::Name); + return true; + } else { + return false; + } +} + +void MainWindow::on_saveButton_clicked() +{ + savePluginList(); + QDateTime now = QDateTime::currentDateTime(); + if (createBackup(m_CurrentProfile->getPluginsFileName(), now) + && createBackup(m_CurrentProfile->getLoadOrderFileName(), now) + && createBackup(m_CurrentProfile->getLockedOrderFileName(), now)) { + MessageDialog::showMessage(tr("Backup of load order created"), this); + } +} + +QString MainWindow::queryRestore(const QString &filePath) +{ + QFileInfo pluginFileInfo(filePath); + QString pattern = pluginFileInfo.fileName() + ".*"; + QFileInfoList files = pluginFileInfo.absoluteDir().entryInfoList(QStringList(pattern), QDir::Files, QDir::Name); + + SelectionDialog dialog(tr("Choose backup to restore"), this); + QRegExp exp(pluginFileInfo.fileName() + PATTERN_BACKUP_REGEX); + QRegExp exp2(pluginFileInfo.fileName() + "\\.(.*)"); + foreach(const QFileInfo &info, files) { + if (exp.exactMatch(info.fileName())) { + QDateTime time = QDateTime::fromString(exp.cap(1), PATTERN_BACKUP_DATE); + dialog.addChoice(time.toString(), "", exp.cap(1)); + } else if (exp2.exactMatch(info.fileName())) { + dialog.addChoice(exp2.cap(1), "", exp2.cap(1)); + } + } + + if (dialog.numChoices() == 0) { + QMessageBox::information(this, tr("No Backups"), tr("There are no backups to restore")); + return QString(); + } + + if (dialog.exec() == QDialog::Accepted) { + return dialog.getChoiceData().toString(); + } else { + return QString(); + } +} + +void MainWindow::on_restoreButton_clicked() +{ + QString pluginName = m_CurrentProfile->getPluginsFileName(); + QString choice = queryRestore(pluginName); + if (!choice.isEmpty()) { + QString loadOrderName = m_CurrentProfile->getLoadOrderFileName(); + QString lockedName = m_CurrentProfile->getLockedOrderFileName(); + if (!shellCopy(pluginName + "." + choice, pluginName, true, this) || + !shellCopy(loadOrderName + "." + choice, loadOrderName, true, this) || + !shellCopy(lockedName + "." + choice, lockedName, true, this)) { + QMessageBox::critical(this, tr("Restore failed"), + tr("Failed to restore the backup. Errorcode: %1").arg(windowsErrorString(::GetLastError()))); + } + refreshESPList(); + } +} + +void MainWindow::on_saveModsButton_clicked() +{ + m_CurrentProfile->writeModlistNow(true); + QDateTime now = QDateTime::currentDateTime(); + if (createBackup(m_CurrentProfile->getModlistFileName(), now)) { + MessageDialog::showMessage(tr("Backup of modlist created"), this); + } +} +void MainWindow::on_restoreModsButton_clicked() +{ + QString modlistName = m_CurrentProfile->getModlistFileName(); + QString choice = queryRestore(modlistName); + if (!choice.isEmpty()) { + if (!shellCopy(modlistName + "." + choice, modlistName, true, this)) { + QMessageBox::critical(this, tr("Restore failed"), + tr("Failed to restore the backup. Errorcode: %1").arg(windowsErrorString(::GetLastError()))); + } + refreshModList(false); + } +} + diff --git a/src/mainwindow.h b/src/mainwindow.h index 23923677..c5b4a8d3 100644 --- a/src/mainwindow.h +++ b/src/mainwindow.h @@ -154,6 +154,8 @@ public: void saveArchiveList(); + void createStdoutPipe(HANDLE *stdOutRead, HANDLE *stdOutWrite); + std::string readFromPipe(HANDLE stdOutRead); public slots: void displayColumnSelection(const QPoint &pos); @@ -207,8 +209,6 @@ private: bool nexusLogin(); - void saveCurrentESPList(); - bool testForSteam(); void startSteam(); @@ -290,11 +290,18 @@ private: void activateProxy(bool activate); void installTranslator(const QString &name); + bool createBackup(const QString &filePath, const QDateTime &time); + QString queryRestore(const QString &filePath); + private: static const unsigned int PROBLEM_PLUGINSNOTLOADED = 1; static const unsigned int PROBLEM_TOOMANYPLUGINS = 2; + static const char *PATTERN_BACKUP_GLOB; + static const char *PATTERN_BACKUP_REGEX; + static const char *PATTERN_BACKUP_DATE; + private: Ui::MainWindow *ui; @@ -574,6 +581,11 @@ private slots: // ui slots void on_showHiddenBox_toggled(bool checked); void on_bsaList_itemChanged(QTreeWidgetItem *item, int column); void on_bossButton_clicked(); + + void on_saveButton_clicked(); + void on_restoreButton_clicked(); + void on_restoreModsButton_clicked(); + void on_saveModsButton_clicked(); }; #endif // MAINWINDOW_H diff --git a/src/mainwindow.ui b/src/mainwindow.ui index 26cbbf83..dc91121c 100644 --- a/src/mainwindow.ui +++ b/src/mainwindow.ui @@ -115,7 +115,7 @@ 2 - + @@ -170,6 +170,47 @@ p, li { white-space: pre-wrap; } + + + + Qt::Horizontal + + + + 40 + 20 + + + + + + + + Restore Backup... + + + + + + + :/MO/gui/restore:/MO/gui/restore + + + + + + + Create Backup + + + + + + + :/MO/gui/backup:/MO/gui/backup + + + @@ -617,6 +658,68 @@ p, li { white-space: pre-wrap; } 0 + + + + + + Sort + + + + :/MO/gui/sort:/MO/gui/sort + + + + + + + Qt::Horizontal + + + + 40 + 20 + + + + + + + + Restore Backup... + + + + + + + :/MO/gui/restore:/MO/gui/restore + + + + 16 + 16 + + + + + + + + Create Backup + + + + + + + :/MO/gui/backup:/MO/gui/backup + + + + + @@ -725,13 +828,6 @@ p, li { white-space: pre-wrap; } - - - - Sort - - - diff --git a/src/modlist.cpp b/src/modlist.cpp index e2cb7cf0..836406e4 100644 --- a/src/modlist.cpp +++ b/src/modlist.cpp @@ -669,7 +669,7 @@ bool ModList::dropURLs(const QMimeData *mimeData, int row, const QModelIndex &pa } if (source.count() != 0) { - shellMove(source, target, NULL); + shellMove(source, target); } return true; diff --git a/src/pluginlist.cpp b/src/pluginlist.cpp index af6f42da..1f4ed9b1 100644 --- a/src/pluginlist.cpp +++ b/src/pluginlist.cpp @@ -78,7 +78,6 @@ PluginList::PluginList(QObject *parent) : QAbstractItemModel(parent) , m_FontMetrics(QFont()) , m_SaveTimer(this) - , m_BOSS(NULL) { m_SaveTimer.setSingleShot(true); connect(&m_SaveTimer, SIGNAL(timeout()), this, SIGNAL(saveTimer())); @@ -95,11 +94,6 @@ PluginList::PluginList(QObject *parent) PluginList::~PluginList() { - if (m_BOSS != NULL) { - m_BOSS->CleanUpAPI(); - delete m_BOSS; - m_BOSS = NULL; - } } @@ -595,225 +589,9 @@ void PluginList::refreshLoadOrder() } -class boss_exception : public std::runtime_error { -public: - boss_exception(const std::string &message) : std::runtime_error(message) {} -}; - -#define THROW_BOSS_ERROR(obj) \ - uint8_t *message; \ - obj->GetLastErrorDetails(&message); \ - throw boss_exception(std::string(reinterpret_cast(message))); - -#define U8(text) reinterpret_cast(text) - - -void outputBossLog(const QString &filename) -{ - QFile file(filename); - if (file.open(QIODevice::ReadOnly)) { - while (!file.atEnd()) { - QByteArray line = file.readLine().trimmed(); - if (line.length() < 1) - continue; - - int endFirstWord = line.indexOf(':'); - if (endFirstWord < 0) { - endFirstWord = 0; - } - QString firstWord = line.mid(0, endFirstWord); - if (firstWord == "DEBUG") { - qDebug("(boss) %s", line.mid(endFirstWord + 2).constData()); - } else { - qWarning("(boss) %s", line.mid(endFirstWord + 2).constData()); - } - } - } - file.resize(0); -} - - -boss_db PluginList::initBoss() -{ - boss_db result; - bool firstRun = (m_BOSS == nullptr); - if (firstRun) { - m_BOSS = new BossDLL(TEXT("dlls\\boss.dll")); - - if (!m_BOSS->IsCompatibleVersion(2,1,1)) { - throw MyException(tr("BOSS dll incompatible")); - } - uint8_t *versionString; - if (m_BOSS->GetVersionString(&versionString) != BossDLL::RESULT_OK) { - THROW_BOSS_ERROR(m_BOSS) - } - qDebug("using boss version %s", versionString); - - m_TempFile.open(); m_TempFile.close(); // yeah, stupid, but open is required to generate the name - m_BOSS->SetLoggerOutput(m_TempFile.fileName().toLocal8Bit().constData(), 4); - } - - if (m_BOSS->CreateBossDb(&result, BossDLL::SKYRIM, NULL) != BossDLL::RESULT_OK) { - uint8_t *message; - m_BOSS->GetLastErrorDetails(&message); - std::string messageCopy(reinterpret_cast(message)); - delete m_BOSS; - m_BOSS = NULL; - throw boss_exception(messageCopy); - } - qApp->processEvents(); - - QString masterlistName = QDir::toNativeSeparators(qApp->applicationDirPath() + "/boss/masterlist.txt"); - - if (firstRun) { - uint32_t res = m_BOSS->UpdateMasterlist(result, U8(masterlistName.toUtf8().constData())); - qApp->processEvents(); - if (res == BossDLL::RESULT_OK) { - qDebug("boss masterlist updated"); - } else if (res == BossDLL::RESULT_NO_UPDATE_NECESSARY) { - qDebug("boss masterlist already up-to-date"); - } else { - THROW_BOSS_ERROR(m_BOSS) - } - } - if (m_BOSS->Load(result, - U8(masterlistName.toUtf8().constData()), - U8(QDir::toNativeSeparators(qApp->applicationDirPath() + "/boss/userlist.txt").toUtf8().constData())) != BossDLL::RESULT_OK) { - THROW_BOSS_ERROR(m_BOSS) - } - return result; -} - -void PluginList::convertPluginListForBoss(boss_db db, boost::ptr_vector &inputPlugins, std::vector &activePlugins) -{ - foreach (int idx, m_ESPsByPriority) { - QString fileName = m_ESPs[idx].m_Name; - QByteArray name = fileName.toUtf8(); - - uint8_t *nameU8 = new uint8_t[name.length() + 1]; - memcpy(nameU8, name.constData(), name.length() + 1); - if (m_ESPs[idx].m_Enabled) { - activePlugins.push_back(nameU8); - } - inputPlugins.push_back(nameU8); - } - if (m_BOSS->SetActivePluginsDumb(db, &activePlugins[0], activePlugins.size()) != BossDLL::RESULT_OK) { - THROW_BOSS_ERROR(m_BOSS) - } -} - -void PluginList::applyBOSSSorting(boss_db db, std::map &lockedLoadOrder, uint8_t **pluginList, size_t size, - int &priority, int &loadOrder, bool recognized, const char *extension) -{ - for (size_t i = 0; i < size; ++i) { - QString name = QString::fromUtf8(reinterpret_cast(pluginList[i])).toLower(); - if (name.endsWith(extension)) { - auto iter = m_ESPsByName.find(name); - if (iter == m_ESPsByName.end()) { - // boss seems to report plugins from userlist as sorted that aren't even installed - continue; - } - - BossMessage *message; - size_t numMessages = 0; - m_BOSS->GetPluginMessages(db, pluginList[i], &message, &numMessages); - BossInfo newInfo; - for (size_t im = 0; im < numMessages; ++im) { - newInfo.m_BOSSMessages.append(QString::fromUtf8(reinterpret_cast(message[im].message))); - } - newInfo.m_BOSSUnrecognized = !recognized; - m_BossInfo[name] = newInfo; - - // locked order plugins are not inserted by boss sorting ... - if (m_LockedOrder.find(name) != m_LockedOrder.end()) { - continue; - } - - // ... but by their enforced priority - while (lockedLoadOrder.find(loadOrder) != lockedLoadOrder.end()) { - auto lloIter = lockedLoadOrder.find(loadOrder); - auto nameIter = m_ESPsByName.find(lloIter->second); - if (nameIter != m_ESPsByName.end()) { - m_ESPs[nameIter->second].m_Priority = priority++; - if (m_ESPs[nameIter->second].m_Enabled) { - m_ESPs[nameIter->second].m_LoadOrder = loadOrder++; - } else { - m_ESPs[nameIter->second].m_LoadOrder = -1; - } - } - lockedLoadOrder.erase(lloIter); - } - - m_ESPs[iter->second].m_Priority = priority++; - if (m_ESPs[iter->second].m_Enabled) { - m_ESPs[iter->second].m_LoadOrder = loadOrder++; - } else { - m_ESPs[iter->second].m_LoadOrder = -1; - } - } - } -} - -void PluginList::bossSort() +void PluginList::lootSort() { - boss_db db = initBoss(); - ON_BLOCK_EXIT([&] { m_BOSS->DestroyBossDb(db); }); - - // create a boss-compatible representation of our current mod list. - boost::ptr_vector inputPlugins; - std::vector activePlugins; - convertPluginListForBoss(db, inputPlugins, activePlugins); - - // sort mods in-memory - uint8_t **sortedPlugins; - uint8_t **unrecognizedPlugins; - size_t sizeSorted, sizeUnrecognized; - if (m_BOSS->SortCustomMods(db, - inputPlugins.c_array(), inputPlugins.size(), - &sortedPlugins, &sizeSorted, - &unrecognizedPlugins, &sizeUnrecognized) != BossDLL::RESULT_OK) { - THROW_BOSS_ERROR(m_BOSS) - } - - // output the log from boss to our own log to make it visible - outputBossLog(m_TempFile.fileName()); - - qDebug("%d sorted, %d unrecognized", sizeSorted, sizeUnrecognized); - ChangeBracket layoutChange(this); - - std::map lockedLoadOrder; - std::for_each(m_LockedOrder.begin(), m_LockedOrder.end(), - [&lockedLoadOrder] (const std::pair &ele) { lockedLoadOrder[ele.second] = ele.first; }); - - int priority = 0; - int loadOrder = 0; - applyBOSSSorting(db, lockedLoadOrder, sortedPlugins, sizeSorted, priority, loadOrder, true, "esm"); - applyBOSSSorting(db, lockedLoadOrder, unrecognizedPlugins, sizeUnrecognized, priority, loadOrder, false, "esm"); - applyBOSSSorting(db, lockedLoadOrder, sortedPlugins, sizeSorted, priority, loadOrder, true, "esp"); - applyBOSSSorting(db, lockedLoadOrder, unrecognizedPlugins, sizeUnrecognized, priority, loadOrder, false, "esp"); - - // applyBOSSSorting removed entries from lockedLoadOrder when they were inserted so everything that's left is plugins - // locked to the end of the list. Now this inserts the rest in the ascending priority order. If the list is too short - // to place the plugins in their intended position then this guarantees plugins are kept in the correct relative order - // but it doesn't minimize the number of misplaced plugins. - for (auto iter = lockedLoadOrder.begin(); iter != lockedLoadOrder.end(); ++iter) { - auto nameIter = m_ESPsByName.find(iter->second); - if (nameIter != m_ESPsByName.end()) { - m_ESPs[nameIter->second].m_Priority = priority++; - if (m_ESPs[nameIter->second].m_Enabled) { - m_ESPs[nameIter->second].m_LoadOrder = loadOrder++; - } else { - m_ESPs[nameIter->second].m_LoadOrder = -1; - } - } - } - - // inform view of the changed data - updateIndices(); - layoutChange.finish(); - emit dataChanged(this->index(0, 0), this->index(m_ESPs.size(), columnCount())); - m_Refreshed(); } IPluginList::PluginState PluginList::state(const QString &name) const diff --git a/src/pluginlist.h b/src/pluginlist.h index fff2a595..5e8557e2 100644 --- a/src/pluginlist.h +++ b/src/pluginlist.h @@ -181,7 +181,7 @@ public: void refreshLoadOrder(); - void bossSort(); + void lootSort(); public: virtual PluginState state(const QString &name) const; @@ -204,7 +204,6 @@ public: // implementation of the QAbstractTableModel interface virtual QModelIndex index(int row, int column, const QModelIndex &parent = QModelIndex()) const; virtual QModelIndex parent(const QModelIndex &child) const; - void applyBOSSSorting(boss_db db, std::map &lockedLoadOrder, uint8_t **pluginList, size_t size, int &priority, int &loadOrder, bool recognized, const char *extension); public slots: /** @@ -260,82 +259,6 @@ private: friend bool ByDate(const ESPInfo& LHS, const ESPInfo& RHS); friend bool ByPriority(const ESPInfo& LHS, const ESPInfo& RHS); - class BossDLL : public PDLL { - DECLARE_CLASS(BossDLL) - - DECLARE_FUNCTION3(__cdecl, uint32_t, CreateBossDb, boss_db*, const uint32_t, const uint8_t*) - DECLARE_FUNCTION1(__cdecl, void, DestroyBossDb, boss_db) - DECLARE_FUNCTION0(__cdecl, void, CleanUpAPI) - - DECLARE_FUNCTION7(__cdecl, uint32_t, SortCustomMods, boss_db, uint8_t**, size_t, uint8_t***, size_t*, uint8_t***, size_t*) - DECLARE_FUNCTION3(__cdecl, uint32_t, SetActivePluginsDumb, boss_db, uint8_t**, const size_t) - - DECLARE_FUNCTION3(__cdecl, uint32_t, GetActivePluginsDumb , boss_db, uint8_t***, size_t*) - - DECLARE_FUNCTION2(__cdecl, uint32_t, UpdateMasterlist, boss_db, const uint8_t*) - DECLARE_FUNCTION3(__cdecl, uint32_t, Load, boss_db, const uint8_t*, const uint8_t*) - - DECLARE_FUNCTION2(__cdecl, void, SetLoggerOutput, const char*, uint8_t) - DECLARE_FUNCTION1(__cdecl, uint32_t, GetLastErrorDetails, uint8_t**) - - DECLARE_FUNCTION1(__cdecl, uint32_t, GetVersionString, uint8_t**) - DECLARE_FUNCTION3(__cdecl, bool, IsCompatibleVersion, const uint32_t, const uint32_t, const uint32_t) - - DECLARE_FUNCTION4(__cdecl, uint32_t, GetPluginMessages, boss_db, const uint8_t*, BossMessage**, size_t*) - - enum ResultCode { - RESULT_OK = 0, - RESULT_NO_MASTER_FILE = 1, - RESULT_FILE_READ_FAIL = 2, - RESULT_FILE_WRITE_FAIL = 3, - RESULT_FILE_NOT_UTF8 = 4, - RESULT_FILE_NOT_FOUND = 5, - RESULT_FILE_PARSE_FAIL = 6, - RESULT_CONDITION_EVAL_FAIL = 7, - RESULT_REGEX_EVAL_FAIL = 8, - RESULT_NO_GAME_DETECTED = 9, - RESULT_ENCODING_CONVERSION_FAIL = 10, - RESULT_FIND_ONLINE_MASTERLIST_REVISION_FAIL = 11, - RESULT_FIND_ONLINE_MASTERLIST_DATE_FAIL = 12, - RESULT_READ_UPDATE_FILE_LIST_FAIL = 13, - RESULT_FILE_CRC_MISMATCH = 14, - RESULT_FS_FILE_MOD_TIME_READ_FAIL = 15, - RESULT_FS_FILE_MOD_TIME_WRITE_FAIL = 16, - RESULT_FS_FILE_RENAME_FAIL = 17, - RESULT_FS_FILE_DELETE_FAIL = 18, - RESULT_FS_CREATE_DIRECTORY_FAIL = 19, - RESULT_FS_ITER_DIRECTORY_FAIL = 20, - RESULT_CURL_INIT_FAIL = 21, - RESULT_CURL_SET_ERRBUFF_FAIL = 22, - RESULT_CURL_SET_OPTION_FAIL = 23, - RESULT_CURL_SET_PROXY_FAIL = 24, - RESULT_CURL_SET_PROXY_TYPE_FAIL = 25, - RESULT_CURL_SET_PROXY_AUTH_FAIL = 26, - RESULT_CURL_SET_PROXY_AUTH_TYPE_FAIL = 27, - RESULT_CURL_PERFORM_FAIL = 28, - RESULT_CURL_USER_CANCEL = 29, - RESULT_GUI_WINDOW_INIT_FAIL = 30, - RESULT_NO_UPDATE_NECESSARY = 31, - RESULT_LO_MISMATCH = 32, - RESULT_NO_MEM = 33, - RESULT_INVALID_ARGS = 34, - RESULT_NETWORK_FAIL = 35, - RESULT_NO_INTERNET_CONNECTION = 36, - RESULT_NO_TAG_MAP = 37, - RESULT_PLUGINS_FULL = 38, - RESULT_PLUGIN_BEFORE_MASTER = 39, - RESULT_INVALID_SYNTAX = 40 - }; - - enum GameIDs { - AUTODETECT = 0, - OBLIVION = 1, - SKYRIM = 3, - FALLOUT3 = 4, - FALLOUTNV = 5 - }; - }; - private: void syncLoadOrder(); @@ -353,9 +276,6 @@ private: void testMasters(); - boss_db initBoss(); - void convertPluginListForBoss(boss_db db, boost::ptr_vector &inputPlugins, std::vector &activePlugins); - private: std::vector m_ESPs; @@ -381,7 +301,6 @@ private: SignalRefreshed m_Refreshed; - BossDLL *m_BOSS; QTemporaryFile m_TempFile; }; diff --git a/src/profile.h b/src/profile.h index 4960671a..5aa77357 100644 --- a/src/profile.h +++ b/src/profile.h @@ -159,6 +159,11 @@ public: */ QString getLockedOrderFileName() const; + /** + * @return the path of the modlist file in this profile + */ + QString getModlistFileName() const; + /** * @return path of the archives file in this profile */ @@ -301,7 +306,6 @@ private: void updateIndices(); - QString getModlistFileName() const; void copyFilesTo(QString &target) const; std::vector splitDZString(const wchar_t *buffer) const; diff --git a/src/resources.qrc b/src/resources.qrc index 73921f64..bf53ea95 100644 --- a/src/resources.qrc +++ b/src/resources.qrc @@ -52,5 +52,8 @@ resources/x-office-calendar.png resources/dialog-warning_16.png resources/mail-attachment.png + resources/document-save_32.png + resources/edit-undo.png + resources/arrange-boxes.png diff --git a/src/resources/arrange-boxes.png b/src/resources/arrange-boxes.png new file mode 100644 index 00000000..b1ab67cf Binary files /dev/null and b/src/resources/arrange-boxes.png differ diff --git a/src/resources/document-save_32.png b/src/resources/document-save_32.png new file mode 100644 index 00000000..db5c52b7 Binary files /dev/null and b/src/resources/document-save_32.png differ diff --git a/src/resources/edit-undo.png b/src/resources/edit-undo.png new file mode 100644 index 00000000..61b2ce9a Binary files /dev/null and b/src/resources/edit-undo.png differ diff --git a/src/selectiondialog.cpp b/src/selectiondialog.cpp index dbc10791..902b4d9c 100644 --- a/src/selectiondialog.cpp +++ b/src/selectiondialog.cpp @@ -17,62 +17,67 @@ You should have received a copy of the GNU General Public License along with Mod Organizer. If not, see . */ -#include "selectiondialog.h" -#include "ui_selectiondialog.h" - -#include - -SelectionDialog::SelectionDialog(const QString &description, QWidget *parent) - : QDialog(parent), ui(new Ui::SelectionDialog), m_Choice(NULL), m_ValidateByData(false) -{ - ui->setupUi(this); - - ui->descriptionLabel->setText(description); -} - -SelectionDialog::~SelectionDialog() -{ - delete ui; -} - - -void SelectionDialog::addChoice(const QString &buttonText, const QString &description, const QVariant &data) -{ - QCommandLinkButton *button = new QCommandLinkButton(buttonText, description, ui->buttonBox); - button->setProperty("data", data); - ui->buttonBox->addButton(button, QDialogButtonBox::AcceptRole); - if (data.isValid()) m_ValidateByData = true; -} - - -QVariant SelectionDialog::getChoiceData() -{ - return m_Choice->property("data"); -} - - -QString SelectionDialog::getChoiceString() -{ - if ((m_Choice == NULL) || - (m_ValidateByData && !m_Choice->property("data").isValid())) { - return QString(); - } else { - return m_Choice->text(); - } -} - - -void SelectionDialog::on_buttonBox_clicked(QAbstractButton *button) -{ - m_Choice = button; - if (!m_ValidateByData || m_Choice->property("data").isValid()) { - this->accept(); - } else { - this->reject(); - } -} - -void SelectionDialog::on_cancelButton_clicked() -{ - this->reject(); -} +#include "selectiondialog.h" +#include "ui_selectiondialog.h" + +#include + +SelectionDialog::SelectionDialog(const QString &description, QWidget *parent) + : QDialog(parent), ui(new Ui::SelectionDialog), m_Choice(NULL), m_ValidateByData(false) +{ + ui->setupUi(this); + + ui->descriptionLabel->setText(description); +} + +SelectionDialog::~SelectionDialog() +{ + delete ui; +} + + +void SelectionDialog::addChoice(const QString &buttonText, const QString &description, const QVariant &data) +{ + QCommandLinkButton *button = new QCommandLinkButton(buttonText, description, ui->buttonBox); + button->setProperty("data", data); + ui->buttonBox->addButton(button, QDialogButtonBox::AcceptRole); + if (data.isValid()) m_ValidateByData = true; +} + +int SelectionDialog::numChoices() const +{ + return ui->buttonBox->findChildren(QString()).count(); +} + + +QVariant SelectionDialog::getChoiceData() +{ + return m_Choice->property("data"); +} + + +QString SelectionDialog::getChoiceString() +{ + if ((m_Choice == NULL) || + (m_ValidateByData && !m_Choice->property("data").isValid())) { + return QString(); + } else { + return m_Choice->text(); + } +} + + +void SelectionDialog::on_buttonBox_clicked(QAbstractButton *button) +{ + m_Choice = button; + if (!m_ValidateByData || m_Choice->property("data").isValid()) { + this->accept(); + } else { + this->reject(); + } +} + +void SelectionDialog::on_cancelButton_clicked() +{ + this->reject(); +} diff --git a/src/selectiondialog.h b/src/selectiondialog.h index a2844e97..fc04291e 100644 --- a/src/selectiondialog.h +++ b/src/selectiondialog.h @@ -17,50 +17,52 @@ You should have received a copy of the GNU General Public License along with Mod Organizer. If not, see . */ -#ifndef SELECTIONDIALOG_H -#define SELECTIONDIALOG_H - -#include -#include - -namespace Ui { -class SelectionDialog; -} - -class SelectionDialog : public QDialog -{ - Q_OBJECT - -public: - - explicit SelectionDialog(const QString &description, QWidget *parent = 0); - - ~SelectionDialog(); - - /** - * @brief add a choice to the dialog - * @param buttonText the text to be displayed on the button - * @param description the description that shows up under in small letters inside the button - * @param data data to be stored with the button. Please note that as soon as one choice has data associated with it (non-invalid QVariant) - * all buttons that contain no data will be treated as "cancel" buttons - */ - void addChoice(const QString &buttonText, const QString &description, const QVariant &data); - - QVariant getChoiceData(); - QString getChoiceString(); - -private slots: - - void on_buttonBox_clicked(QAbstractButton *button); - - void on_cancelButton_clicked(); - -private: - - Ui::SelectionDialog *ui; - QAbstractButton *m_Choice; - bool m_ValidateByData; - -}; - -#endif // SELECTIONDIALOG_H +#ifndef SELECTIONDIALOG_H +#define SELECTIONDIALOG_H + +#include +#include + +namespace Ui { +class SelectionDialog; +} + +class SelectionDialog : public QDialog +{ + Q_OBJECT + +public: + + explicit SelectionDialog(const QString &description, QWidget *parent = 0); + + ~SelectionDialog(); + + /** + * @brief add a choice to the dialog + * @param buttonText the text to be displayed on the button + * @param description the description that shows up under in small letters inside the button + * @param data data to be stored with the button. Please note that as soon as one choice has data associated with it (non-invalid QVariant) + * all buttons that contain no data will be treated as "cancel" buttons + */ + void addChoice(const QString &buttonText, const QString &description, const QVariant &data); + + int numChoices() const; + + QVariant getChoiceData(); + QString getChoiceString(); + +private slots: + + void on_buttonBox_clicked(QAbstractButton *button); + + void on_cancelButton_clicked(); + +private: + + Ui::SelectionDialog *ui; + QAbstractButton *m_Choice; + bool m_ValidateByData; + +}; + +#endif // SELECTIONDIALOG_H diff --git a/src/shared/gameinfo.cpp b/src/shared/gameinfo.cpp index 00bb42fd..b580a226 100644 --- a/src/shared/gameinfo.cpp +++ b/src/shared/gameinfo.cpp @@ -172,6 +172,14 @@ std::wstring GameInfo::getLogDir() const } +std::wstring GameInfo::getLootDir() const +{ + std::wostringstream temp; + temp << m_OrganizerDirectory << "\\loot"; + return temp.str(); +} + + std::wstring GameInfo::getTutorialDir() const { std::wostringstream temp; diff --git a/src/shared/gameinfo.h b/src/shared/gameinfo.h index 10775e6c..89c9402d 100644 --- a/src/shared/gameinfo.h +++ b/src/shared/gameinfo.h @@ -113,6 +113,7 @@ public: virtual std::wstring getCacheDir() const; virtual std::wstring getOverwriteDir() const; virtual std::wstring getLogDir() const; + virtual std::wstring getLootDir() const; virtual std::wstring getTutorialDir() const; virtual bool requiresBSAInvalidation() const { return true; } diff --git a/src/spawn.cpp b/src/spawn.cpp index b1c5e963..6adafba0 100644 --- a/src/spawn.cpp +++ b/src/spawn.cpp @@ -36,10 +36,23 @@ using namespace MOShared; static const int BUFSIZE = 4096; -bool spawn(LPCWSTR binary, LPCWSTR arguments, LPCWSTR currentDirectory, bool suspended, HANDLE& processHandle, HANDLE& threadHandle) +bool spawn(LPCWSTR binary, LPCWSTR arguments, LPCWSTR currentDirectory, bool suspended, + HANDLE stdOut, HANDLE stdErr, + HANDLE& processHandle, HANDLE& threadHandle) { + BOOL inheritHandles = FALSE; STARTUPINFO si; ::ZeroMemory(&si, sizeof(si)); + if (stdOut != INVALID_HANDLE_VALUE) { + si.hStdOutput = stdOut; + inheritHandles = TRUE; + si.dwFlags |= STARTF_USESTDHANDLES; + } + if (stdErr != INVALID_HANDLE_VALUE) { + si.hStdError = stdErr; + inheritHandles = TRUE; + si.dwFlags |= STARTF_USESTDHANDLES; + } si.cb = sizeof(si); int length = wcslen(binary) + wcslen(arguments) + 4; wchar_t *commandLine = NULL; @@ -74,7 +87,7 @@ bool spawn(LPCWSTR binary, LPCWSTR arguments, LPCWSTR currentDirectory, bool sus BOOL success = ::CreateProcess(NULL, commandLine, NULL, NULL, // no special process or thread attributes - FALSE, // don't inherit handle + inheritHandles, // inherit handles if we plan to use stdout or stderr reroute suspended ? CREATE_SUSPENDED : 0, // create suspended so I have time to inject the DLL NULL, // same environment as parent currentDirectory, // current directory @@ -95,14 +108,22 @@ bool spawn(LPCWSTR binary, LPCWSTR arguments, LPCWSTR currentDirectory, bool sus } -HANDLE startBinary(const QFileInfo &binary, const QString &arguments, const QString& profileName, int logLevel, const QDir ¤tDirectory, bool hooked) +HANDLE startBinary(const QFileInfo &binary, + const QString &arguments, + const QString& profileName, + int logLevel, + const QDir ¤tDirectory, + bool hooked, + HANDLE stdOut, + HANDLE stdErr) { HANDLE processHandle, threadHandle; std::wstring binaryName = ToWString(QDir::toNativeSeparators(binary.absoluteFilePath())); std::wstring currentDirectoryName = ToWString(QDir::toNativeSeparators(currentDirectory.absolutePath())); try { - if (!spawn(binaryName.c_str(), ToWString(arguments).c_str(), currentDirectoryName.c_str(), hooked, processHandle, threadHandle)) { + if (!spawn(binaryName.c_str(), ToWString(arguments).c_str(), currentDirectoryName.c_str(), hooked, + stdOut, stdErr, processHandle, threadHandle)) { reportError(QObject::tr("failed to spawn \"%1\"").arg(binary.fileName())); return INVALID_HANDLE_VALUE; } diff --git a/src/spawn.h b/src/spawn.h index 48320fea..3f037119 100644 --- a/src/spawn.h +++ b/src/spawn.h @@ -52,11 +52,17 @@ private: * @param arguments arguments to pass to the binary * @param profileName name of the active profile * @param currentDirectory the directory to use as the working directory to run in + * @param logLevel log level to be used by the hook library. Ignored if hooked is false * @param hooked if set, the binary is started with mo injected + * @param stdout if not equal to INVALID_HANDLE_VALUE, this is used as stdout for the process + * @param stderr if not equal to INVALID_HANDLE_VALUE, this is used as stderr for the process * @return the process handle * @todo is the profile name even used any more? * @todo is the hooked parameter used? **/ -HANDLE startBinary(const QFileInfo &binary, const QString &arguments, const QString &profileName, int logLevel, const QDir ¤tDirectory, bool hooked); +HANDLE startBinary(const QFileInfo &binary, const QString &arguments, const QString &profileName, int logLevel, + const QDir ¤tDirectory, bool hooked, + HANDLE stdOut = INVALID_HANDLE_VALUE, HANDLE stdErr = INVALID_HANDLE_VALUE); #endif // SPAWN_H + -- cgit v1.3.1