fix: 修复蓝牙列表hover颜色错误问题

窗口必须初始化父窗口,否则当主题切换之后再设置父窗口的时候palette会更改为主题切换前的palette

Log: 优化蓝牙列表hover效果
Bug: https://pms.uniontech.com/zentao/bug-view-83257.html
Change-Id: Ib2bf437232ac9784a41f47c92720181c6a9ab31c
This commit is contained in:
yanghongwei 2021-06-25 15:29:25 +08:00
parent 12383fd53e
commit 19cc7effa0

View File

@ -69,6 +69,11 @@ SystemTrayItem::SystemTrayItem(PluginsItemInterface *const pluginInter, const QS
connect(qApp, &QApplication::aboutToQuit, PopupWindow, &DockPopupWindow::deleteLater);
}
// 必须初始化父窗口否则当主题切换之后再设置父窗口的时候palette会更改为主题切换前的palette
if (QWidget *w = m_pluginInter->itemPopupApplet(m_itemKey)) {
w->setParent(PopupWindow.data());
}
m_popupTipsDelayTimer->setInterval(500);
m_popupTipsDelayTimer->setSingleShot(true);