From 32b3ed0a1362a4b0798ad71fac3450fb77cb7e41 Mon Sep 17 00:00:00 2001 From: Thomas Groman Date: Thu, 19 Sep 2019 00:41:48 -0700 Subject: merged from 0.6.7 codebase --- api/logic/BaseInstanceProvider.h | 57 ---------------------------------------- 1 file changed, 57 deletions(-) delete mode 100644 api/logic/BaseInstanceProvider.h (limited to 'api/logic/BaseInstanceProvider.h') diff --git a/api/logic/BaseInstanceProvider.h b/api/logic/BaseInstanceProvider.h deleted file mode 100644 index 34489c5d..00000000 --- a/api/logic/BaseInstanceProvider.h +++ /dev/null @@ -1,57 +0,0 @@ -#pragma once - -#include -#include -#include "BaseInstance.h" -#include "settings/SettingsObject.h" - -#include "multimc_logic_export.h" - -using InstanceId = QString; -using InstanceLocator = std::pair; - -enum class InstCreateError -{ - NoCreateError = 0, - NoSuchVersion, - UnknownCreateError, - InstExists, - CantCreateDir -}; - -class MULTIMC_LOGIC_EXPORT BaseInstanceProvider : public QObject -{ - Q_OBJECT -public: - BaseInstanceProvider(SettingsObjectPtr settings) : m_globalSettings(settings) - { - // nil - } -public: - virtual QList discoverInstances() = 0; - virtual InstancePtr loadInstance(const InstanceId &id) = 0; - virtual void loadGroupList() = 0; - virtual void saveGroupList() = 0; - - virtual QString getStagedInstancePath() - { - return QString(); - } - virtual bool commitStagedInstance(const QString & path, const QString& instanceName, const QString & groupName) - { - return false; - } - virtual bool destroyStagingPath(const QString & path) - { - return true; - } - -signals: - // Emit this when the list of provided instances changed - void instancesChanged(); - // Emit when the set of groups your provider supplies changes. - void groupsChanged(QSet groups); - -protected: - SettingsObjectPtr m_globalSettings; -}; -- cgit v1.2.3