summaryrefslogtreecommitdiffstats
path: root/logic/MinecraftVersion.h
diff options
context:
space:
mode:
authorPetr Mrázek <peterix@gmail.com>2013-09-16 00:54:39 +0200
committerPetr Mrázek <peterix@gmail.com>2013-09-16 00:54:39 +0200
commitd38b90530b3ba3a49c4eb072eb344ae2b0836913 (patch)
tree5dd07e59ae1bc8392a773ec8fec6b6a3aa7e4840 /logic/MinecraftVersion.h
parent7721c57e5e1093a3d8597b6b6f30c97d2aa3d8a5 (diff)
downloadMultiMC-d38b90530b3ba3a49c4eb072eb344ae2b0836913.tar
MultiMC-d38b90530b3ba3a49c4eb072eb344ae2b0836913.tar.gz
MultiMC-d38b90530b3ba3a49c4eb072eb344ae2b0836913.tar.lz
MultiMC-d38b90530b3ba3a49c4eb072eb344ae2b0836913.tar.xz
MultiMC-d38b90530b3ba3a49c4eb072eb344ae2b0836913.zip
Forge version list implementation. Needs integration and testing.
Diffstat (limited to 'logic/MinecraftVersion.h')
-rw-r--r--logic/MinecraftVersion.h29
1 files changed, 21 insertions, 8 deletions
diff --git a/logic/MinecraftVersion.h b/logic/MinecraftVersion.h
index 27977262..53c2f5ef 100644
--- a/logic/MinecraftVersion.h
+++ b/logic/MinecraftVersion.h
@@ -15,17 +15,16 @@
#pragma once
-#include "InstanceVersion.h"
+#include "BaseVersion.h"
#include <QStringList>
-struct MinecraftVersion : public InstVersion
+struct MinecraftVersion : public BaseVersion
{
- // From InstVersion:
- /*
- QString m_descriptor;
- QString m_name;
- qint64 m_timestamp;
- */
+ /*!
+ * Gets the version's timestamp.
+ * This is primarily used for sorting versions in a list.
+ */
+ qint64 timestamp;
/// The URL that this version will be downloaded from. maybe.
QString download_url;
@@ -44,6 +43,20 @@ struct MinecraftVersion : public InstVersion
/// is this a snapshot?
bool is_snapshot = false;
+ QString m_name;
+
+ QString m_descriptor;
+
+ virtual QString descriptor()
+ {
+ return m_descriptor;
+ }
+
+ virtual QString name()
+ {
+ return m_name;
+ }
+
virtual QString typeString() const
{
QStringList pre_final;