Details
-
Bug
-
Resolution: Done
-
P3: Somewhat important
-
5.1.0 RC2, 5.1.1
-
None
-
-
ae380584de53cf927fe4a7bd62ffb41f73b1faa1
Description
Destroying a menu causes the following warning:
"virtual void QCocoaMenu::removeMenuItem(QPlatformMenuItem *) Menu does not contain the item to be removed"
Warnings are generated when running the QtQuickControls autotests on mac. And this can also be reproduced using the test case:
1 - click the button once to create the combo box
2 - click the button a second time to destroy it
=> the warning specified above is generated
import QtQuick 2.1 import QtQuick.Controls 1.0 Item { id: root width: 640 height: 480 property bool created: false property var combobox; Button { text: qsTr("click me") anchors.centerIn: parent onClicked: { if (!created) { combobox = Qt.createQmlObject('import QtQuick.Controls 1.0 ; ComboBox {}', root, ''); created = true } else { combobox.destroy() } } } }