From a78212e8dd0204fdf87b145481e368ad043b882c Mon Sep 17 00:00:00 2001 From: scorpio810 Date: Sun, 25 Nov 2018 10:47:36 +0000 Subject: [PATCH] Minor fix previous commits git-svn-id: svn+ssh://svn.tuxfamily.org/svnroot/qet/qet/trunk@5609 bfdf4180-ca20-0410-9c96-a3a8aa849046 --- sources/qetapp.cpp | 2 +- sources/ui/configpage/generalconfigurationpage.cpp | 9 +++++---- 2 files changed, 6 insertions(+), 5 deletions(-) diff --git a/sources/qetapp.cpp b/sources/qetapp.cpp index e06d1dd1a..f26f5c50b 100644 --- a/sources/qetapp.cpp +++ b/sources/qetapp.cpp @@ -564,7 +564,7 @@ QString QETApp::customTitleBlockTemplatesDir() { if (m_user_custom_tbt_dir.isEmpty()) { QSettings settings; - QString path = settings.value("elements-collections/custom-tbt-collection-path", "default").toString(); + QString path = settings.value("elements-collections/custom-tbt-path", "default").toString(); if (path != "default" && !path.isEmpty()) { QDir dir(path); diff --git a/sources/ui/configpage/generalconfigurationpage.cpp b/sources/ui/configpage/generalconfigurationpage.cpp index e097f266d..2fa0cf9c8 100644 --- a/sources/ui/configpage/generalconfigurationpage.cpp +++ b/sources/ui/configpage/generalconfigurationpage.cpp @@ -167,18 +167,19 @@ void GeneralConfigurationPage::applyConf() if (path != settings.value("elements-collections/custom-collection-path").toString()) { QETApp::resetUserElementsDir(); } - path = settings.value("elements-collections/custom-tbt-collection-path").toString(); + + path = settings.value("elements-collections/custom-tbt-path").toString(); if (ui->m_custom_tbt_path_cb->currentIndex() == 1) { QString path = ui->m_custom_tbt_path_cb->currentText(); QDir dir(path); - settings.setValue("elements-collections/custom-tbt-collection-path", + settings.setValue("elements-collections/custom-tbt-path", dir.exists() ? path : "default"); } else { - settings.setValue("elements-collections/custom-tbt-collection-path", "default"); + settings.setValue("elements-collections/custom-tbt-path", "default"); } - if (path != settings.value("elements-collections/custom-tbt-collection-path").toString()) { + if (path != settings.value("elements-collections/custom-tbt-path").toString()) { QETApp::resetUserElementsDir(); } }