fix: 解决代码中告警信息

记录打印信息的文本中不能有告警信息

Log:将打印的告警信息转为调试信息
Bug:https://pms.uniontech.com/zentao/bug-view-20977.html
This commit is contained in:
fengshaoxiong 2020-06-30 09:54:12 +08:00
parent b6a48e73c9
commit 43d3e50aad
8 changed files with 12 additions and 12 deletions

View File

@ -165,7 +165,7 @@ void AbstractPluginsController::loadPlugin(const QString &pluginFile)
const QString &pluginApi = meta.value("api").toString();
bool pluginIsValid = true;
if (pluginApi.isEmpty() || !CompatiblePluginApiList.contains(pluginApi)) {
qWarning() << objectName()
qDebug() << objectName()
<< "plugin api version not matched! expect versions:" << CompatiblePluginApiList
<< ", got version:" << pluginApi
<< ", the plugin file is:" << pluginFile;
@ -175,7 +175,7 @@ void AbstractPluginsController::loadPlugin(const QString &pluginFile)
PluginsItemInterface *interface = qobject_cast<PluginsItemInterface *>(pluginLoader->instance());
if (!interface) {
qWarning() << objectName() << "load plugin failed!!!" << pluginLoader->errorString() << pluginFile;
qDebug() << objectName() << "load plugin failed!!!" << pluginLoader->errorString() << pluginFile;
pluginLoader->unload();
pluginLoader->deleteLater();

View File

@ -686,8 +686,8 @@ void MainWindow::setStrutPartial()
++count;
}
if (count > 0) {
qWarning() << "strutArea is intersects with another screen.";
qWarning() << maxScreenHeight << maxScreenWidth << m_dockPosition << p << s;
qDebug() << "strutArea is intersects with another screen.";
qDebug() << maxScreenHeight << maxScreenWidth << m_dockPosition << p << s;
return;
}

View File

@ -55,7 +55,7 @@ QString DBusAdaptors::layout() const
if (m_currentLayout.isEmpty()) {
// refetch data
QTimer::singleShot(1000, m_keyboard, &Keyboard::currentLayout);
qWarning() << Q_FUNC_INFO << "currentLayout is Empty!!";
qDebug() << Q_FUNC_INFO << "currentLayout is Empty!!";
}
return m_currentLayout;
@ -103,7 +103,7 @@ void DBusAdaptors::initAllLayoutList()
QDBusPendingCallWatcher *watcher = new QDBusPendingCallWatcher(call, this);
connect(watcher, &QDBusPendingCallWatcher::finished, this, [=] {
if (call.isError()) {
qWarning() << "failed to get all keyboard list: " << call.error().message();
qDebug() << "failed to get all keyboard list: " << call.error().message();
} else {
QDBusReply<KeyboardLayoutList> reply = call.reply();
m_allLayoutList = reply.value();

View File

@ -298,7 +298,7 @@ bool ShutdownPlugin::checkSwap()
file.close();
} else {
qWarning() << "open /proc/swaps failed! please check permission!!!";
qDebug() << "open /proc/swaps failed! please check permission!!!";
}
return hasSwap;

View File

@ -127,7 +127,7 @@ void PopupControlWidget::clearTrashFloder()
if (DTrashManager::instance()->cleanTrash()) {
DDesktopServices::playSystemSoundEffect(DDesktopServices::SSE_EmptyTrash);
} else {
qWarning() << "Clear trash failed";
qDebug() << "Clear trash failed";
}
// DFMGlobal::instance()->clearTrash();
}

View File

@ -84,13 +84,13 @@ public:
callback(v);
return;
} else if (3 != arguments.count()) {
qWarning() << "arguments count must be 3";
qDebug() << "arguments count must be 3";
return;
}
QString interfaceName = msg.arguments().at(0).toString();
if (interfaceName != propertyInterfaceNames.value(key)) {
qWarning() << "interfaceName mismatch" << interfaceName << propertyInterfaceNames.value(key) << key;
qDebug() << "interfaceName mismatch" << interfaceName << propertyInterfaceNames.value(key) << key;
return;
}
QVariantMap changedProps = qdbus_cast<QVariantMap>(arguments.at(1).value<QDBusArgument>());

View File

@ -585,7 +585,7 @@ void SNITrayWidget::showHoverTips()
QProcess p;
p.start("qdbus", {m_dbusService});
if (!p.waitForFinished(1000)) {
qWarning() << "sni dbus service error : " << m_dbusService;
qDebug() << "sni dbus service error : " << m_dbusService;
return;
}

View File

@ -417,7 +417,7 @@ void TrayPlugin::traySNIAdded(const QString &itemKey, const QString &sniServiceP
QProcess p;
p.start("qdbus", {nsiServerName});
if (!p.waitForFinished(1000)) {
qWarning() << "sni dbus service error : " << nsiServerName;
qDebug() << "sni dbus service error : " << nsiServerName;
return;
}