fix: Icon size adaptive abnormal

当特效模式关闭后,任务栏的“多任务视图”图标会隐藏,此时任务栏图标应重新计算图标大小,调整显示区域。

Log: 修复关闭特效后任务栏图标大小错误的问题。
Bug: https://pms.uniontech.com/zentao/bug-view-47755.html
Change-Id: Ifbc697c4fa897953f8051eb3e86b73af5eb2f99a
Reviewed-on: http://gerrit.uniontech.com/c/dde-dock/+/5210
Reviewed-by: <mailman@uniontech.com>
Reviewed-by: fanpengcheng <fanpengcheng@uniontech.com>
Tested-by: <mailman@uniontech.com>
This commit is contained in:
Zhang Qipeng 2020-09-17 11:28:47 +08:00 committed by zhangqipeng
parent 00d99837a5
commit 38683211fa

View File

@ -573,15 +573,17 @@ void MainPanelControl::dragMoveEvent(QDragMoveEvent *e)
bool MainPanelControl::eventFilter(QObject *watched, QEvent *event)
{
if (watched == m_appAreaSonWidget) {
if (event->type() == QEvent::LayoutRequest) {
switch (event->type()) {
case QEvent::LayoutRequest:
m_appAreaSonWidget->adjustSize();
resizeDockIcon();
} else {
moveAppSonWidget();
}
if (event->type() == QEvent::Resize) {
break;
case QEvent::Paint:
resizeDockIcon();
break;
default:
moveAppSonWidget();
break;
}
}