diff options
author | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2011-06-11 04:58:26 +0000 |
---|---|---|
committer | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2011-06-11 04:58:26 +0000 |
commit | 838baf3f99ec5ab81b063eb5449a3381d860f377 (patch) | |
tree | dd31abcfde08ca92e4623b8f50b3d762a87c997a /kolf/ball.cpp | |
parent | 2bf598bafa22fac4126fc8842df6b0119aadc0e9 (diff) | |
download | tdegames-838baf3f99ec5ab81b063eb5449a3381d860f377.tar.gz tdegames-838baf3f99ec5ab81b063eb5449a3381d860f377.zip |
TQt4 port kdegames
This enables compilation under both Qt3 and Qt4
git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdegames@1236074 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'kolf/ball.cpp')
-rw-r--r-- | kolf/ball.cpp | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/kolf/ball.cpp b/kolf/ball.cpp index 9ac849bc..569a5ba2 100644 --- a/kolf/ball.cpp +++ b/kolf/ball.cpp @@ -33,7 +33,7 @@ Ball::Ball(TQCanvas *canvas) //font.setPixelSize(10); label = new TQCanvasText("", font, canvas); label->setColor(white); - label->setVisible(false); + label->tqsetVisible(false); // this sets z setState(Stopped); @@ -249,7 +249,7 @@ void Ball::collisionDetect(double oldx, double oldy) m_collisionLock = true; // move this ball to where it was barely touching double ballAngle = m_vector.direction(); - while (collisions(true).contains(item) > 0) + while (collisions(true).tqcontains(item) > 0) move(x() - cos(ballAngle) / 2.0, y() + sin(ballAngle) / 2.0); // make a 2 pixel separation @@ -308,10 +308,10 @@ void Ball::collisionDetect(double oldx, double oldy) for (iterpoint = points.first(); iterpoint; iterpoint = points.next()) { //kdDebug(12007) << "-----\n"; - const Wall *parentWall = iterpoint->parentWall(); - const TQPoint qp(iterpoint->x() + parentWall->x(), iterpoint->y() + parentWall->y()); + const Wall *tqparentWall = iterpoint->tqparentWall(); + const TQPoint qp(iterpoint->x() + tqparentWall->x(), iterpoint->y() + tqparentWall->y()); const Point p(qp.x(), qp.y()); - const TQPoint qother = TQPoint(parentWall->startPoint() == qp? parentWall->endPoint() : parentWall->startPoint()) + TQPoint(parentWall->x(), parentWall->y()); + const TQPoint qother = TQPoint(tqparentWall->startPoint() == qp? tqparentWall->endPoint() : tqparentWall->startPoint()) + TQPoint(tqparentWall->x(), tqparentWall->y()); const Point other(qother.x(), qother.y()); // vector of wall @@ -438,12 +438,12 @@ BallState Ball::currentState() void Ball::showInfo() { - label->setVisible(isVisible()); + label->tqsetVisible(isVisible()); } void Ball::hideInfo() { - label->setVisible(false); + label->tqsetVisible(false); } void Ball::setName(const TQString &name) @@ -459,8 +459,8 @@ void Ball::setCanvas(TQCanvas *c) void Ball::setVisible(bool yes) { - TQCanvasEllipse::setVisible(yes); + TQCanvasEllipse::tqsetVisible(yes); - label->setVisible(yes && game && game->isInfoShowing()); + label->tqsetVisible(yes && game && game->isInfoShowing()); } |