mirror of
https://github.com/amyinspace/MagicSetEditor2.git
synced 2026-06-10 21:06:59 -04:00
Fixed/hacked 'no parameter' for 0.2.7 keyword compatability;
Added 'just_header' flag to make stylesheet list load faster; Added versioning and dependency support to packages git-svn-id: svn://svn.code.sf.net/p/magicseteditor/code/trunk@320 0fc631ac-6414-0410-93d0-97cfa31319b6
This commit is contained in:
@@ -52,7 +52,7 @@ void PackageList::showData(const String& pattern) {
|
||||
while (!f.empty()) {
|
||||
// try to open the package
|
||||
// try {
|
||||
PackagedP package = ::packages.openAny(f);
|
||||
PackagedP package = ::packages.openAny(f, true);
|
||||
// open image
|
||||
InputStreamP stream = package->openIconFile();
|
||||
Image img;
|
||||
|
||||
@@ -41,6 +41,7 @@ class PackageList : public GalleryList {
|
||||
shared_ptr<T> getSelection() const {
|
||||
shared_ptr<T> ret = dynamic_pointer_cast<T>(packages.at(selection).package);
|
||||
if (!ret) throw InternalError(_("PackageList: Selected package has the wrong type"));
|
||||
ret->loadFully();
|
||||
return ret;
|
||||
}
|
||||
|
||||
|
||||
@@ -8,22 +8,38 @@
|
||||
|
||||
#include <gui/update_checker.hpp>
|
||||
#include <data/settings.hpp>
|
||||
#include <util/io/package_manager.hpp>
|
||||
#include <util/version.hpp>
|
||||
#include <script/value.hpp> // for some strange reason the profile build needs this :(
|
||||
#include <wx/dialup.h>
|
||||
#include <wx/url.h>
|
||||
#include <wx/html/htmlwin.h>
|
||||
|
||||
DECLARE_POINTER_TYPE(PackageVersionData);
|
||||
DECLARE_POINTER_TYPE(VersionData);
|
||||
|
||||
// ----------------------------------------------------------------------------- : Update data
|
||||
|
||||
/// Information on available packages
|
||||
class PackageVersionData {
|
||||
public:
|
||||
PackageVersionData() : is_installer(true) {}
|
||||
|
||||
String name; ///< Name of the package
|
||||
String description; ///< html description
|
||||
String url; ///< Where can the package be downloaded?
|
||||
bool is_installer; ///< Download url refers to a .mse-installer
|
||||
Version version; ///< Version number of the download
|
||||
vector<PackageDependencyP> depends; ///< Packages this depends on
|
||||
};
|
||||
|
||||
/// Information on the latest availible version
|
||||
class VersionData {
|
||||
public:
|
||||
Version version; ///< Latest version number
|
||||
String description; ///< html description
|
||||
Version version; ///< Latest version number of MSE
|
||||
String description; ///< html description of the latest MSE release
|
||||
String new_updates_url; ///< updates url has moved?
|
||||
vector<PackageVersionDataP> packages; ///< Available packages
|
||||
|
||||
DECLARE_REFLECTION();
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user