summaryrefslogtreecommitdiffstats
path: root/konquest
diff options
context:
space:
mode:
Diffstat (limited to 'konquest')
-rw-r--r--konquest/fleetdlg.cc32
-rw-r--r--konquest/fleetdlg.h6
-rw-r--r--konquest/gameboard.cc92
-rw-r--r--konquest/gameboard.h7
-rw-r--r--konquest/gamecore.cc34
-rw-r--r--konquest/gamecore.h23
-rw-r--r--konquest/gameenddlg.cc12
-rw-r--r--konquest/gameenddlg.h3
-rw-r--r--konquest/int_validator.cc8
-rw-r--r--konquest/int_validator.h7
-rw-r--r--konquest/mainwin.cc14
-rw-r--r--konquest/mainwin.h1
-rw-r--r--konquest/map_widget.cc6
-rw-r--r--konquest/map_widget.h5
-rw-r--r--konquest/minimap.cc4
-rw-r--r--konquest/minimap.h5
-rw-r--r--konquest/newGameDlg_ui.ui76
-rw-r--r--konquest/newgamedlg.cc18
-rw-r--r--konquest/newgamedlg.h3
-rw-r--r--konquest/planet_info.cc46
-rw-r--r--konquest/planet_info.h7
-rw-r--r--konquest/scoredlg.cc34
-rw-r--r--konquest/scoredlg.h8
23 files changed, 231 insertions, 220 deletions
diff --git a/konquest/fleetdlg.cc b/konquest/fleetdlg.cc
index e933e895..e2194089 100644
--- a/konquest/fleetdlg.cc
+++ b/konquest/fleetdlg.cc
@@ -8,7 +8,7 @@
#include "fleetdlg.h"
-FleetDlgListViewItem::FleetDlgListViewItem(TQListView *parent, TQString s1, TQString s2, TQString s3, TQString s4, TQString s5) : TQListViewItem(parent, s1, s2, s3, s4, s5)
+FleetDlgListViewItem::FleetDlgListViewItem(TQListView *tqparent, TQString s1, TQString s2, TQString s3, TQString s4, TQString s5) : TQListViewItem(tqparent, s1, s2, s3, s4, s5)
{
}
@@ -35,8 +35,8 @@ int FleetDlgListViewItem::compare(TQListViewItem *i, int col, bool) const
}
-FleetDlg::FleetDlg( TQWidget *parent, AttackFleetList *fleets )
- : TQDialog(parent, "FleetDlg", true ), fleetList(fleets)
+FleetDlg::FleetDlg( TQWidget *tqparent, AttackFleetList *fleets )
+ : TQDialog(tqparent, "FleetDlg", true ), fleetList(fleets)
{
setCaption( kapp->makeStdCaption(i18n("Fleet Overview")) );
@@ -46,21 +46,21 @@ FleetDlg::FleetDlg( TQWidget *parent, AttackFleetList *fleets )
fleetTable->addColumn(i18n("Ships"));
fleetTable->addColumn(i18n("Kill Percentage"));
fleetTable->addColumn(i18n("Arrival Turn"));
- fleetTable->setMinimumSize( fleetTable->sizeHint() );
+ fleetTable->setMinimumSize( fleetTable->tqsizeHint() );
KPushButton *okButton = new KPushButton( KStdGuiItem::ok(), this );
- okButton->setMinimumSize( okButton->sizeHint() );
+ okButton->setMinimumSize( okButton->tqsizeHint() );
okButton->setDefault(true);
- TQVBoxLayout *layout1 = new TQVBoxLayout( this );
- TQHBoxLayout *layout2 = new TQHBoxLayout;
+ TQVBoxLayout *tqlayout1 = new TQVBoxLayout( this );
+ TQHBoxLayout *tqlayout2 = new TQHBoxLayout;
- layout1->addWidget( fleetTable, 1 );
- layout1->addLayout( layout2 );
+ tqlayout1->addWidget( fleetTable, 1 );
+ tqlayout1->addLayout( tqlayout2 );
- layout2->addStretch( 2 );
- layout2->addWidget( okButton );
- layout2->addStretch( 2 );
+ tqlayout2->addStretch( 2 );
+ tqlayout2->addWidget( okButton );
+ tqlayout2->addStretch( 2 );
connect( okButton, TQT_SIGNAL(clicked()), this, TQT_SLOT(accept()) );
@@ -79,10 +79,10 @@ FleetDlg::init()
while( (curFleet = nextFleet())) {
fleetNumber++;
new FleetDlgListViewItem(fleetTable,
- TQString("%1").arg(fleetNumber),
+ TQString("%1").tqarg(fleetNumber),
curFleet->destination->getName(),
- TQString("%1").arg(curFleet->getShipCount()),
- TQString("%1").arg(KGlobal::locale()->formatNumber(curFleet->killPercentage, 3)),
- TQString("%1").arg((int)ceil(curFleet->arrivalTurn)));
+ TQString("%1").tqarg(curFleet->getShipCount()),
+ TQString("%1").tqarg(KGlobal::locale()->formatNumber(curFleet->killPercentage, 3)),
+ TQString("%1").tqarg((int)ceil(curFleet->arrivalTurn)));
}
}
diff --git a/konquest/fleetdlg.h b/konquest/fleetdlg.h
index 7937f69e..a823cf0c 100644
--- a/konquest/fleetdlg.h
+++ b/konquest/fleetdlg.h
@@ -7,17 +7,17 @@
#include "gamecore.h"
-class FleetDlgListViewItem : public QListViewItem
+class FleetDlgListViewItem : public TQListViewItem
{
public:
- FleetDlgListViewItem(TQListView *parent, TQString s1, TQString s2, TQString s3, TQString s4, TQString s5);
+ FleetDlgListViewItem(TQListView *tqparent, TQString s1, TQString s2, TQString s3, TQString s4, TQString s5);
int compare(TQListViewItem *i, int col, bool) const;
};
class FleetDlg : public TQDialog {
public:
- FleetDlg( TQWidget *parent, AttackFleetList *fleets );
+ FleetDlg( TQWidget *tqparent, AttackFleetList *fleets );
private:
void init();
diff --git a/konquest/gameboard.cc b/konquest/gameboard.cc
index 17b40272..96433e02 100644
--- a/konquest/gameboard.cc
+++ b/konquest/gameboard.cc
@@ -33,8 +33,8 @@
/*********************************************************************
Game Board
*********************************************************************/
-GameBoard::GameBoard( TQWidget *parent )
- : TQWidget( parent ), gameInProgress( false ), gameState( NONE )
+GameBoard::GameBoard( TQWidget *tqparent )
+ : TQWidget( tqparent ), gameInProgress( false ), gameState( NONE )
{
TQColorGroup cg( white, black, green.light(), green.dark(), green, green.dark(75), green.dark() );
TQPalette palette( cg, cg, cg );
@@ -53,17 +53,17 @@ GameBoard::GameBoard( TQWidget *parent )
msgWidget->setTextFormat(LogText);
msgWidget->setMinimumHeight(100);
msgWidget->setHScrollBarMode(TQScrollView::AlwaysOff);
- msgWidget->setPaper(TQBrush(Qt::black));
+ msgWidget->setPaper(TQBrush(TQt::black));
planetInfo = new PlanetInfo( this, palette );
gameMessage = new TQLabel( this );
gameMessage->setPalette( palette );
turnCounter = new TQLabel( this );
turnCounter->setPalette( palette );
turnCounter->setText( "Turn" );
- turnCounter->setMaximumHeight( turnCounter->sizeHint().height() );
+ turnCounter->setMaximumHeight( turnCounter->tqsizeHint().height() );
endTurn = new TQPushButton( i18n("End Turn"), this );
- endTurn->setFixedSize( endTurn->sizeHint() );
+ endTurn->setFixedSize( endTurn->tqsizeHint() );
endTurn->setPalette( palette );
shipCountEdit = new TQLineEdit( this );
@@ -82,39 +82,39 @@ GameBoard::GameBoard( TQWidget *parent )
setMinimumSize( 600, 600 );
setMouseTracking( true );
- setFocusPolicy( StrongFocus );
+ setFocusPolicy( TQ_StrongFocus );
setFocus();
//********************************************************************
// Layout the main window
//********************************************************************
- TQHBoxLayout *layout1 = new TQHBoxLayout( this );
- TQVBoxLayout *layout2 = new TQVBoxLayout;
- TQHBoxLayout *layout3 = new TQHBoxLayout;
- TQVBoxLayout *layout4 = new TQVBoxLayout;
+ TQHBoxLayout *tqlayout1 = new TQHBoxLayout( this );
+ TQVBoxLayout *tqlayout2 = new TQVBoxLayout;
+ TQHBoxLayout *tqlayout3 = new TQHBoxLayout;
+ TQVBoxLayout *tqlayout4 = new TQVBoxLayout;
- layout1->addLayout( layout2 );
- layout2->addLayout( layout3 );
+ tqlayout1->addLayout( tqlayout2 );
+ tqlayout2->addLayout( tqlayout3 );
- layout3->addSpacing( 5 );
- layout3->addWidget( gameMessage, 10 );
- layout3->addWidget( shipCountEdit, 1 );
- layout3->addWidget( endTurn, 1 );
+ tqlayout3->addSpacing( 5 );
+ tqlayout3->addWidget( gameMessage, 10 );
+ tqlayout3->addWidget( shipCountEdit, 1 );
+ tqlayout3->addWidget( endTurn, 1 );
- layout2->addSpacing( 5 );
- layout2->addWidget( mapWidget, 0, AlignTop );
- layout2->addWidget( msgWidget );
- layout2->addStretch( 1 );
+ tqlayout2->addSpacing( 5 );
+ tqlayout2->addWidget( mapWidget, 0, AlignTop );
+ tqlayout2->addWidget( msgWidget );
+ tqlayout2->addStretch( 1 );
- layout1->addSpacing( 5 );
- layout1->addLayout( layout4, 10 );
+ tqlayout1->addSpacing( 5 );
+ tqlayout1->addLayout( tqlayout4, 10 );
- layout4->addWidget( planetInfo, 1 );
- layout4->addSpacing( 10 );
- layout4->addWidget( turnCounter, 1 );
- layout4->addStretch( 1 );
+ tqlayout4->addWidget( planetInfo, 1 );
+ tqlayout4->addSpacing( 10 );
+ tqlayout4->addWidget( turnCounter, 1 );
+ tqlayout4->addStretch( 1 );
- layout1->addStretch( 1 );
+ tqlayout1->addStretch( 1 );
//**********************************************************************
// Set up signal/slot connections
@@ -137,7 +137,7 @@ GameBoard::~GameBoard()
}
#if 0
-TQSize GameBoard::sizeHint() const
+TQSize GameBoard::tqsizeHint() const
{
return TQSize( 600, 550 );
}
@@ -187,7 +187,7 @@ GameBoard::keyPressEvent( TQKeyEvent *e )
}
-QString
+TQString
GameBoard::playerString(Player *player)
{
if (!player)
@@ -315,10 +315,10 @@ GameBoard::turn()
TQString msg;
msg = i18n("The distance from Planet %1 to Planet %2 is %3 light years.\n"
"A ship leaving this turn will arrive on turn %4")
- .arg(sourcePlanet->getName())
- .arg(destPlanet->getName())
- .arg(KGlobal::locale()->formatNumber( dist, 2 ))
- .arg(KGlobal::locale()->formatNumber( turnNumber + (int)dist, 0 ));
+ .tqarg(sourcePlanet->getName())
+ .tqarg(destPlanet->getName())
+ .tqarg(KGlobal::locale()->formatNumber( dist, 2 ))
+ .tqarg(KGlobal::locale()->formatNumber( turnNumber + (int)dist, 0 ));
KMessageBox::information( this, msg, i18n("Distance"));
gameState = NONE;
@@ -431,7 +431,7 @@ GameBoard::turn()
}
TQString turnStr;
- turnStr = i18n("Turn #: %1 of %2").arg(turnNumber).arg(lastTurn);
+ turnStr = i18n("Turn #: %1 of %2").tqarg(turnNumber).tqarg(lastTurn);
turnCounter->setText( turnStr );
@@ -470,15 +470,15 @@ GameBoard::nextTurn()
Player *winner = findWinner();
if (winner)
{
- mapWidget->repaint(true);
+ mapWidget->tqrepaint(true);
KMessageBox::information(this,
- i18n("The mighty %1 has conquered the galaxy!").arg(winner->getName()),
+ i18n("The mighty %1 has conquered the galaxy!").tqarg(winner->getName()),
i18n("Game Over"));
}
if( (turnNumber == lastTurn) && !winner )
{
- mapWidget->repaint(true);
+ mapWidget->tqrepaint(true);
GameEndDlg *dlg = new GameEndDlg( this );
if( dlg->exec() == KDialogBase::Yes ) {
@@ -492,7 +492,7 @@ GameBoard::nextTurn()
{
// Game over, man! Game over.
- mapWidget->repaint(true);
+ mapWidget->tqrepaint(true);
gameOver();
};
@@ -565,8 +565,8 @@ GameBoard::gameMsg(const TQString &msg, Player *player, Planet *planet, Player *
{
if (!player->isAiPlayer())
isHumanInvolved = true;
- colorMsg = colorMsg.arg(playerString(player));
- plainMsg = plainMsg.arg(player->getName());
+ colorMsg = colorMsg.tqarg(playerString(player));
+ plainMsg = plainMsg.tqarg(player->getName());
}
if (planet)
@@ -577,15 +577,15 @@ GameBoard::gameMsg(const TQString &msg, Player *player, Planet *planet, Player *
isHumanInvolved = true;
TQString color = planetPlayer->getColor().name();
- colorMsg = colorMsg.arg(TQString("<font color=\"%1\">%2</font>").arg(color, planet->getName()));
- plainMsg = plainMsg.arg(planet->getName());
+ colorMsg = colorMsg.tqarg(TQString("<font color=\"%1\">%2</font>").tqarg(color, planet->getName()));
+ plainMsg = plainMsg.tqarg(planet->getName());
}
- msgWidget->append(("<qt><font color=\"white\">Turn %1:</font> <font color=\""+color+"\">").arg(turnNumber)+colorMsg+"</font></qt>");
+ msgWidget->append(("<qt><font color=\"white\">Turn %1:</font> <font color=\""+color+"\">").tqarg(turnNumber)+colorMsg+"</font></qt>");
msgWidget->scrollToBottom();
if (isHumanInvolved)
{
- mapWidget->repaint(true);
+ mapWidget->tqrepaint(true);
KMessageBox::information(this, plainMsg);
}
}
@@ -660,7 +660,7 @@ GameBoard::doFleetArrival( AttackFleet *arrivingFleet )
TQString msg;
msg = i18n("Reinforcements (%1 ships) have arrived for planet %2.")
- .arg(arrivingFleet->getShipCount());
+ .tqarg(arrivingFleet->getShipCount());
gameMsg(msg, 0, arrivingFleet->destination);
}
} else {
@@ -717,7 +717,7 @@ GameBoard::doFleetArrival( AttackFleet *arrivingFleet )
}
}
- mapWidget->repaint(true);
+ mapWidget->tqrepaint(true);
}
//************************************************************************
diff --git a/konquest/gameboard.h b/konquest/gameboard.h
index ed165b21..7826d00f 100644
--- a/konquest/gameboard.h
+++ b/konquest/gameboard.h
@@ -21,17 +21,18 @@ enum GameState { NONE, SOURCE_PLANET, DEST_PLANET, SHIP_COUNT, RULER_SOURCE, RUL
//************************************************************************
// GameBoard Widget
//************************************************************************
-class GameBoard : public QWidget
+class GameBoard : public TQWidget
{
Q_OBJECT
+ TQ_OBJECT
public:
- GameBoard( TQWidget *parent );
+ GameBoard( TQWidget *tqparent );
virtual ~GameBoard();
bool isGameInProgress(void) const { return gameInProgress; }
-// virtual TQSize sizeHint() const;
+// virtual TQSize tqsizeHint() const;
protected slots:
void startNewGame();
diff --git a/konquest/gamecore.cc b/konquest/gamecore.cc
index 3706cf68..df8ba86e 100644
--- a/konquest/gamecore.cc
+++ b/konquest/gamecore.cc
@@ -94,7 +94,7 @@ Map::populateMap( PlayerList &players, Player *neutral,
Freeze();
int index = 0;
- TQString names( "ABCDEFGHIJKLMNOPQRSTUVWXYZ1234567890!@#$%^&*(),.<>;:[]{}/?-+\\|" );
+ TQString names( "ABCDEFGHIJKLMNOPTQRSTUVWXYZ1234567890!@#$%^&*(),.<>;:[]{}/?-+\\|" );
// Create a planet for each player
Player *plr;
@@ -242,16 +242,16 @@ const int Map::getColumns() const
//---------------------------------------------------------------------------
Sector::Sector()
-: TQObject(0,0), planet( NULL ), parentMap(NULL ), x(0), y(0)
+: TQObject(0,0), planet( NULL ), tqparentMap(NULL ), x(0), y(0)
{}
Sector::Sector( Map *newParentMap, int xPos, int yPos )
-: TQObject(0,0), planet(NULL), parentMap( newParentMap ), x(xPos), y(yPos)
+: TQObject(0,0), planet(NULL), tqparentMap( newParentMap ), x(xPos), y(yPos)
{
}
Sector::Sector( const Sector & other )
-: TQObject(0,0), planet(other.planet), parentMap(other.parentMap), x(other.x), y(other.y)
+: TQObject(0,0), planet(other.planet), tqparentMap(other.tqparentMap), x(other.x), y(other.y)
{
}
@@ -294,7 +294,7 @@ Sector::operator=( const Sector &other )
x = other.x;
y = other.y;
planet = other.planet;
- parentMap = other.parentMap;
+ tqparentMap = other.tqparentMap;
return *this;
}
@@ -302,7 +302,7 @@ Sector::operator=( const Sector &other )
void
Sector::select()
{
- parentMap->setSelectedSector( x, y );
+ tqparentMap->setSelectedSector( x, y );
emit selected();
}
@@ -322,29 +322,29 @@ int Sector::getColumn()
Planet::Planet( TQString planetName, Sector &newParentSector, Player *initialOwner,
int newProd, double newKillP, double newMorale )
- : TQObject(0,0), name(planetName), owner(initialOwner), parentSector(newParentSector),
+ : TQObject(0,0), name(planetName), owner(initialOwner), tqparentSector(newParentSector),
homeFleet( this, newProd ), killPercentage(newKillP), morale( newMorale ), productionRate(newProd)
{
- parentSector.setPlanet( this );
+ tqparentSector.setPlanet( this );
}
Planet::~Planet() {}
Planet *
-Planet::createPlayerPlanet( Sector &parentSector, Player *initialOwner, TQString planetName )
+Planet::createPlayerPlanet( Sector &tqparentSector, Player *initialOwner, TQString planetName )
{
CoreLogic clogic;
double morale = clogic.generateMorale();
- return new Planet( planetName, parentSector, initialOwner,
+ return new Planet( planetName, tqparentSector, initialOwner,
10, 0.400, morale );
}
Planet *
-Planet::createNeutralPlanet( Sector &parentSector, Player *initialOwner, TQString planetName )
+Planet::createNeutralPlanet( Sector &tqparentSector, Player *initialOwner, TQString planetName )
{
CoreLogic clogic;
double morale = clogic.generateMorale();
@@ -353,7 +353,7 @@ Planet::createNeutralPlanet( Sector &parentSector, Player *initialOwner, TQStrin
int productionRate = (int)clogic.generatePlanetProduction();
- return new Planet( planetName, parentSector,
+ return new Planet( planetName, tqparentSector,
initialOwner, productionRate, killP, morale );
}
@@ -398,7 +398,7 @@ Planet::setProduction( int newProduction )
void
Planet::select()
{
- parentSector.select();
+ tqparentSector.select();
emit selected();
}
@@ -423,7 +423,7 @@ Planet::getName() const
Sector &
Planet::getSector() const
{
- return parentSector;
+ return tqparentSector;
}
void
@@ -479,10 +479,10 @@ Player::getName()
return name;
}
-QString
+TQString
Player::getColoredName()
{
- return TQString("<font color=\"%1\">%2</font>").arg(color.name(), name);
+ return TQString("<font color=\"%1\">%2</font>").tqarg(color.name(), name);
}
Player *Player::createPlayer( TQString newName, TQColor color, int playerNum, bool isAi )
@@ -492,7 +492,7 @@ Player *Player::createPlayer( TQString newName, TQColor color, int playerNum, bo
Player *Player::createNeutralPlayer()
{
- return new Player( TQString::null, gray, NEUTRAL_PLAYER_NUMBER, false );
+ return new Player( TQString(), gray, NEUTRAL_PLAYER_NUMBER, false );
}
TQColor &Player::getColor()
diff --git a/konquest/gamecore.h b/konquest/gamecore.h
index 03683a08..80dab502 100644
--- a/konquest/gamecore.h
+++ b/konquest/gamecore.h
@@ -56,7 +56,7 @@ private:
// \--- class DefenseFleet
//**********************************************************
-class Fleet : public QObject
+class Fleet : public TQObject
{
public:
@@ -107,7 +107,7 @@ public:
// class Player
//**************************************************************
-class Player : public QObject
+class Player : public TQObject
{
public:
@@ -171,9 +171,10 @@ public:
// class Planet
//**************************************************************
-class Planet : public QObject
+class Planet : public TQObject
{
Q_OBJECT
+ TQ_OBJECT
private:
@@ -184,9 +185,9 @@ private:
public:
virtual ~Planet();
- static Planet *createPlayerPlanet( Sector &parentSector,
+ static Planet *createPlayerPlanet( Sector &tqparentSector,
Player *initialOwner, TQString planetName );
- static Planet *createNeutralPlanet( Sector &parentSector,
+ static Planet *createNeutralPlanet( Sector &tqparentSector,
Player *initialOwner, TQString planetName );
Sector &getSector() const;
@@ -213,7 +214,7 @@ signals:
private:
TQString name;
Player *owner;
- Sector &parentSector;
+ Sector &tqparentSector;
DefenseFleet homeFleet;
double killPercentage;
@@ -225,15 +226,16 @@ private:
// class Sector
//***************************************************************
-class Sector : public QObject
+class Sector : public TQObject
{
Q_OBJECT
+ TQ_OBJECT
public:
// constructors
Sector();
- Sector( Map *parentMap, int xpos, int ypos );
+ Sector( Map *tqparentMap, int xpos, int ypos );
Sector( const Sector & );
// assignment operator (makes initialization easy)
@@ -259,7 +261,7 @@ protected slots:
protected:
Planet *planet; // a sector has 0 or 1 planets
- Map *parentMap;
+ Map *tqparentMap;
int x, y;
};
@@ -268,9 +270,10 @@ protected:
// class Map
//*****************************************************************
-class Map : public QObject
+class Map : public TQObject
{
Q_OBJECT
+ TQ_OBJECT
public:
Map();
diff --git a/konquest/gameenddlg.cc b/konquest/gameenddlg.cc
index 2295acd9..2c31869e 100644
--- a/konquest/gameenddlg.cc
+++ b/konquest/gameenddlg.cc
@@ -11,23 +11,23 @@
#include "gameenddlg.h"
#include "gameenddlg.moc"
-GameEndDlg::GameEndDlg( TQWidget *parent )
+GameEndDlg::GameEndDlg( TQWidget *tqparent )
: KDialogBase( i18n("Out of Turns"),
KDialogBase::Yes|KDialogBase::No, KDialogBase::Yes, KDialogBase::No,
- parent, "end_game_dialog", true, true )
+ tqparent, "end_game_dialog", true, true )
{
TQVBox *page = makeVBoxMainWidget();
// Create controls
TQLabel *label1 = new TQLabel( i18n("This is the last turn.\nDo you wish to add extra turns?")+"\n\n", page );
- label1->setAlignment( AlignCenter );
+ label1->tqsetAlignment( AlignCenter );
turnCountLbl = new TQLabel( page );
turnCount = new TQSlider( 1, 40, 1, 5, Qt::Horizontal, page );
- KGuiItem addTurns(i18n("&Add Turns"), TQString::null, TQString::null,
+ KGuiItem addTurns(i18n("&Add Turns"), TQString(), TQString(),
i18n("Add the specified number of turns to the game and continue playing."));
- KGuiItem gameOver(i18n("&Game Over"), TQString::null, TQString::null,
+ KGuiItem gameOver(i18n("&Game Over"), TQString(), TQString(),
i18n("Terminate the current game."));
setButtonGuiItem(KDialogBase::Yes, addTurns);
@@ -71,6 +71,6 @@ GameEndDlg::extraTurns()
void
GameEndDlg::turnCountChange( int newTurnCount )
{
- TQString newLbl = i18n("Extra turns: %1").arg( newTurnCount );
+ TQString newLbl = i18n("Extra turns: %1").tqarg( newTurnCount );
turnCountLbl->setText( newLbl);
}
diff --git a/konquest/gameenddlg.h b/konquest/gameenddlg.h
index 4ffab262..4836a795 100644
--- a/konquest/gameenddlg.h
+++ b/konquest/gameenddlg.h
@@ -9,9 +9,10 @@ class TQPushButton;
class GameEndDlg : public KDialogBase
{
Q_OBJECT
+ TQ_OBJECT
public:
- GameEndDlg( TQWidget *parent );
+ GameEndDlg( TQWidget *tqparent );
virtual ~GameEndDlg();
int extraTurns();
diff --git a/konquest/int_validator.cc b/konquest/int_validator.cc
index 12f707c6..06315b18 100644
--- a/konquest/int_validator.cc
+++ b/konquest/int_validator.cc
@@ -3,8 +3,8 @@
#include "int_validator.h"
#include "int_validator.moc"
-IntValidator::IntValidator( TQWidget *parent, const char *name ) :
- TQValidator( parent, name )
+IntValidator::IntValidator( TQWidget *tqparent, const char *name ) :
+ TQValidator( TQT_TQOBJECT(tqparent), name )
{
#ifdef INT_MIN
v_bottom = INT_MIN;
@@ -14,8 +14,8 @@ IntValidator::IntValidator( TQWidget *parent, const char *name ) :
v_top = INT_MIN;
}
-IntValidator::IntValidator( int bottom, int top, TQWidget *parent, const char *name ) :
-TQValidator( parent, name )
+IntValidator::IntValidator( int bottom, int top, TQWidget *tqparent, const char *name ) :
+TQValidator( TQT_TQOBJECT(tqparent), name )
{
v_bottom = bottom;
v_top = top;
diff --git a/konquest/int_validator.h b/konquest/int_validator.h
index 6cb67bcb..4f995158 100644
--- a/konquest/int_validator.h
+++ b/konquest/int_validator.h
@@ -4,13 +4,14 @@
#include <tqvalidator.h>
-class IntValidator : public QValidator
+class IntValidator : public TQValidator
{
Q_OBJECT
+ TQ_OBJECT
public:
- IntValidator( TQWidget *parent, const char *name = 0 );
- IntValidator( int bottom, int top, TQWidget *parent, const char *name = 0 );
+ IntValidator( TQWidget *tqparent, const char *name = 0 );
+ IntValidator( int bottom, int top, TQWidget *tqparent, const char *name = 0 );
virtual ~IntValidator();
diff --git a/konquest/mainwin.cc b/konquest/mainwin.cc
index 866cd936..a5306172 100644
--- a/konquest/mainwin.cc
+++ b/konquest/mainwin.cc
@@ -37,18 +37,18 @@ MainWindow::~MainWindow()
void
MainWindow::setupKAction()
{
- KStdGameAction::gameNew( gameBoard, TQT_SLOT( startNewGame() ), actionCollection() );
- KStdGameAction::quit( this, TQT_SLOT( close() ), actionCollection() );
- endAction = KStdGameAction::end( gameBoard, TQT_SLOT( shutdownGame() ), actionCollection() );
+ KStdGameAction::gameNew( TQT_TQOBJECT(gameBoard), TQT_SLOT( startNewGame() ), actionCollection() );
+ KStdGameAction::quit( TQT_TQOBJECT(this), TQT_SLOT( close() ), actionCollection() );
+ endAction = KStdGameAction::end( TQT_TQOBJECT(gameBoard), TQT_SLOT( shutdownGame() ), actionCollection() );
endAction->setEnabled(false);
//AB: there is no icon for disabled - KToolBar::insertButton shows the
//different state - KAction not :-(
- measureAction = new KAction( i18n("&Measure Distance"), "ruler", 0, gameBoard, TQT_SLOT( measureDistance() ), actionCollection(), "game_measure" );
+ measureAction = new KAction( i18n("&Measure Distance"), "ruler", 0, TQT_TQOBJECT(gameBoard), TQT_SLOT( measureDistance() ), actionCollection(), "game_measure" );
measureAction->setEnabled(false);
- standingAction = new KAction( i18n("&Show Standings"), "help", 0, gameBoard, TQT_SLOT( showScores() ), actionCollection(), "game_scores" );
+ standingAction = new KAction( i18n("&Show Standings"), "help", 0, TQT_TQOBJECT(gameBoard), TQT_SLOT( showScores() ), actionCollection(), "game_scores" );
standingAction->setEnabled(false);
- fleetAction = new KAction( i18n("&Fleet Overview"), "launch", 0, gameBoard, TQT_SLOT( showFleets() ), actionCollection(), "game_fleets" );
+ fleetAction = new KAction( i18n("&Fleet Overview"), "launch", 0, TQT_TQOBJECT(gameBoard), TQT_SLOT( showFleets() ), actionCollection(), "game_fleets" );
fleetAction->setEnabled(false);
toolBar()->setBarPos( KToolBar::Left );
toolBar()->setMovingEnabled( false );
@@ -60,7 +60,7 @@ MainWindow::setupGameBoard()
gameBoard = new GameBoard( this );
setCentralWidget(gameBoard);
- connect( gameBoard, TQT_SIGNAL( newGameState( GameState )), this, TQT_SLOT( gameStateChange( GameState ) ) );
+ connect( gameBoard, TQT_SIGNAL( newGameState( GameState )), TQT_TQOBJECT(this), TQT_SLOT( gameStateChange( GameState ) ) );
}
diff --git a/konquest/mainwin.h b/konquest/mainwin.h
index 2954039c..50779e41 100644
--- a/konquest/mainwin.h
+++ b/konquest/mainwin.h
@@ -11,6 +11,7 @@ class PlanetStatusTable;
class MainWindow : public KMainWindow
{
Q_OBJECT
+ TQ_OBJECT
public:
MainWindow();
diff --git a/konquest/map_widget.cc b/konquest/map_widget.cc
index a8aa33de..e6d8512c 100644
--- a/konquest/map_widget.cc
+++ b/konquest/map_widget.cc
@@ -9,8 +9,8 @@
#include <kglobal.h>
#include "map_widget.moc"
-ConquestMap::ConquestMap( Map *newMap, TQWidget *parent )
- : TQGridView( parent ),
+ConquestMap::ConquestMap( Map *newMap, TQWidget *tqparent )
+ : TQGridView( tqparent ),
SECTOR_HEIGHT( 28 ), SECTOR_WIDTH( 28 ),
BOARD_HEIGHT( newMap->getRows() * SECTOR_HEIGHT ),
BOARD_WIDTH( newMap->getColumns() * SECTOR_WIDTH ),
@@ -149,7 +149,7 @@ ConquestMap::squareBlink()
void
ConquestMap::mapUpdate()
{
- viewport()->repaint(false);
+ viewport()->tqrepaint(false);
}
diff --git a/konquest/map_widget.h b/konquest/map_widget.h
index ed8d98f3..e408b2dd 100644
--- a/konquest/map_widget.h
+++ b/konquest/map_widget.h
@@ -13,13 +13,14 @@
#include "gamecore.h"
#include "images.h"
-class ConquestMap : public QGridView
+class ConquestMap : public TQGridView
{
Q_OBJECT
+ TQ_OBJECT
// Constructors
public:
- ConquestMap( Map *newMap, TQWidget *parent = 0 );
+ ConquestMap( Map *newMap, TQWidget *tqparent = 0 );
virtual ~ConquestMap();
// Interface
diff --git a/konquest/minimap.cc b/konquest/minimap.cc
index a287ab79..c08e7282 100644
--- a/konquest/minimap.cc
+++ b/konquest/minimap.cc
@@ -7,8 +7,8 @@
#include "minimap.h"
#include "minimap.moc"
-MiniMap::MiniMap( TQWidget *parent, const char *name )
- : TQGridView( parent, name ),
+MiniMap::MiniMap( TQWidget *tqparent, const char *name )
+ : TQGridView( tqparent, name ),
SECTOR_HEIGHT( 12 ), SECTOR_WIDTH( 12 ),
BOARD_HEIGHT( 10 * SECTOR_HEIGHT ),
BOARD_WIDTH( 10 * SECTOR_WIDTH ),
diff --git a/konquest/minimap.h b/konquest/minimap.h
index 886e247c..33d90ef2 100644
--- a/konquest/minimap.h
+++ b/konquest/minimap.h
@@ -11,13 +11,14 @@
#include "images.h"
-class MiniMap : public QGridView
+class MiniMap : public TQGridView
{
Q_OBJECT
+ TQ_OBJECT
// Constructors
public:
- MiniMap( TQWidget *parent = 0, const char* name = 0 );
+ MiniMap( TQWidget *tqparent = 0, const char* name = 0 );
virtual ~MiniMap();
void setMap( Map *newMap );
diff --git a/konquest/newGameDlg_ui.ui b/konquest/newGameDlg_ui.ui
index 2768e5f8..61188418 100644
--- a/konquest/newGameDlg_ui.ui
+++ b/konquest/newGameDlg_ui.ui
@@ -1,10 +1,10 @@
<!DOCTYPE UI><UI version="3.3" stdsetdef="1">
<class>NewGameDlgUI</class>
-<widget class="QWidget">
+<widget class="TQWidget">
<property name="name">
<cstring>NewGameDlgUI</cstring>
</property>
- <property name="geometry">
+ <property name="tqgeometry">
<rect>
<x>0</x>
<y>0</y>
@@ -16,23 +16,23 @@
<property name="name">
<cstring>unnamed</cstring>
</property>
- <widget class="QLayoutWidget">
+ <widget class="TQLayoutWidget">
<property name="name">
- <cstring>layout9</cstring>
+ <cstring>tqlayout9</cstring>
</property>
<hbox>
<property name="name">
<cstring>unnamed</cstring>
</property>
- <widget class="QLayoutWidget">
+ <widget class="TQLayoutWidget">
<property name="name">
- <cstring>layout4</cstring>
+ <cstring>tqlayout4</cstring>
</property>
<vbox>
<property name="name">
<cstring>unnamed</cstring>
</property>
- <widget class="QLabel">
+ <widget class="TQLabel">
<property name="name">
<cstring>labelPlayers</cstring>
</property>
@@ -43,7 +43,7 @@
<cstring>sliderPlayers</cstring>
</property>
</widget>
- <widget class="QSlider">
+ <widget class="TQSlider">
<property name="name">
<cstring>sliderPlayers</cstring>
</property>
@@ -57,7 +57,7 @@
<enum>Horizontal</enum>
</property>
</widget>
- <widget class="QLabel">
+ <widget class="TQLabel">
<property name="name">
<cstring>labelPlayerList</cstring>
</property>
@@ -68,7 +68,7 @@
<cstring>listPlayers</cstring>
</property>
</widget>
- <widget class="QListView">
+ <widget class="TQListView">
<column>
<property name="text">
<string>Name</string>
@@ -95,15 +95,15 @@
<cstring>listPlayers</cstring>
</property>
</widget>
- <widget class="QLayoutWidget">
+ <widget class="TQLayoutWidget">
<property name="name">
- <cstring>layout3</cstring>
+ <cstring>tqlayout3</cstring>
</property>
<hbox>
<property name="name">
<cstring>unnamed</cstring>
</property>
- <widget class="QLabel">
+ <widget class="TQLabel">
<property name="name">
<cstring>labelNewPlayer</cstring>
</property>
@@ -114,7 +114,7 @@
<cstring>newPlayer</cstring>
</property>
</widget>
- <widget class="QLineEdit">
+ <widget class="TQLineEdit">
<property name="name">
<cstring>newPlayer</cstring>
</property>
@@ -129,9 +129,9 @@
</widget>
</hbox>
</widget>
- <widget class="QLayoutWidget">
+ <widget class="TQLayoutWidget">
<property name="name">
- <cstring>layout2</cstring>
+ <cstring>tqlayout2</cstring>
</property>
<hbox>
<property name="name">
@@ -147,14 +147,14 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>0</width>
<height>20</height>
</size>
</property>
</spacer>
- <widget class="QPushButton">
+ <widget class="TQPushButton">
<property name="name">
<cstring>addPlayer</cstring>
</property>
@@ -172,7 +172,7 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>0</width>
<height>20</height>
@@ -193,22 +193,22 @@
<property name="sizeType">
<enum>Fixed</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>20</width>
<height>20</height>
</size>
</property>
</spacer>
- <widget class="QLayoutWidget">
+ <widget class="TQLayoutWidget">
<property name="name">
- <cstring>layout8</cstring>
+ <cstring>tqlayout8</cstring>
</property>
<vbox>
<property name="name">
<cstring>unnamed</cstring>
</property>
- <widget class="QLabel">
+ <widget class="TQLabel">
<property name="name">
<cstring>labelPlanets</cstring>
</property>
@@ -219,7 +219,7 @@
<cstring>sliderPlanets</cstring>
</property>
</widget>
- <widget class="QSlider">
+ <widget class="TQSlider">
<property name="name">
<cstring>sliderPlanets</cstring>
</property>
@@ -236,7 +236,7 @@
<enum>Horizontal</enum>
</property>
</widget>
- <widget class="QLabel">
+ <widget class="TQLabel">
<property name="name">
<cstring>labelMap</cstring>
</property>
@@ -244,9 +244,9 @@
<string>Preview map:</string>
</property>
</widget>
- <widget class="QLayoutWidget">
+ <widget class="TQLayoutWidget">
<property name="name">
- <cstring>layout7</cstring>
+ <cstring>tqlayout7</cstring>
</property>
<hbox>
<property name="name">
@@ -262,7 +262,7 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>0</width>
<height>20</height>
@@ -284,7 +284,7 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>0</width>
<height>20</height>
@@ -303,16 +303,16 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>20</width>
<height>16</height>
</size>
</property>
</spacer>
- <widget class="QLayoutWidget">
+ <widget class="TQLayoutWidget">
<property name="name">
- <cstring>layout5</cstring>
+ <cstring>tqlayout5</cstring>
</property>
<hbox>
<property name="name">
@@ -328,14 +328,14 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>31</width>
<height>20</height>
</size>
</property>
</spacer>
- <widget class="QPushButton">
+ <widget class="TQPushButton">
<property name="name">
<cstring>rejectMap</cstring>
</property>
@@ -353,7 +353,7 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>51</width>
<height>20</height>
@@ -380,7 +380,7 @@
<enum>Horizontal</enum>
</property>
</widget>
- <widget class="QLabel">
+ <widget class="TQLabel">
<property name="name">
<cstring>labelTurns</cstring>
</property>
@@ -391,7 +391,7 @@
<cstring>sliderTurns</cstring>
</property>
</widget>
- <widget class="QSlider">
+ <widget class="TQSlider">
<property name="name">
<cstring>sliderTurns</cstring>
</property>
@@ -433,7 +433,7 @@
<data format="PNG" length="1002">89504e470d0a1a0a0000000d4948445200000016000000160806000000c4b46c3b000003b149444154789cad945f4c5b551cc73fe7dc4b7b4bcba0762d45c43114323599ee6192609c51d883892ce083f1718b3ebb185f8dc91e972cf39d2d2a2f1af664b6f1e0fe3863a0718969700eb0c52142da0242a1bd6d696f7bcff101585203ceb8fd9ece39f99dcff9fe7edf939f88c562ec465f5f9fe609442c161362173c3e3eae7b7a7ac8e7f36432196cdbfe4f907c3e4f2291201e8fe338cec3737357e9e8e828aded1e229d650e1f2d51754b082110124c13a4dc5ea341eb9dc284c0558a853f3ce8cb0677ef500fde7d39d2596679e326597b8e9abb85d7a770ab16ab6983ec5a05b487a70e36f0f4e10afe408d6a558310980108478dba4a1e8233990c5d474b64ed39aa3a8fe5f3317fbf81dbd70bccfeb205947632fd74f6589c1c6ea2f70d03a58ba0c1f2c9bdc1b66de3b8256a6e11cbe7e3ee1d181b590124fe2693aeee08d223c82c3a2c24b7b874bec8f26288774f7bd054504aef0dde6e99c0eb83f9fb266323cb80a27fb0958141836044605a2ee5523393371cc646fee2da37195aa35d0c0c5b4859ac03d7e91712dcaac5adab3650a3ff9d08ef7dd8404bb48869e5d958b5b87dadc4c9a1464e9f0d0326df7ebd86bd2e310cb1bf62d384d59441f2d70a070e1c60e09489929b988681bdd9cc97170bcc4c65595f71f8e0e3301337fc24a7732467831875a47f289652b0be5e4151e6d07316c1b0c0340d8ab92023e76d66a6b2840e36d2fb7a13fee632475e6edc367ea98a90fb98b7dd6310ca0328a44761582e1bab41befabcc0ec940d28bc5e93b68e064cab84e1d9beaeb48934eac1f53b01c1b000fca496aa54b61a99fcde61662a4b4b4b23d1680be9d426173e4df3602a48ea411989a4fd590f52a8fd156b05ed9d350e3defe3cfdf4b4c7ce770ea7d3fb9f520afbe1620daeee5c26735d20b9b9cfb6811a754a439e4e5c5639a4caa1e5caf586bfc0197b78702005cb9b4cae4cd3267ce8638fe964bd72b393e39d74928d242617303a756a37f284447770dcdbffc6384a05a85de1306e9a52057c7527c7131c3c42d3f475eb2303c82d4fc3276d6811db37efeb148723082d9b08f79f97c1e5729109a9a28307cc622d2d6cdf52b2b24efe548dedb00142009862cfa879ee1a71f6cec928353511472fbf4389148b0b0e0c108081412458dfe21c9f11351e67e7358595468246d1d1e5e38a6e9e851bc39d84ab502a669331dafec0d8ec7e3e8cb06e1a881d727d1ae40180a434a8c9db129a54126ad48a7358c2b4c5352c8c374bcccdab2bb37d8719cba79fab8211f9df218e0582c261e95f8bfc04f1a1e8bc5c4dfe0a19017a725d8c60000000049454e44ae426082</data>
</image>
</images>
-<layoutdefaults spacing="6" margin="11"/>
+<tqlayoutdefaults spacing="6" margin="11"/>
<includehints>
<includehint>minimap.h</includehint>
</includehints>
diff --git a/konquest/newgamedlg.cc b/konquest/newgamedlg.cc
index 232e6415..fffe17d4 100644
--- a/konquest/newgamedlg.cc
+++ b/konquest/newgamedlg.cc
@@ -25,9 +25,9 @@
New Game Dialog Members
************************************************************************/
-NewGameDlg::NewGameDlg( TQWidget *parent, Map *pmap, PlayerList *players,
+NewGameDlg::NewGameDlg( TQWidget *tqparent, Map *pmap, PlayerList *players,
Player *neutralPlayer, PlanetList *planets )
- : KDialogBase( parent, "new_game_dialog", true, i18n("Start New Game"),
+ : KDialogBase( tqparent, "new_game_dialog", true, i18n("Start New Game"),
KDialogBase::Ok|KDialogBase::Default|KDialogBase::Cancel, KDialogBase::NoDefault, true ),
plrList(players), plnetList(planets), neutral(neutralPlayer),
map(pmap)
@@ -96,7 +96,7 @@ NewGameDlg::init()
for( TQListViewItem *item = w->listPlayers->firstChild();
item; item = item->nextSibling(), plrNum++ )
{
- TQString key = TQString("Player_%1").arg(plrNum);
+ TQString key = TQString("Player_%1").tqarg(plrNum);
TQString playerName = config->readEntry(key);
if (playerName.isEmpty())
@@ -151,7 +151,7 @@ NewGameDlg::slotAddPlayer()
item->setText(1, i18n("Human Player"));
item->setText(0, playerName);
- w->newPlayer->setText(TQString::null);
+ w->newPlayer->setText(TQString());
updateMiniMap();
updateLabels();
@@ -184,7 +184,7 @@ NewGameDlg::setPlayerCount(int playerCount)
while(w->listPlayers->childCount() < playerCount)
{
- TQString playerName = i18n("Generated AI player name", "Comp%1").arg(i+1);
+ TQString playerName = i18n("Generated AI player name", "Comp%1").tqarg(i+1);
TQPixmap pm(16,16);
TQColor color(PlayerColors[i]);
pm.fill(color);
@@ -229,9 +229,9 @@ NewGameDlg::turns()
void
NewGameDlg::updateLabels()
{
- w->labelPlayers->setText(i18n("Number of &players: %1").arg(w->sliderPlayers->value()));
- w->labelPlanets->setText(i18n("Number of neutral p&lanets: %1").arg(w->sliderPlanets->value()));
- w->labelTurns->setText(i18n("Number of &turns: %1").arg(w->sliderTurns->value()));
+ w->labelPlayers->setText(i18n("Number of &players: %1").tqarg(w->sliderPlayers->value()));
+ w->labelPlanets->setText(i18n("Number of neutral p&lanets: %1").tqarg(w->sliderPlanets->value()));
+ w->labelTurns->setText(i18n("Number of &turns: %1").tqarg(w->sliderTurns->value()));
}
void
@@ -269,7 +269,7 @@ NewGameDlg::save()
for( TQListViewItem *item = w->listPlayers->firstChild();
item; item = item->nextSibling() )
{
- TQString key = TQString("Player_%1").arg(plrNum);
+ TQString key = TQString("Player_%1").tqarg(plrNum);
TQString playerName = item->text(0);
bool ai = (item->text(2) == "A");
if (ai)
diff --git a/konquest/newgamedlg.h b/konquest/newgamedlg.h
index 6a8c81d4..b3c93b2c 100644
--- a/konquest/newgamedlg.h
+++ b/konquest/newgamedlg.h
@@ -15,9 +15,10 @@ class NewGameDlgUI;
class NewGameDlg : public KDialogBase
{
Q_OBJECT
+ TQ_OBJECT
public:
- NewGameDlg( TQWidget *parent, Map *map, PlayerList *playerList,
+ NewGameDlg( TQWidget *tqparent, Map *map, PlayerList *playerList,
Player *neutralPlayer, PlanetList *planetList );
int turns( void );
diff --git a/konquest/planet_info.cc b/konquest/planet_info.cc
index 1d178493..a9f03034 100644
--- a/konquest/planet_info.cc
+++ b/konquest/planet_info.cc
@@ -9,8 +9,8 @@
#include <kglobal.h>
#include "planet_info.moc"
-PlanetInfo::PlanetInfo( TQWidget *parent, TQPalette palette )
- : TQFrame( parent )
+PlanetInfo::PlanetInfo( TQWidget *tqparent, TQPalette palette )
+ : TQFrame( tqparent )
{
setPalette( palette );
@@ -27,19 +27,19 @@ PlanetInfo::PlanetInfo( TQWidget *parent, TQPalette palette )
clearDisplay();
- TQVBoxLayout *layout1 = new TQVBoxLayout( this );
+ TQVBoxLayout *tqlayout1 = new TQVBoxLayout( this );
- layout1->addWidget( name );
- layout1->addWidget( owner );
- layout1->addWidget( ships );
- layout1->addWidget( production );
- layout1->addWidget( kill_percent );
- layout1->addStretch(1);
+ tqlayout1->addWidget( name );
+ tqlayout1->addWidget( owner );
+ tqlayout1->addWidget( ships );
+ tqlayout1->addWidget( production );
+ tqlayout1->addWidget( kill_percent );
+ tqlayout1->addStretch(1);
setMouseTracking( true );
- setMinimumSize( sizeHint() );
- setMaximumHeight( sizeHint().height() );
+ setMinimumSize( tqsizeHint() );
+ setMaximumHeight( tqsizeHint().height() );
}
PlanetInfo::~PlanetInfo()
@@ -47,15 +47,15 @@ PlanetInfo::~PlanetInfo()
emptyPlanetInfoList();
}
-TQSize PlanetInfo::sizeHint() const
+TQSize PlanetInfo::tqsizeHint() const
{
int height;
- height = name->sizeHint().height() +
- owner->sizeHint().height() +
- ships->sizeHint().height() +
- production->sizeHint().height()+
- kill_percent->sizeHint().height();
+ height = name->tqsizeHint().height() +
+ owner->tqsizeHint().height() +
+ ships->tqsizeHint().height() +
+ production->tqsizeHint().height()+
+ kill_percent->tqsizeHint().height();
return TQSize( 100, height );
}
@@ -126,7 +126,7 @@ void PlanetInfo::showPlanet( Planet *planet )
TQString temp;
- temp = "<qt>" + i18n("Planet name: %1").arg(planet->getName());
+ temp = "<qt>" + i18n("Planet name: %1").tqarg(planet->getName());
name->setText( temp );
return;
}
@@ -141,19 +141,19 @@ void PlanetInfo::showPlanet( Planet *planet )
TQString temp;
- temp = "<qt>" + i18n("Planet name: %1").arg(p->planet->getName());
+ temp = "<qt>" + i18n("Planet name: %1").tqarg(p->planet->getName());
name->setText( temp );
- temp = "<qt>" + i18n("Owner: %1").arg(p->planet->getPlayer()->getColoredName());
+ temp = "<qt>" + i18n("Owner: %1").tqarg(p->planet->getPlayer()->getColoredName());
owner->setText( temp );
- temp = "<qt>" + i18n("Ships: %1").arg( KGlobal::locale()->formatNumber(p->ships, 0) );
+ temp = "<qt>" + i18n("Ships: %1").tqarg( KGlobal::locale()->formatNumber(p->ships, 0) );
ships->setText( temp );
- temp = "<qt>" + i18n("Production: %1").arg( KGlobal::locale()->formatNumber(p->production, 0) );
+ temp = "<qt>" + i18n("Production: %1").tqarg( KGlobal::locale()->formatNumber(p->production, 0) );
production->setText( temp );
- temp = "<qt>" + i18n("Kill percent: %1").arg( KGlobal::locale()->formatNumber(p->killRate, 3) );
+ temp = "<qt>" + i18n("Kill percent: %1").tqarg( KGlobal::locale()->formatNumber(p->killRate, 3) );
kill_percent->setText( temp );
}
}
diff --git a/konquest/planet_info.h b/konquest/planet_info.h
index e31882a9..c4386cee 100644
--- a/konquest/planet_info.h
+++ b/konquest/planet_info.h
@@ -20,17 +20,18 @@ struct planet_info_buffer {
typedef TQPtrList<planet_info_buffer> PlanetInfoList;
typedef TQPtrListIterator<planet_info_buffer> PlanetInfoListIterator;
-class PlanetInfo : public QFrame
+class PlanetInfo : public TQFrame
{
Q_OBJECT
+ TQ_OBJECT
public:
- PlanetInfo( TQWidget *parent, TQPalette palette );
+ PlanetInfo( TQWidget *tqparent, TQPalette palette );
virtual ~PlanetInfo();
void setPlanetList( PlanetList &newPlanets );
void rescanPlanets();
- TQSize sizeHint() const;
+ TQSize tqsizeHint() const;
public slots:
void showPlanet( Planet * );
diff --git a/konquest/scoredlg.cc b/konquest/scoredlg.cc
index fee4a404..3400032e 100644
--- a/konquest/scoredlg.cc
+++ b/konquest/scoredlg.cc
@@ -6,7 +6,7 @@
#include "scoredlg.h"
-ScoreDlgListViewItem::ScoreDlgListViewItem(TQListView *parent, TQString s1, TQString s2, TQString s3, TQString s4, TQString s5, TQString s6) : TQListViewItem(parent, s1, s2, s3, s4, s5, s6)
+ScoreDlgListViewItem::ScoreDlgListViewItem(TQListView *tqparent, TQString s1, TQString s2, TQString s3, TQString s4, TQString s5, TQString s6) : TQListViewItem(tqparent, s1, s2, s3, s4, s5, s6)
{
}
@@ -27,8 +27,8 @@ int ScoreDlgListViewItem::compare(TQListViewItem *i, int col, bool) const
}
-ScoreDlg::ScoreDlg( TQWidget *parent, const TQString& title, PlayerList *players )
- : TQDialog(parent, "ScoreDlg", true ), plrList(players)
+ScoreDlg::ScoreDlg( TQWidget *tqparent, const TQString& title, PlayerList *players )
+ : TQDialog(tqparent, "ScoreDlg", true ), plrList(players)
{
setCaption( kapp->makeStdCaption(title) );
@@ -39,21 +39,21 @@ ScoreDlg::ScoreDlg( TQWidget *parent, const TQString& title, PlayerList *players
scoreTable->addColumn(i18n("Fleets Launched"));
scoreTable->addColumn(i18n("Fleets Destroyed"));
scoreTable->addColumn(i18n("Ships Destroyed"));
- scoreTable->setMinimumSize( scoreTable->sizeHint() );
+ scoreTable->setMinimumSize( scoreTable->tqsizeHint() );
KPushButton *okButton = new KPushButton( KStdGuiItem::ok(), this );
- okButton->setMinimumSize( okButton->sizeHint() );
+ okButton->setMinimumSize( okButton->tqsizeHint() );
okButton->setDefault(true);
- TQVBoxLayout *layout1 = new TQVBoxLayout( this );
- TQHBoxLayout *layout2 = new TQHBoxLayout;
+ TQVBoxLayout *tqlayout1 = new TQVBoxLayout( this );
+ TQHBoxLayout *tqlayout2 = new TQHBoxLayout;
- layout1->addWidget( scoreTable, 1 );
- layout1->addLayout( layout2 );
+ tqlayout1->addWidget( scoreTable, 1 );
+ tqlayout1->addLayout( tqlayout2 );
- layout2->addStretch( 2 );
- layout2->addWidget( okButton );
- layout2->addStretch( 2 );
+ tqlayout2->addStretch( 2 );
+ tqlayout2->addWidget( okButton );
+ tqlayout2->addStretch( 2 );
connect( okButton, TQT_SIGNAL(clicked()), this, TQT_SLOT(accept()) );
@@ -71,10 +71,10 @@ ScoreDlg::init()
for( ;(curPlayer = itr()); )
new ScoreDlgListViewItem(scoreTable,
curPlayer->getName(),
- TQString("%1").arg(curPlayer->getShipsBuilt()),
- TQString("%1").arg(curPlayer->getPlanetsConquered()),
- TQString("%1").arg(curPlayer->getFleetsLaunched()),
- TQString("%1").arg(curPlayer->getEnemyFleetsDestroyed()),
- TQString("%1").arg(curPlayer->getEnemyShipsDestroyed()));
+ TQString("%1").tqarg(curPlayer->getShipsBuilt()),
+ TQString("%1").tqarg(curPlayer->getPlanetsConquered()),
+ TQString("%1").tqarg(curPlayer->getFleetsLaunched()),
+ TQString("%1").tqarg(curPlayer->getEnemyFleetsDestroyed()),
+ TQString("%1").tqarg(curPlayer->getEnemyShipsDestroyed()));
}
diff --git a/konquest/scoredlg.h b/konquest/scoredlg.h
index 55eaa926..88b7911d 100644
--- a/konquest/scoredlg.h
+++ b/konquest/scoredlg.h
@@ -7,18 +7,18 @@
#include "gamecore.h"
-class ScoreDlgListViewItem : public QListViewItem
+class ScoreDlgListViewItem : public TQListViewItem
{
public:
- ScoreDlgListViewItem(TQListView *parent, TQString s1, TQString s2, TQString s3, TQString s4, TQString s5, TQString s6);
+ ScoreDlgListViewItem(TQListView *tqparent, TQString s1, TQString s2, TQString s3, TQString s4, TQString s5, TQString s6);
int compare(TQListViewItem *i, int col, bool) const;
};
-class ScoreDlg : public QDialog
+class ScoreDlg : public TQDialog
{
public:
- ScoreDlg( TQWidget *parent, const TQString& title, PlayerList *players );
+ ScoreDlg( TQWidget *tqparent, const TQString& title, PlayerList *players );
private:
void init();