Skip to content

Instantly share code, notes, and snippets.

@iamutkarshtiwari
Created September 30, 2016 18:41
Show Gist options
  • Select an option

  • Save iamutkarshtiwari/bf12ac134c16f75a3e865082236b1720 to your computer and use it in GitHub Desktop.

Select an option

Save iamutkarshtiwari/bf12ac134c16f75a3e865082236b1720 to your computer and use it in GitHub Desktop.
// All blue balls placement
Row {
id: blueAnswerBallsPlacement
x: rootWindow.width / 2000
y: rootWindow.height / 1.2
Repeater {
model: 15
Image {
source: "resources/bargame/blue_ball.png"
height: rootWindow.height / 9
width: rootWindow.width / 15
visible: true
}
}
}
// OK BUTTON
Rectangle {
id: playLabel
x: rootWindow.width / 1.2
y: rootWindow.height / 2
width: rootWindow.width / 10
height: rootWindow.height / 9
color: "red"
border.color: "black"
border.width: 5
radius: 10
Text {
id: play
text: "OK"
font.bold: true
color: "white"
font.pixelSize: rootWindow.height / 17
anchors.centerIn: playLabel
}
MouseArea {
anchors.fill: parent
onClicked: {
blueAnswerBallsPlacement.children[2].visible = false;
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment