diff options
author | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2011-06-11 04:44:41 +0000 |
---|---|---|
committer | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2011-06-11 04:44:41 +0000 |
commit | a374efce3a207b39514be3c52264091400ce297e (patch) | |
tree | 77bdf654b55826d4f59b53a5621310206bcaead1 /kgeography/src/mapwidget.cpp | |
parent | f81a494f3957d5cf38c787973415597941934727 (diff) | |
download | tdeedu-a374efce3a207b39514be3c52264091400ce297e.tar.gz tdeedu-a374efce3a207b39514be3c52264091400ce297e.zip |
TQt4 port kdeedu
This enables compilation under both Qt3 and Qt4
git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdeedu@1236073 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'kgeography/src/mapwidget.cpp')
-rw-r--r-- | kgeography/src/mapwidget.cpp | 22 |
1 files changed, 11 insertions, 11 deletions
diff --git a/kgeography/src/mapwidget.cpp b/kgeography/src/mapwidget.cpp index f551940f..2560f11a 100644 --- a/kgeography/src/mapwidget.cpp +++ b/kgeography/src/mapwidget.cpp @@ -19,7 +19,7 @@ #include "mapwidget.h" -mapWidget::mapWidget(TQWidget *parent) : TQWidget(parent) +mapWidget::mapWidget(TQWidget *tqparent) : TQWidget(tqparent) { p_wantZoom = false; p_zooming = false; @@ -61,9 +61,9 @@ void mapWidget::setMapZoom(bool b) } } -TQSize mapWidget::sizeHint() const +TQSize mapWidget::tqsizeHint() const { - return maximumSize(); + return tqmaximumSize(); } void mapWidget::updateHPosition(int value) @@ -91,12 +91,12 @@ void mapWidget::mousePressEvent(TQMouseEvent *e) else if (p_wantMove) { p_initial = e -> pos(); - setCursor(Qt::SizeAllCursor); + setCursor(TQt::SizeAllCursor); p_moving = true; } else { - QRgb rgb; + TQRgb rgb; TQImage *currentImage; currentImage = getCurrentImage(); @@ -121,8 +121,8 @@ void mapWidget::mouseMoveEvent(TQMouseEvent *e) { TQPainter p(this); - p.setRasterOp(Qt::XorROP); - p.setPen(TQPen(Qt::white, 1, Qt::DotLine)); + p.setRasterOp(TQt::XorROP); + p.setPen(TQPen(TQt::white, 1, TQt::DotLine)); // remove previous rectangle p.drawRect(TQRect(p_initial, p_prev)); @@ -176,8 +176,8 @@ void mapWidget::mouseReleaseEvent(TQMouseEvent *e) TQPainter p(this); TQRect r(p_initial, e -> pos()); - p.setRasterOp(Qt::XorROP); - p.setPen(TQPen(Qt::white, 1, Qt::DotLine)); + p.setRasterOp(TQt::XorROP); + p.setPen(TQPen(TQt::white, 1, TQt::DotLine)); // remove previous rectangle p.drawRect(r); @@ -279,7 +279,7 @@ TQImage *mapWidget::getCurrentImage() void mapWidget::setOriginalImage() { - setPaletteBackgroundPixmap(p_originalImage); + setPaletteBackgroundPixmap(TQPixmap(p_originalImage)); erase(); p_zoomedImageShown = TQImage(); p_lastFactorX = 1; @@ -314,7 +314,7 @@ void mapWidget::updateShownImage() { p_zoomedImageShown = p_originalImage.copy(p_zoomX, p_zoomY, p_zoomW, p_zoomH); p_zoomedImageShown = p_zoomedImageShown.scale(size()); - setPaletteBackgroundPixmap(p_zoomedImageShown); + setPaletteBackgroundPixmap(TQPixmap(p_zoomedImageShown)); erase(); p_oldZoomX = p_zoomX; p_oldZoomY = p_zoomY; |