Fix bug#39021 There's no notification when cable network disconnected

This commit is contained in:
andrew-wuhan-huawei-990-pc 2021-03-04 11:30:56 +08:00
parent 4364e118f0
commit cc51c760b0
3 changed files with 2 additions and 5 deletions

View File

@ -645,7 +645,6 @@ void MainWindow::iconActivated(QSystemTrayIcon::ActivationReason reason)
switch (reason) {
case QSystemTrayIcon::Trigger:
case QSystemTrayIcon::MiddleClick:
handleIconClicked();
if (this->isHidden()) {
@ -991,7 +990,7 @@ void MainWindow::onPhysicalCarrierChanged(bool flag)
} else {
qDebug()<<"拔出了有线网的网线";
syslog(LOG_DEBUG,"wired physical cable is already plug out");
activeLanDisconn();
BackThread *bt = new BackThread();
IFace *iface = bt->execGetIface();
if (iface->lstate != 0) {
@ -2714,7 +2713,6 @@ void MainWindow::activeLanDisconn()
QString txt(tr("Wired net is disconnected"));
objKyDBus->showDesktopNotify(txt);
currSelNetName = "";
oldActLanName = "";
oldDbusActLanDNS = 0;
@ -2739,7 +2737,6 @@ void MainWindow::activeWifiDisconn()
void MainWindow::activeStartLoading()
{
syslog(LOG_DEBUG, "Wi-Fi is disconnected");
QString txt(tr("Wi-Fi is disconnected"));
objKyDBus->showDesktopNotify(txt);

Binary file not shown.

View File

@ -1465,7 +1465,7 @@
<message>
<location filename="../src/mainwindow.cpp" line="2359"/>
<source>Wired net is disconnected</source>
<translation type="unfinished">线</translation>
<translation type="unfinished">线</translation>
</message>
<message>
<location filename="../src/mainwindow.cpp" line="2385"/>