summaryrefslogtreecommitdiff
path: root/src/profile.h
diff options
context:
space:
mode:
authorThomas Tanner <trtanner@btinternet.com>2015-11-25 08:22:40 +0000
committerThomas Tanner <trtanner@btinternet.com>2015-11-25 08:22:40 +0000
commit78b686b2bc507a5606bc7c673745b02346bc667a (patch)
treed161d6096289aed99cfb1bf79cce4c2404c202dd /src/profile.h
parent42a68689fe60ba29367dc0c8f65083d9bde93e1f (diff)
Removes all references to GameInfo::getGameDirectory apart from one during startup
Did some const correctness improvements Also may have fixed a potential crash as the Profile copy constructor didn't copy the m_GamePlugin membber
Diffstat (limited to 'src/profile.h')
-rw-r--r--src/profile.h8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/profile.h b/src/profile.h
index e9edca56..b306e0c5 100644
--- a/src/profile.h
+++ b/src/profile.h
@@ -57,7 +57,7 @@ public:
* @param name name of the new profile
* @param filter save game filter. Defaults to &lt;no filter&gt;.
**/
- Profile(const QString &name, MOBase::IPluginGame *gamePlugin, bool useDefaultSettings);
+ Profile(const QString &name, MOBase::IPluginGame const *gamePlugin, bool useDefaultSettings);
/**
* @brief constructor
@@ -67,7 +67,7 @@ public:
* invoking this should always produce a working profile
* @param directory directory to read the profile from
**/
- Profile(const QDir &directory, MOBase::IPluginGame *gamePlugin);
+ Profile(const QDir &directory, MOBase::IPluginGame const *gamePlugin);
Profile(const Profile &reference);
@@ -82,7 +82,7 @@ public:
* @param name of the new profile
* @param reference profile to copy from
**/
- static Profile *createPtrFrom(const QString &name, const Profile &reference, MOBase::IPluginGame *gamePlugin);
+ static Profile *createPtrFrom(const QString &name, const Profile &reference, MOBase::IPluginGame const *gamePlugin);
MOBase::DelayedFileWriter &modlistWriter() { return m_ModListWriter; }
@@ -302,7 +302,7 @@ private:
QDir m_Directory;
- MOBase::IPluginGame *m_GamePlugin;
+ MOBase::IPluginGame const * const m_GamePlugin;
mutable QByteArray m_LastModlistHash;
std::vector<ModStatus> m_ModStatus;