import QtQuick 1.0
import org.hildon.components 1.0
Window {
id: window
title: qsTr("Actions Example")
visible: true
action: action1
}
action: action2
}
}
id: group
}
id: action1
autoRepeat: false
checkable: true
exclusiveGroup: group
shortcut: Qt.Key_A
text: qsTr("Action One")
onTriggered: console.log(qsTr("Action One triggered"))
}
id: action2
autoRepeat: false
checkable: true
exclusiveGroup: group
shortcut: Qt.Key_B
text: qsTr("Action Two")
onTriggered: console.log(qsTr("Action Two triggered"))
}
MouseArea {
anchors.fill: parent
onClicked: menu.popup()
}
Column {
anchors.centerIn: parent
action: action1
}
action: action2
}
}
id: menu
action: action1
}
action: action2
}
}
}