import QtQuick 2.1 import QtQuick.Controls 1.1 Item { width: 400; height: 200 Action { id: action2 text: "Action2" } Menu { id: menu MenuItem { id: menuItem action: Action { id: action1 text: "Action1" onTriggered: { menuItem.action = action2 } } } } //note how this should have prevented GC-ing property QtObject action1Ref: action1 MouseArea { anchors.fill: parent onClicked: menu.popup() } }