Merge branch 'dev-0619' into 'main'

Fixed: The problem of being blocked in English mode of 'Hide WLAN'

See merge request kylin-desktop/kylin-nm!44
This commit is contained in:
chen lelin 2021-06-18 11:29:44 +00:00
commit 20663b267b
1 changed files with 2 additions and 1 deletions

View File

@ -327,10 +327,11 @@ void MainWindow::createTopWifiUI()
lbTopWifiList->show(); lbTopWifiList->show();
/*新建有线网按钮*/ /*新建有线网按钮*/
btnAddNet = new QPushButton(topWifiListWidget); btnAddNet = new QPushButton(topWifiListWidget);
btnAddNet->resize(W_BTN_FUN, H_BTN_FUN);
btnAddNet->move(X_BTN_FUN, Y_BTN_FUN); btnAddNet->move(X_BTN_FUN, Y_BTN_FUN);
btnAddNet->setText(tr("Hide WLAN"));//"加入网络" btnAddNet->setText(tr("Hide WLAN"));//"加入网络"
btnAddNet->setStyleSheet(funcBtnQss); btnAddNet->setStyleSheet(funcBtnQss);
int textWidth = QFontMetrics(btnAddNet->font()).width(btnAddNet->text());
btnAddNet->resize(textWidth > W_BTN_FUN ? textWidth : W_BTN_FUN, H_BTN_FUN);
btnAddNet->setFocusPolicy(Qt::NoFocus); btnAddNet->setFocusPolicy(Qt::NoFocus);
btnAddNet->show(); btnAddNet->show();
connect(btnAddNet,SIGNAL(clicked()),this,SLOT(onBtnAddNetClicked())); connect(btnAddNet,SIGNAL(clicked()),this,SLOT(onBtnAddNetClicked()));