mirror of
https://github.com/huderlem/porymap.git
synced 2026-08-19 23:25:09 -05:00
Add option to turn custom scripts on/off
This commit is contained in:
@@ -348,8 +348,11 @@ public:
|
||||
bool getEncounterJsonActive();
|
||||
void setProjectDir(QString projectDir);
|
||||
QString getProjectDir();
|
||||
void setCustomScripts(QStringList scripts);
|
||||
QStringList getCustomScripts();
|
||||
void setCustomScripts(QStringList scripts, QList<bool> enabled);
|
||||
QStringList getCustomScriptPaths();
|
||||
QList<bool> getCustomScriptsEnabled();
|
||||
void parseCustomScripts(QString input);
|
||||
QString outputCustomScripts();
|
||||
protected:
|
||||
virtual QString getConfigFilepath() override;
|
||||
virtual void parseConfigKeyValue(QString key, QString value) override;
|
||||
@@ -363,7 +366,7 @@ private:
|
||||
QString projectDir;
|
||||
QString recentMap;
|
||||
bool useEncounterJson;
|
||||
QStringList customScripts;
|
||||
QMap<QString, bool> customScripts;
|
||||
QStringList readKeys;
|
||||
};
|
||||
|
||||
|
||||
@@ -31,16 +31,17 @@ private:
|
||||
QString importDir;
|
||||
const QString baseDir;
|
||||
|
||||
void displayScript(const QString &filepath);
|
||||
void displayScript(const QString &filepath, bool enabled);
|
||||
QString chooseScript(QString dir);
|
||||
|
||||
void removeScript(QListWidgetItem * item);
|
||||
void replaceScript(QListWidgetItem * item);
|
||||
void openScript(QListWidgetItem * item);
|
||||
QString getScriptFilepath(QListWidgetItem * item, bool absolutePath = true) const;
|
||||
void setScriptFilepath(QListWidgetItem * item, QString filepath) const;
|
||||
bool getScriptEnabled(QListWidgetItem * item) const;
|
||||
|
||||
QString getListItemFilepath(QListWidgetItem * item) const;
|
||||
void setListItemFilepath(QListWidgetItem * item, QString filepath) const;
|
||||
|
||||
void markEdited();
|
||||
int prompt(const QString &text, QMessageBox::StandardButton defaultButton);
|
||||
void save();
|
||||
void closeEvent(QCloseEvent*);
|
||||
|
||||
Reference in New Issue
Block a user