summaryrefslogtreecommitdiffstats
path: root/kreversi/qreversigameview.cpp
diff options
context:
space:
mode:
authorTimothy Pearson <[email protected]>2011-12-15 15:47:36 -0600
committerTimothy Pearson <[email protected]>2011-12-15 15:47:36 -0600
commit97d1732e257f8700488d7ca1660ae7eba8fc6065 (patch)
tree4c6397ed2c1dd6f7c3354b5b87f313547d92a35f /kreversi/qreversigameview.cpp
parent9c27a1a03e02fd53aedc1a182444b35fd8e14967 (diff)
downloadtdegames-97d1732e257f8700488d7ca1660ae7eba8fc6065.tar.gz
tdegames-97d1732e257f8700488d7ca1660ae7eba8fc6065.zip
Rename a number of old tq methods that are no longer tq specific
Diffstat (limited to 'kreversi/qreversigameview.cpp')
-rw-r--r--kreversi/qreversigameview.cpp50
1 files changed, 25 insertions, 25 deletions
diff --git a/kreversi/qreversigameview.cpp b/kreversi/qreversigameview.cpp
index f661d62c..df9bc680 100644
--- a/kreversi/qreversigameview.cpp
+++ b/kreversi/qreversigameview.cpp
@@ -37,7 +37,7 @@
*/
-#include <tqlayout.h>
+#include <layout.h>
#include <tqwidget.h>
#include <tqlabel.h>
@@ -156,30 +156,30 @@ QReversiGameView::~QReversiGameView()
void QReversiGameView::createView()
{
- TQGridLayout *tqlayout = new TQGridLayout(this, 4, 2);
+ TQGridLayout *layout = new TQGridLayout(this, 4, 2);
// The board
m_boardView = new QReversiBoardView(this, m_game);
m_boardView->loadSettings(); // Load the pixmaps used in the status widgets.
- tqlayout->addMultiCellWidget(m_boardView, 0, 3, 0, 0);
+ layout->addMultiCellWidget(m_boardView, 0, 3, 0, 0);
// The status widgets
- m_blacktqStatus = new StatusWidget(TQString(), this);
- m_blacktqStatus->setPixmap(m_boardView->chipPixmap(Black, 20));
- tqlayout->addWidget(m_blacktqStatus, 0, 1);
- m_whitetqStatus = new StatusWidget(TQString(), this);
- m_whitetqStatus->setPixmap(m_boardView->chipPixmap(White, 20));
- tqlayout->addWidget(m_whitetqStatus, 1, 1);
+ m_blackStatus = new StatusWidget(TQString(), this);
+ m_blackStatus->setPixmap(m_boardView->chipPixmap(Black, 20));
+ layout->addWidget(m_blackStatus, 0, 1);
+ m_whiteStatus = new StatusWidget(TQString(), this);
+ m_whiteStatus->setPixmap(m_boardView->chipPixmap(White, 20));
+ layout->addWidget(m_whiteStatus, 1, 1);
// The "Moves" label
TQLabel *movesLabel = new TQLabel( i18n("Moves"), this);
- movesLabel->tqsetAlignment(AlignCenter);
- tqlayout->addWidget(movesLabel, 2, 1);
+ movesLabel->setAlignment(AlignCenter);
+ layout->addWidget(movesLabel, 2, 1);
// The list of moves.
m_movesView = new TQListBox(this, "moves");
m_movesView->setMinimumWidth(150);
- tqlayout->addWidget(m_movesView, 3, 1);
+ layout->addWidget(m_movesView, 3, 1);
}
@@ -193,7 +193,7 @@ void QReversiGameView::newGame()
{
m_boardView->updateBoard(true);
m_movesView->clear();
- updatetqStatus();
+ updateStatus();
}
@@ -213,10 +213,10 @@ void QReversiGameView::moveMade(uint moveNum, Move &move)
// Insert the new move in the listbox and mark it as the current one.
m_movesView->insertItem(TQString("%1. %2 %3")
- .tqarg(moveNum)
- .tqarg(Prefs::grayscale() ? colorsWB[move.color()]
+ .arg(moveNum)
+ .arg(Prefs::grayscale() ? colorsWB[move.color()]
: colorsRB[move.color()])
- .tqarg(move.asString()));
+ .arg(move.asString()));
m_movesView->setCurrentItem(moveNum - 1);
m_movesView->ensureCurrentVisible();
@@ -225,7 +225,7 @@ void QReversiGameView::moveMade(uint moveNum, Move &move)
m_boardView->updateBoard();
// Update the score.
- updatetqStatus();
+ updateStatus();
}
@@ -236,16 +236,16 @@ void QReversiGameView::updateView()
{
m_boardView->updateBoard(true);
updateMovelist();
- updatetqStatus();
+ updateStatus();
}
// Only updates the status widgets (score).
-void QReversiGameView::updatetqStatus()
+void QReversiGameView::updateStatus()
{
- m_blacktqStatus->setScore(m_game->score(Black));
- m_whitetqStatus->setScore(m_game->score(White));
+ m_blackStatus->setScore(m_game->score(Black));
+ m_whiteStatus->setScore(m_game->score(White));
}
@@ -285,12 +285,12 @@ void QReversiGameView::setHumanColor(Color color)
m_humanColor = color;
if (color == Black) {
- m_blacktqStatus->setText(i18n("You"));
- m_whitetqStatus->setText("");
+ m_blackStatus->setText(i18n("You"));
+ m_whiteStatus->setText("");
}
else {
- m_blacktqStatus->setText("");
- m_whitetqStatus->setText(i18n("You"));
+ m_blackStatus->setText("");
+ m_whiteStatus->setText(i18n("You"));
}
}