Enforce project folder for custom filepaths

This commit is contained in:
GriffinR
2023-09-09 19:36:12 -04:00
parent 7a399daaff
commit a5a864926a
4 changed files with 66 additions and 24 deletions

View File

@@ -274,8 +274,8 @@ public:
void setDefaultSecondaryTileset(QString tilesetName);
void setFilePath(QString pathId, QString path);
void setFilePath(ProjectFilePath pathId, QString path);
QString getFilePath(QString defaultPath, bool allowDefault = true);
QString getFilePath(ProjectFilePath pathId, bool allowDefault = true);
QString getFilePath(QString defaultPath, bool customOnly = false);
QString getFilePath(ProjectFilePath pathId, bool customOnly = false);
void setPrefabFilepath(QString filepath);
QString getPrefabFilepath();
void setPrefabImportPrompted(bool prompted);

View File

@@ -30,6 +30,7 @@ private:
bool hasUnsavedChanges = false;
bool projectNeedsReload = false;
bool refreshing = false;
const QString baseDir;
void initUi();
void connectSignals();
@@ -42,6 +43,7 @@ private:
bool promptRestoreDefaults();
void createProjectPathsTable();
QString chooseProjectFile(const QString &defaultFilepath);
private slots:
void dialogButtonClicked(QAbstractButton *button);