解决 131035 【wayland】【控制面板】【系统】设置缩放屏幕或方向后,右下角自动弹出电池模式窗口;

This commit is contained in:
何朴尧 2022-07-30 08:11:44 +00:00 committed by Gitee
parent 3f9086a5ad
commit f77c873b8c
No known key found for this signature in database
GPG Key ID: 173E9B9CA92EEF8F
1 changed files with 3 additions and 3 deletions

View File

@ -77,14 +77,14 @@ powerwindow::powerwindow(QWidget *parent) : QWidget(parent)
initgsetting();
// set_window_position(); //设置出现在屏幕的位置以及大小
watchTranspartency();
#if 0
//监听屏幕改变的信号
connect(QApplication::desktop(), &QDesktopWidget::resized, this, [=]() {
QTimer::singleShot(1000, this, [=]() { set_window_position(); });
});
connect(QApplication::desktop(), &QDesktopWidget::screenCountChanged, this, [=]() { set_window_position(); });
connect(QApplication::desktop(), &QDesktopWidget::primaryScreenChanged, this, [=]() { set_window_position(); });
#endif
installEventFilter(this);
}
@ -170,7 +170,7 @@ void powerwindow::initUI()
get_power_list();
//this->setFixedSize(420, 258 + deviceNum * 48);
this->setFixedSize(420, 258 + deviceNum * 48);
//电源设置按钮
settingLabel = new KyLable();