fix bug:131247
This commit is contained in:
parent
9236fc91f4
commit
77e99382c3
|
@ -1,3 +1,9 @@
|
|||
kylin-nm (3.14.0.0+0512-0k9) yangtz; urgency=medium
|
||||
|
||||
* close-cd #131247 登录界面连接wifi后,登录桌面任务栏网络工具显示未连接,wifi依旧关闭状态
|
||||
|
||||
-- zhaoshixu <zhaoshixu@kylinos.cn> Wed, 03 Aug 2022 16:12:40 +0800
|
||||
|
||||
kylin-nm (3.14.0.0+0512-0k8) yangtz; urgency=medium
|
||||
|
||||
* close-cd #127890 开启无线局域网后关闭,重新打开控制面板,无线局域网处显示网卡名称
|
||||
|
|
|
@ -136,6 +136,7 @@ void WlanPage::onWlanSwithGsettingsChanged(const QString &key)
|
|||
void WlanPage::initWlanSwitchState()
|
||||
{
|
||||
bool wirelessGsetting = true;
|
||||
bool wirelessEnabled = m_wirelessConnectOpreation->getWirelessEnabled();
|
||||
if (QGSettings::isSchemaInstalled(GSETTINGS_SCHEMA)) {
|
||||
m_switchGsettings = new QGSettings(GSETTINGS_SCHEMA);
|
||||
if (m_switchGsettings->keys().contains(WIRELESS_SWITCH)) {
|
||||
|
@ -144,18 +145,18 @@ void WlanPage::initWlanSwitchState()
|
|||
m_netSwitch->setChecked(false);
|
||||
} else {
|
||||
wirelessGsetting = m_switchGsettings->get(WIRELESS_SWITCH).toBool();
|
||||
if (m_wirelessConnectOpreation->getWirelessEnabled()
|
||||
if (wirelessEnabled
|
||||
!= wirelessGsetting) {
|
||||
//以gsetting为准
|
||||
m_wirelessConnectOpreation->setWirelessEnabled(wirelessGsetting);
|
||||
//以后端状态为准
|
||||
m_switchGsettings->set(WIRELESS_SWITCH, wirelessEnabled);
|
||||
}
|
||||
m_netSwitch->setChecked(wirelessGsetting);
|
||||
m_netSwitch->setChecked(wirelessEnabled);
|
||||
}
|
||||
connect(m_switchGsettings, &QGSettings::changed, this, &WlanPage::onWlanSwithGsettingsChanged);
|
||||
}
|
||||
}
|
||||
m_netSwitch->setChecked(wirelessGsetting);
|
||||
m_wlanSwitchEnable = wirelessGsetting;
|
||||
m_netSwitch->setChecked(wirelessEnabled);
|
||||
m_wlanSwitchEnable = wirelessEnabled;
|
||||
}
|
||||
|
||||
void WlanPage::initTimer()
|
||||
|
|
Loading…
Reference in New Issue