Skip to content
Snippets Groups Projects
Commit 4f1181c2 authored by Yuya Nishihara's avatar Yuya Nishihara
Browse files

add button to toggle timer

parent b51ae6f8
No related branches found
No related tags found
No related merge requests found
......@@ -4,6 +4,8 @@ import QtQuick.Layouts 1.12
import QtQuick.Window 2.12
Window {
id: root
width: 640
height: 480
visible: true
......@@ -14,15 +16,23 @@ Window {
Button {
id: button
Layout.alignment: Qt.AlignHCenter
text: "Greeting to crash"
onClicked: {
serviceObject.greeting();
}
}
Button {
id: timerButton
Layout.alignment: Qt.AlignHCenter
text: "start timer to destroy"
checkable: true
}
}
Timer {
running: true
running: timerButton.checked
interval: 5000
onTriggered: {
console.log("triggered");
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment