summaryrefslogtreecommitdiffstats
path: root/application/InstancePageProvider.h
diff options
context:
space:
mode:
authorPetr Mrázek <peterix@gmail.com>2018-07-15 14:51:05 +0200
committerPetr Mrázek <peterix@gmail.com>2018-07-15 14:51:05 +0200
commitbbb3b3e6f6e3c0f95873f22e6d0a4aaf350f49d9 (patch)
treee6497e304b7b9368367565fbc7c06efab1124b1c /application/InstancePageProvider.h
parent03280cc62e75f8073f8d3d9e9e3952acf21fa77d (diff)
downloadMultiMC-bbb3b3e6f6e3c0f95873f22e6d0a4aaf350f49d9.tar
MultiMC-bbb3b3e6f6e3c0f95873f22e6d0a4aaf350f49d9.tar.gz
MultiMC-bbb3b3e6f6e3c0f95873f22e6d0a4aaf350f49d9.tar.lz
MultiMC-bbb3b3e6f6e3c0f95873f22e6d0a4aaf350f49d9.tar.xz
MultiMC-bbb3b3e6f6e3c0f95873f22e6d0a4aaf350f49d9.zip
NOISSUE tabs -> spaces
Diffstat (limited to 'application/InstancePageProvider.h')
-rw-r--r--application/InstancePageProvider.h98
1 files changed, 49 insertions, 49 deletions
diff --git a/application/InstancePageProvider.h b/application/InstancePageProvider.h
index ab0f9a72..d07b2ac2 100644
--- a/application/InstancePageProvider.h
+++ b/application/InstancePageProvider.h
@@ -21,57 +21,57 @@
class InstancePageProvider : public QObject, public BasePageProvider
{
- Q_OBJECT
+ Q_OBJECT
public:
- explicit InstancePageProvider(InstancePtr parent)
- {
- inst = parent;
- }
+ explicit InstancePageProvider(InstancePtr parent)
+ {
+ inst = parent;
+ }
- virtual ~InstancePageProvider() {};
- virtual QList<BasePage *> getPages() override
- {
- QList<BasePage *> values;
- values.append(new LogPage(inst));
- std::shared_ptr<MinecraftInstance> onesix = std::dynamic_pointer_cast<MinecraftInstance>(inst);
- if(onesix)
- {
- values.append(new VersionPage(onesix.get()));
- auto modsPage = new ModFolderPage(onesix.get(), onesix->loaderModList(), "mods", "loadermods", tr("Loader mods"), "Loader-mods");
- modsPage->setFilter("%1 (*.zip *.jar *.litemod)");
- values.append(modsPage);
- auto modsPage2 = new NewModFolderPage(onesix.get(), onesix->modsModel(), "newmods", "newloadermods", tr("New loader mods"), "New-loader-mods");
- modsPage2->setFilter("%1 (*.zip *.jar *.litemod)");
- values.append(modsPage2);
- values.append(new CoreModFolderPage(onesix.get(), onesix->coreModList(), "coremods", "coremods", tr("Core mods"), "Core-mods"));
- values.append(new ResourcePackPage(onesix.get()));
- values.append(new TexturePackPage(onesix.get()));
- values.append(new NotesPage(onesix.get()));
- values.append(new WorldListPage(onesix.get(), onesix->worldList(), "worlds", "worlds", tr("Worlds"), "Worlds"));
- values.append(new ServersPage(onesix.get()));
- values.append(new ScreenshotsPage(FS::PathCombine(onesix->minecraftRoot(), "screenshots")));
- values.append(new InstanceSettingsPage(onesix.get()));
- }
- std::shared_ptr<LegacyInstance> legacy = std::dynamic_pointer_cast<LegacyInstance>(inst);
- if(legacy)
- {
- values.append(new LegacyUpgradePage(legacy));
- values.append(new NotesPage(legacy.get()));
- values.append(new WorldListPage(legacy.get(), legacy->worldList(), "worlds", "worlds", tr("Worlds"), "Worlds"));
- values.append(new ScreenshotsPage(FS::PathCombine(legacy->minecraftRoot(), "screenshots")));
- }
- auto logMatcher = inst->getLogFileMatcher();
- if(logMatcher)
- {
- values.append(new OtherLogsPage(inst->getLogFileRoot(), logMatcher));
- }
- return values;
- }
+ virtual ~InstancePageProvider() {};
+ virtual QList<BasePage *> getPages() override
+ {
+ QList<BasePage *> values;
+ values.append(new LogPage(inst));
+ std::shared_ptr<MinecraftInstance> onesix = std::dynamic_pointer_cast<MinecraftInstance>(inst);
+ if(onesix)
+ {
+ values.append(new VersionPage(onesix.get()));
+ auto modsPage = new ModFolderPage(onesix.get(), onesix->loaderModList(), "mods", "loadermods", tr("Loader mods"), "Loader-mods");
+ modsPage->setFilter("%1 (*.zip *.jar *.litemod)");
+ values.append(modsPage);
+ auto modsPage2 = new NewModFolderPage(onesix.get(), onesix->modsModel(), "newmods", "newloadermods", tr("New loader mods"), "New-loader-mods");
+ modsPage2->setFilter("%1 (*.zip *.jar *.litemod)");
+ values.append(modsPage2);
+ values.append(new CoreModFolderPage(onesix.get(), onesix->coreModList(), "coremods", "coremods", tr("Core mods"), "Core-mods"));
+ values.append(new ResourcePackPage(onesix.get()));
+ values.append(new TexturePackPage(onesix.get()));
+ values.append(new NotesPage(onesix.get()));
+ values.append(new WorldListPage(onesix.get(), onesix->worldList(), "worlds", "worlds", tr("Worlds"), "Worlds"));
+ values.append(new ServersPage(onesix.get()));
+ values.append(new ScreenshotsPage(FS::PathCombine(onesix->minecraftRoot(), "screenshots")));
+ values.append(new InstanceSettingsPage(onesix.get()));
+ }
+ std::shared_ptr<LegacyInstance> legacy = std::dynamic_pointer_cast<LegacyInstance>(inst);
+ if(legacy)
+ {
+ values.append(new LegacyUpgradePage(legacy));
+ values.append(new NotesPage(legacy.get()));
+ values.append(new WorldListPage(legacy.get(), legacy->worldList(), "worlds", "worlds", tr("Worlds"), "Worlds"));
+ values.append(new ScreenshotsPage(FS::PathCombine(legacy->minecraftRoot(), "screenshots")));
+ }
+ auto logMatcher = inst->getLogFileMatcher();
+ if(logMatcher)
+ {
+ values.append(new OtherLogsPage(inst->getLogFileRoot(), logMatcher));
+ }
+ return values;
+ }
- virtual QString dialogTitle() override
- {
- return tr("Edit Instance (%1)").arg(inst->name());
- }
+ virtual QString dialogTitle() override
+ {
+ return tr("Edit Instance (%1)").arg(inst->name());
+ }
protected:
- InstancePtr inst;
+ InstancePtr inst;
};