summaryrefslogtreecommitdiff
path: root/src/imports/location/qdeclarativepolylinemapitem.cpp
diff options
context:
space:
mode:
authorLiang Qi <liang.qi@theqtcompany.com>2015-12-01 23:00:31 +0100
committerLiang Qi <liang.qi@theqtcompany.com>2015-12-01 23:00:31 +0100
commit99a1ba7c488939f606628593e7d21e42aa583502 (patch)
tree4ed34a0bc7500a9a429d8009f4777fb7250ab65f /src/imports/location/qdeclarativepolylinemapitem.cpp
parentf87ba0409856a678e8a940b70f7452c3a1b730c3 (diff)
parenteea315187d1add70aaf69745c031b8d6342b2303 (diff)
downloadqtlocation-99a1ba7c488939f606628593e7d21e42aa583502.tar.gz
Merge remote-tracking branch 'origin/5.6' into dev
Conflicts: src/imports/location/qdeclarativegeomap.cpp src/imports/location/qdeclarativegeomap_p.h Change-Id: Iaf232acbe9098eb1b57f571638dd37f75b2ff345
Diffstat (limited to 'src/imports/location/qdeclarativepolylinemapitem.cpp')
-rw-r--r--src/imports/location/qdeclarativepolylinemapitem.cpp17
1 files changed, 8 insertions, 9 deletions
diff --git a/src/imports/location/qdeclarativepolylinemapitem.cpp b/src/imports/location/qdeclarativepolylinemapitem.cpp
index 9201701c..71a205d3 100644
--- a/src/imports/location/qdeclarativepolylinemapitem.cpp
+++ b/src/imports/location/qdeclarativepolylinemapitem.cpp
@@ -472,7 +472,7 @@ void QDeclarativePolylineMapItem::updateAfterLinePropertiesChanged()
{
// mark dirty just in case we're a width change
geometry_.markSourceDirty();
- updateMapItem();
+ polishAndUpdate();
}
/*!
@@ -483,7 +483,7 @@ void QDeclarativePolylineMapItem::setMap(QDeclarativeGeoMap *quickMap, QGeoMap *
QDeclarativeGeoMapItemBase::setMap(quickMap,map);
if (map) {
geometry_.markSourceDirty();
- updateMapItem();
+ polishAndUpdate();
}
}
@@ -546,7 +546,7 @@ void QDeclarativePolylineMapItem::setPathFromGeoList(const QList<QGeoCoordinate>
path_ = path;
geometry_.markSourceDirty();
- updateMapItem();
+ polishAndUpdate();
emit pathChanged();
}
@@ -563,7 +563,7 @@ void QDeclarativePolylineMapItem::addCoordinate(const QGeoCoordinate &coordinate
path_.append(coordinate);
geometry_.markSourceDirty();
- updateMapItem();
+ polishAndUpdate();
emit pathChanged();
}
@@ -586,7 +586,7 @@ void QDeclarativePolylineMapItem::removeCoordinate(const QGeoCoordinate &coordin
path_.removeAt(index);
geometry_.markSourceDirty();
- updateMapItem();
+ polishAndUpdate();
emit pathChanged();
}
@@ -652,7 +652,7 @@ void QDeclarativePolylineMapItem::geometryChanged(const QRectF &newGeometry, con
+ newCoordinate.longitude() - firstLongitude));
geometry_.setPreserveGeometry(true, leftBoundCoord);
geometry_.markSourceDirty();
- updateMapItem();
+ polishAndUpdate();
emit pathChanged();
}
@@ -688,13 +688,13 @@ void QDeclarativePolylineMapItem::afterViewportChanged(const QGeoMapViewportChan
}
geometry_.setPreserveGeometry(true, geometry_.geoLeftBound());
geometry_.markScreenDirty();
- updateMapItem();
+ polishAndUpdate();
}
/*!
\internal
*/
-void QDeclarativePolylineMapItem::updateMapItem()
+void QDeclarativePolylineMapItem::updatePolish()
{
if (!map() || path_.count() == 0)
return;
@@ -709,7 +709,6 @@ void QDeclarativePolylineMapItem::updateMapItem()
setHeight(geometry_.sourceBoundingBox().height());
setPositionOnMap(path_.at(0), -1 * geometry_.sourceBoundingBox().topLeft());
- update();
}
/*!