summaryrefslogtreecommitdiff
path: root/src/location/declarativemaps/qdeclarativegeomapquickitem.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/location/declarativemaps/qdeclarativegeomapquickitem.cpp')
-rw-r--r--src/location/declarativemaps/qdeclarativegeomapquickitem.cpp9
1 files changed, 8 insertions, 1 deletions
diff --git a/src/location/declarativemaps/qdeclarativegeomapquickitem.cpp b/src/location/declarativemaps/qdeclarativegeomapquickitem.cpp
index 86d67cf8..7c0764aa 100644
--- a/src/location/declarativemaps/qdeclarativegeomapquickitem.cpp
+++ b/src/location/declarativemaps/qdeclarativegeomapquickitem.cpp
@@ -159,7 +159,7 @@ QDeclarativeGeoMapQuickItem::~QDeclarativeGeoMapQuickItem() {}
*/
void QDeclarativeGeoMapQuickItem::setCoordinate(const QGeoCoordinate &coordinate)
{
- if (coordinate_ == coordinate || !coordinate.isValid())
+ if (coordinate_ == coordinate)
return;
coordinate_ = coordinate;
@@ -378,6 +378,13 @@ void QDeclarativeGeoMapQuickItem::updatePolish()
this, SLOT(polishAndUpdate()));
}
+ if (!coordinate_.isValid()) {
+ opacityContainer_->setVisible(false);
+ return;
+ } else {
+ opacityContainer_->setVisible(true);
+ }
+
QScopedValueRollback<bool> rollback(updatingGeometry_);
updatingGeometry_ = true;