summaryrefslogtreecommitdiffstats
path: root/examples/tetrix/qtetrixb.cpp
diff options
context:
space:
mode:
authorMichele Calgaro <michele.calgaro@yahoo.it>2025-07-01 22:09:14 +0900
committerMichele Calgaro <michele.calgaro@yahoo.it>2025-07-08 08:53:47 +0900
commitc03a4800879ab62692e017e01c825ba12a421ad0 (patch)
tree57aeff4300eb9fa64d193569f56b2d98305b49a2 /examples/tetrix/qtetrixb.cpp
parent030b165ac197ce4c2eb62c7700dc4c10604637aa (diff)
downloadtqt-c03a4800879ab62692e017e01c825ba12a421ad0.tar.gz
tqt-c03a4800879ab62692e017e01c825ba12a421ad0.zip
Replace TRUE/FALSE with boolean values true/false - part 2
Signed-off-by: Michele Calgaro <michele.calgaro@yahoo.it>
Diffstat (limited to 'examples/tetrix/qtetrixb.cpp')
-rw-r--r--examples/tetrix/qtetrixb.cpp18
1 files changed, 9 insertions, 9 deletions
diff --git a/examples/tetrix/qtetrixb.cpp b/examples/tetrix/qtetrixb.cpp
index a0e33b249..14d53ce89 100644
--- a/examples/tetrix/qtetrixb.cpp
+++ b/examples/tetrix/qtetrixb.cpp
@@ -35,9 +35,9 @@ TQTetrixBoard::TQTetrixBoard( TQWidget *p, const char *name )
blockWidth = 20;
yOffset = 30;
blockHeight = 20;
- noGame = TRUE;
- isPaused = FALSE;
- waitingAfterLine = FALSE;
+ noGame = true;
+ isPaused = false;
+ waitingAfterLine = false;
updateTimeoutTime(); // Sets timeoutTime
}
@@ -45,7 +45,7 @@ void TQTetrixBoard::startGame(int gameType,int fillRandomLines)
{
if ( isPaused )
return; // ignore if game is paused
- noGame = FALSE;
+ noGame = false;
GenericTetrix::startGame( gameType, fillRandomLines );
// Note that the timer is started by updateLevel!
}
@@ -92,7 +92,7 @@ void TQTetrixBoard::drawSquare(int x,int y,int value)
tc = colors[value-1].light();
bc = colors[value-1].dark();
p->drawShadePanel( X, Y, blockWidth, blockHeight,
- tc, bc, 1, colors[value-1], TRUE );
+ tc, bc, 1, colors[value-1], true );
}
else
p->fillRect( X, Y, blockWidth, blockHeight, backgroundColor() );
@@ -114,7 +114,7 @@ void TQTetrixBoard::updateRemoved( int noOfLines )
if ( noOfLines > 0 ) {
timer->stop();
timer->start( waitAfterLineTime );
- waitingAfterLine = TRUE;
+ waitingAfterLine = true;
}
emit updateRemovedSignal( noOfLines );
}
@@ -142,7 +142,7 @@ void TQTetrixBoard::pieceDropped(int)
void TQTetrixBoard::gameOver()
{
timer->stop();
- noGame = TRUE;
+ noGame = true;
emit gameOverSignal();
}
@@ -150,7 +150,7 @@ void TQTetrixBoard::timeout()
{
if ( waitingAfterLine ) {
timer->stop();
- waitingAfterLine = FALSE;
+ waitingAfterLine = false;
newPiece();
timer->start( timeoutTime );
} else {
@@ -192,7 +192,7 @@ void TQTetrixBoard::drawContents( TQPainter *p )
if (y2 >= boardHeight())
y2 = boardHeight() - 1;
- updateBoard( x1, y1, x2, y2, TRUE );
+ updateBoard( x1, y1, x2, y2, true );
paint = 0; // reset widget painter
return;
}