From e4ff9e5a64c77833cd64965a69b8f3feb342bf58 Mon Sep 17 00:00:00 2001 From: zhangyuanyuan1 Date: Fri, 15 Sep 2023 18:05:13 +0800 Subject: [PATCH] fix(ui): hide minimize button for detailpage(bug#193349 #191910) --- src/frontend/enterprise-wlan/enterprisewlandialog.cpp | 3 ++- src/frontend/netdetails/netdetail.cpp | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/src/frontend/enterprise-wlan/enterprisewlandialog.cpp b/src/frontend/enterprise-wlan/enterprisewlandialog.cpp index 36bbeb5f..a593c106 100644 --- a/src/frontend/enterprise-wlan/enterprisewlandialog.cpp +++ b/src/frontend/enterprise-wlan/enterprisewlandialog.cpp @@ -51,7 +51,8 @@ EnterpriseWlanDialog::EnterpriseWlanDialog(KyWirelessNetItem &wirelessNetItem, Q // this->setWindowFlags(Qt::Dialog | Qt::FramelessWindowHint); //#endif this->setAttribute(Qt::WA_DeleteOnClose); - this->setWindowFlag(Qt::Window); +// this->setWindowFlag(Qt::Window); + this->setWindowFlags(Qt::Dialog); // this->setWindowTitle(tr("Connect Enterprise WLAN")); this->setWindowIcon(QIcon::fromTheme("kylin-network")); KWindowSystem::setState(this->winId(), NET::SkipTaskbar | NET::SkipPager); diff --git a/src/frontend/netdetails/netdetail.cpp b/src/frontend/netdetails/netdetail.cpp index edc0d636..b170674d 100644 --- a/src/frontend/netdetails/netdetail.cpp +++ b/src/frontend/netdetails/netdetail.cpp @@ -157,12 +157,13 @@ NetDetail::NetDetail(QString interface, QString name, QString uuid, bool isActiv // XAtomHelper::getInstance()->setWindowMotifHint(this->winId(), window_hints); //#else // this->setWindowFlags(Qt::Dialog /*| Qt::FramelessWindowHint*/); - this->setWindowFlag(Qt::Window); +// this->setWindowFlag(Qt::Window); KWindowSystem::setState(this->winId(), NET::SkipTaskbar | NET::SkipPager); //#endif // this->setProperty("useStyleWindowManager", false); //禁用拖动 // setWindowFlags(Qt::Dialog | Qt::FramelessWindowHint ); // setAttribute(Qt::WA_TranslucentBackground); + setWindowFlags(Qt::Dialog); setAttribute(Qt::WA_DeleteOnClose); setFixedSize(WINDOW_WIDTH,WINDOW_HEIGHT); centerToScreen();