Details
-
Bug
-
Resolution: Duplicate
-
P3: Somewhat important
-
None
-
5.11.1
-
None
Description
When a MenuItem has "visible: false" set (or is behind a Loader that is not active), it still leaves an empty menu entry.
import QtQuick 2.0 import QtQuick.Controls 2.2 Rectangle { id: root width: 1024 height: 768 color: "blue" property bool showEntry: true Menu { id: testMenu MenuItem { text: "Static" } MenuItem { visible: root.showEntry text: "Dynamic" } } MouseArea { anchors.fill: parent onClicked: { root.showEntry = false testMenu.popup(mouse.x, mouse.y) } } }
Attachments
Issue Links
- duplicates
-
QTBUG-54767 Qt.Quick.Controls 2.0 MenuItem appears even when visible:false
- Open