ToolChainOptionsPage: Don't leak QMenu

Change-Id: I2d123b72a28f9aa9c566f0b186817c94e5ecacd3
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
This commit is contained in:
Jarek Kobus
2024-03-14 16:00:06 +01:00
parent 7fbb7e0bee
commit 4a7f3db615

View File

@@ -193,7 +193,7 @@ public:
m_toolChainView->expandAll(); m_toolChainView->expandAll();
m_addButton = new QPushButton(Tr::tr("Add"), this); m_addButton = new QPushButton(Tr::tr("Add"), this);
auto addMenu = new QMenu; auto addMenu = new QMenu(this);
for (ToolchainFactory *factory : std::as_const(m_factories)) { for (ToolchainFactory *factory : std::as_const(m_factories)) {
QList<Utils::Id> languages = factory->supportedLanguages(); QList<Utils::Id> languages = factory->supportedLanguages();
if (languages.isEmpty()) if (languages.isEmpty())