Skip to content

Commit

Permalink
Misc. tidy up.
Browse files Browse the repository at this point in the history
git-svn-id: http://svn.osgeo.org/qgis/trunk/qgis@5290 c8812cc2-4d05-0410-92ff-de0c093fc19c
  • Loading branch information
g_j_m committed Apr 16, 2006
1 parent 8ca7fd9 commit 5c641d2
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 9 deletions.
8 changes: 4 additions & 4 deletions src/core/qgsrect.cpp
Expand Up @@ -22,8 +22,8 @@
#ifdef WIN32
#include <limits>
#endif
#include <qstring.h>
#include <qtextstream.h>
#include <QString>
#include <QTextStream>

#include "qgspoint.h"
#include "qgsrect.h"
Expand Down Expand Up @@ -86,7 +86,7 @@ void QgsRect::setMinimal()
ymax =-std::numeric_limits<double>::max();
}

void QgsRect::scale(double scaleFactor, QgsPoint * cp)
void QgsRect::scale(double scaleFactor, const QgsPoint * cp)
{
// scale from the center
double centerX, centerY;
Expand All @@ -107,7 +107,7 @@ void QgsRect::scale(double scaleFactor, QgsPoint * cp)
ymax = centerY + newHeight / 2.0;
}

void QgsRect::expand(double scaleFactor, QgsPoint * cp)
void QgsRect::expand(double scaleFactor, const QgsPoint * cp)
{
// scale from the center
double centerX, centerY;
Expand Down
8 changes: 3 additions & 5 deletions src/core/qgsrect.h
Expand Up @@ -21,9 +21,7 @@

#include <iosfwd>

#ifndef QSTRING_H
#include <qstring.h>
#endif
class QString;

#include "qgspoint.h"

Expand Down Expand Up @@ -79,9 +77,9 @@ class QgsRect
//! Center point of the rectangle
QgsPoint center() const;
//! Scale the rectangle around its center point
void scale(double, QgsPoint *c =0);
void scale(double, const QgsPoint *c =0);
//! Expand the rectangle to support zoom out scaling
void expand(double, QgsPoint *c = 0);
void expand(double, const QgsPoint *c = 0);
//! return the intersection with the given rectangle
QgsRect intersect(QgsRect *rect);
//! expand the rectangle so that covers both the original rectangle and the given rectangle
Expand Down

0 comments on commit 5c641d2

Please sign in to comment.