summaryrefslogtreecommitdiff
path: root/src/profilesdialog.cpp
diff options
context:
space:
mode:
authorisanae <14251494+isanae@users.noreply.github.com>2019-09-09 01:25:01 -0400
committerGitHub <noreply@github.com>2019-09-09 01:25:01 -0400
commit99fdbb2539227cec4fab534efc7420cfc5ca1a92 (patch)
tree4fe70561a85d86b65cc4c6725541767684af09a7 /src/profilesdialog.cpp
parent73626b297904d50507bb7d5d1342120040e655e8 (diff)
parentd863e62c6e2f3c0daa50e16a0206f59558a7bb7e (diff)
Merge pull request #830 from isanae/settings-interface
Settings interface
Diffstat (limited to 'src/profilesdialog.cpp')
-rw-r--r--src/profilesdialog.cpp10
1 files changed, 8 insertions, 2 deletions
diff --git a/src/profilesdialog.cpp b/src/profilesdialog.cpp
index d7863fc8..c91f48f4 100644
--- a/src/profilesdialog.cpp
+++ b/src/profilesdialog.cpp
@@ -57,7 +57,7 @@ ProfilesDialog::ProfilesDialog(const QString &profileName, MOBase::IPluginGame c
{
ui->setupUi(this);
- QDir profilesDir(Settings::instance().getProfileDirectory());
+ QDir profilesDir(Settings::instance().paths().profiles());
profilesDir.setFilter(QDir::AllDirs | QDir::NoDotAndDotDot);
QDirIterator profileIter(profilesDir);
@@ -84,6 +84,12 @@ ProfilesDialog::~ProfilesDialog()
delete ui;
}
+int ProfilesDialog::exec()
+{
+ GeometrySaver gs(Settings::instance(), this);
+ return QDialog::exec();
+}
+
void ProfilesDialog::showEvent(QShowEvent *event)
{
TutorableDialog::showEvent(event);
@@ -197,7 +203,7 @@ void ProfilesDialog::on_removeProfileButton_clicked()
if (confirmBox.exec() == QMessageBox::Yes) {
QString profilePath;
if (profileToDelete.get() == nullptr) {
- profilePath = Settings::instance().getProfileDirectory()
+ profilePath = Settings::instance().paths().profiles()
+ "/" + ui->profilesList->currentItem()->text();
if (QMessageBox::question(this, tr("Profile broken"),
tr("This profile you're about to delete seems to be broken or the path is invalid. "