mirror of
https://github.com/tnodir/fort
synced 2024-11-14 22:05:12 +00:00
UI: Log purged obsolete app paths as Info
This commit is contained in:
parent
c5dc5b16a3
commit
98ea775e6c
@ -535,7 +535,7 @@ QVector<qint64> ConfAppManager::collectObsoleteApps(quint32 driveMask)
|
||||
const qint64 appId = stmt.columnInt64(0);
|
||||
appIdList.append(appId);
|
||||
|
||||
qCDebug(LC) << "Obsolete app:" << appId << appPath;
|
||||
qCInfo(LC) << "Obsolete app:" << appId << appPath;
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -25,8 +25,10 @@ Logger::LogLevel levelByMsgType(QtMsgType type)
|
||||
case QtCriticalMsg:
|
||||
case QtFatalMsg:
|
||||
return Logger::Error;
|
||||
default:
|
||||
case QtInfoMsg:
|
||||
return Logger::Info;
|
||||
default:
|
||||
return Logger::Debug;
|
||||
}
|
||||
}
|
||||
|
||||
@ -36,7 +38,7 @@ void processMessage(QtMsgType type, const QMessageLogContext &context, const QSt
|
||||
|
||||
Logger *logger = Logger::instance();
|
||||
|
||||
const bool isLogToFile = (level != Logger::Info || logger->debug());
|
||||
const bool isLogToFile = (level != Logger::Debug || logger->debug());
|
||||
const bool isLogConsole = logger->console();
|
||||
|
||||
if (!(isLogToFile || isLogConsole))
|
||||
@ -134,7 +136,7 @@ QString Logger::getDateString(const QString &format)
|
||||
|
||||
QString Logger::makeLogLine(LogLevel level, const QString &dateString, const QString &message)
|
||||
{
|
||||
static const char *const g_levelChars = ".WE";
|
||||
static const char *const g_levelChars = "..WE";
|
||||
|
||||
return dateString + ' ' + g_levelChars[int(level)] + ' ' + message + '\n';
|
||||
}
|
||||
|
@ -12,7 +12,7 @@ protected:
|
||||
explicit Logger(QObject *parent = nullptr);
|
||||
|
||||
public:
|
||||
enum LogLevel { Info = 0, Warning, Error };
|
||||
enum LogLevel { Debug = 0, Info, Warning, Error };
|
||||
Q_ENUM(LogLevel)
|
||||
|
||||
bool isPortable() const { return m_isPortable; }
|
||||
|
@ -34,5 +34,5 @@ void WindowManagerFake::showErrorBox(
|
||||
|
||||
void WindowManagerFake::showInfoBox(const QString &text, const QString &title, QWidget * /*parent*/)
|
||||
{
|
||||
qCInfo(LC) << title << ":" << text;
|
||||
qCDebug(LC) << title << ":" << text;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user