From 9fb639a00e1a809a9ea9b5e68777ec46f534761c Mon Sep 17 00:00:00 2001 From: Mikaƫl Capelle Date: Sun, 24 May 2020 13:27:40 +0200 Subject: Update ModInfo to use a single file tree for all content-related operations. --- src/modinfo.h | 23 ++++++++--------------- 1 file changed, 8 insertions(+), 15 deletions(-) (limited to 'src/modinfo.h') diff --git a/src/modinfo.h b/src/modinfo.h index f582cc32..b3e75bc4 100644 --- a/src/modinfo.h +++ b/src/modinfo.h @@ -702,7 +702,7 @@ public: /** * @return true if this mod is considered "valid", that is: it contains data used by the game **/ - virtual bool isValid() const { return m_Valid; } + virtual bool isValid() const = 0; /** * @return true if the file has been endorsed on nexus @@ -714,11 +714,6 @@ public: */ virtual ETrackedState trackedState() const { return TRACKED_FALSE; } - /** - * @brief updates the valid-flag for this mod - */ - void testValid(); - /** * @brief updates the mod to flag it as converted in order to ignore the alternate game warning */ @@ -801,6 +796,13 @@ public: **/ QUrl parseCustomURL() const; +public slots: + + /** + * @brief Notify this mod that the content of the disk may have changed. + */ + virtual void diskContentModified() = 0; + signals: /** @@ -817,13 +819,6 @@ protected: static void updateIndices(); static bool ByName(const ModInfo::Ptr &LHS, const ModInfo::Ptr &RHS); - /** - * @brief check if the content of this mod is valid. - * - * @return true if the content is valid, false otherwize. - **/ - virtual bool doTestValid() const = 0; - private: static void createFromOverwrite(PluginContainer *pluginContainer, @@ -848,8 +843,6 @@ private: static std::map, std::vector > s_ModsByModID; static int s_NextID; - bool m_Valid; - }; -- cgit v1.3.1