author | unc0rr |
Sat, 15 Dec 2007 20:08:08 +0000 | |
changeset 667 | 194dc62d1519 |
parent 665 | 5c7bfc8bac6a |
child 668 | 0d7683a66d61 |
permissions | -rw-r--r-- |
184 | 1 |
/* |
2 |
* Hedgewars, a worms-like game |
|
486 | 3 |
* Copyright (c) 2006, 2007 Andrey Korotaev <unC0Rr@gmail.com> |
184 | 4 |
* |
5 |
* This program is free software; you can redistribute it and/or modify |
|
6 |
* it under the terms of the GNU General Public License as published by |
|
7 |
* the Free Software Foundation; version 2 of the License |
|
8 |
* |
|
9 |
* This program is distributed in the hope that it will be useful, |
|
10 |
* but WITHOUT ANY WARRANTY; without even the implied warranty of |
|
11 |
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
|
12 |
* GNU General Public License for more details. |
|
13 |
* |
|
14 |
* You should have received a copy of the GNU General Public License |
|
15 |
* along with this program; if not, write to the Free Software |
|
16 |
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA |
|
17 |
*/ |
|
18 |
||
19 |
#include <QGridLayout> |
|
20 |
#include <QPushButton> |
|
21 |
#include <QGroupBox> |
|
22 |
#include <QComboBox> |
|
311 | 23 |
#include <QCheckBox> |
184 | 24 |
#include <QLabel> |
25 |
#include <QToolBox> |
|
26 |
#include <QLineEdit> |
|
27 |
#include <QListWidget> |
|
28 |
#include <QApplication> |
|
231 | 29 |
#include <QSpinBox> |
452 | 30 |
#include <QTextEdit> |
636 | 31 |
#include <QRadioButton> |
665 | 32 |
#include <QTableView> |
184 | 33 |
|
34 |
#include "pages.h" |
|
35 |
#include "sdlkeys.h" |
|
36 |
#include "hwconsts.h" |
|
37 |
#include "gamecfgwidget.h" |
|
38 |
#include "teamselect.h" |
|
39 |
#include "gamecfgwidget.h" |
|
40 |
#include "SquareLabel.h" |
|
41 |
#include "mapContainer.h" |
|
187 | 42 |
#include "about.h" |
297 | 43 |
#include "fpsedit.h" |
632
5e09ae25729f
Half implement possibility for different backends of servers list
unc0rr
parents:
617
diff
changeset
|
44 |
#include "netserverslist.h" |
412 | 45 |
#include "netudpwidget.h" |
632
5e09ae25729f
Half implement possibility for different backends of servers list
unc0rr
parents:
617
diff
changeset
|
46 |
#include "netwwwwidget.h" |
461 | 47 |
#include "chatwidget.h" |
555 | 48 |
#include "SDLs.h" |
579 | 49 |
#include "playrecordpage.h" |
612
333d095319de
abstract class for items container (hedgehogs num, bullets, etc.)
displacer
parents:
603
diff
changeset
|
50 |
#include "selectWeapon.h" |
184 | 51 |
|
52 |
PageMain::PageMain(QWidget* parent) : QWidget(parent) |
|
53 |
{ |
|
54 |
QFont * font14 = new QFont("MS Shell Dlg", 14); |
|
55 |
QGridLayout * pageLayout = new QGridLayout(this); |
|
56 |
pageLayout->setMargin(25); |
|
57 |
pageLayout->setColumnStretch(0, 1); |
|
58 |
pageLayout->setColumnStretch(1, 2); |
|
59 |
pageLayout->setColumnStretch(2, 1); |
|
60 |
||
61 |
BtnSinglePlayer = new QPushButton(this); |
|
62 |
BtnSinglePlayer->setSizePolicy(QSizePolicy::Expanding, QSizePolicy::Expanding); |
|
63 |
BtnSinglePlayer->setFont(*font14); |
|
64 |
BtnSinglePlayer->setText(QPushButton::tr("Single Player")); |
|
586 | 65 |
pageLayout->addWidget(BtnSinglePlayer, 0, 1); |
184 | 66 |
|
67 |
BtnMultiplayer = new QPushButton(this); |
|
68 |
BtnMultiplayer->setSizePolicy(QSizePolicy::Expanding, QSizePolicy::Expanding); |
|
69 |
BtnMultiplayer->setFont(*font14); |
|
70 |
BtnMultiplayer->setText(QPushButton::tr("Multiplayer")); |
|
586 | 71 |
pageLayout->addWidget(BtnMultiplayer, 1, 1); |
184 | 72 |
|
73 |
BtnNet = new QPushButton(this); |
|
74 |
BtnNet->setSizePolicy(QSizePolicy::Expanding, QSizePolicy::Expanding); |
|
75 |
BtnNet->setFont(*font14); |
|
76 |
BtnNet->setText(QPushButton::tr("Net game")); |
|
586 | 77 |
pageLayout->addWidget(BtnNet, 2, 1); |
184 | 78 |
|
579 | 79 |
BtnLoad = new QPushButton(this); |
80 |
BtnLoad->setSizePolicy(QSizePolicy::Expanding, QSizePolicy::Expanding); |
|
81 |
BtnLoad->setFont(*font14); |
|
82 |
BtnLoad->setText(QPushButton::tr("Load")); |
|
586 | 83 |
pageLayout->addWidget(BtnLoad, 3, 1); |
579 | 84 |
|
184 | 85 |
BtnDemos = new QPushButton(this); |
86 |
BtnDemos->setSizePolicy(QSizePolicy::Expanding, QSizePolicy::Expanding); |
|
87 |
BtnDemos->setFont(*font14); |
|
88 |
BtnDemos->setText(QPushButton::tr("Demos")); |
|
586 | 89 |
pageLayout->addWidget(BtnDemos, 4, 1); |
184 | 90 |
|
91 |
BtnSetup = new QPushButton(this); |
|
92 |
BtnSetup->setSizePolicy(QSizePolicy::Expanding, QSizePolicy::Expanding); |
|
93 |
BtnSetup->setFont(*font14); |
|
94 |
BtnSetup->setText(QPushButton::tr("Setup")); |
|
586 | 95 |
pageLayout->addWidget(BtnSetup, 5, 1); |
184 | 96 |
|
187 | 97 |
BtnInfo = new QPushButton(this); |
98 |
BtnInfo->setSizePolicy(QSizePolicy::Expanding, QSizePolicy::Expanding); |
|
99 |
BtnInfo->setFont(*font14); |
|
100 |
BtnInfo->setText(QPushButton::tr("About")); |
|
586 | 101 |
pageLayout->addWidget(BtnInfo, 6, 1); |
187 | 102 |
|
184 | 103 |
BtnExit = new QPushButton(parent); |
104 |
BtnExit->setSizePolicy(QSizePolicy::Expanding, QSizePolicy::Expanding); |
|
105 |
BtnExit->setFont(*font14); |
|
106 |
BtnExit->setText(QPushButton::tr("Exit")); |
|
187 | 107 |
pageLayout->addWidget(BtnExit, 7, 1); |
184 | 108 |
} |
109 |
||
585
7531ae5b146e
Rename PageLocalGame -> PageSimpleGame due to future changes
unc0rr
parents:
579
diff
changeset
|
110 |
PageSimpleGame::PageSimpleGame(QWidget* parent) : QWidget(parent) |
184 | 111 |
{ |
112 |
QFont * font14 = new QFont("MS Shell Dlg", 14); |
|
440 | 113 |
QVBoxLayout * pageLayout = new QVBoxLayout(this); |
114 |
QHBoxLayout * topLayout = new QHBoxLayout(); |
|
115 |
QHBoxLayout * bottomLayout = new QHBoxLayout(); |
|
116 |
pageLayout->addLayout(topLayout, 100); |
|
117 |
pageLayout->addLayout(bottomLayout, 0); |
|
118 |
||
119 |
BtnBack = new QPushButton(this); |
|
184 | 120 |
BtnBack->setFont(*font14); |
121 |
BtnBack->setText(QPushButton::tr("Back")); |
|
440 | 122 |
bottomLayout->addWidget(BtnBack, 100); |
123 |
bottomLayout->addStretch(100); |
|
586 | 124 |
BtnSimpleGame = new QPushButton(this); |
184 | 125 |
BtnSimpleGame->setFont(*font14); |
126 |
BtnSimpleGame->setText(QPushButton::tr("Simple Game")); |
|
440 | 127 |
bottomLayout->addWidget(BtnSimpleGame, 100); |
128 |
||
184 | 129 |
gameCFG = new GameCFGWidget(this); |
440 | 130 |
topLayout->addStretch(100); |
131 |
topLayout->addWidget(gameCFG); |
|
132 |
topLayout->addStretch(100); |
|
184 | 133 |
} |
134 |
||
135 |
PageEditTeam::PageEditTeam(QWidget* parent) : QWidget(parent) |
|
136 |
{ |
|
137 |
QFont * font14 = new QFont("MS Shell Dlg", 14); |
|
138 |
QGridLayout * pageLayout = new QGridLayout(this); |
|
310 | 139 |
pageLayout->setColumnStretch(0, 1); |
184 | 140 |
pageLayout->setColumnMinimumWidth(0, 150); |
141 |
pageLayout->setColumnStretch(1, 100); |
|
336 | 142 |
pageLayout->setColumnMinimumWidth(1, 210); |
451 | 143 |
pageLayout->setColumnStretch(2, 75); |
336 | 144 |
pageLayout->setColumnMinimumWidth(2, 110); |
451 | 145 |
pageLayout->setColumnStretch(3, 75); |
336 | 146 |
pageLayout->setColumnMinimumWidth(3, 110); |
184 | 147 |
|
148 |
GBoxTeam = new QGroupBox(this); |
|
149 |
GBoxTeam->setTitle(QGroupBox::tr("Team")); |
|
150 |
GBoxTeam->setSizePolicy(QSizePolicy::Expanding, QSizePolicy::Fixed); |
|
151 |
QGridLayout * GBTLayout = new QGridLayout(GBoxTeam); |
|
152 |
TeamNameEdit = new QLineEdit(GBoxTeam); |
|
153 |
TeamNameEdit->setMaxLength(15); |
|
231 | 154 |
GBTLayout->addWidget(TeamNameEdit, 0, 0, 1, 0); |
155 |
||
184 | 156 |
pageLayout->addWidget(GBoxTeam, 0, 0); |
157 |
||
588 | 158 |
GBoxHedgehogs = new QGroupBox(this); |
184 | 159 |
GBoxHedgehogs->setTitle(QGroupBox::tr("Team Members")); |
160 |
GBoxHedgehogs->setSizePolicy(QSizePolicy::Expanding, QSizePolicy::Fixed); |
|
161 |
QGridLayout * GBHLayout = new QGridLayout(GBoxHedgehogs); |
|
162 |
for(int i = 0; i < 8; i++) |
|
163 |
{ |
|
164 |
HHNameEdit[i] = new QLineEdit(GBoxHedgehogs); |
|
165 |
HHNameEdit[i]->setGeometry(QRect(10, 20 + i * 30, 141, 20)); |
|
166 |
HHNameEdit[i]->setMaxLength(15); |
|
167 |
GBHLayout->addWidget(HHNameEdit[i]); |
|
168 |
} |
|
169 |
pageLayout->addWidget(GBoxHedgehogs, 1, 0, 2, 1); |
|
170 |
||
171 |
BtnTeamDiscard = new QPushButton(this); |
|
172 |
BtnTeamDiscard->setFont(*font14); |
|
173 |
BtnTeamDiscard->setText(QPushButton::tr("Discard")); |
|
174 |
pageLayout->addWidget(BtnTeamDiscard, 4, 0); |
|
175 |
||
588 | 176 |
GBoxBinds = new QGroupBox(this); |
184 | 177 |
GBoxBinds->setTitle(QGroupBox::tr("Key binds")); |
178 |
QGridLayout * GBBLayout = new QGridLayout(GBoxBinds); |
|
179 |
BindsBox = new QToolBox(GBoxBinds); |
|
180 |
BindsBox->setLineWidth(0); |
|
181 |
GBBLayout->addWidget(BindsBox); |
|
182 |
page_A = new QWidget(); |
|
183 |
BindsBox->addItem(page_A, QToolBox::tr("Actions")); |
|
184 |
page_W = new QWidget(); |
|
185 |
BindsBox->addItem(page_W, QToolBox::tr("Weapons")); |
|
186 |
page_WP = new QWidget(); |
|
187 |
BindsBox->addItem(page_WP, QToolBox::tr("Weapon properties")); |
|
188 |
page_O = new QWidget(); |
|
189 |
BindsBox->addItem(page_O, QToolBox::tr("Other")); |
|
190 |
pageLayout->addWidget(GBoxBinds, 0, 1, 5, 1); |
|
191 |
||
192 |
QStringList binds; |
|
193 |
for(int i = 0; strlen(sdlkeys[i][1]) > 0; i++) |
|
194 |
{ |
|
195 |
binds << sdlkeys[i][1]; |
|
196 |
} |
|
197 |
||
198 |
quint16 widind = 0, i = 0; |
|
199 |
while (i < BINDS_NUMBER) { |
|
200 |
quint16 num = 0; |
|
201 |
QGridLayout * pagelayout = new QGridLayout(BindsBox->widget(widind)); |
|
202 |
do { |
|
203 |
LBind[i] = new QLabel(BindsBox->widget(widind)); |
|
204 |
LBind[i]->setText(QApplication::translate("binds", cbinds[i].name)); |
|
205 |
LBind[i]->setAlignment(Qt::AlignRight); |
|
206 |
pagelayout->addWidget(LBind[i], num, 0); |
|
207 |
CBBind[i] = new QComboBox(BindsBox->widget(widind)); |
|
208 |
CBBind[i]->addItems(binds); |
|
209 |
pagelayout->addWidget(CBBind[i], num, 1); |
|
210 |
num++; |
|
211 |
} while (!cbinds[i++].chwidget); |
|
212 |
pagelayout->addWidget(new QWidget(BindsBox->widget(widind)), num, 0, 1, 2); |
|
213 |
widind++; |
|
214 |
} |
|
215 |
||
588 | 216 |
GBoxGrave = new QGroupBox(this); |
184 | 217 |
GBoxGrave->setSizePolicy(QSizePolicy::Expanding, QSizePolicy::Fixed); |
218 |
GBoxGrave->setTitle(QGroupBox::tr("Grave")); |
|
219 |
QGridLayout * GBGLayout = new QGridLayout(GBoxGrave); |
|
220 |
CBGrave = new QComboBox(GBoxGrave); |
|
221 |
CBGrave->setMaxCount(65535); |
|
222 |
GBGLayout->addWidget(CBGrave, 0, 0, 1, 3); |
|
223 |
GravePreview = new QLabel(GBoxGrave); |
|
224 |
GravePreview->setScaledContents(false); |
|
336 | 225 |
pageLayout->addWidget(GBoxGrave, 0, 3, 2, 1); |
184 | 226 |
GBGLayout->addWidget(GravePreview, 1, 1); |
336 | 227 |
|
228 |
GBoxTeamLvl = new QGroupBox(this); |
|
229 |
GBoxTeamLvl->setSizePolicy(QSizePolicy::Expanding, QSizePolicy::Fixed); |
|
230 |
GBoxTeamLvl->setTitle(QGroupBox::tr("Team level")); |
|
231 |
QGridLayout * GBTLLayout = new QGridLayout(GBoxTeamLvl); |
|
232 |
CBTeamLvl = new QComboBox(GBoxTeamLvl); |
|
233 |
CBTeamLvl->addItem(QComboBox::tr("Human")); |
|
427 | 234 |
CBTeamLvl->addItem(QComboBox::tr("Level 5")); |
235 |
CBTeamLvl->addItem(QComboBox::tr("Level 4")); |
|
336 | 236 |
CBTeamLvl->addItem(QComboBox::tr("Level 3")); |
427 | 237 |
CBTeamLvl->addItem(QComboBox::tr("Level 2")); |
238 |
CBTeamLvl->addItem(QComboBox::tr("Level 1")); |
|
336 | 239 |
CBTeamLvl->setMaxCount(6); |
240 |
GBTLLayout->addWidget(CBTeamLvl, 0, 0, 1, 3); |
|
241 |
LevelPict = new QLabel(GBoxTeamLvl); |
|
242 |
LevelPict->setScaledContents(false); |
|
243 |
LevelPict->setFixedSize(32, 32); |
|
244 |
pageLayout->addWidget(GBoxTeamLvl, 0, 2, 2, 1); |
|
245 |
GBTLLayout->addWidget(LevelPict, 1, 1); |
|
184 | 246 |
|
247 |
GBoxFort = new QGroupBox(this); |
|
248 |
GBoxFort->setTitle(QGroupBox::tr("Fort")); |
|
249 |
QGridLayout * GBFLayout = new QGridLayout(GBoxFort); |
|
250 |
CBFort = new QComboBox(GBoxFort); |
|
251 |
CBFort->setMaxCount(65535); |
|
252 |
GBFLayout->addWidget(CBFort, 0, 0); |
|
588 | 253 |
FortPreview = new SquareLabel(GBoxFort); |
310 | 254 |
FortPreview->setSizePolicy(QSizePolicy::Expanding, QSizePolicy::Expanding); |
184 | 255 |
FortPreview->setPixmap(QPixmap()); |
256 |
GBFLayout->addWidget(FortPreview, 1, 0); |
|
336 | 257 |
pageLayout->addWidget(GBoxFort, 2, 2, 1, 2); |
184 | 258 |
|
588 | 259 |
BtnTeamSave = new QPushButton(this); |
184 | 260 |
BtnTeamSave->setFont(*font14); |
261 |
BtnTeamSave->setText(QPushButton::tr("Save")); |
|
336 | 262 |
pageLayout->addWidget(BtnTeamSave, 4, 2, 1, 2); |
184 | 263 |
|
264 |
QDir tmpdir; |
|
265 |
tmpdir.cd(datadir->absolutePath()); |
|
266 |
tmpdir.cd("Forts"); |
|
267 |
tmpdir.setFilter(QDir::Files); |
|
268 |
||
603 | 269 |
CBFort->addItems(tmpdir.entryList(QStringList("*L.png")).replaceInStrings(QRegExp("^(.*)L\\.png"), "\\1")); |
184 | 270 |
tmpdir.cd("../Graphics/Graves"); |
271 |
QStringList list = tmpdir.entryList(QStringList("*.png")); |
|
272 |
for (QStringList::Iterator it = list.begin(); it != list.end(); ++it ) |
|
273 |
{ |
|
603 | 274 |
CBGrave->addItem((*it).replace(QRegExp("^(.*)\\.png"), "\\1")); |
184 | 275 |
} |
276 |
||
277 |
connect(CBGrave, SIGNAL(activated(const QString &)), this, SLOT(CBGrave_activated(const QString &))); |
|
336 | 278 |
connect(CBTeamLvl, SIGNAL(activated(int)), this, SLOT(CBTeamLvl_activated(int))); |
184 | 279 |
connect(CBFort, SIGNAL(activated(const QString &)), this, SLOT(CBFort_activated(const QString &))); |
280 |
} |
|
281 |
||
282 |
void PageEditTeam::CBGrave_activated(const QString & gravename) |
|
283 |
{ |
|
284 |
QPixmap pix(datadir->absolutePath() + "/Graphics/Graves/" + gravename + ".png"); |
|
285 |
GravePreview->setPixmap(pix.copy(0, 0, 32, 32)); |
|
286 |
} |
|
287 |
||
288 |
void PageEditTeam::CBFort_activated(const QString & fortname) |
|
289 |
{ |
|
290 |
QPixmap pix(datadir->absolutePath() + "/Forts/" + fortname + "L.png"); |
|
291 |
FortPreview->setPixmap(pix); |
|
292 |
} |
|
293 |
||
336 | 294 |
void PageEditTeam::CBTeamLvl_activated(int id) |
295 |
{ |
|
296 |
QPixmap pix(QString(":/res/botlevels/%1.png").arg(id)); |
|
297 |
LevelPict->setPixmap(pix); |
|
298 |
} |
|
299 |
||
184 | 300 |
PageMultiplayer::PageMultiplayer(QWidget* parent) : QWidget(parent) |
301 |
{ |
|
302 |
QFont * font14 = new QFont("MS Shell Dlg", 14); |
|
303 |
QGridLayout * pageLayout = new QGridLayout(this); |
|
304 |
||
305 |
BtnBack = new QPushButton(this); |
|
306 |
BtnBack->setFont(*font14); |
|
307 |
BtnBack->setText(QPushButton::tr("Back")); |
|
308 |
pageLayout->addWidget(BtnBack, 1, 0); |
|
187 | 309 |
|
184 | 310 |
gameCFG = new GameCFGWidget(this); |
311 |
pageLayout->addWidget(gameCFG, 0, 0, 1, 2); |
|
312 |
teamsSelect = new TeamSelWidget(this); |
|
313 |
pageLayout->addWidget(teamsSelect, 0, 2, 1, 2); |
|
314 |
||
315 |
BtnStartMPGame = new QPushButton(this); |
|
316 |
BtnStartMPGame->setFont(*font14); |
|
317 |
BtnStartMPGame->setText(QPushButton::tr("Start")); |
|
318 |
pageLayout->addWidget(BtnStartMPGame, 1, 3); |
|
319 |
} |
|
320 |
||
321 |
PageOptions::PageOptions(QWidget* parent) : QWidget(parent) |
|
322 |
{ |
|
323 |
QFont * font14 = new QFont("MS Shell Dlg", 14); |
|
324 |
QGridLayout * pageLayout = new QGridLayout(this); |
|
427 | 325 |
pageLayout->setColumnStretch(0, 100); |
326 |
pageLayout->setColumnStretch(1, 100); |
|
327 |
pageLayout->setColumnStretch(2, 100); |
|
328 |
pageLayout->setRowStretch(0, 0); |
|
329 |
pageLayout->setRowStretch(1, 0); |
|
330 |
pageLayout->setRowStretch(2, 100); |
|
331 |
pageLayout->setRowStretch(3, 0); |
|
332 |
||
184 | 333 |
groupBox = new QGroupBox(this); |
334 |
groupBox->setSizePolicy(QSizePolicy::Expanding, QSizePolicy::Fixed); |
|
335 |
groupBox->setTitle(QGroupBox::tr("Teams")); |
|
336 |
pageLayout->addWidget(groupBox, 0, 0, 1, 3); |
|
337 |
||
338 |
QGridLayout * GBTlayout = new QGridLayout(groupBox); |
|
339 |
BtnNewTeam = new QPushButton(groupBox); |
|
340 |
BtnNewTeam->setFont(*font14); |
|
341 |
BtnNewTeam->setText(QPushButton::tr("New team")); |
|
342 |
GBTlayout->addWidget(BtnNewTeam, 0, 0); |
|
343 |
||
344 |
CBTeamName = new QComboBox(groupBox); |
|
345 |
GBTlayout->addWidget(CBTeamName, 0, 1); |
|
346 |
||
347 |
BtnEditTeam = new QPushButton(groupBox); |
|
348 |
BtnEditTeam->setFont(*font14); |
|
349 |
BtnEditTeam->setText(QPushButton::tr("Edit team")); |
|
350 |
GBTlayout->addWidget(BtnEditTeam, 0, 2); |
|
351 |
||
352 |
AGGroupBox = new QGroupBox(this); |
|
353 |
AGGroupBox->setSizePolicy(QSizePolicy::Expanding, QSizePolicy::Fixed); |
|
354 |
AGGroupBox->setTitle(QGroupBox::tr("Audio/Graphic options")); |
|
427 | 355 |
pageLayout->addWidget(AGGroupBox, 1, 1); |
184 | 356 |
|
427 | 357 |
QVBoxLayout * GBAlayout = new QVBoxLayout(AGGroupBox); |
436 | 358 |
QHBoxLayout * GBAreslayout = new QHBoxLayout(0); |
427 | 359 |
QLabel * resolution = new QLabel(AGGroupBox); |
360 |
resolution->setText(QLabel::tr("Resolution")); |
|
361 |
GBAreslayout->addWidget(resolution); |
|
362 |
||
184 | 363 |
CBResolution = new QComboBox(AGGroupBox); |
555 | 364 |
SDLInteraction sdli; |
365 |
CBResolution->addItems(sdli.getResolutions()); |
|
427 | 366 |
GBAreslayout->addWidget(CBResolution); |
367 |
GBAlayout->addLayout(GBAreslayout); |
|
368 |
||
436 | 369 |
QHBoxLayout * GBAfpslayout = new QHBoxLayout(0); |
427 | 370 |
QLabel * maxfps = new QLabel(AGGroupBox); |
371 |
maxfps->setText(QLabel::tr("FPS limit")); |
|
372 |
GBAfpslayout->addWidget(maxfps); |
|
373 |
GBAlayout->addLayout(GBAfpslayout); |
|
184 | 374 |
|
375 |
CBFullscreen = new QCheckBox(AGGroupBox); |
|
376 |
CBFullscreen->setText(QCheckBox::tr("Fullscreen")); |
|
427 | 377 |
GBAlayout->addWidget(CBFullscreen); |
184 | 378 |
|
379 |
CBEnableSound = new QCheckBox(AGGroupBox); |
|
380 |
CBEnableSound->setText(QCheckBox::tr("Enable sound")); |
|
427 | 381 |
GBAlayout->addWidget(CBEnableSound); |
184 | 382 |
|
297 | 383 |
CBShowFPS = new QCheckBox(AGGroupBox); |
384 |
CBShowFPS->setText(QCheckBox::tr("Show FPS")); |
|
427 | 385 |
GBAlayout->addWidget(CBShowFPS); |
297 | 386 |
|
529 | 387 |
CBAltDamage = new QCheckBox(AGGroupBox); |
388 |
CBAltDamage->setText(QCheckBox::tr("Alternative damage show")); |
|
389 |
GBAlayout->addWidget(CBAltDamage); |
|
390 |
||
297 | 391 |
fpsedit = new FPSEdit(AGGroupBox); |
427 | 392 |
GBAfpslayout->addWidget(fpsedit); |
184 | 393 |
|
394 |
BtnSaveOptions = new QPushButton(this); |
|
395 |
BtnSaveOptions->setFont(*font14); |
|
396 |
BtnSaveOptions->setText(QPushButton::tr("Save")); |
|
397 |
pageLayout->addWidget(BtnSaveOptions, 4, 2); |
|
398 |
||
399 |
BtnBack = new QPushButton(this); |
|
400 |
BtnBack->setFont(*font14); |
|
401 |
BtnBack->setText(QPushButton::tr("Back")); |
|
402 |
pageLayout->addWidget(BtnBack, 4, 0); |
|
597
ec5f057ab268
kdevelop project add, initial weapons scheme button
displacer
parents:
588
diff
changeset
|
403 |
|
ec5f057ab268
kdevelop project add, initial weapons scheme button
displacer
parents:
588
diff
changeset
|
404 |
WeaponsButt = new QPushButton(this); |
ec5f057ab268
kdevelop project add, initial weapons scheme button
displacer
parents:
588
diff
changeset
|
405 |
WeaponsButt->setFont(*font14); |
ec5f057ab268
kdevelop project add, initial weapons scheme button
displacer
parents:
588
diff
changeset
|
406 |
WeaponsButt->setText(QPushButton::tr("Weapons scheme")); |
ec5f057ab268
kdevelop project add, initial weapons scheme button
displacer
parents:
588
diff
changeset
|
407 |
pageLayout->addWidget(WeaponsButt, 1, 0); |
ec5f057ab268
kdevelop project add, initial weapons scheme button
displacer
parents:
588
diff
changeset
|
408 |
|
647 | 409 |
NNGroupBox = new QGroupBox(this); |
410 |
NNGroupBox->setSizePolicy(QSizePolicy::MinimumExpanding, QSizePolicy::Fixed); |
|
411 |
NNGroupBox->setTitle(QGroupBox::tr("Net options")); |
|
412 |
pageLayout->addWidget(NNGroupBox, 1, 2); |
|
413 |
||
414 |
QGridLayout * GBNlayout = new QGridLayout(NNGroupBox); |
|
415 |
labelNN = new QLabel(NNGroupBox); |
|
416 |
labelNN->setText(QLabel::tr("Net nick")); |
|
417 |
GBNlayout->addWidget(labelNN, 0, 0); |
|
418 |
||
419 |
editNetNick = new QLineEdit(NNGroupBox); |
|
420 |
editNetNick->setMaxLength(20); |
|
421 |
editNetNick->setText(QLineEdit::tr("unnamed")); |
|
422 |
GBNlayout->addWidget(editNetNick, 0, 1); |
|
184 | 423 |
} |
424 |
||
425 |
PageNet::PageNet(QWidget* parent) : QWidget(parent) |
|
426 |
{ |
|
427 |
QFont * font14 = new QFont("MS Shell Dlg", 14); |
|
428 |
QGridLayout * pageLayout = new QGridLayout(this); |
|
429 |
pageLayout->setColumnStretch(0, 1); |
|
430 |
pageLayout->setColumnStretch(1, 1); |
|
617 | 431 |
pageLayout->setColumnStretch(2, 1); |
421 | 432 |
|
433 |
BtnNetSvrStart = new QPushButton(this); |
|
434 |
BtnNetSvrStart->setFont(*font14); |
|
435 |
BtnNetSvrStart->setText(QPushButton::tr("Start server")); |
|
617 | 436 |
pageLayout->addWidget(BtnNetSvrStart, 3, 2); |
184 | 437 |
|
636 | 438 |
QGroupBox * NetTypeGroupBox = new QGroupBox(this); |
439 |
NetTypeGroupBox->setSizePolicy(QSizePolicy::MinimumExpanding, QSizePolicy::Fixed); |
|
440 |
NetTypeGroupBox->setTitle(QGroupBox::tr("Connection type")); |
|
441 |
pageLayout->addWidget(NetTypeGroupBox, 0, 1); |
|
442 |
||
443 |
QVBoxLayout * GBTlayout = new QVBoxLayout(NetTypeGroupBox); |
|
444 |
rbLocalGame = new QRadioButton(NetTypeGroupBox); |
|
445 |
rbLocalGame->setText(tr("Local game")); |
|
446 |
rbLocalGame->setChecked(true); |
|
447 |
GBTlayout->addWidget(rbLocalGame); |
|
448 |
rbInternetGame = new QRadioButton(NetTypeGroupBox); |
|
449 |
rbInternetGame->setText(tr("Internet game")); |
|
450 |
GBTlayout->addWidget(rbInternetGame); |
|
451 |
||
632
5e09ae25729f
Half implement possibility for different backends of servers list
unc0rr
parents:
617
diff
changeset
|
452 |
ConnGroupBox = new QGroupBox(this); |
421 | 453 |
ConnGroupBox->setTitle(QGroupBox::tr("Net game")); |
454 |
pageLayout->addWidget(ConnGroupBox, 2, 0, 1, 3); |
|
632
5e09ae25729f
Half implement possibility for different backends of servers list
unc0rr
parents:
617
diff
changeset
|
455 |
GBClayout = new QGridLayout(ConnGroupBox); |
646 | 456 |
GBClayout->setColumnStretch(0, 1); |
421 | 457 |
GBClayout->setColumnStretch(1, 1); |
458 |
GBClayout->setColumnStretch(2, 1); |
|
184 | 459 |
|
632
5e09ae25729f
Half implement possibility for different backends of servers list
unc0rr
parents:
617
diff
changeset
|
460 |
BtnNetConnect = new QPushButton(ConnGroupBox); |
184 | 461 |
BtnNetConnect->setFont(*font14); |
462 |
BtnNetConnect->setText(QPushButton::tr("Connect")); |
|
646 | 463 |
GBClayout->addWidget(BtnNetConnect, 2, 2); |
416 | 464 |
|
665 | 465 |
tvServersList = new QTableView(ConnGroupBox); |
466 |
GBClayout->addWidget(tvServersList, 1, 0, 1, 3); |
|
421 | 467 |
|
632
5e09ae25729f
Half implement possibility for different backends of servers list
unc0rr
parents:
617
diff
changeset
|
468 |
BtnUpdateSList = new QPushButton(ConnGroupBox); |
5e09ae25729f
Half implement possibility for different backends of servers list
unc0rr
parents:
617
diff
changeset
|
469 |
BtnUpdateSList->setFont(*font14); |
5e09ae25729f
Half implement possibility for different backends of servers list
unc0rr
parents:
617
diff
changeset
|
470 |
BtnUpdateSList->setText(QPushButton::tr("Update")); |
646 | 471 |
GBClayout->addWidget(BtnUpdateSList, 2, 0); |
314 | 472 |
|
653
4f44fc06ca45
Class to ask host/port to connect to ('Specify' button on PageNet)
unc0rr
parents:
647
diff
changeset
|
473 |
BtnSpecifyServer = new QPushButton(ConnGroupBox); |
4f44fc06ca45
Class to ask host/port to connect to ('Specify' button on PageNet)
unc0rr
parents:
647
diff
changeset
|
474 |
BtnSpecifyServer->setFont(*font14); |
4f44fc06ca45
Class to ask host/port to connect to ('Specify' button on PageNet)
unc0rr
parents:
647
diff
changeset
|
475 |
BtnSpecifyServer->setText(QPushButton::tr("Specify")); |
4f44fc06ca45
Class to ask host/port to connect to ('Specify' button on PageNet)
unc0rr
parents:
647
diff
changeset
|
476 |
GBClayout->addWidget(BtnSpecifyServer, 2, 1); |
4f44fc06ca45
Class to ask host/port to connect to ('Specify' button on PageNet)
unc0rr
parents:
647
diff
changeset
|
477 |
|
184 | 478 |
BtnBack = new QPushButton(this); |
479 |
BtnBack->setFont(*font14); |
|
480 |
BtnBack->setText(QPushButton::tr("Back")); |
|
412 | 481 |
pageLayout->addWidget(BtnBack, 3, 0); |
636 | 482 |
|
646 | 483 |
connect(rbLocalGame, SIGNAL(toggled(bool)), this, SLOT(updateServersList())); |
184 | 484 |
} |
485 |
||
646 | 486 |
void PageNet::updateServersList() |
632
5e09ae25729f
Half implement possibility for different backends of servers list
unc0rr
parents:
617
diff
changeset
|
487 |
{ |
636 | 488 |
if (rbLocalGame->isChecked()) |
667 | 489 |
tvServersList->setModel(new HWNetUdpModel()); |
490 |
else |
|
665 | 491 |
tvServersList->setModel(new HWNetWwwModel()); |
659 | 492 |
|
665 | 493 |
static_cast<HWNetServersModel *>(tvServersList->model())->updateList(); |
632
5e09ae25729f
Half implement possibility for different backends of servers list
unc0rr
parents:
617
diff
changeset
|
494 |
|
665 | 495 |
connect(BtnUpdateSList, SIGNAL(clicked()), static_cast<HWNetServersModel *>(tvServersList->model()), SLOT(updateList())); |
496 |
// connect(netServersWidget->serversList, SIGNAL(itemDoubleClicked(QListWidgetItem *)), this, SLOT(slotConnect())); |
|
646 | 497 |
} |
498 |
||
499 |
void PageNet::slotConnect() |
|
500 |
{ |
|
665 | 501 |
emit connectClicked("localhost", 46631); |
646 | 502 |
} |
503 |
||
504 |
PageNetServer::PageNetServer(QWidget* parent) : QWidget(parent) |
|
505 |
{ |
|
506 |
QFont * font14 = new QFont("MS Shell Dlg", 14); |
|
507 |
QGridLayout * pageLayout = new QGridLayout(this); |
|
508 |
pageLayout->setColumnStretch(0, 1); |
|
509 |
pageLayout->setColumnStretch(1, 1); |
|
510 |
pageLayout->setColumnStretch(2, 1); |
|
511 |
||
657
b34fc518a48a
Basic concept for net server options page (subject to change)
unc0rr
parents:
653
diff
changeset
|
512 |
pageLayout->setRowStretch(0, 0); |
b34fc518a48a
Basic concept for net server options page (subject to change)
unc0rr
parents:
653
diff
changeset
|
513 |
pageLayout->setRowStretch(1, 0); |
b34fc518a48a
Basic concept for net server options page (subject to change)
unc0rr
parents:
653
diff
changeset
|
514 |
pageLayout->setRowStretch(2, 1); |
b34fc518a48a
Basic concept for net server options page (subject to change)
unc0rr
parents:
653
diff
changeset
|
515 |
pageLayout->setRowStretch(3, 0); |
b34fc518a48a
Basic concept for net server options page (subject to change)
unc0rr
parents:
653
diff
changeset
|
516 |
|
646 | 517 |
BtnBack = new QPushButton(this); |
518 |
BtnBack->setFont(*font14); |
|
519 |
BtnBack->setText(QPushButton::tr("Back")); |
|
657
b34fc518a48a
Basic concept for net server options page (subject to change)
unc0rr
parents:
653
diff
changeset
|
520 |
pageLayout->addWidget(BtnBack, 3, 0); |
646 | 521 |
|
522 |
BtnStart = new QPushButton(this); |
|
523 |
BtnStart->setFont(*font14); |
|
524 |
BtnStart->setText(QPushButton::tr("Start")); |
|
657
b34fc518a48a
Basic concept for net server options page (subject to change)
unc0rr
parents:
653
diff
changeset
|
525 |
pageLayout->addWidget(BtnStart, 3, 2); |
b34fc518a48a
Basic concept for net server options page (subject to change)
unc0rr
parents:
653
diff
changeset
|
526 |
|
b34fc518a48a
Basic concept for net server options page (subject to change)
unc0rr
parents:
653
diff
changeset
|
527 |
labelSD = new QLabel(this); |
b34fc518a48a
Basic concept for net server options page (subject to change)
unc0rr
parents:
653
diff
changeset
|
528 |
labelSD->setText(QLabel::tr("Server name:")); |
b34fc518a48a
Basic concept for net server options page (subject to change)
unc0rr
parents:
653
diff
changeset
|
529 |
pageLayout->addWidget(labelSD, 0, 0); |
b34fc518a48a
Basic concept for net server options page (subject to change)
unc0rr
parents:
653
diff
changeset
|
530 |
|
b34fc518a48a
Basic concept for net server options page (subject to change)
unc0rr
parents:
653
diff
changeset
|
531 |
leServerDescr = new QLineEdit(this); |
b34fc518a48a
Basic concept for net server options page (subject to change)
unc0rr
parents:
653
diff
changeset
|
532 |
pageLayout->addWidget(leServerDescr, 0, 1); |
b34fc518a48a
Basic concept for net server options page (subject to change)
unc0rr
parents:
653
diff
changeset
|
533 |
|
b34fc518a48a
Basic concept for net server options page (subject to change)
unc0rr
parents:
653
diff
changeset
|
534 |
labelPort = new QLabel(this); |
b34fc518a48a
Basic concept for net server options page (subject to change)
unc0rr
parents:
653
diff
changeset
|
535 |
labelPort->setText(QLabel::tr("Server port:")); |
b34fc518a48a
Basic concept for net server options page (subject to change)
unc0rr
parents:
653
diff
changeset
|
536 |
pageLayout->addWidget(labelPort, 1, 0); |
b34fc518a48a
Basic concept for net server options page (subject to change)
unc0rr
parents:
653
diff
changeset
|
537 |
|
b34fc518a48a
Basic concept for net server options page (subject to change)
unc0rr
parents:
653
diff
changeset
|
538 |
sbPort = new QSpinBox(this); |
b34fc518a48a
Basic concept for net server options page (subject to change)
unc0rr
parents:
653
diff
changeset
|
539 |
sbPort->setMinimum(0); |
b34fc518a48a
Basic concept for net server options page (subject to change)
unc0rr
parents:
653
diff
changeset
|
540 |
sbPort->setMaximum(65535); |
b34fc518a48a
Basic concept for net server options page (subject to change)
unc0rr
parents:
653
diff
changeset
|
541 |
pageLayout->addWidget(sbPort, 1, 1); |
b34fc518a48a
Basic concept for net server options page (subject to change)
unc0rr
parents:
653
diff
changeset
|
542 |
|
b34fc518a48a
Basic concept for net server options page (subject to change)
unc0rr
parents:
653
diff
changeset
|
543 |
BtnDefault = new QPushButton(this); |
b34fc518a48a
Basic concept for net server options page (subject to change)
unc0rr
parents:
653
diff
changeset
|
544 |
BtnDefault->setText(QPushButton::tr("default")); |
b34fc518a48a
Basic concept for net server options page (subject to change)
unc0rr
parents:
653
diff
changeset
|
545 |
pageLayout->addWidget(BtnDefault, 1, 2); |
b34fc518a48a
Basic concept for net server options page (subject to change)
unc0rr
parents:
653
diff
changeset
|
546 |
|
b34fc518a48a
Basic concept for net server options page (subject to change)
unc0rr
parents:
653
diff
changeset
|
547 |
connect(BtnDefault, SIGNAL(clicked()), this, SLOT(setDefaultPort())); |
b34fc518a48a
Basic concept for net server options page (subject to change)
unc0rr
parents:
653
diff
changeset
|
548 |
} |
b34fc518a48a
Basic concept for net server options page (subject to change)
unc0rr
parents:
653
diff
changeset
|
549 |
|
b34fc518a48a
Basic concept for net server options page (subject to change)
unc0rr
parents:
653
diff
changeset
|
550 |
void PageNetServer::setDefaultPort() |
b34fc518a48a
Basic concept for net server options page (subject to change)
unc0rr
parents:
653
diff
changeset
|
551 |
{ |
b34fc518a48a
Basic concept for net server options page (subject to change)
unc0rr
parents:
653
diff
changeset
|
552 |
sbPort->setValue(46631); |
632
5e09ae25729f
Half implement possibility for different backends of servers list
unc0rr
parents:
617
diff
changeset
|
553 |
} |
5e09ae25729f
Half implement possibility for different backends of servers list
unc0rr
parents:
617
diff
changeset
|
554 |
|
184 | 555 |
PageNetGame::PageNetGame(QWidget* parent) : QWidget(parent) |
556 |
{ |
|
557 |
QFont * font14 = new QFont("MS Shell Dlg", 14); |
|
558 |
QGridLayout * pageLayout = new QGridLayout(this); |
|
452 | 559 |
pageLayout->setSizeConstraint(QLayout::SetMinimumSize); |
461 | 560 |
//pageLayout->setSpacing(1); |
561 |
//pageLayout->setMargin(1); |
|
463 | 562 |
pageLayout->setColumnStretch(0, 50); |
563 |
pageLayout->setColumnStretch(1, 50); |
|
322 | 564 |
|
461 | 565 |
// chatwidget |
566 |
pChatWidget = new HWChatWidget(this); |
|
567 |
pageLayout->addWidget(pChatWidget, 1, 0); |
|
464 | 568 |
pageLayout->setRowStretch(1, 100); |
453 | 569 |
|
329
4c3aad46baa5
Send game parameters by net... Currently it leads to infinite loop, flooding traffic with messages about changes
unc0rr
parents:
323
diff
changeset
|
570 |
pGameCFG = new GameCFGWidget(this); |
322 | 571 |
pageLayout->addWidget(pGameCFG, 0, 0); |
329
4c3aad46baa5
Send game parameters by net... Currently it leads to infinite loop, flooding traffic with messages about changes
unc0rr
parents:
323
diff
changeset
|
572 |
|
4c3aad46baa5
Send game parameters by net... Currently it leads to infinite loop, flooding traffic with messages about changes
unc0rr
parents:
323
diff
changeset
|
573 |
pNetTeamsWidget = new TeamSelWidget(this); |
373 | 574 |
pNetTeamsWidget->setAcceptOuter(true); |
461 | 575 |
pageLayout->addWidget(pNetTeamsWidget, 0, 1, 2, 1); |
184 | 576 |
|
577 |
BtnBack = new QPushButton(this); |
|
578 |
BtnBack->setFont(*font14); |
|
579 |
BtnBack->setText(QPushButton::tr("Back")); |
|
461 | 580 |
pageLayout->addWidget(BtnBack, 2, 0); |
184 | 581 |
|
646 | 582 |
BtnGo = new QPushButton(this); |
184 | 583 |
BtnGo->setFont(*font14); |
584 |
BtnGo->setText(QPushButton::tr("Go!")); |
|
492 | 585 |
BtnGo->setEnabled(false); |
461 | 586 |
pageLayout->addWidget(BtnGo, 2, 1); |
184 | 587 |
} |
187 | 588 |
|
589 |
PageInfo::PageInfo(QWidget* parent) : QWidget(parent) |
|
590 |
{ |
|
591 |
QFont * font14 = new QFont("MS Shell Dlg", 14); |
|
592 |
QGridLayout * pageLayout = new QGridLayout(this); |
|
593 |
pageLayout->setColumnStretch(0, 1); |
|
594 |
pageLayout->setColumnStretch(1, 1); |
|
595 |
pageLayout->setColumnStretch(2, 1); |
|
596 |
||
597 |
BtnBack = new QPushButton(this); |
|
598 |
BtnBack->setFont(*font14); |
|
599 |
BtnBack->setText(QPushButton::tr("Back")); |
|
600 |
pageLayout->addWidget(BtnBack, 1, 0); |
|
601 |
||
602 |
about = new About(this); |
|
603 |
pageLayout->addWidget(about, 0, 0, 1, 3); |
|
604 |
} |
|
306 | 605 |
|
606 |
PageGameStats::PageGameStats(QWidget* parent) : QWidget(parent) |
|
607 |
{ |
|
608 |
QFont * font14 = new QFont("MS Shell Dlg", 14); |
|
609 |
QGridLayout * pageLayout = new QGridLayout(this); |
|
610 |
pageLayout->setColumnStretch(0, 1); |
|
611 |
pageLayout->setColumnStretch(1, 1); |
|
612 |
pageLayout->setColumnStretch(2, 1); |
|
613 |
||
614 |
BtnBack = new QPushButton(this); |
|
615 |
BtnBack->setFont(*font14); |
|
616 |
BtnBack->setText(QPushButton::tr("Back")); |
|
617 |
pageLayout->addWidget(BtnBack, 1, 0); |
|
618 |
||
307 | 619 |
labelGameStats = new QLabel(this); |
620 |
labelGameStats->setTextFormat(Qt::RichText); |
|
621 |
pageLayout->addWidget(labelGameStats, 0, 0, 1, 3); |
|
306 | 622 |
} |
586 | 623 |
|
624 |
PageSinglePlayer::PageSinglePlayer(QWidget* parent) : QWidget(parent) |
|
625 |
{ |
|
626 |
QFont * font14 = new QFont("MS Shell Dlg", 14); |
|
627 |
QGridLayout * pageLayout = new QGridLayout(this); |
|
628 |
pageLayout->setMargin(25); |
|
629 |
pageLayout->setColumnStretch(0, 1); |
|
630 |
pageLayout->setColumnStretch(1, 2); |
|
631 |
pageLayout->setColumnStretch(2, 1); |
|
588 | 632 |
pageLayout->setRowStretch(0, 1); |
633 |
pageLayout->setRowStretch(3, 1); |
|
586 | 634 |
|
635 |
BtnSimpleGamePage = new QPushButton(this); |
|
636 |
BtnSimpleGamePage->setFont(*font14); |
|
637 |
BtnSimpleGamePage->setText(QPushButton::tr("Simple Game")); |
|
588 | 638 |
pageLayout->addWidget(BtnSimpleGamePage, 1, 1); |
586 | 639 |
|
640 |
BtnTrainPage = new QPushButton(this); |
|
641 |
BtnTrainPage->setFont(*font14); |
|
642 |
BtnTrainPage->setText(QPushButton::tr("Training")); |
|
588 | 643 |
pageLayout->addWidget(BtnTrainPage, 2, 1); |
586 | 644 |
|
645 |
BtnBack = new QPushButton(this); |
|
646 |
BtnBack->setFont(*font14); |
|
647 |
BtnBack->setText(QPushButton::tr("Back")); |
|
588 | 648 |
pageLayout->addWidget(BtnBack, 4, 0); |
586 | 649 |
|
650 |
} |
|
651 |
||
587 | 652 |
PageTraining::PageTraining(QWidget* parent) : QWidget(parent) |
653 |
{ |
|
654 |
QFont * font14 = new QFont("MS Shell Dlg", 14); |
|
655 |
QGridLayout * pageLayout = new QGridLayout(this); |
|
656 |
pageLayout->setMargin(25); |
|
657 |
pageLayout->setColumnStretch(0, 1); |
|
658 |
pageLayout->setColumnStretch(1, 2); |
|
659 |
pageLayout->setColumnStretch(2, 1); |
|
660 |
||
661 |
BtnStartTrain = new QPushButton(this); |
|
662 |
BtnStartTrain->setFont(*font14); |
|
663 |
BtnStartTrain->setText(QPushButton::tr("Go!")); |
|
664 |
pageLayout->addWidget(BtnStartTrain, 1, 2); |
|
665 |
||
666 |
BtnBack = new QPushButton(this); |
|
667 |
BtnBack->setFont(*font14); |
|
668 |
BtnBack->setText(QPushButton::tr("Back")); |
|
669 |
pageLayout->addWidget(BtnBack, 1, 0); |
|
670 |
} |
|
671 |
||
600 | 672 |
PageSelectWeapon::PageSelectWeapon(QWidget* parent) : QWidget(parent) |
673 |
{ |
|
674 |
QFont * font14 = new QFont("MS Shell Dlg", 14); |
|
675 |
QGridLayout * pageLayout = new QGridLayout(this); |
|
676 |
pageLayout->setMargin(25); |
|
612
333d095319de
abstract class for items container (hedgehogs num, bullets, etc.)
displacer
parents:
603
diff
changeset
|
677 |
//pageLayout->setColumnStretch(0, 1); |
333d095319de
abstract class for items container (hedgehogs num, bullets, etc.)
displacer
parents:
603
diff
changeset
|
678 |
//pageLayout->setColumnStretch(1, 2); |
333d095319de
abstract class for items container (hedgehogs num, bullets, etc.)
displacer
parents:
603
diff
changeset
|
679 |
//pageLayout->setColumnStretch(2, 1); |
333d095319de
abstract class for items container (hedgehogs num, bullets, etc.)
displacer
parents:
603
diff
changeset
|
680 |
|
333d095319de
abstract class for items container (hedgehogs num, bullets, etc.)
displacer
parents:
603
diff
changeset
|
681 |
pWeapons=new SelWeaponWidget(this); |
333d095319de
abstract class for items container (hedgehogs num, bullets, etc.)
displacer
parents:
603
diff
changeset
|
682 |
pageLayout->addWidget(pWeapons, 0, 0); |
600 | 683 |
|
684 |
BtnBack = new QPushButton(this); |
|
685 |
BtnBack->setFont(*font14); |
|
686 |
BtnBack->setText(QPushButton::tr("Back")); |
|
687 |
pageLayout->addWidget(BtnBack, 1, 0); |
|
688 |
} |
|
689 |