added GameComboBox
This commit is contained in:
parent
03ec3b9c58
commit
79187ba807
3 changed files with 34 additions and 0 deletions
|
@ -11,6 +11,18 @@ Page {
|
|||
}
|
||||
|
||||
signal pageOpened()
|
||||
GameComboBox {
|
||||
height: 40
|
||||
width: 140
|
||||
}
|
||||
ComboBox {
|
||||
anchors {
|
||||
top: parent.top
|
||||
topMargin: 40
|
||||
}
|
||||
}
|
||||
|
||||
/*
|
||||
GameButton {
|
||||
id: calenderButton
|
||||
text: "calender"
|
||||
|
@ -40,4 +52,5 @@ Page {
|
|||
game.calculator()
|
||||
}
|
||||
}
|
||||
*/
|
||||
}
|
||||
|
|
20
qml/components/GameComboBox.qml
Normal file
20
qml/components/GameComboBox.qml
Normal file
|
@ -0,0 +1,20 @@
|
|||
import QtQuick 2.0
|
||||
import QtQuick.Controls 2.2
|
||||
|
||||
Item {
|
||||
property string clickedColor: "#BDBDBD"
|
||||
property string normalColor: "#e0e0e0"
|
||||
property string color: normalColor
|
||||
Rectangle {
|
||||
color: parent.color
|
||||
width: parent.width
|
||||
height: parent.height
|
||||
}
|
||||
|
||||
MouseArea {
|
||||
width: parent.width
|
||||
height: parent.height
|
||||
onPressed: parent.color = parent.clickedColor
|
||||
onReleased: parent.color = parent.normalColor
|
||||
}
|
||||
}
|
|
@ -11,5 +11,6 @@
|
|||
<file>calender/CalenderRunningPage.qml</file>
|
||||
<file>calender/CalenderGameOverPage.qml</file>
|
||||
<file>components/GameButton.qml</file>
|
||||
<file>components/GameComboBox.qml</file>
|
||||
</qresource>
|
||||
</RCC>
|
||||
|
|
Loading…
Reference in a new issue