Skip to content
Permalink
Browse files
Remove Mac conditional code. As of Qt 4.1.3, Q3CanvasView is behaving…
… the same on both Mac and X11.

git-svn-id: http://svn.osgeo.org/qgis/trunk/qgis@5508 c8812cc2-4d05-0410-92ff-de0c093fc19c
  • Loading branch information
telwertowski committed Jun 7, 2006
1 parent d890c35 commit 456c27a383d37759189c77ac67c500cb521becad
Showing with 0 additions and 23 deletions.
  1. +0 −18 src/gui/qgsmapcanvas.cpp
  2. +0 −5 src/gui/qgsmapcanvas.h
@@ -260,26 +260,9 @@ QgsMapLayer* QgsMapCanvas::currentLayer()
void QgsMapCanvas::refresh()
{
clear();
#ifdef Q_WS_MACX
if (mDirty)
{
render();
}
#endif

updateContents();
} // refresh

#ifdef Q_WS_MACX
void QgsMapCanvas::paintEvent(QPaintEvent * ev)
{
int cx, cy, cw, ch;
ev->rect().getRect(&cx, &cy, &cw, &ch);
QPainter p(this);
drawContents(&p, cx, cy, cw, ch);
}
#else

void QgsMapCanvas::drawContents(QPainter * p, int cx, int cy, int cw, int ch)
{
#ifdef QGISDEBUG
@@ -298,7 +281,6 @@ void QgsMapCanvas::drawContents(QPainter * p, int cx, int cy, int cw, int ch)

Q3CanvasView::drawContents(p, cx, cy, cw, ch);
}
#endif

void QgsMapCanvas::render()
{
@@ -326,13 +326,8 @@ class QgsMapCanvas : public Q3CanvasView
//! Overridden resize event
void resizeEvent(QResizeEvent * e);

#ifdef Q_WS_MACX
//! Overridden paint event
void paintEvent(QPaintEvent * ev);
#else
//! Overridden draw contents from canvas view
void drawContents(QPainter * p, int cx, int cy, int cw, int ch);
#endif

//! Zooms to a given center and scale
void zoomByScale(int x, int y, double scaleFactor);

0 comments on commit 456c27a

Please sign in to comment.