格式修改

This commit is contained in:
zhouxiali 2021-09-06 13:51:54 +08:00
parent 344d87be08
commit efc853119a
8 changed files with 170 additions and 156 deletions

View File

@ -52,12 +52,12 @@ void LanListItem::setIcon(bool isOn)
void LanListItem::onInfoButtonClicked()
{
if(m_data){
qDebug()<<"是否激活:"<<m_isActive;
qDebug()<<"Net active or not:"<<m_isActive;
qDebug() << "On lan info button clicked! uuid = " << m_data->m_connectUuid << "; name = " << m_data->m_connectName << "." <<Q_FUNC_INFO << __LINE__;
NetDetail *netDetail = new NetDetail(m_data->m_connectName, m_data->m_connectUuid, m_isActive,false, false);
netDetail->show();
}
else{
qDebug() << "On wlan info button clicked! But there is no wlan connect " ;
qDebug() << "On lan info button clicked! But there is no wlan connect " ;
}
}

View File

@ -195,9 +195,8 @@ void WlanListItem::onInfoButtonClicked()
{
//ZJP_TODO 呼出无线详情页
if(m_data){
qDebug()<<"是否已激活:"<<m_isActive;
qDebug()<<"Net active or not:"<<m_isActive;
qDebug() << "On wlan info button clicked! ssid = " << m_data->m_NetSsid << "; name = " << m_data->m_connName << "." <<Q_FUNC_INFO << __LINE__;
qDebug()<<m_data->m_connName<<m_data->m_NetSsid;
NetDetail *netDetail = new NetDetail(m_data->m_NetSsid, m_data->m_connectUuid,m_isActive, true, false);
netDetail->show();
}

View File

@ -1,27 +1,26 @@
#include "ipv4page.h"
#include "netdetail.h"
Ipv4Page::Ipv4Page(bool isWlan)
: isWlan(isWlan)
Ipv4Page::Ipv4Page(bool isWlan, QWidget *parent)
: isWlan(isWlan), QFrame(parent)
{
initUI();
initComponent();
}
void Ipv4Page::initUI() {
ipv4ConfigCombox = new QComboBox;
ipv4addressEdit = new QLineEdit;
netMaskCombox = new QComboBox;
gateWayEdit = new QLineEdit;
firstDnsEidt = new QLineEdit;
secondDnsEidt = new QLineEdit;
ipv4ConfigCombox = new QComboBox(this);
ipv4addressEdit = new QLineEdit(this);
netMaskCombox = new QComboBox(this);
gateWayEdit = new QLineEdit(this);
firstDnsEidt = new QLineEdit(this);
secondDnsEidt = new QLineEdit(this);
m_configLabel = new QLabel;
m_addressLabel = new QLabel;
m_maskLabel = new QLabel;
m_gateWayLabel = new QLabel;
m_dnsLabel = new QLabel;
m_secDnsLabel = new QLabel;
m_configLabel = new QLabel(this);
m_addressLabel = new QLabel(this);
m_maskLabel = new QLabel(this);
m_gateWayLabel = new QLabel(this);
m_dnsLabel = new QLabel(this);
m_secDnsLabel = new QLabel(this);
m_configLabel->setText(tr("Ipv4Config"));
m_addressLabel->setText(tr("Address"));
@ -57,9 +56,9 @@ void Ipv4Page::initUI() {
}
void Ipv4Page::initComponent() {
if (ipv4ConfigCombox->currentIndex() == 0) {
if (ipv4ConfigCombox->currentIndex() == AUTO_CONFIG) {
setLineEnabled(false);
} else if (ipv4ConfigCombox->currentIndex() == 1) {
} else if (ipv4ConfigCombox->currentIndex() == MANUAL_CONFIG) {
setLineEnabled(true);
}
connect(ipv4ConfigCombox, SIGNAL(currentIndexChanged(int)), this, SLOT(configChanged(int)));
@ -68,10 +67,10 @@ void Ipv4Page::initComponent() {
void Ipv4Page::setIpv4Config(const QString &ipv4Config)
{
if (ipv4Config == "0") {
ipv4ConfigCombox->setCurrentIndex(1);
if (ipv4Config.toInt() == AUTO_CONFIG) {
ipv4ConfigCombox->setCurrentIndex(MANUAL_CONFIG);
} else {
ipv4ConfigCombox->setCurrentIndex(0);
ipv4ConfigCombox->setCurrentIndex(AUTO_CONFIG);
}
}
@ -96,10 +95,10 @@ void Ipv4Page::setGateWay(const QString &gateWay)
}
void Ipv4Page::configChanged(int index) {
if (index == 0) {
if (index == AUTO_CONFIG) {
setLineEnabled(false);
}
if (index == 1) {
if (index == MANUAL_CONFIG) {
setLineEnabled(true);
}
}

View File

@ -28,7 +28,7 @@ class Ipv4Page : public QFrame
{
Q_OBJECT
public:
Ipv4Page(bool isWlan);
Ipv4Page(bool isWlan, QWidget *parent = nullptr);
void setIpv4Config(const QString &ipv4Config);
void setIpv4(const QString &ipv4);
void setIpv4FirDns(const QString &ipv4FirDns);
@ -42,16 +42,15 @@ public:
QLineEdit *firstDnsEidt;
QLineEdit *secondDnsEidt;
private:
QFormLayout *m_detailLayout;
QVBoxLayout *mvBoxLayout;
QLabel *m_configLabel;
QLabel *m_addressLabel;
QLabel *m_maskLabel;
QLabel *m_gateWayLabel;
QLabel *m_dnsLabel;
QLabel *m_secDnsLabel;
private:
QFormLayout *m_detailLayout;
QVBoxLayout *mvBoxLayout;
bool isWlan;
private:
void initUI();

View File

@ -1,7 +1,7 @@
#include "ipv6page.h"
Ipv6Page::Ipv6Page(bool isWlan)
:isWlan(isWlan)
#include "netdetail.h"
Ipv6Page::Ipv6Page(bool isWlan, QWidget *parent)
:isWlan(isWlan), QFrame(parent)
{
initUI();
initComponent();
@ -9,10 +9,10 @@ Ipv6Page::Ipv6Page(bool isWlan)
void Ipv6Page::setIpv6Config(const QString &ipv6Config)
{
if (ipv6Config == "0") {
ipv6ConfigCombox->setCurrentIndex(1);
if (ipv6Config.toInt() == AUTO_CONFIG) {
ipv6ConfigCombox->setCurrentIndex(MANUAL_CONFIG);
} else {
ipv6ConfigCombox->setCurrentIndex(0);
ipv6ConfigCombox->setCurrentIndex(AUTO_CONFIG);
}
}
@ -37,36 +37,36 @@ void Ipv6Page::setGateWay(const QString &gateWay)
}
void Ipv6Page::initUI() {
ipv6ConfigCombox = new QComboBox;
ipv6AddressEdit = new QLineEdit;
lengthEdit = new QLineEdit;
gateWayEdit = new QLineEdit;
firstDnsEdit = new QLineEdit;
secondDnsEdit = new QLineEdit;
ipv6ConfigCombox = new QComboBox(this);
ipv6AddressEdit = new QLineEdit(this);
lengthEdit = new QLineEdit(this);
gateWayEdit = new QLineEdit(this);
firstDnsEdit = new QLineEdit(this);
secondDnsEdit = new QLineEdit(this);
mConfigLabel = new QLabel;
mAddressLabel = new QLabel;
mSubnetLabel = new QLabel;
mGateWayLabel = new QLabel;
mDnsLabel = new QLabel;
mSecDnsLabel = new QLabel;
m_configLabel = new QLabel(this);
m_addressLabel = new QLabel(this);
m_subnetLabel = new QLabel(this);
m_gateWayLabel = new QLabel(this);
m_dnsLabel = new QLabel(this);
m_secDnsLabel = new QLabel(this);
mConfigLabel->setText(tr("Ipv6Config"));
mAddressLabel->setText(tr("Address"));
mSubnetLabel->setText(tr("Subnet prefix Length"));
mGateWayLabel->setText(tr("Default Gateway"));
mDnsLabel->setText(tr("Prefs DNS"));
mSecDnsLabel->setText(tr("Alternative DNS"));
m_configLabel->setText(tr("Ipv6Config"));
m_addressLabel->setText(tr("Address"));
m_subnetLabel->setText(tr("Subnet prefix Length"));
m_gateWayLabel->setText(tr("Default Gateway"));
m_dnsLabel->setText(tr("Prefs DNS"));
m_secDnsLabel->setText(tr("Alternative DNS"));
mDetailLayout = new QFormLayout(this);
mDetailLayout->addRow(mConfigLabel,ipv6ConfigCombox);
mDetailLayout->addRow(mAddressLabel,ipv6AddressEdit);
mDetailLayout->addRow(mSubnetLabel,lengthEdit);
mDetailLayout->addRow(mGateWayLabel,gateWayEdit);
mDetailLayout->addRow(mDnsLabel,firstDnsEdit);
mDetailLayout->addRow(mSecDnsLabel,secondDnsEdit);
m_detailLayout = new QFormLayout(this);
m_detailLayout->addRow(m_configLabel,ipv6ConfigCombox);
m_detailLayout->addRow(m_addressLabel,ipv6AddressEdit);
m_detailLayout->addRow(m_subnetLabel,lengthEdit);
m_detailLayout->addRow(m_gateWayLabel,gateWayEdit);
m_detailLayout->addRow(m_dnsLabel,firstDnsEdit);
m_detailLayout->addRow(m_secDnsLabel,secondDnsEdit);
ipv6ConfigCombox->addItem(tr("Auto(DHCP)")); //"自动(DHCP)"
ipv6ConfigCombox->addItem(tr("Manual")); //"手动"
@ -76,33 +76,33 @@ void Ipv6Page::initUI() {
}
void Ipv6Page::initComponent() {
if (ipv6ConfigCombox->currentIndex() == 0) {
if (ipv6ConfigCombox->currentIndex() == MANUAL_CONFIG) {
setControlEnabled(false);
} else if (ipv6ConfigCombox->currentIndex() == 1) {
} else if (ipv6ConfigCombox->currentIndex() == MANUAL_CONFIG) {
setControlEnabled(true);
}
connect(ipv6ConfigCombox, SIGNAL(currentIndexChanged(int)), this, SLOT(configChanged(int)));
}
void Ipv6Page::configChanged(int index) {
if (index == 0) {
if (index == AUTO_CONFIG) {
setControlEnabled(false);
}
if (index == 1) {
if (index == MANUAL_CONFIG) {
setControlEnabled(true);
}
}
void Ipv6Page::setControlEnabled(bool check) {
mAddressLabel->setEnabled(check);
mSubnetLabel->setEnabled(check);
m_addressLabel->setEnabled(check);
m_subnetLabel->setEnabled(check);
lengthEdit->setEnabled(check);
mGateWayLabel->setEnabled(check);
mDnsLabel->setEnabled(check);
mSecDnsLabel->setEnabled(check);
m_gateWayLabel->setEnabled(check);
m_dnsLabel->setEnabled(check);
m_secDnsLabel->setEnabled(check);
ipv6AddressEdit->setEnabled(check);
mSubnetLabel->setEnabled(check);
m_subnetLabel->setEnabled(check);
gateWayEdit->setEnabled(check);
firstDnsEdit->setEnabled(check);
secondDnsEdit->setEnabled(check);

View File

@ -16,7 +16,7 @@ class Ipv6Page : public QFrame
{
Q_OBJECT
public:
Ipv6Page(bool isWlan);
Ipv6Page(bool isWlan, QWidget *parent = nullptr);
void setIpv6Config(const QString &ipv6Config);
void setIpv6(const QString &ipv4);
void setIpv6FirDns(const QString &ipv6FirDns);
@ -30,15 +30,14 @@ public:
QLineEdit *gateWayEdit;
QLineEdit *firstDnsEdit;
QLineEdit *secondDnsEdit;
QLabel *mConfigLabel;
QLabel *mAddressLabel;
QLabel *mSubnetLabel;
QLabel *mGateWayLabel;
QLabel *mDnsLabel;
QLabel *mSecDnsLabel;
private:
QFormLayout *mDetailLayout;
QFormLayout *m_detailLayout;
QLabel *m_configLabel;
QLabel *m_addressLabel;
QLabel *m_subnetLabel;
QLabel *m_gateWayLabel;
QLabel *m_dnsLabel;
QLabel *m_secDnsLabel;
private:
bool isWlan;
private:

View File

@ -1,17 +1,32 @@
#include "netdetail.h"
#define WINDOW_WIDTH 540
#define WINDOW_HEIGHT 574
#define BUTTON_SIZE 30
#define ICON_SIZE 22,22
#define TITLE_LAYOUT_MARGINS 9,9,0,0
#define LAYOUT_MARGINS 24,0,24,0
#define BOTTOM_LAYOUT_SPACING 16
#define PAGE_LAYOUT_SPACING 1
#define DETAIL_PAGE_NUM 0
#define IPV4_PAGE_NUM 1
#define IPV6_PAGE_NUM 2
#define SECURITY_PAGE_NUM 3
#define CREATE_NET_PAGE_NUM 4
#define PAGE_MIN_HEIGHT 40
extern void qt_blurImage(QImage &blurImage, qreal radius, bool quality, int transposed);
NetDetail::NetDetail(QString name, QString uuid, bool isActive, bool isWlan, bool isCreateNet, QWidget *parent)
:name(name), uuid(uuid), isActive(isActive), isWlan(isWlan), isCreateNet(isCreateNet), QDialog(parent)
:m_name(name), m_uuid(uuid), isActive(isActive), isWlan(isWlan), isCreateNet(isCreateNet), QDialog(parent)
{
setWindowFlags(Qt::FramelessWindowHint | Qt::Tool);
setAttribute(Qt::WA_TranslucentBackground);
setAttribute(Qt::WA_DeleteOnClose);
setFixedSize(540,574);
m_netDeviceResource = new KyNetworkDeviceResourse;
setFixedSize(WINDOW_WIDTH,WINDOW_HEIGHT);
centerToScreen();
m_netDeviceResource = new KyNetworkDeviceResourse(this);
initWifiDevice();
initLanDevice();
initUI();
@ -38,14 +53,14 @@ void NetDetail::centerToScreen()
void NetDetail::initUI()
{
QVBoxLayout *vboxLayout = new QVBoxLayout(this);
vboxLayout->setContentsMargins(9,9,14,24);
QVBoxLayout *mainLayout = new QVBoxLayout(this);
mainLayout->setContentsMargins(9,9,14,24);
detailPage = new DetailPage(isWlan);
ipv4Page = new Ipv4Page(isWlan);
ipv6Page = new Ipv6Page(isWlan);
securityWidget = new SecurityPage;
createNetPage = new CreatNetPage;
detailPage = new DetailPage(isWlan,this);
ipv4Page = new Ipv4Page(isWlan,this);
ipv6Page = new Ipv6Page(isWlan,this);
securityWidget = new SecurityPage(this);
createNetPage = new CreatNetPage(this);
// addLanWidget = new AddLanWidget;
titleWidget = new QWidget(this);
@ -59,73 +74,73 @@ void NetDetail::initUI()
stackWidget->addWidget(securityWidget);
stackWidget->addWidget(createNetPage);
vboxLayout->addWidget(titleWidget);
vboxLayout->addWidget(centerWidget);
vboxLayout->addWidget(bottomWidget);
mainLayout->addWidget(titleWidget);
mainLayout->addWidget(centerWidget);
mainLayout->addWidget(bottomWidget);
titleWidget->setMinimumHeight(40);
bottomWidget->setMinimumHeight(40);
titleWidget->setMinimumHeight(PAGE_MIN_HEIGHT);
bottomWidget->setMinimumHeight(PAGE_MIN_HEIGHT);
QHBoxLayout *titleLayout = new QHBoxLayout(titleWidget);
titleLayout->setContentsMargins(9,9,0,0);
titleLayout->setContentsMargins(TITLE_LAYOUT_MARGINS);
pageFrame = new QFrame(this);
QHBoxLayout *pageLayout = new QHBoxLayout(pageFrame);
pageLayout->setSpacing(1);
pageLayout->setSpacing(PAGE_LAYOUT_SPACING);
detailBtn = new QPushButton(this);
detailBtn->setText(tr("Detail"));
Ipv4Btn = new QPushButton(this);
Ipv4Btn->setText(tr("Ipv4"));
ipv4Btn = new QPushButton(this);
ipv4Btn->setText(tr("Ipv4"));
Ipv6Btn = new QPushButton(this);
Ipv6Btn->setText(tr("Ipv6"));
ipv6Btn = new QPushButton(this);
ipv6Btn->setText(tr("Ipv6"));
SecurityBtn = new QPushButton(this);
SecurityBtn->setText(tr("Security"));
securityBtn = new QPushButton(this);
securityBtn->setText(tr("Security"));
pageLayout->addStretch();
pageLayout->addWidget(detailBtn);
pageLayout->addWidget(Ipv4Btn);
pageLayout->addWidget(Ipv6Btn);
pageLayout->addWidget(SecurityBtn);
pageLayout->addWidget(ipv4Btn);
pageLayout->addWidget(ipv6Btn);
pageLayout->addWidget(securityBtn);
pageLayout->addStretch();
closeBtn = new QPushButton;
closeBtn->setFixedSize(30,30);
closeBtn = new QPushButton(this);
closeBtn->setFixedSize(BUTTON_SIZE,BUTTON_SIZE);
closeBtn->setToolTip(tr("Close"));
closeBtn->setProperty("isWindowButton", 0x02);
closeBtn->setProperty("useIconHighlightEffect", 0x08);
closeBtn->setFlat(true);
closeBtn->setIcon(QIcon::fromTheme("window-close-symbolic"));
confimBtn = new QPushButton;
confimBtn = new QPushButton(this);
confimBtn->setText(tr("Confirm"));
cancelBtn = new QPushButton;
cancelBtn = new QPushButton(this);
cancelBtn->setText(tr("Cancel"));
forgetBtn = new QPushButton;
forgetBtn = new QPushButton(this);
forgetBtn->setText(tr("Forget this network"));
titleLabel = new QLabel;
titleLabel->setMinimumHeight(20);
titleLabel = new QLabel(this);
iconLabel = new QLabel;
iconLabel->setFixedSize(22,22);
iconLabel = new QLabel(this);
iconLabel->setFixedSize(ICON_SIZE);
titleLayout->addWidget(iconLabel);
titleLayout->addWidget(titleLabel);
titleLayout->addStretch();
titleLayout->addWidget(closeBtn);
QVBoxLayout *layout = new QVBoxLayout(centerWidget);
layout->setContentsMargins(24,0,24,0);
layout->addWidget(pageFrame);
layout->addWidget(stackWidget);
QVBoxLayout *centerlayout = new QVBoxLayout(centerWidget);
centerlayout->setContentsMargins(LAYOUT_MARGINS);
centerlayout->addWidget(pageFrame);
centerlayout->addWidget(stackWidget);
QHBoxLayout *bottomLayout = new QHBoxLayout(bottomWidget);
bottomLayout->setContentsMargins(24,0,24,0);
bottomLayout->setSpacing(16);
bottomLayout->setContentsMargins(LAYOUT_MARGINS);
bottomLayout->setSpacing(BOTTOM_LAYOUT_SPACING);
bottomLayout->addWidget(forgetBtn);
bottomLayout->addStretch();
bottomLayout->addWidget(cancelBtn);
@ -138,16 +153,16 @@ void NetDetail::loadPage()
//判断是否创建网络
if (isCreateNet) {
pageFrame->hide();
stackWidget->setCurrentIndex(4);
stackWidget->setCurrentIndex(CREATE_NET_PAGE_NUM);
titleLabel->setText(tr("Add Connect"));
} else {
stackWidget->setCurrentIndex(0);
titleLabel->setText(name);
stackWidget->setCurrentIndex(DETAIL_PAGE_NUM);
titleLabel->setText(m_name);
}
if (!isWlan) {
SecurityBtn->hide();
securityBtn->hide();
} else {
SecurityBtn->show();
securityBtn->show();
}
}
@ -160,16 +175,16 @@ void NetDetail::initComponent()
close();
});
connect(detailBtn, &QPushButton::clicked, this, [=] {
stackWidget->setCurrentIndex(0);
stackWidget->setCurrentIndex(DETAIL_PAGE_NUM);
});
connect(Ipv4Btn, &QPushButton::clicked, this, [=] {
stackWidget->setCurrentIndex(1);
connect(ipv4Btn, &QPushButton::clicked, this, [=] {
stackWidget->setCurrentIndex(IPV4_PAGE_NUM);
});
connect(Ipv6Btn, &QPushButton::clicked, this, [=] {
stackWidget->setCurrentIndex(2);
connect(ipv6Btn, &QPushButton::clicked, this, [=] {
stackWidget->setCurrentIndex(IPV6_PAGE_NUM);
});
connect(SecurityBtn, &QPushButton::clicked, this, [=] {
stackWidget->setCurrentIndex(3);
connect(securityBtn, &QPushButton::clicked, this, [=] {
stackWidget->setCurrentIndex(SECURITY_PAGE_NUM);
});
connect(confimBtn, SIGNAL(clicked()), this, SLOT(on_btnConfirm_clicked()));
}
@ -204,7 +219,7 @@ void NetDetail::pagePadding(QString netName, bool isWlan)
}
//ipv4页面填充
if (!netInfo.strConName.compare(netName, Qt::CaseInsensitive)) {
if (netInfo.strIPV4ConfigType == "0") {
if (netInfo.strIPV4ConfigType.toInt() == AUTO_CONFIG) {
ipv4Page->setIpv4Config(netInfo.strIPV4ConfigType);
ipv4Page->setIpv4(netInfo.strIPV4Address);
ipv4Page->setIpv4FirDns(netInfo.strIPV4FirDns);
@ -216,7 +231,7 @@ void NetDetail::pagePadding(QString netName, bool isWlan)
}
//ipv6页面填充
if (!netInfo.strConName.compare(netName, Qt::CaseInsensitive)) {
if (netInfo.strIPV4ConfigType == "0") {
if (netInfo.strIPV4ConfigType.toInt() == AUTO_CONFIG) {
ipv6Page->setIpv6Config(netInfo.strIPV6ConfigType);
ipv6Page->setIpv6(netInfo.strIPV4Address);
ipv6Page->setIpv6FirDns(netInfo.strIPV6FirDns);
@ -258,11 +273,11 @@ void NetDetail::initWifiDevice()
m_settings->beginGroup("DEFAULTCARD");
QString key("wireless");
QString deviceName = m_settings->value(key, "").toString();
m_netDeviceResource->getNetworkDeviceList(NetworkManager::Device::Type::Wifi, devList);
m_netDeviceResource->getNetworkDeviceList(NetworkManager::Device::Type::Wifi, m_devList);
if (deviceName.isEmpty()) {
qDebug() << "initDevice but defalut wireless card is null";
if (!devList.isEmpty()) {
deviceName = devList.at(0);
if (!m_devList.isEmpty()) {
deviceName = m_devList.at(0);
m_settings->setValue(key, deviceName);
}
}
@ -287,17 +302,17 @@ void NetDetail::getConInfo(QList<ConInfo>& qlConInfo)
QString hardAddress;
int bandWith;
if (!devList.isEmpty()) {
deviceName = devList.at(0);
if (!m_devList.isEmpty()) {
deviceName = m_devList.at(0);
}
if(isWlan) {
if (!m_resource->getWifiNetwork(deviceName, name, kyWirelessNetItem)) {
if (!m_resource->getWifiNetwork(deviceName, m_name, kyWirelessNetItem)) {
return;
}
}
kyConnectResourse->getConnectionSetting(uuid,connetSetting);
kyConnectResourse->getConnectionSetting(m_uuid,connetSetting);
conInfo.strConUUID = uuid;
conInfo.strConUUID = m_uuid;
conInfo.strIPV4ConfigType = QString("%1").arg(connetSetting.m_ipv4ConfigIpType);
conInfo.strIPV6ConfigType = QString("%1").arg(connetSetting.m_ipv6ConfigIpType);
qDebug()<<"conInfo.strConUUID:"<<conInfo.strConUUID<<"conInfo.strSecType"<<conInfo.strSecType;
@ -323,11 +338,11 @@ void NetDetail::getConInfo(QList<ConInfo>& qlConInfo)
KyActiveConnectResourse *activeResourse = new KyActiveConnectResourse;
QString ipv4,ipv6;
QList<QHostAddress> ipv4Dns,ipv6Dns;
activeResourse->getActiveConnectIpInfo(uuid,ipv4,ipv6);
activeResourse->getActiveConnectDnsInfo(uuid,ipv4Dns,ipv6Dns);
activeResourse->getActiveConnectIpInfo(m_uuid,ipv4,ipv6);
activeResourse->getActiveConnectDnsInfo(m_uuid,ipv4Dns,ipv6Dns);
m_netDeviceResource->getHardwareInfo(deviceName, hardAddress, bandWith);
qDebug()<<"802-11-wireless : "<<"deviceName:"<<deviceName<<",ssid:"<<ssid<<",uuid:"<<uuid;
qDebug()<<"802-11-wireless : "<<"deviceName:"<<deviceName<<",ssid:"<<m_ssid<<",uuid:"<<m_uuid;
if (ipv4Dns.length() == 1) {
conInfo.strIPV4FirDns = ipv4Dns.at(0).toString();
@ -363,8 +378,8 @@ void NetDetail::getConInfo(QList<ConInfo>& qlConInfo)
conInfo.strConType = "802-11-wireless";
} else {
conInfo.strConType = "802-3-ethernet";
qDebug()<<"802-11-ethernet : "<<"deviceName:"<<m_deviceName<<",ssid:"<<ssid<<",uuid:"<<uuid;
conInfo.strConName = name;
qDebug()<<"802-11-ethernet : "<<"deviceName:"<<m_deviceName<<",ssid:"<<m_ssid<<",uuid:"<<m_uuid;
conInfo.strConName = m_name;
qDebug()<<"conInfo.strConName :aaaaaa"<<conInfo.strConName;
m_netDeviceResource->getHardwareInfo(m_deviceName, hardAddress, bandWith);
if (connetSetting.m_ipv4Dns.length() == 1) {

View File

@ -30,6 +30,9 @@
#include "kywirelessnetresource.h"
#include "tab-pages/tabpage.h"
static int AUTO_CONFIG = 0;
static int MANUAL_CONFIG = 1;
typedef struct ConInfo_s {
QString strConName;
QString strConUUID;
@ -102,15 +105,15 @@ private:
QPushButton * confimBtn;
QPushButton * detailBtn;
QPushButton * Ipv4Btn;
QPushButton * Ipv6Btn;
QPushButton * SecurityBtn;
QPushButton * ipv4Btn;
QPushButton * ipv6Btn;
QPushButton * securityBtn;
QFrame * pageFrame;
QString name;
QString uuid;
QString ssid;
QStringList devList;
QString m_name;
QString m_uuid;
QString m_ssid;
QStringList m_devList;
QString m_deviceName;
bool isWlan;