Commit 4e4e93cc authored by Laurent Montel's avatar Laurent Montel 😁
Browse files

Move in namespace + use constexpr

parent 8cf5578d
...@@ -35,8 +35,13 @@ ...@@ -35,8 +35,13 @@
#include "notifications_interface.h" // DBUS-generated #include "notifications_interface.h" // DBUS-generated
#include "dbusproperties.h" // DBUS-generated #include "dbusproperties.h" // DBUS-generated
static const char s_fdo_notifications_service[] = "org.freedesktop.Notifications";
static const char s_fdo_notifications_path[] = "/org/freedesktop/Notifications";
namespace {
static constexpr const char s_fdo_notifications_service[] = "org.freedesktop.Notifications";
static constexpr const char s_fdo_notifications_path[] = "/org/freedesktop/Notifications";
static constexpr const char DialogGroup[] = "FollowUpReminderNoAnswerDialog";
}
FollowUpReminderNoAnswerDialog::FollowUpReminderNoAnswerDialog(QWidget *parent) FollowUpReminderNoAnswerDialog::FollowUpReminderNoAnswerDialog(QWidget *parent)
: QDialog(parent) : QDialog(parent)
...@@ -118,7 +123,7 @@ void FollowUpReminderNoAnswerDialog::setInfo(const QList<FollowUpReminder::Follo ...@@ -118,7 +123,7 @@ void FollowUpReminderNoAnswerDialog::setInfo(const QList<FollowUpReminder::Follo
void FollowUpReminderNoAnswerDialog::readConfig() void FollowUpReminderNoAnswerDialog::readConfig()
{ {
KConfigGroup group(KSharedConfig::openConfig(), "FollowUpReminderNoAnswerDialog"); KConfigGroup group(KSharedConfig::openConfig(), DialogGroup);
const QSize sizeDialog = group.readEntry("Size", QSize(800, 600)); const QSize sizeDialog = group.readEntry("Size", QSize(800, 600));
if (sizeDialog.isValid()) { if (sizeDialog.isValid()) {
resize(sizeDialog); resize(sizeDialog);
...@@ -128,7 +133,7 @@ void FollowUpReminderNoAnswerDialog::readConfig() ...@@ -128,7 +133,7 @@ void FollowUpReminderNoAnswerDialog::readConfig()
void FollowUpReminderNoAnswerDialog::writeConfig() void FollowUpReminderNoAnswerDialog::writeConfig()
{ {
KConfigGroup group(KSharedConfig::openConfig(), "FollowUpReminderNoAnswerDialog"); KConfigGroup group(KSharedConfig::openConfig(), DialogGroup);
group.writeEntry("Size", size()); group.writeEntry("Size", size());
mWidget->saveTreeWidgetHeader(group); mWidget->saveTreeWidgetHeader(group);
} }
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment