# HG changeset patch
# User smxx
# Date 1265061695 0
# Node ID f860f27028cc014f9f3cb0106c479b1f14f2b440
# Parent bfccb2ec4334a2b920d8fc432051cd3cdaec25a9
Frontend:
+ New edit buttons for game and weapon scheme selection
diff -r bfccb2ec4334 -r f860f27028cc QTfrontend/gamecfgwidget.cpp
--- a/QTfrontend/gamecfgwidget.cpp Mon Feb 01 21:26:15 2010 +0000
+++ b/QTfrontend/gamecfgwidget.cpp Mon Feb 01 22:01:35 2010 +0000
@@ -52,22 +52,29 @@
GBoxOptionsLayout->addWidget(new QLabel(QLabel::tr("Game scheme"), GBoxOptions), 0, 0);
-
+ QPixmap pmEdit(":/res/edit.png");
+
QPushButton * goToSchemePage = new QPushButton(GBoxOptions);
- goToSchemePage->setText(tr("Edit schemes"));
- GBoxOptionsLayout->addWidget(goToSchemePage, 1, 0, 1, 2);
+ //goToSchemePage->setText(tr("Edit schemes"));
+ goToSchemePage->setIconSize(pmEdit.size());
+ goToSchemePage->setIcon(pmEdit);
+ goToSchemePage->setMaximumWidth(pmEdit.width() + 6);
+ GBoxOptionsLayout->addWidget(goToSchemePage, 0, 2);
connect(goToSchemePage, SIGNAL(clicked()), this, SIGNAL(goToSchemes()));
- GBoxOptionsLayout->addWidget(new QLabel(QLabel::tr("Weapons"), GBoxOptions), 2, 0);
+ GBoxOptionsLayout->addWidget(new QLabel(QLabel::tr("Weapons"), GBoxOptions), 1, 0);
WeaponsName = new QComboBox(GBoxOptions);
- GBoxOptionsLayout->addWidget(WeaponsName, 2, 1);
+ GBoxOptionsLayout->addWidget(WeaponsName, 1, 1);
connect(WeaponsName, SIGNAL(currentIndexChanged(int)), this, SLOT(ammoChanged(int)));
QPushButton * goToWeaponPage = new QPushButton(GBoxOptions);
- goToWeaponPage->setText(tr("Edit weapons"));
- GBoxOptionsLayout->addWidget(goToWeaponPage, 3, 0, 1, 2);
+ //goToWeaponPage->setText(tr("Edit weapons"));
+ goToWeaponPage->setIconSize(pmEdit.size());
+ goToWeaponPage->setIcon(pmEdit);
+ goToWeaponPage->setMaximumWidth(pmEdit.width() + 6);
+ GBoxOptionsLayout->addWidget(goToWeaponPage, 1, 2);
connect(goToWeaponPage, SIGNAL(clicked()), this, SLOT(jumpToWeapons()));
diff -r bfccb2ec4334 -r f860f27028cc QTfrontend/hedgewars.qrc
--- a/QTfrontend/hedgewars.qrc Mon Feb 01 21:26:15 2010 +0000
+++ b/QTfrontend/hedgewars.qrc Mon Feb 01 22:01:35 2010 +0000
@@ -30,6 +30,7 @@
res/NetworkPlay.png
res/Settings.png
res/dropdown.png
+ res/edit.png
res/checked.png
res/unchecked.png
res/graphicsicon.png
diff -r bfccb2ec4334 -r f860f27028cc QTfrontend/res/edit.png
Binary file QTfrontend/res/edit.png has changed