mirror of
https://github.com/amyinspace/MagicSetEditor2.git
synced 2026-06-11 05:07:00 -04:00
Added installer code.
git-svn-id: svn://svn.code.sf.net/p/magicseteditor/code/trunk@561 0fc631ac-6414-0410-93d0-97cfa31319b6
This commit is contained in:
@@ -497,3 +497,11 @@ void Packaged::validate(Version) {
|
||||
packages.checkDependency(*dep, true);
|
||||
}
|
||||
}
|
||||
|
||||
// ----------------------------------------------------------------------------- : IncludePackage
|
||||
|
||||
String IncludePackage::typeName() const { return _("include"); }
|
||||
|
||||
IMPLEMENT_REFLECTION(IncludePackage) {
|
||||
REFLECT_BASE(Packaged);
|
||||
}
|
||||
+10
-1
@@ -171,8 +171,8 @@ class Package : public IntrusivePtrVirtualBase {
|
||||
void openDirectory();
|
||||
void openSubdir(const String&);
|
||||
void openZipfile();
|
||||
void saveToDirectory(const String&, bool);
|
||||
void saveToZipfile(const String&, bool);
|
||||
void saveToDirectory(const String&, bool);
|
||||
FileInfos::iterator addFile(const String& file);
|
||||
static String toStandardName(const String& file);
|
||||
};
|
||||
@@ -228,5 +228,14 @@ class Packaged : public Package {
|
||||
friend struct JustAsPackageProxy;
|
||||
};
|
||||
|
||||
// ----------------------------------------------------------------------------- : IncludePackage
|
||||
|
||||
/// A package that just contains a bunch of files that are used from other packages
|
||||
class IncludePackage : public Packaged {
|
||||
protected:
|
||||
String typeName() const;
|
||||
DECLARE_REFLECTION();
|
||||
};
|
||||
|
||||
// ----------------------------------------------------------------------------- : EOF
|
||||
#endif
|
||||
|
||||
@@ -15,21 +15,6 @@
|
||||
#include <data/export_template.hpp>
|
||||
#include <wx/stdpaths.h>
|
||||
|
||||
// ----------------------------------------------------------------------------- : IncludePackage
|
||||
|
||||
/// A package that just contains a bunch of files that are used from other packages
|
||||
class IncludePackage : public Packaged {
|
||||
protected:
|
||||
String typeName() const;
|
||||
DECLARE_REFLECTION();
|
||||
};
|
||||
|
||||
String IncludePackage::typeName() const { return _("include"); }
|
||||
|
||||
IMPLEMENT_REFLECTION(IncludePackage) {
|
||||
REFLECT_BASE(Packaged);
|
||||
}
|
||||
|
||||
// ----------------------------------------------------------------------------- : PackageManager
|
||||
|
||||
PackageManager packages;
|
||||
|
||||
@@ -70,6 +70,9 @@ class PackageManager {
|
||||
|
||||
/// Check if the given dependency is currently installed
|
||||
bool checkDependency(const PackageDependency& dep, bool report_errors = false);
|
||||
|
||||
inline String getGlobalDataDir() const { return global_data_directory; }
|
||||
inline String getLocalDataDir() const { return local_data_directory; }
|
||||
|
||||
private:
|
||||
map<String, PackagedP> loaded_packages;
|
||||
|
||||
Reference in New Issue
Block a user