summaryrefslogtreecommitdiff
path: root/src/modinfo.h
diff options
context:
space:
mode:
authorSilarn <jrim@rimpo.org>2019-07-22 01:00:42 -0500
committerSilarn <jrim@rimpo.org>2019-07-22 01:00:42 -0500
commitdcd6d624672019727d7effd17aac86f72bff438b (patch)
tree1e8d3856f657d898c5992631599cf272d785f973 /src/modinfo.h
parent179a73857125ee604f42b0d5c2d765183c86d2c7 (diff)
parente73c309f08eff98f0dbd2590f594a83b67431eac (diff)
Merge branch 'Develop'
Diffstat (limited to 'src/modinfo.h')
-rw-r--r--src/modinfo.h29
1 files changed, 23 insertions, 6 deletions
diff --git a/src/modinfo.h b/src/modinfo.h
index f1d816fe..e395f45b 100644
--- a/src/modinfo.h
+++ b/src/modinfo.h
@@ -733,14 +733,31 @@ public:
virtual void doConflictCheck() const {}
/**
- * @brief set the URL for a mod
- */
- virtual void setURL(QString const &) {}
+ * @brief sets whether this mod uses a custom url
+ **/
+ virtual void setHasCustomURL(bool) {}
/**
- * @returns the URL for a mod
- */
- virtual QString getURL() const { return ""; }
+ * @brief returns whether this mod uses a custom url
+ **/
+ virtual bool hasCustomURL() const { return false; }
+
+ /**
+ * @brief sets the custom url
+ **/
+ virtual void setCustomURL(QString const &) {}
+
+ /**
+ * @brief returns the custom url
+ **/
+ virtual QString getCustomURL() const { return ""; }
+
+ /**
+ * If hasCustomURL() is true and getCustomURL() is not empty, tries to parse
+ * the url using QUrl::fromUserInput() and returns it. Otherwise, returns an
+ * empty QUrl.
+ **/
+ QUrl parseCustomURL() const;
signals: