130 lines
4.9 KiB
Diff
130 lines
4.9 KiB
Diff
From 53a57618838cb9f816af5cce5906e9eec98db7df Mon Sep 17 00:00:00 2001
|
|
From: liuxinhao <liuxinhao@kylinsec.com.cn>
|
|
Date: Fri, 8 Jul 2022 17:24:27 +0800
|
|
Subject: [PATCH 1/2] refactor(log): Reduce some log output levels
|
|
MIME-Version: 1.0
|
|
Content-Type: text/plain; charset=UTF-8
|
|
Content-Transfer-Encoding: 8bit
|
|
|
|
- 降低部分日志输出级别
|
|
---
|
|
common/src/kiran-appearance-monitor.cpp | 14 +++++++-------
|
|
platformtheme/kiran-theme.cpp | 4 ++--
|
|
style-helper/src/scheme-loader.cpp | 2 +-
|
|
style/src/kiran-style-plugin.cpp | 2 +-
|
|
4 files changed, 11 insertions(+), 11 deletions(-)
|
|
|
|
diff --git a/common/src/kiran-appearance-monitor.cpp b/common/src/kiran-appearance-monitor.cpp
|
|
index 2046757..7af4f9d 100644
|
|
--- a/common/src/kiran-appearance-monitor.cpp
|
|
+++ b/common/src/kiran-appearance-monitor.cpp
|
|
@@ -57,7 +57,7 @@ KiranAppearanceMonitor::KiranAppearanceMonitor(QObject *parent)
|
|
}
|
|
else
|
|
{
|
|
- qWarning(kiranPlatformThemeCommon) << "parse titlebar font failed!";
|
|
+ qDebug(kiranPlatformThemeCommon) << "parse titlebar font failed!";
|
|
}
|
|
|
|
//icon theme
|
|
@@ -70,7 +70,7 @@ KiranAppearanceMonitor::KiranAppearanceMonitor(QObject *parent)
|
|
}
|
|
else
|
|
{
|
|
- qWarning(kiranPlatformThemeCommon) << "get icon theme failed," << themeReply.error();
|
|
+ qDebug(kiranPlatformThemeCommon) << "get icon theme failed," << themeReply.error();
|
|
}
|
|
|
|
//gtk theme
|
|
@@ -89,12 +89,12 @@ KiranAppearanceMonitor::KiranAppearanceMonitor(QObject *parent)
|
|
}
|
|
else
|
|
{
|
|
- qWarning(kiranPlatformThemeCommon) << "get gtk theme failed," << themeReply.error();
|
|
+ qDebug(kiranPlatformThemeCommon) << "get gtk theme failed," << themeReply.error();
|
|
}
|
|
}
|
|
else
|
|
{
|
|
- qCritical(kiranPlatformThemeCommon) << "kiran session daemon appearance service isn't registered!";
|
|
+ qDebug(kiranPlatformThemeCommon) << "kiran session daemon appearance service isn't registered!";
|
|
}
|
|
|
|
connect(m_appearanceIface, &KiranAppearanceProxy::FontChanged,
|
|
@@ -113,7 +113,7 @@ KiranAppearanceMonitor::KiranAppearanceMonitor(QObject *parent)
|
|
}
|
|
else
|
|
{
|
|
- qCritical(kiranPlatformThemeCommon) << "kiran session daemon display service isn't registered!";
|
|
+ qDebug(kiranPlatformThemeCommon) << "kiran session daemon display service isn't registered!";
|
|
}
|
|
|
|
connect(m_displayIface, &KiranDisplayProxy::window_scaling_factorChanged,
|
|
@@ -197,7 +197,7 @@ bool KiranAppearanceMonitor::parseFontValue(const QString &font, QString &fontNa
|
|
QFontDatabase fontDatabase;
|
|
if( !fontDatabase.hasFamily(fontName) )
|
|
{
|
|
- qInfo() << "font data base don't has this font:" << fontName;
|
|
+ qDebug(kiranPlatformThemeCommon) << "font data base don't has this font:" << fontName;
|
|
return false;
|
|
}
|
|
|
|
@@ -252,7 +252,7 @@ void KiranAppearanceMonitor::handleThemeSettingChanged(int type, const QString &
|
|
|
|
if(gtkTheme!=m_gtkThemeName)
|
|
{
|
|
- qInfo() << "gtk theme changed:" << themeName;
|
|
+ qDebug(kiranPlatformThemeCommon) << "gtk theme changed:" << themeName;
|
|
m_gtkThemeName = gtkTheme;
|
|
emit gtkThemeChanged(m_gtkThemeName);
|
|
}
|
|
diff --git a/platformtheme/kiran-theme.cpp b/platformtheme/kiran-theme.cpp
|
|
index 3a046e9..4636030 100644
|
|
--- a/platformtheme/kiran-theme.cpp
|
|
+++ b/platformtheme/kiran-theme.cpp
|
|
@@ -274,13 +274,13 @@ void KiranTheme::handleScaleFactorChanged(int factor)
|
|
}
|
|
else
|
|
{
|
|
- qWarning(kiranPlatformTheme) << "not support this factor:" << factor;
|
|
+ qDebug(kiranPlatformTheme) << "not support this factor:" << factor;
|
|
return;
|
|
}
|
|
}
|
|
else
|
|
{
|
|
- qWarning(kiranPlatformTheme) << "disable real time scaling,ignore scale factor changed!";
|
|
+ qDebug(kiranPlatformTheme) << "disable real time scaling,ignore scale factor changed!";
|
|
}
|
|
}
|
|
|
|
diff --git a/style-helper/src/scheme-loader.cpp b/style-helper/src/scheme-loader.cpp
|
|
index bd6ac05..2c71094 100644
|
|
--- a/style-helper/src/scheme-loader.cpp
|
|
+++ b/style-helper/src/scheme-loader.cpp
|
|
@@ -290,7 +290,7 @@ bool SchemeLoader::load(const QString& schemeFile)
|
|
}
|
|
|
|
m_isValid = true;
|
|
- qInfo() << "load" << schemeFile << "succeed!";
|
|
+ qDebug() << "load" << schemeFile << "succeed!";
|
|
return true;
|
|
}
|
|
|
|
diff --git a/style/src/kiran-style-plugin.cpp b/style/src/kiran-style-plugin.cpp
|
|
index ed7d965..bb3df1f 100644
|
|
--- a/style/src/kiran-style-plugin.cpp
|
|
+++ b/style/src/kiran-style-plugin.cpp
|
|
@@ -34,7 +34,7 @@ QStyle *KiranStylePlugin::create(const QString & key)
|
|
return QStyleFactory::create("fusion");
|
|
}
|
|
|
|
- qInfo("create style:%s",key.toStdString().c_str());
|
|
+ qDebug("create style:%s",key.toStdString().c_str());
|
|
if( key.compare("kiran",Qt::CaseInsensitive) == 0 )
|
|
{
|
|
return new Style();
|
|
--
|
|
2.33.0
|
|
|