From 95f8804ecaed79792a57b1fe3580266bfbbf7590 Mon Sep 17 00:00:00 2001 From: Paolo Angelelli Date: Fri, 18 Nov 2016 19:02:36 +0100 Subject: Renaming QGeoMapPrivate::changeMapSize to changeViewportSize The current name of this method generate confusion, as what it does is changing the size of the final element in the application, and not the actual map size. This patch renames this method to changeDisplaySize It also renames QGeoMap::setSize to setViewportSize, as well as ::size to viewportSize , width to viewportWidth and height to viewportHeight, to make everything consistent and self-explanatory. Finally it also renames minimumZoomAtMapSize to minimumZoomAtViewportSize. Change-Id: I7c1ca8bb3ca3d6f6b0fe6fc881b9300db7110527 Reviewed-by: Alex Blasche --- src/location/maps/qgeomap.cpp | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) (limited to 'src/location/maps/qgeomap.cpp') diff --git a/src/location/maps/qgeomap.cpp b/src/location/maps/qgeomap.cpp index c3b01a3e..0e0a2007 100644 --- a/src/location/maps/qgeomap.cpp +++ b/src/location/maps/qgeomap.cpp @@ -51,31 +51,31 @@ QGeoMap::~QGeoMap() { } -void QGeoMap::setSize(const QSize& size) +void QGeoMap::setViewportSize(const QSize& size) { Q_D(QGeoMap); - if (size == d->m_size) + if (size == d->m_viewportSize) return; - d->m_size = size; - d->changeMapSize(size); + d->m_viewportSize = size; + d->changeViewportSize(size); } -QSize QGeoMap::size() const +QSize QGeoMap::viewportSize() const { Q_D(const QGeoMap); - return d->m_size; + return d->m_viewportSize; } -int QGeoMap::width() const +int QGeoMap::viewportWidth() const { Q_D(const QGeoMap); - return d->m_size.width(); + return d->m_viewportSize.width(); } -int QGeoMap::height() const +int QGeoMap::viewportHeight() const { Q_D(const QGeoMap); - return d->m_size.height(); + return d->m_viewportSize.height(); } void QGeoMap::setCameraData(const QGeoCameraData &cameraData) -- cgit v1.2.3