summaryrefslogtreecommitdiffstats
path: root/kmines/dialogs.cpp
diff options
context:
space:
mode:
authortpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2010-07-31 19:42:31 +0000
committertpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2010-07-31 19:42:31 +0000
commit576eb4299a00bc053db35414406f46372a0f70f2 (patch)
tree4c030922d533821db464af566188e7d40cc8848c /kmines/dialogs.cpp
parent0718336b6017d1a4fc1d626544180a5a2a29ddec (diff)
downloadtdegames-576eb4299a00bc053db35414406f46372a0f70f2.tar.gz
tdegames-576eb4299a00bc053db35414406f46372a0f70f2.zip
Trinity Qt initial conversion
git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdegames@1157643 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'kmines/dialogs.cpp')
-rw-r--r--kmines/dialogs.cpp82
1 files changed, 41 insertions, 41 deletions
diff --git a/kmines/dialogs.cpp b/kmines/dialogs.cpp
index d02b2eea..ad956c30 100644
--- a/kmines/dialogs.cpp
+++ b/kmines/dialogs.cpp
@@ -19,16 +19,16 @@
#include "dialogs.h"
#include "dialogs.moc"
-#include <qpixmap.h>
-#include <qvgroupbox.h>
-#include <qlayout.h>
-#include <qhbox.h>
-#include <qvbox.h>
-#include <qgrid.h>
-#include <qlabel.h>
-#include <qtimer.h>
-#include <qwhatsthis.h>
-#include <qcheckbox.h>
+#include <tqpixmap.h>
+#include <tqvgroupbox.h>
+#include <tqlayout.h>
+#include <tqhbox.h>
+#include <tqvbox.h>
+#include <tqgrid.h>
+#include <tqlabel.h>
+#include <tqtimer.h>
+#include <tqwhatsthis.h>
+#include <tqcheckbox.h>
#include <klocale.h>
#include <kmessagebox.h>
@@ -56,12 +56,12 @@ const char **Smiley::XPM_NAMES[NbMoods] = {
void Smiley::setMood(Mood mood)
{
- QPixmap p(XPM_NAMES[mood]);
+ TQPixmap p(XPM_NAMES[mood]);
setPixmap(p);
}
//-----------------------------------------------------------------------------
-DigitalClock::DigitalClock(QWidget *parent)
+DigitalClock::DigitalClock(TQWidget *parent)
: KGameLCDClock(parent, "digital_clock")
{
setFrameStyle(Panel | Sunken);
@@ -120,40 +120,40 @@ const uint CustomConfig::maxHeight = 50;
const uint CustomConfig::minHeight = 5;
CustomConfig::CustomConfig()
- : QWidget(0, "custom_config_widget"), _block(false)
+ : TQWidget(0, "custom_config_widget"), _block(false)
{
- QVBoxLayout *top = new QVBoxLayout(this, KDialog::spacingHint());
+ TQVBoxLayout *top = new TQVBoxLayout(this, KDialog::spacingHint());
_width = new KIntNumInput(this, "kcfg_CustomWidth");
_width->setLabel(i18n("Width:"));
_width->setRange(minWidth, maxWidth);
- connect(_width, SIGNAL(valueChanged(int)), SLOT(updateNbMines()));
+ connect(_width, TQT_SIGNAL(valueChanged(int)), TQT_SLOT(updateNbMines()));
top->addWidget(_width);
_height = new KIntNumInput(this, "kcfg_CustomHeight");
_height->setLabel(i18n("Height:"));
_height->setRange(minWidth, maxWidth);
- connect(_height, SIGNAL(valueChanged(int)), SLOT(updateNbMines()));
+ connect(_height, TQT_SIGNAL(valueChanged(int)), TQT_SLOT(updateNbMines()));
top->addWidget(_height);
_mines = new KIntNumInput(this, "kcfg_CustomMines");
_mines->setLabel(i18n("No. of mines:"));
_mines->setRange(1, Level::maxNbMines(maxWidth, maxHeight));
- connect(_mines, SIGNAL(valueChanged(int)), SLOT(updateNbMines()));
+ connect(_mines, TQT_SIGNAL(valueChanged(int)), TQT_SLOT(updateNbMines()));
top->addWidget(_mines);
top->addSpacing(2 * KDialog::spacingHint());
// combo to choose level
- QHBoxLayout *hbox = new QHBoxLayout(top);
- QLabel *label = new QLabel(i18n("Choose level:"), this);
+ TQHBoxLayout *hbox = new TQHBoxLayout(top);
+ TQLabel *label = new TQLabel(i18n("Choose level:"), this);
hbox->addWidget(label);
_gameType = new KComboBox(false, this);
- connect(_gameType, SIGNAL(activated(int)), SLOT(typeChosen(int)));
+ connect(_gameType, TQT_SIGNAL(activated(int)), TQT_SLOT(typeChosen(int)));
for (uint i=0; i<=Level::NB_TYPES; i++)
_gameType->insertItem(i18n(Level::LABELS[i]));
hbox->addWidget(_gameType);
- hbox->addWidget(new QWidget(this), 1);
+ hbox->addWidget(new TQWidget(this), 1);
top->addStretch(1);
}
@@ -209,34 +209,34 @@ static const char *MOUSE_ACTION_LABELS[Settings::EnumMouseAction::COUNT-1] = {
};
GameConfig::GameConfig()
- : QWidget(0, "game_config_widget"), _magicDialogEnabled(false)
+ : TQWidget(0, "game_config_widget"), _magicDialogEnabled(false)
{
- QVBoxLayout *top = new QVBoxLayout(this, KDialog::spacingHint());
+ TQVBoxLayout *top = new TQVBoxLayout(this, KDialog::spacingHint());
- QCheckBox *cb = new QCheckBox(i18n("Enable ? mark"), this, "kcfg_UncertainMark");
+ TQCheckBox *cb = new TQCheckBox(i18n("Enable ? mark"), this, "kcfg_UncertainMark");
top->addWidget(cb);
- cb = new QCheckBox(i18n("Enable keyboard"), this, "kcfg_KeyboardGame");
+ cb = new TQCheckBox(i18n("Enable keyboard"), this, "kcfg_KeyboardGame");
top->addWidget(cb);
- cb = new QCheckBox(i18n("Pause if window loses focus"), this, "kcfg_PauseFocus");
+ cb = new TQCheckBox(i18n("Pause if window loses focus"), this, "kcfg_PauseFocus");
top->addWidget(cb);
- cb = new QCheckBox(i18n("\"Magic\" reveal"), this, "kcfg_MagicReveal");
- QWhatsThis::add(cb, i18n("Set flags and reveal squares where they are trivial."));
- connect(cb, SIGNAL(toggled(bool)), SLOT(magicModified(bool)));
+ cb = new TQCheckBox(i18n("\"Magic\" reveal"), this, "kcfg_MagicReveal");
+ TQWhatsThis::add(cb, i18n("Set flags and reveal squares where they are trivial."));
+ connect(cb, TQT_SIGNAL(toggled(bool)), TQT_SLOT(magicModified(bool)));
top->addWidget(cb);
top->addSpacing(2 * KDialog::spacingHint());
- QHBoxLayout *hbox = new QHBoxLayout(top);
- QVGroupBox *gb = new QVGroupBox(i18n("Mouse Bindings"), this);
+ TQHBoxLayout *hbox = new TQHBoxLayout(top);
+ TQVGroupBox *gb = new TQVGroupBox(i18n("Mouse Bindings"), this);
hbox->addWidget(gb);
- QGrid *grid = new QGrid(2, gb);
+ TQGrid *grid = new TQGrid(2, gb);
grid->setSpacing(KDialog::spacingHint());
for (uint i=0; i< Settings::EnumButton::COUNT; i++) {
- (void)new QLabel(i18n(MOUSE_BUTTON_LABELS[i]), grid);
- QComboBox *cb = new QComboBox(false, grid, MOUSE_CONFIG_NAMES[i]);
+ (void)new TQLabel(i18n(MOUSE_BUTTON_LABELS[i]), grid);
+ TQComboBox *cb = new TQComboBox(false, grid, MOUSE_CONFIG_NAMES[i]);
for (uint k=0; k< (Settings::EnumMouseAction::COUNT-1); k++)
cb->insertItem(i18n(MOUSE_ACTION_LABELS[k]));
cb->setCurrentItem(i);
@@ -249,7 +249,7 @@ GameConfig::GameConfig()
void GameConfig::magicModified(bool on)
{
if ( !_magicDialogEnabled || !on ) return;
- KMessageBox::information(this, i18n("When the \"magic\" reveal is on, you lose the ability to enter the highscores."), QString::null, "magic_reveal_warning");
+ KMessageBox::information(this, i18n("When the \"magic\" reveal is on, you lose the ability to enter the highscores."), TQString::null, "magic_reveal_warning");
}
//-----------------------------------------------------------------------------
@@ -269,21 +269,21 @@ static const char *N_COLOR_CONFIG_NAMES[KMines::NB_N_COLORS] = {
};
AppearanceConfig::AppearanceConfig()
- : QWidget(0, "appearance_config_widget")
+ : TQWidget(0, "appearance_config_widget")
{
- QVBoxLayout *top = new QVBoxLayout(this, KDialog::spacingHint());
+ TQVBoxLayout *top = new TQVBoxLayout(this, KDialog::spacingHint());
- QHBoxLayout *hbox = new QHBoxLayout(top);
- QGrid *grid = new QGrid(2, this);
+ TQHBoxLayout *hbox = new TQHBoxLayout(top);
+ TQGrid *grid = new TQGrid(2, this);
grid->setSpacing(KDialog::spacingHint());
hbox->addWidget(grid);
for (uint i=0; i<Settings::EnumType::COUNT; i++) {
- (void)new QLabel(i18n(COLOR_LABELS[i]), grid);
+ (void)new TQLabel(i18n(COLOR_LABELS[i]), grid);
KColorButton *cb = new KColorButton(grid, COLOR_CONFIG_NAMES[i]);
cb->setFixedWidth(100);
}
for (uint i=0; i<NB_N_COLORS; i++) {
- (void)new QLabel(i18n("%n mine color:", "%n mines color:", i+1), grid);
+ (void)new TQLabel(i18n("%n mine color:", "%n mines color:", i+1), grid);
KColorButton *cb = new KColorButton(grid, N_COLOR_CONFIG_NAMES[i]);
cb->setFixedWidth(100);
}