chore: 修复任务栏内存泄露

修复任务栏内存泄露,不影响功能

Log: 修复任务栏内存泄露
Influence: 任务栏
Task: https://pms.uniontech.com/zentao/task-view-88885.html
Change-Id: Id0e1ecd672c91dce79d66c2d45115279657948a1
This commit is contained in:
donghualin 2021-10-25 11:20:48 +08:00
parent 6c9492d971
commit 5c7e5ffefc
2 changed files with 5 additions and 3 deletions

View File

@ -302,6 +302,8 @@ void MainPanelControl::removePluginAreaItem(QWidget *wdg)
if (boxLayout && boxLayout->itemAt(0)->widget() == wdg) { if (boxLayout && boxLayout->itemAt(0)->widget() == wdg) {
boxLayout->removeWidget(wdg); boxLayout->removeWidget(wdg);
m_pluginLayout->removeItem(layoutItem); m_pluginLayout->removeItem(layoutItem);
delete layoutItem;
layoutItem = nullptr;
} }
} }
} }

View File

@ -14,9 +14,9 @@ QAccessibleInterface *soundAccessibleFactory(const QString &classname, QObject *
{ {
QAccessibleInterface *interface = nullptr; QAccessibleInterface *interface = nullptr;
USE_ACCESSIBLE(classname, SoundItem); USE_ACCESSIBLE(classname, SoundItem)
USE_ACCESSIBLE(classname, SoundApplet); ELSE_USE_ACCESSIBLE(classname, SoundApplet)
USE_ACCESSIBLE(classname, VolumeSlider); ELSE_USE_ACCESSIBLE(classname, VolumeSlider);
return interface; return interface;
} }