Changeset View
Changeset View
Standalone View
Standalone View
src/activities/money/MoneyCore.qml
Context not available. | |||||
56 | property alias store: store | 56 | property alias store: store | ||
---|---|---|---|---|---|
57 | property alias instructions: instructions | 57 | property alias instructions: instructions | ||
58 | property alias tux: tux | 58 | property alias tux: tux | ||
59 | property var levels: activity.datasetLoader.item.data | ||||
59 | property alias tuxMoney: tuxMoney | 60 | property alias tuxMoney: tuxMoney | ||
60 | property alias bar: bar | 61 | property alias bar: bar | ||
61 | property alias bonus: bonus | 62 | property alias bonus: bonus | ||
62 | property int itemIndex | 63 | property int itemIndex | ||
64 | property int pocketRows | ||||
65 | property var verticalOrientation: background.height > background.width | ||||
63 | property var selectedArea | 66 | property var selectedArea | ||
64 | property alias pocket: pocketArea.answer | 67 | property alias pocket: pocketArea.answer | ||
65 | property alias answer: answerArea.answer | 68 | property alias answer: answerArea.answer | ||
Context not available. | |||||
76 | width: parent.width * 0.9 | 79 | width: parent.width * 0.9 | ||
77 | 80 | | |||
78 | property int nbColumns: 5 | 81 | property int nbColumns: 5 | ||
79 | property int nbLines: 2 | 82 | property int nbLines: (items.verticalOrientation) ? items.pocketRows + 1 : items.pocketRows | ||
80 | property int itemWidth: | 83 | property int itemWidth: | ||
81 | Math.min(width / nbColumns - 10 - 10 / nbColumns, | 84 | Math.min(width / nbColumns - 10 - 10 / nbColumns, | ||
82 | parent.height * 0.4 / nbLines - 10 - 10 / nbLines) | 85 | parent.height * 0.4 / nbLines - 10 - 10 / nbLines) | ||
Context not available. | |||||
101 | 104 | | |||
102 | Rectangle { | 105 | Rectangle { | ||
103 | id: storeArea | 106 | id: storeArea | ||
104 | height: (columnLayout.itemStoreHeight + 10) | 107 | height: columnLayout.itemStoreHeight + 10 | ||
105 | width: columnLayout.width | 108 | width: columnLayout.width | ||
106 | color: "#55333333" | 109 | color: "#55333333" | ||
107 | border.color: "black" | 110 | border.color: "black" | ||
108 | border.width: 2 | 111 | border.width: 2 | ||
109 | radius: 5 | 112 | radius: 5 | ||
110 | | ||||
111 | Flow { | 113 | Flow { | ||
112 | id: storeAreaFlow | 114 | id: storeAreaFlow | ||
113 | anchors.topMargin: 4 | 115 | anchors.topMargin: 4 | ||
Context not available. | |||||
135 | Repeater { | 137 | Repeater { | ||
136 | id: tuxMoney | 138 | id: tuxMoney | ||
137 | Image { | 139 | Image { | ||
138 | source: Activity.url + modelData.img | 140 | source: modelData.img | ||
139 | sourceSize.height: columnLayout.itemStoreHeight * 0.4 | 141 | sourceSize.height: columnLayout.itemStoreHeight * 0.4 | ||
140 | x: tux.x + index * 20 | 142 | x: tux.x + index * 50 | ||
141 | y: tux.y + tux.height / 2 + index * 20 | 143 | y: tux.y + tux.height / 2 + index * 20 | ||
142 | } | 144 | } | ||
143 | } | 145 | } | ||
Context not available. | |||||
146 | Repeater { | 148 | Repeater { | ||
147 | id: store | 149 | id: store | ||
148 | Image { | 150 | Image { | ||
149 | source: Activity.url + modelData.img | 151 | source: modelData.img | ||
150 | sourceSize.height: columnLayout.itemStoreHeight | 152 | sourceSize.height: columnLayout.itemStoreHeight | ||
151 | sourceSize.width: columnLayout.itemStoreHeight | 153 | sourceSize.width: columnLayout.itemStoreHeight | ||
152 | GCText { | 154 | GCText { | ||
Context not available. |