-
Notifications
You must be signed in to change notification settings - Fork 40
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Settings manager: Create a class to manage all shared settings #206
Settings manager: Create a class to manage all shared settings #206
Conversation
cedae6f
to
71cf4bc
Compare
src/logger.cpp
Outdated
@@ -42,7 +34,7 @@ void Logger::installHandler() | |||
originalHandler = qInstallMessageHandler(handleMessage); // This function returns the previous message handler | |||
|
|||
if (qEnvironmentVariableIsEmpty("QT_MESSAGE_PATTERN")) { | |||
qSetMessagePattern(QStringLiteral("%{time [hh:mm:ss.zzz]} %{message}")); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Was adding this hunk intentional? What does this do?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ops, my bad, I was using a personal pattern while debugging.
@@ -115,7 +114,6 @@ class Logger : public QObject | |||
QFile _file; | |||
QTextStream _fileStream; | |||
QStringList _registeredCategories; | |||
QSettings _settings; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we assign SettingsManager::self()->settings() to a member _settings, and use that everywhere for better readability?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yep, Will do that
71cf4bc
to
1206aa3
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This looks great @patrickelectric!
Signed-off-by: Patrick José Pereira <patrickelectric@gmail.com>
Signed-off-by: Patrick José Pereira <patrickelectric@gmail.com>
Signed-off-by: Patrick José Pereira <patrickelectric@gmail.com>
Signed-off-by: Patrick José Pereira <patrickelectric@gmail.com>
Signed-off-by: Patrick José Pereira <patrickelectric@gmail.com>
Signed-off-by: Patrick José Pereira <patrickelectric@gmail.com>
Signed-off-by: Patrick José Pereira <patrickelectric@gmail.com>
Signed-off-by: Patrick José Pereira <patrickelectric@gmail.com>
ebb708c
to
b3487f7
Compare
Fix #205
Will help #199
Fix #42