author | unc0rr |
Wed, 03 Dec 2014 23:36:18 +0300 | |
branch | qmlfrontend |
changeset 10610 | eadf2cea55e0 |
parent 10608 | b85759f2ba18 |
child 10612 | eb3c1a289a23 |
permissions | -rw-r--r-- |
10422 | 1 |
import QtQuick 2.0 |
2 |
import Hedgewars.Engine 1.0 |
|
3 |
||
10442 | 4 |
|
10422 | 5 |
Rectangle { |
6 |
HWButton { |
|
7 |
id: btnPreview |
|
8 |
x: 50 |
|
10434
1614b13ad35e
Themes model, also add some files I forgot to add previously
unc0rr
parents:
10432
diff
changeset
|
9 |
y: 16 |
1614b13ad35e
Themes model, also add some files I forgot to add previously
unc0rr
parents:
10432
diff
changeset
|
10 |
width: 256 |
1614b13ad35e
Themes model, also add some files I forgot to add previously
unc0rr
parents:
10432
diff
changeset
|
11 |
height: 128 |
10422 | 12 |
|
10432 | 13 |
onClicked: HWEngine.getPreview() |
10422 | 14 |
|
15 |
Connections { |
|
16 |
target: HWEngine |
|
10424
4be6cd55f1cf
- Get rid of engine's PathPrefix and UserPathPrefix
unc0rr
parents:
10422
diff
changeset
|
17 |
onPreviewImageChanged: previewImage.source = "image://preview/" + HWEngine.currentSeed() |
10422 | 18 |
} |
10434
1614b13ad35e
Themes model, also add some files I forgot to add previously
unc0rr
parents:
10432
diff
changeset
|
19 |
|
1614b13ad35e
Themes model, also add some files I forgot to add previously
unc0rr
parents:
10432
diff
changeset
|
20 |
Image { |
1614b13ad35e
Themes model, also add some files I forgot to add previously
unc0rr
parents:
10432
diff
changeset
|
21 |
id: previewImage |
1614b13ad35e
Themes model, also add some files I forgot to add previously
unc0rr
parents:
10432
diff
changeset
|
22 |
x: 0 |
1614b13ad35e
Themes model, also add some files I forgot to add previously
unc0rr
parents:
10432
diff
changeset
|
23 |
y: 0 |
1614b13ad35e
Themes model, also add some files I forgot to add previously
unc0rr
parents:
10432
diff
changeset
|
24 |
width: 256 |
1614b13ad35e
Themes model, also add some files I forgot to add previously
unc0rr
parents:
10432
diff
changeset
|
25 |
height: 128 |
1614b13ad35e
Themes model, also add some files I forgot to add previously
unc0rr
parents:
10432
diff
changeset
|
26 |
cache: false |
1614b13ad35e
Themes model, also add some files I forgot to add previously
unc0rr
parents:
10432
diff
changeset
|
27 |
} |
10422 | 28 |
} |
29 |
||
10448 | 30 |
HWButton { |
31 |
id: btnRunGame |
|
32 |
x: 600 |
|
33 |
y: 440 |
|
34 |
width: 32 |
|
35 |
height: 32 |
|
36 |
||
37 |
onClicked: HWEngine.runLocalGame() |
|
38 |
} |
|
39 |
||
10519 | 40 |
HWComboBox { |
10608 | 41 |
id: cbTheme |
10610
eadf2cea55e0
Finish combobox implementation (except for visual part)
unc0rr
parents:
10608
diff
changeset
|
42 |
x: 50 |
eadf2cea55e0
Finish combobox implementation (except for visual part)
unc0rr
parents:
10608
diff
changeset
|
43 |
y: 160 |
eadf2cea55e0
Finish combobox implementation (except for visual part)
unc0rr
parents:
10608
diff
changeset
|
44 |
width: 256 |
eadf2cea55e0
Finish combobox implementation (except for visual part)
unc0rr
parents:
10608
diff
changeset
|
45 |
height: 64 |
10519 | 46 |
|
47 |
model: themesModel |
|
48 |
delegate: Rectangle { |
|
49 |
height: 25 |
|
50 |
width: 100 |
|
51 |
color: "transparent" |
|
10610
eadf2cea55e0
Finish combobox implementation (except for visual part)
unc0rr
parents:
10608
diff
changeset
|
52 |
|
eadf2cea55e0
Finish combobox implementation (except for visual part)
unc0rr
parents:
10608
diff
changeset
|
53 |
property alias itemIconSource: themeIcon.source |
eadf2cea55e0
Finish combobox implementation (except for visual part)
unc0rr
parents:
10608
diff
changeset
|
54 |
property alias itemText: themeName.text |
eadf2cea55e0
Finish combobox implementation (except for visual part)
unc0rr
parents:
10608
diff
changeset
|
55 |
|
10608 | 56 |
Row { |
10610
eadf2cea55e0
Finish combobox implementation (except for visual part)
unc0rr
parents:
10608
diff
changeset
|
57 |
Image {id: themeIcon; width: height; height: parent.height; source: "image://theme/" + modelData} |
10608 | 58 |
Text {id: themeName; text: modelData } |
59 |
} |
|
10610
eadf2cea55e0
Finish combobox implementation (except for visual part)
unc0rr
parents:
10608
diff
changeset
|
60 |
|
10519 | 61 |
MouseArea { |
62 |
z: 1 |
|
63 |
anchors.fill: parent |
|
64 |
onClicked: { |
|
10608 | 65 |
cbTheme.currentIndex = index |
10519 | 66 |
HWEngine.setTheme(themeName.text) |
67 |
} |
|
68 |
} |
|
69 |
} |
|
70 |
} |
|
71 |
||
72 |
/* Rectangle { |
|
10436 | 73 |
x: 320 |
10434
1614b13ad35e
Themes model, also add some files I forgot to add previously
unc0rr
parents:
10432
diff
changeset
|
74 |
y: 16 |
10436 | 75 |
width: 100 |
76 |
height: 256 |
|
77 |
color: "#15193a" |
|
78 |
radius: 8 |
|
79 |
border.width: 4 |
|
80 |
border.color: "#eaea00" |
|
81 |
Image { |
|
82 |
id: themeImage |
|
83 |
x: 0 |
|
84 |
y: 0 |
|
85 |
width: 64 |
|
86 |
height: 64 |
|
87 |
fillMode: Image.Pad |
|
88 |
} |
|
10519 | 89 |
*/ |
10442 | 90 |
|
91 |
ListView { |
|
92 |
id: playingTeamsList |
|
93 |
x: 440 |
|
94 |
y: 16 |
|
95 |
width: 100 |
|
96 |
height: 192 |
|
97 |
highlight: Rectangle { color: "#eaea00"; radius: 4 } |
|
98 |
focus: true |
|
99 |
clip: true |
|
100 |
||
101 |
model: ListModel { |
|
10444
47a6231f1fc1
Teams widget now allows to add and remove teams (basic implementation, no checks performed, no colors, no hedgehogs)
unc0rr
parents:
10442
diff
changeset
|
102 |
id: playingTeamsModel |
10442 | 103 |
} |
104 |
||
105 |
delegate: Rectangle { |
|
106 |
id: teamDelegate |
|
107 |
height: 24 |
|
108 |
width: parent.width |
|
109 |
radius: 8 |
|
110 |
border.width: 2 |
|
111 |
border.color: "#eaea00" |
|
112 |
||
113 |
Row { |
|
10452
03519fd9f98d
Show team color in teams list widget, also allow to change it on mouse click
unc0rr
parents:
10450
diff
changeset
|
114 |
Rectangle { |
03519fd9f98d
Show team color in teams list widget, also allow to change it on mouse click
unc0rr
parents:
10450
diff
changeset
|
115 |
height: 20 |
03519fd9f98d
Show team color in teams list widget, also allow to change it on mouse click
unc0rr
parents:
10450
diff
changeset
|
116 |
width: height |
03519fd9f98d
Show team color in teams list widget, also allow to change it on mouse click
unc0rr
parents:
10450
diff
changeset
|
117 |
color: teamColor |
03519fd9f98d
Show team color in teams list widget, also allow to change it on mouse click
unc0rr
parents:
10450
diff
changeset
|
118 |
border.width: 2 |
03519fd9f98d
Show team color in teams list widget, also allow to change it on mouse click
unc0rr
parents:
10450
diff
changeset
|
119 |
border.color: "#eaea00" |
03519fd9f98d
Show team color in teams list widget, also allow to change it on mouse click
unc0rr
parents:
10450
diff
changeset
|
120 |
|
03519fd9f98d
Show team color in teams list widget, also allow to change it on mouse click
unc0rr
parents:
10450
diff
changeset
|
121 |
MouseArea { |
03519fd9f98d
Show team color in teams list widget, also allow to change it on mouse click
unc0rr
parents:
10450
diff
changeset
|
122 |
z: 1 |
03519fd9f98d
Show team color in teams list widget, also allow to change it on mouse click
unc0rr
parents:
10450
diff
changeset
|
123 |
anchors.fill: parent |
10454
2b590e7972b1
Allow using right button or wheel to change team color
unc0rr
parents:
10452
diff
changeset
|
124 |
acceptedButtons: Qt.LeftButton | Qt.RightButton |
2b590e7972b1
Allow using right button or wheel to change team color
unc0rr
parents:
10452
diff
changeset
|
125 |
onClicked: { |
2b590e7972b1
Allow using right button or wheel to change team color
unc0rr
parents:
10452
diff
changeset
|
126 |
if (mouse.button === Qt.LeftButton) |
2b590e7972b1
Allow using right button or wheel to change team color
unc0rr
parents:
10452
diff
changeset
|
127 |
HWEngine.changeTeamColor(name, 1) |
2b590e7972b1
Allow using right button or wheel to change team color
unc0rr
parents:
10452
diff
changeset
|
128 |
else if (mouse.button === Qt.RightButton) |
2b590e7972b1
Allow using right button or wheel to change team color
unc0rr
parents:
10452
diff
changeset
|
129 |
HWEngine.changeTeamColor(name, -1) |
2b590e7972b1
Allow using right button or wheel to change team color
unc0rr
parents:
10452
diff
changeset
|
130 |
} |
2b590e7972b1
Allow using right button or wheel to change team color
unc0rr
parents:
10452
diff
changeset
|
131 |
onWheel: HWEngine.changeTeamColor(name, -wheel.angleDelta.y) |
10452
03519fd9f98d
Show team color in teams list widget, also allow to change it on mouse click
unc0rr
parents:
10450
diff
changeset
|
132 |
} |
03519fd9f98d
Show team color in teams list widget, also allow to change it on mouse click
unc0rr
parents:
10450
diff
changeset
|
133 |
} |
03519fd9f98d
Show team color in teams list widget, also allow to change it on mouse click
unc0rr
parents:
10450
diff
changeset
|
134 |
|
03519fd9f98d
Show team color in teams list widget, also allow to change it on mouse click
unc0rr
parents:
10450
diff
changeset
|
135 |
Text { text: name |
03519fd9f98d
Show team color in teams list widget, also allow to change it on mouse click
unc0rr
parents:
10450
diff
changeset
|
136 |
MouseArea { |
03519fd9f98d
Show team color in teams list widget, also allow to change it on mouse click
unc0rr
parents:
10450
diff
changeset
|
137 |
z: 1 |
03519fd9f98d
Show team color in teams list widget, also allow to change it on mouse click
unc0rr
parents:
10450
diff
changeset
|
138 |
anchors.fill: parent |
03519fd9f98d
Show team color in teams list widget, also allow to change it on mouse click
unc0rr
parents:
10450
diff
changeset
|
139 |
onClicked: HWEngine.tryRemoveTeam(name) |
03519fd9f98d
Show team color in teams list widget, also allow to change it on mouse click
unc0rr
parents:
10450
diff
changeset
|
140 |
} |
03519fd9f98d
Show team color in teams list widget, also allow to change it on mouse click
unc0rr
parents:
10450
diff
changeset
|
141 |
} |
10442 | 142 |
} |
10444
47a6231f1fc1
Teams widget now allows to add and remove teams (basic implementation, no checks performed, no colors, no hedgehogs)
unc0rr
parents:
10442
diff
changeset
|
143 |
|
10452
03519fd9f98d
Show team color in teams list widget, also allow to change it on mouse click
unc0rr
parents:
10450
diff
changeset
|
144 |
|
10444
47a6231f1fc1
Teams widget now allows to add and remove teams (basic implementation, no checks performed, no colors, no hedgehogs)
unc0rr
parents:
10442
diff
changeset
|
145 |
} |
47a6231f1fc1
Teams widget now allows to add and remove teams (basic implementation, no checks performed, no colors, no hedgehogs)
unc0rr
parents:
10442
diff
changeset
|
146 |
|
47a6231f1fc1
Teams widget now allows to add and remove teams (basic implementation, no checks performed, no colors, no hedgehogs)
unc0rr
parents:
10442
diff
changeset
|
147 |
Connections { |
47a6231f1fc1
Teams widget now allows to add and remove teams (basic implementation, no checks performed, no colors, no hedgehogs)
unc0rr
parents:
10442
diff
changeset
|
148 |
target: HWEngine |
10452
03519fd9f98d
Show team color in teams list widget, also allow to change it on mouse click
unc0rr
parents:
10450
diff
changeset
|
149 |
onPlayingTeamAdded: playingTeamsModel.append({ |
03519fd9f98d
Show team color in teams list widget, also allow to change it on mouse click
unc0rr
parents:
10450
diff
changeset
|
150 |
"aiLevel": aiLevel |
03519fd9f98d
Show team color in teams list widget, also allow to change it on mouse click
unc0rr
parents:
10450
diff
changeset
|
151 |
, "name": teamName |
03519fd9f98d
Show team color in teams list widget, also allow to change it on mouse click
unc0rr
parents:
10450
diff
changeset
|
152 |
, "local": isLocal |
03519fd9f98d
Show team color in teams list widget, also allow to change it on mouse click
unc0rr
parents:
10450
diff
changeset
|
153 |
, "teamColor": "#000000" |
03519fd9f98d
Show team color in teams list widget, also allow to change it on mouse click
unc0rr
parents:
10450
diff
changeset
|
154 |
}) |
10444
47a6231f1fc1
Teams widget now allows to add and remove teams (basic implementation, no checks performed, no colors, no hedgehogs)
unc0rr
parents:
10442
diff
changeset
|
155 |
onPlayingTeamRemoved: { |
47a6231f1fc1
Teams widget now allows to add and remove teams (basic implementation, no checks performed, no colors, no hedgehogs)
unc0rr
parents:
10442
diff
changeset
|
156 |
var i = playingTeamsModel.count - 1; |
47a6231f1fc1
Teams widget now allows to add and remove teams (basic implementation, no checks performed, no colors, no hedgehogs)
unc0rr
parents:
10442
diff
changeset
|
157 |
while ((i >= 0) && (playingTeamsModel.get(i).name !== teamName)) --i |
47a6231f1fc1
Teams widget now allows to add and remove teams (basic implementation, no checks performed, no colors, no hedgehogs)
unc0rr
parents:
10442
diff
changeset
|
158 |
|
47a6231f1fc1
Teams widget now allows to add and remove teams (basic implementation, no checks performed, no colors, no hedgehogs)
unc0rr
parents:
10442
diff
changeset
|
159 |
if(i >= 0) playingTeamsModel.remove(i, 1) |
47a6231f1fc1
Teams widget now allows to add and remove teams (basic implementation, no checks performed, no colors, no hedgehogs)
unc0rr
parents:
10442
diff
changeset
|
160 |
} |
10452
03519fd9f98d
Show team color in teams list widget, also allow to change it on mouse click
unc0rr
parents:
10450
diff
changeset
|
161 |
onTeamColorChanged: { |
03519fd9f98d
Show team color in teams list widget, also allow to change it on mouse click
unc0rr
parents:
10450
diff
changeset
|
162 |
var i = playingTeamsModel.count - 1; |
03519fd9f98d
Show team color in teams list widget, also allow to change it on mouse click
unc0rr
parents:
10450
diff
changeset
|
163 |
while ((i >= 0) && (playingTeamsModel.get(i).name !== teamName)) --i |
03519fd9f98d
Show team color in teams list widget, also allow to change it on mouse click
unc0rr
parents:
10450
diff
changeset
|
164 |
|
03519fd9f98d
Show team color in teams list widget, also allow to change it on mouse click
unc0rr
parents:
10450
diff
changeset
|
165 |
if(i >= 0) playingTeamsModel.setProperty(i, "teamColor", colorValue) |
03519fd9f98d
Show team color in teams list widget, also allow to change it on mouse click
unc0rr
parents:
10450
diff
changeset
|
166 |
} |
10444
47a6231f1fc1
Teams widget now allows to add and remove teams (basic implementation, no checks performed, no colors, no hedgehogs)
unc0rr
parents:
10442
diff
changeset
|
167 |
} |
47a6231f1fc1
Teams widget now allows to add and remove teams (basic implementation, no checks performed, no colors, no hedgehogs)
unc0rr
parents:
10442
diff
changeset
|
168 |
} |
47a6231f1fc1
Teams widget now allows to add and remove teams (basic implementation, no checks performed, no colors, no hedgehogs)
unc0rr
parents:
10442
diff
changeset
|
169 |
|
47a6231f1fc1
Teams widget now allows to add and remove teams (basic implementation, no checks performed, no colors, no hedgehogs)
unc0rr
parents:
10442
diff
changeset
|
170 |
ListView { |
47a6231f1fc1
Teams widget now allows to add and remove teams (basic implementation, no checks performed, no colors, no hedgehogs)
unc0rr
parents:
10442
diff
changeset
|
171 |
id: localTeamsList |
47a6231f1fc1
Teams widget now allows to add and remove teams (basic implementation, no checks performed, no colors, no hedgehogs)
unc0rr
parents:
10442
diff
changeset
|
172 |
x: 440 |
47a6231f1fc1
Teams widget now allows to add and remove teams (basic implementation, no checks performed, no colors, no hedgehogs)
unc0rr
parents:
10442
diff
changeset
|
173 |
y: 224 |
47a6231f1fc1
Teams widget now allows to add and remove teams (basic implementation, no checks performed, no colors, no hedgehogs)
unc0rr
parents:
10442
diff
changeset
|
174 |
width: 100 |
47a6231f1fc1
Teams widget now allows to add and remove teams (basic implementation, no checks performed, no colors, no hedgehogs)
unc0rr
parents:
10442
diff
changeset
|
175 |
height: 192 |
47a6231f1fc1
Teams widget now allows to add and remove teams (basic implementation, no checks performed, no colors, no hedgehogs)
unc0rr
parents:
10442
diff
changeset
|
176 |
highlight: Rectangle { color: "#eaea00"; radius: 4 } |
47a6231f1fc1
Teams widget now allows to add and remove teams (basic implementation, no checks performed, no colors, no hedgehogs)
unc0rr
parents:
10442
diff
changeset
|
177 |
focus: true |
47a6231f1fc1
Teams widget now allows to add and remove teams (basic implementation, no checks performed, no colors, no hedgehogs)
unc0rr
parents:
10442
diff
changeset
|
178 |
clip: true |
47a6231f1fc1
Teams widget now allows to add and remove teams (basic implementation, no checks performed, no colors, no hedgehogs)
unc0rr
parents:
10442
diff
changeset
|
179 |
|
47a6231f1fc1
Teams widget now allows to add and remove teams (basic implementation, no checks performed, no colors, no hedgehogs)
unc0rr
parents:
10442
diff
changeset
|
180 |
model: ListModel { |
47a6231f1fc1
Teams widget now allows to add and remove teams (basic implementation, no checks performed, no colors, no hedgehogs)
unc0rr
parents:
10442
diff
changeset
|
181 |
id: localTeamsModel |
47a6231f1fc1
Teams widget now allows to add and remove teams (basic implementation, no checks performed, no colors, no hedgehogs)
unc0rr
parents:
10442
diff
changeset
|
182 |
} |
47a6231f1fc1
Teams widget now allows to add and remove teams (basic implementation, no checks performed, no colors, no hedgehogs)
unc0rr
parents:
10442
diff
changeset
|
183 |
|
47a6231f1fc1
Teams widget now allows to add and remove teams (basic implementation, no checks performed, no colors, no hedgehogs)
unc0rr
parents:
10442
diff
changeset
|
184 |
delegate: Rectangle { |
47a6231f1fc1
Teams widget now allows to add and remove teams (basic implementation, no checks performed, no colors, no hedgehogs)
unc0rr
parents:
10442
diff
changeset
|
185 |
id: localTeamDelegate |
47a6231f1fc1
Teams widget now allows to add and remove teams (basic implementation, no checks performed, no colors, no hedgehogs)
unc0rr
parents:
10442
diff
changeset
|
186 |
height: 24 |
47a6231f1fc1
Teams widget now allows to add and remove teams (basic implementation, no checks performed, no colors, no hedgehogs)
unc0rr
parents:
10442
diff
changeset
|
187 |
width: parent.width |
47a6231f1fc1
Teams widget now allows to add and remove teams (basic implementation, no checks performed, no colors, no hedgehogs)
unc0rr
parents:
10442
diff
changeset
|
188 |
radius: 8 |
47a6231f1fc1
Teams widget now allows to add and remove teams (basic implementation, no checks performed, no colors, no hedgehogs)
unc0rr
parents:
10442
diff
changeset
|
189 |
border.width: 2 |
47a6231f1fc1
Teams widget now allows to add and remove teams (basic implementation, no checks performed, no colors, no hedgehogs)
unc0rr
parents:
10442
diff
changeset
|
190 |
border.color: "#eaea00" |
47a6231f1fc1
Teams widget now allows to add and remove teams (basic implementation, no checks performed, no colors, no hedgehogs)
unc0rr
parents:
10442
diff
changeset
|
191 |
|
47a6231f1fc1
Teams widget now allows to add and remove teams (basic implementation, no checks performed, no colors, no hedgehogs)
unc0rr
parents:
10442
diff
changeset
|
192 |
Row { |
47a6231f1fc1
Teams widget now allows to add and remove teams (basic implementation, no checks performed, no colors, no hedgehogs)
unc0rr
parents:
10442
diff
changeset
|
193 |
Text { text: name } |
47a6231f1fc1
Teams widget now allows to add and remove teams (basic implementation, no checks performed, no colors, no hedgehogs)
unc0rr
parents:
10442
diff
changeset
|
194 |
} |
47a6231f1fc1
Teams widget now allows to add and remove teams (basic implementation, no checks performed, no colors, no hedgehogs)
unc0rr
parents:
10442
diff
changeset
|
195 |
|
47a6231f1fc1
Teams widget now allows to add and remove teams (basic implementation, no checks performed, no colors, no hedgehogs)
unc0rr
parents:
10442
diff
changeset
|
196 |
MouseArea { |
47a6231f1fc1
Teams widget now allows to add and remove teams (basic implementation, no checks performed, no colors, no hedgehogs)
unc0rr
parents:
10442
diff
changeset
|
197 |
z: 1 |
47a6231f1fc1
Teams widget now allows to add and remove teams (basic implementation, no checks performed, no colors, no hedgehogs)
unc0rr
parents:
10442
diff
changeset
|
198 |
anchors.fill: parent |
47a6231f1fc1
Teams widget now allows to add and remove teams (basic implementation, no checks performed, no colors, no hedgehogs)
unc0rr
parents:
10442
diff
changeset
|
199 |
onClicked: HWEngine.tryAddTeam(name) |
47a6231f1fc1
Teams widget now allows to add and remove teams (basic implementation, no checks performed, no colors, no hedgehogs)
unc0rr
parents:
10442
diff
changeset
|
200 |
} |
10442 | 201 |
} |
202 |
||
203 |
Connections { |
|
204 |
target: HWEngine |
|
205 |
onLocalTeamAdded: localTeamsModel.append({"aiLevel": aiLevel, "name": teamName}) |
|
10444
47a6231f1fc1
Teams widget now allows to add and remove teams (basic implementation, no checks performed, no colors, no hedgehogs)
unc0rr
parents:
10442
diff
changeset
|
206 |
onLocalTeamRemoved: { |
47a6231f1fc1
Teams widget now allows to add and remove teams (basic implementation, no checks performed, no colors, no hedgehogs)
unc0rr
parents:
10442
diff
changeset
|
207 |
var i = localTeamsModel.count - 1; |
47a6231f1fc1
Teams widget now allows to add and remove teams (basic implementation, no checks performed, no colors, no hedgehogs)
unc0rr
parents:
10442
diff
changeset
|
208 |
while ((i >= 0) && (localTeamsModel.get(i).name !== teamName)) --i |
47a6231f1fc1
Teams widget now allows to add and remove teams (basic implementation, no checks performed, no colors, no hedgehogs)
unc0rr
parents:
10442
diff
changeset
|
209 |
|
47a6231f1fc1
Teams widget now allows to add and remove teams (basic implementation, no checks performed, no colors, no hedgehogs)
unc0rr
parents:
10442
diff
changeset
|
210 |
if(i >= 0) localTeamsModel.remove(i, 1) |
47a6231f1fc1
Teams widget now allows to add and remove teams (basic implementation, no checks performed, no colors, no hedgehogs)
unc0rr
parents:
10442
diff
changeset
|
211 |
} |
10442 | 212 |
} |
213 |
} |
|
214 |
||
215 |
Component.onCompleted: { |
|
10450 | 216 |
HWEngine.resetGameConfig() |
10442 | 217 |
HWEngine.getTeamsList() |
218 |
HWEngine.getPreview() |
|
219 |
} |
|
10422 | 220 |
} |