fix(ui): UI controls block each other in wpa wifi dialog.
Description: 修复企业wifi弹窗ui控件互相遮挡的bug Log: 修复企业wifi弹窗ui控件互相遮挡的bug Bug: http://172.17.66.192/biz/bug-view-54451.html
This commit is contained in:
parent
c53c84ef1c
commit
c6096ffa7f
|
@ -130,7 +130,8 @@ WpaWifiDialog::~WpaWifiDialog()
|
|||
void WpaWifiDialog::initUI() {
|
||||
mainWidget = new QWidget(this);
|
||||
mainLyt = new QVBoxLayout(mainWidget);
|
||||
mainWidget->setFixedSize(360, 590);
|
||||
mainWidget->setFixedSize(WINDOW_WIDTH, WINDOW_HEIGHT_PEAP);
|
||||
this->setFixedSize(WINDOW_WIDTH, WINDOW_HEIGHT_PEAP);
|
||||
|
||||
titleFrame = new QFrame(mainWidget); //标题栏
|
||||
titleFrame->setFixedHeight(48);
|
||||
|
@ -222,7 +223,7 @@ void WpaWifiDialog::initUI() {
|
|||
userFrame->setLayout(userLyt);
|
||||
|
||||
pwdFrame = new QFrame(); //密码
|
||||
pwdFrame->setFixedHeight(96);
|
||||
pwdFrame->setFixedHeight(72);
|
||||
pwdLyt = new QVBoxLayout(pwdFrame);
|
||||
pwdLyt->setContentsMargins(0, 0, 0, 0);
|
||||
pwdLyt->setSpacing(0);
|
||||
|
@ -878,15 +879,23 @@ void WpaWifiDialog::eapTypeChange()
|
|||
mainLyt->addWidget(m_UserCertificateFrame);
|
||||
mainLyt->addWidget(m_UserPrivateKeyFrame);
|
||||
mainLyt->addWidget(m_pwd4PrivateKeyPWDFrame);
|
||||
mainWidget->setFixedSize(WINDOW_WIDTH, WINDOW_HEIGHT_TLP);
|
||||
this->setFixedSize(WINDOW_WIDTH, WINDOW_HEIGHT_TLP);
|
||||
break;
|
||||
case EapType::LEAP:
|
||||
// Todo
|
||||
mainWidget->setFixedSize(WINDOW_WIDTH, WINDOW_HEIGHT_ELSE);
|
||||
this->setFixedSize(WINDOW_WIDTH, WINDOW_HEIGHT_ELSE);
|
||||
break;
|
||||
case EapType::PWD:
|
||||
// Todo
|
||||
mainWidget->setFixedSize(WINDOW_WIDTH, WINDOW_HEIGHT_ELSE);
|
||||
this->setFixedSize(WINDOW_WIDTH, WINDOW_HEIGHT_ELSE);
|
||||
break;
|
||||
case EapType::FAST:
|
||||
// Todo
|
||||
mainWidget->setFixedSize(WINDOW_WIDTH, WINDOW_HEIGHT_ELSE);
|
||||
this->setFixedSize(WINDOW_WIDTH, WINDOW_HEIGHT_ELSE);
|
||||
break;
|
||||
case EapType::TTLS:
|
||||
// Todo
|
||||
|
@ -899,12 +908,16 @@ void WpaWifiDialog::eapTypeChange()
|
|||
mainLyt->addWidget(userFrame);
|
||||
mainLyt->addWidget(pwdFrame);
|
||||
*/
|
||||
mainWidget->setFixedSize(WINDOW_WIDTH, WINDOW_HEIGHT_ELSE);
|
||||
this->setFixedSize(WINDOW_WIDTH, WINDOW_HEIGHT_ELSE);
|
||||
break;
|
||||
case EapType::PEAP:
|
||||
// 需要抽离的
|
||||
mainLyt->addWidget(innerFrame);
|
||||
mainLyt->addWidget(userFrame);
|
||||
mainLyt->addWidget(pwdFrame);
|
||||
mainWidget->setFixedSize(WINDOW_WIDTH, WINDOW_HEIGHT_PEAP);
|
||||
this->setFixedSize(WINDOW_WIDTH, WINDOW_HEIGHT_PEAP);
|
||||
break;
|
||||
default: // TLS
|
||||
mainLyt->addWidget(m_identityFrame);
|
||||
|
@ -913,6 +926,8 @@ void WpaWifiDialog::eapTypeChange()
|
|||
mainLyt->addWidget(m_UserCertificateFrame);
|
||||
mainLyt->addWidget(m_UserPrivateKeyFrame);
|
||||
mainLyt->addWidget(m_pwd4PrivateKeyPWDFrame);
|
||||
mainWidget->setFixedSize(WINDOW_WIDTH, WINDOW_HEIGHT_TLP);
|
||||
this->setFixedSize(WINDOW_WIDTH, WINDOW_HEIGHT_TLP);
|
||||
break;
|
||||
}
|
||||
|
||||
|
|
|
@ -38,6 +38,11 @@
|
|||
#include <QModelIndex>
|
||||
#include <QList>
|
||||
|
||||
#define WINDOW_WIDTH 360
|
||||
#define WINDOW_HEIGHT_PEAP 540
|
||||
#define WINDOW_HEIGHT_TLP 670
|
||||
#define WINDOW_HEIGHT_ELSE 360
|
||||
|
||||
class MainWindow;
|
||||
|
||||
typedef QList<QObject*> QObjectList;
|
||||
|
|
|
@ -13,13 +13,13 @@
|
|||
<property name="minimumSize">
|
||||
<size>
|
||||
<width>360</width>
|
||||
<height>660</height>
|
||||
<height>0</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="maximumSize">
|
||||
<size>
|
||||
<width>360</width>
|
||||
<height>660</height>
|
||||
<height>680</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="windowTitle">
|
||||
|
|
Loading…
Reference in New Issue