From 6853e47fb8269eff0878698106d987104db75318 Mon Sep 17 00:00:00 2001 From: Marcus Tillmanns Date: Mon, 16 Sep 2024 09:00:36 +0200 Subject: [PATCH] ProjectExplorer: Remove "Add Library" from context menu "Add Library" is only available if the project is a qmake project. This patch removes it in case its not a qmake project. Change-Id: I1f37139584fed3bfb784b7b54b4693f2f3d526dd Reviewed-by: Christian Kandeler --- src/plugins/qmakeprojectmanager/qmakeprojectmanagerplugin.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/plugins/qmakeprojectmanager/qmakeprojectmanagerplugin.cpp b/src/plugins/qmakeprojectmanager/qmakeprojectmanagerplugin.cpp index c2f2d2c6e22..035d878fce2 100644 --- a/src/plugins/qmakeprojectmanager/qmakeprojectmanagerplugin.cpp +++ b/src/plugins/qmakeprojectmanager/qmakeprojectmanagerplugin.cpp @@ -489,7 +489,7 @@ void QmakeProjectManagerPluginPrivate::updateContextActions(Node *node) const ContainerNode *containerNode = node ? node->asContainerNode() : nullptr; const auto *proFileNode = dynamic_cast(containerNode ? containerNode->rootProjectNode() : node); - m_addLibraryActionContextMenu->setEnabled(proFileNode); + m_addLibraryActionContextMenu->setVisible(proFileNode); auto *qmakeProject = qobject_cast(project); QmakeProFileNode *subProjectNode = nullptr; disableBuildFileMenus();