summaryrefslogtreecommitdiff
path: root/src/location/declarativemaps
diff options
context:
space:
mode:
Diffstat (limited to 'src/location/declarativemaps')
-rw-r--r--src/location/declarativemaps/qdeclarativecirclemapitem.cpp8
-rw-r--r--src/location/declarativemaps/qdeclarativegeocodemodel.cpp36
-rw-r--r--src/location/declarativemaps/qdeclarativegeomap.cpp34
-rw-r--r--src/location/declarativemaps/qdeclarativegeomap_p.h2
-rw-r--r--src/location/declarativemaps/qdeclarativegeomapcopyrightsnotice.cpp19
-rw-r--r--src/location/declarativemaps/qdeclarativegeomapcopyrightsnotice_p.h2
-rw-r--r--src/location/declarativemaps/qdeclarativegeomapitembase.cpp7
-rw-r--r--src/location/declarativemaps/qdeclarativegeomapitemview.cpp8
-rw-r--r--src/location/declarativemaps/qdeclarativegeomapquickitem.cpp20
-rw-r--r--src/location/declarativemaps/qdeclarativegeoroutemodel.cpp27
-rw-r--r--src/location/declarativemaps/qdeclarativepolygonmapitem.cpp9
-rw-r--r--src/location/declarativemaps/qdeclarativepolylinemapitem.cpp8
-rw-r--r--src/location/declarativemaps/qdeclarativerectanglemapitem.cpp8
-rw-r--r--src/location/declarativemaps/qdeclarativeroutemapitem.cpp3
14 files changed, 105 insertions, 86 deletions
diff --git a/src/location/declarativemaps/qdeclarativecirclemapitem.cpp b/src/location/declarativemaps/qdeclarativecirclemapitem.cpp
index 92d38a22..328eaae2 100644
--- a/src/location/declarativemaps/qdeclarativecirclemapitem.cpp
+++ b/src/location/declarativemaps/qdeclarativecirclemapitem.cpp
@@ -288,10 +288,10 @@ QDeclarativeCircleMapItem::QDeclarativeCircleMapItem(QQuickItem *parent)
// ToDo: handle envvar, and switch implementation.
m_itemType = QGeoMap::MapCircle;
setFlag(ItemHasContents, true);
- QObject::connect(&m_border, SIGNAL(colorChanged(QColor)),
- this, SLOT(onLinePropertiesChanged()));
- QObject::connect(&m_border, SIGNAL(widthChanged(qreal)),
- this, SLOT(onLinePropertiesChanged()));
+ QObject::connect(&m_border, &QDeclarativeMapLineProperties::colorChanged,
+ this, &QDeclarativeCircleMapItem::onLinePropertiesChanged);
+ QObject::connect(&m_border, &QDeclarativeMapLineProperties::widthChanged,
+ this, &QDeclarativeCircleMapItem::onLinePropertiesChanged);
// assume that circles are not self-intersecting
// to speed up processing
diff --git a/src/location/declarativemaps/qdeclarativegeocodemodel.cpp b/src/location/declarativemaps/qdeclarativegeocodemodel.cpp
index 7f5bd70a..8089ae0f 100644
--- a/src/location/declarativemaps/qdeclarativegeocodemodel.cpp
+++ b/src/location/declarativemaps/qdeclarativegeocodemodel.cpp
@@ -283,8 +283,8 @@ void QDeclarativeGeocodeModel::setPlugin(QDeclarativeGeoServiceProvider *plugin)
if (plugin_->isAttached()) {
pluginReady();
} else {
- connect(plugin_, SIGNAL(attached()),
- this, SLOT(pluginReady()));
+ connect(plugin_, &QDeclarativeGeoServiceProvider::attached,
+ this, &QDeclarativeGeocodeModel::pluginReady);
}
}
@@ -320,10 +320,10 @@ void QDeclarativeGeocodeModel::pluginReady()
return;
}
- connect(geocodingManager, SIGNAL(finished(QGeoCodeReply*)),
- this, SLOT(geocodeFinished(QGeoCodeReply*)));
- connect(geocodingManager, SIGNAL(error(QGeoCodeReply*,QGeoCodeReply::Error,QString)),
- this, SLOT(geocodeError(QGeoCodeReply*,QGeoCodeReply::Error,QString)));
+ connect(geocodingManager, &QGeoCodingManager::finished,
+ this, &QDeclarativeGeocodeModel::geocodeFinished);
+ connect(geocodingManager, &QGeoCodingManager::errorOccurred,
+ this, &QDeclarativeGeocodeModel::geocodeError);
if (complete_ && autoUpdate_)
update();
@@ -682,14 +682,22 @@ void QDeclarativeGeocodeModel::setQuery(const QVariant &query)
searchString_.clear();
address_ = address;
- connect(address_, SIGNAL(countryChanged()), this, SLOT(queryContentChanged()));
- connect(address_, SIGNAL(countryCodeChanged()), this, SLOT(queryContentChanged()));
- connect(address_, SIGNAL(stateChanged()), this, SLOT(queryContentChanged()));
- connect(address_, SIGNAL(countyChanged()), this, SLOT(queryContentChanged()));
- connect(address_, SIGNAL(cityChanged()), this, SLOT(queryContentChanged()));
- connect(address_, SIGNAL(districtChanged()), this, SLOT(queryContentChanged()));
- connect(address_, SIGNAL(streetChanged()), this, SLOT(queryContentChanged()));
- connect(address_, SIGNAL(postalCodeChanged()), this, SLOT(queryContentChanged()));
+ connect(address_, &QDeclarativeGeoAddress::countryChanged,
+ this, &QDeclarativeGeocodeModel::queryContentChanged);
+ connect(address_, &QDeclarativeGeoAddress::countryCodeChanged,
+ this, &QDeclarativeGeocodeModel::queryContentChanged);
+ connect(address_, &QDeclarativeGeoAddress::stateChanged,
+ this, &QDeclarativeGeocodeModel::queryContentChanged);
+ connect(address_, &QDeclarativeGeoAddress::countyChanged,
+ this, &QDeclarativeGeocodeModel::queryContentChanged);
+ connect(address_, &QDeclarativeGeoAddress::cityChanged,
+ this, &QDeclarativeGeocodeModel::queryContentChanged);
+ connect(address_, &QDeclarativeGeoAddress::districtChanged,
+ this, &QDeclarativeGeocodeModel::queryContentChanged);
+ connect(address_, &QDeclarativeGeoAddress::streetChanged,
+ this, &QDeclarativeGeocodeModel::queryContentChanged);
+ connect(address_, &QDeclarativeGeoAddress::postalCodeChanged,
+ this, &QDeclarativeGeocodeModel::queryContentChanged);
} else {
qmlWarning(this) << QStringLiteral("Unsupported query type for geocode model ")
<< QStringLiteral("(coordinate, string and Address supported).");
diff --git a/src/location/declarativemaps/qdeclarativegeomap.cpp b/src/location/declarativemaps/qdeclarativegeomap.cpp
index d3548d49..cdd104e9 100644
--- a/src/location/declarativemaps/qdeclarativegeomap.cpp
+++ b/src/location/declarativemaps/qdeclarativegeomap.cpp
@@ -418,13 +418,16 @@ void QDeclarativeGeoMap::pluginReady()
return;
}
- if (!m_mappingManager->isInitialized())
- connect(m_mappingManager, SIGNAL(initialized()), this, SLOT(mappingManagerInitialized()));
- else
+ if (!m_mappingManager->isInitialized()) {
+ connect(m_mappingManager, &QGeoMappingManager::initialized,
+ this, &QDeclarativeGeoMap::mappingManagerInitialized);
+ } else {
mappingManagerInitialized();
+ }
// make sure this is only called once
- disconnect(this, SLOT(pluginReady()));
+ disconnect(m_plugin, &QDeclarativeGeoServiceProvider::attached,
+ this, &QDeclarativeGeoMap::pluginReady);
}
/*!
@@ -535,8 +538,8 @@ void QDeclarativeGeoMap::setPlugin(QDeclarativeGeoServiceProvider *plugin)
if (m_plugin->isAttached()) {
pluginReady();
} else {
- connect(m_plugin, SIGNAL(attached()),
- this, SLOT(pluginReady()));
+ connect(m_plugin, &QDeclarativeGeoServiceProvider::attached,
+ this, &QDeclarativeGeoMap::pluginReady);
}
}
@@ -686,12 +689,10 @@ void QDeclarativeGeoMap::mappingManagerInitialized()
QImage copyrightImage;
if (!m_initialized && width() > 0 && height() > 0) {
QMetaObject::Connection copyrightStringCatcherConnection =
- connect(m_map.data(),
- QOverload<const QString &>::of(&QGeoMap::copyrightsChanged),
+ connect(m_map.data(), &QGeoMap::copyrightsChanged,
[&copyrightString](const QString &copy){ copyrightString = copy; });
QMetaObject::Connection copyrightImageCatcherConnection =
- connect(m_map.data(),
- QOverload<const QImage &>::of(&QGeoMap::copyrightsChanged),
+ connect(m_map.data(), &QGeoMap::copyrightsImageChanged,
[&copyrightImage](const QImage &copy){ copyrightImage = copy; });
m_map->setViewportSize(QSize(width(), height()));
initialize(); // This emits the caught signals above
@@ -701,14 +702,14 @@ void QDeclarativeGeoMap::mappingManagerInitialized()
/* COPYRIGHT SIGNALS REWIRING */
- connect(m_map.data(), SIGNAL(copyrightsChanged(QImage)),
- this, SIGNAL(copyrightsChanged(QImage)));
- connect(m_map.data(), SIGNAL(copyrightsChanged(QString)),
- this, SIGNAL(copyrightsChanged(QString)));
+ connect(m_map.data(), &QGeoMap::copyrightsImageChanged,
+ this, &QDeclarativeGeoMap::copyrightsImageChanged);
+ connect(m_map.data(), &QGeoMap::copyrightsChanged,
+ this, &QDeclarativeGeoMap::copyrightsChanged);
if (!copyrightString.isEmpty())
emit m_map->copyrightsChanged(copyrightString);
else if (!copyrightImage.isNull())
- emit m_map->copyrightsChanged(copyrightImage);
+ emit m_map->copyrightsImageChanged(copyrightImage);
connect(window(), &QQuickWindow::beforeSynchronizing, this, &QDeclarativeGeoMap::updateItemToWindowTransform, Qt::DirectConnection);
@@ -718,7 +719,8 @@ void QDeclarativeGeoMap::mappingManagerInitialized()
// This prefetches a buffer around the map
m_map->prefetchData();
- connect(m_mappingManager, SIGNAL(supportedMapTypesChanged()), this, SLOT(onSupportedMapTypesChanged()));
+ connect(m_mappingManager, &QGeoMappingManager::supportedMapTypesChanged,
+ this, &QDeclarativeGeoMap::onSupportedMapTypesChanged);
emit minimumZoomLevelChanged();
emit maximumZoomLevelChanged();
emit supportedMapTypesChanged();
diff --git a/src/location/declarativemaps/qdeclarativegeomap_p.h b/src/location/declarativemaps/qdeclarativegeomap_p.h
index 74618c7f..c12671a0 100644
--- a/src/location/declarativemaps/qdeclarativegeomap_p.h
+++ b/src/location/declarativemaps/qdeclarativegeomap_p.h
@@ -233,7 +233,7 @@ Q_SIGNALS:
void maximumTiltChanged(qreal maximumTilt);
void minimumFieldOfViewChanged(qreal minimumFieldOfView);
void maximumFieldOfViewChanged(qreal maximumFieldOfView);
- void copyrightsChanged(const QImage &copyrightsImage);
+ void copyrightsImageChanged(const QImage &copyrightsImage);
void copyrightsChanged(const QString &copyrightsHtml);
void mapReadyChanged(bool ready);
Q_REVISION(11) void mapObjectsChanged();
diff --git a/src/location/declarativemaps/qdeclarativegeomapcopyrightsnotice.cpp b/src/location/declarativemaps/qdeclarativegeomapcopyrightsnotice.cpp
index b66b3b0e..6212614b 100644
--- a/src/location/declarativemaps/qdeclarativegeomapcopyrightsnotice.cpp
+++ b/src/location/declarativemaps/qdeclarativegeomapcopyrightsnotice.cpp
@@ -43,6 +43,7 @@
#include <QtGui/QTextDocument>
#include <QtGui/QAbstractTextDocumentLayout>
#include <QtGui/QPainter>
+#include <QtGui/QImage>
#include <QtQuick/private/qquickanchors_p.h>
#include <QtLocation/private/qdeclarativegeomap_p.h>
#include <QtQuick/private/qquickpainteditem_p.h>
@@ -149,10 +150,10 @@ void QDeclarativeGeoMapCopyrightNotice::setMapSource(QDeclarativeGeoMap *map)
if (m_mapSource->m_copyrights && !m_mapSource->m_copyrights->m_copyrightsImage.isNull())
m_copyrightsImage = m_mapSource->m_copyrights->m_copyrightsImage;
- connect(mapSource(), SIGNAL(copyrightsChanged(QImage)),
- this, SLOT(copyrightsChanged(QImage)));
- connect(mapSource(), SIGNAL(copyrightsChanged(QString)),
- this, SLOT(copyrightsChanged(QString)));
+ connect(mapSource(), &QDeclarativeGeoMap::copyrightsImageChanged,
+ this, &QDeclarativeGeoMapCopyrightNotice::copyrightsImageChanged);
+ connect(mapSource(), &QDeclarativeGeoMap::copyrightsChanged,
+ this, &QDeclarativeGeoMapCopyrightNotice::copyrightsChanged);
if (m_mapSource->m_map)
connectMap();
@@ -163,10 +164,10 @@ void QDeclarativeGeoMapCopyrightNotice::setMapSource(QDeclarativeGeoMap *map)
void QDeclarativeGeoMapCopyrightNotice::connectMap()
{
- connect(m_mapSource->m_map, SIGNAL(copyrightsStyleSheetChanged(QString)),
- this, SLOT(onCopyrightsStyleSheetChanged(QString)));
- connect(this, SIGNAL(linkActivated(QString)),
- mapSource(), SIGNAL(copyrightLinkActivated(QString)));
+ connect(m_mapSource->m_map.data(), &QGeoMap::copyrightsStyleSheetChanged,
+ this, &QDeclarativeGeoMapCopyrightNotice::onCopyrightsStyleSheetChanged);
+ connect(this, &QDeclarativeGeoMapCopyrightNotice::linkActivated,
+ mapSource(), &QDeclarativeGeoMap::copyrightLinkActivated);
onCopyrightsStyleSheetChanged(m_mapSource->m_map->copyrightsStyleSheet());
@@ -308,7 +309,7 @@ void QDeclarativeGeoMapCopyrightNotice::setCopyrightsZ(qreal copyrightsZ)
/*!
\internal
*/
-void QDeclarativeGeoMapCopyrightNotice::copyrightsChanged(const QImage &copyrightsImage)
+void QDeclarativeGeoMapCopyrightNotice::copyrightsImageChanged(const QImage &copyrightsImage)
{
Q_D(QDeclarativeGeoMapCopyrightNotice);
delete m_copyrightsHtml;
diff --git a/src/location/declarativemaps/qdeclarativegeomapcopyrightsnotice_p.h b/src/location/declarativemaps/qdeclarativegeomapcopyrightsnotice_p.h
index fe26ad2b..5127c95f 100644
--- a/src/location/declarativemaps/qdeclarativegeomapcopyrightsnotice_p.h
+++ b/src/location/declarativemaps/qdeclarativegeomapcopyrightsnotice_p.h
@@ -89,7 +89,7 @@ public:
void setStyleSheet(const QString &styleSheet);
public Q_SLOTS:
- void copyrightsChanged(const QImage &copyrightsImage);
+ void copyrightsImageChanged(const QImage &copyrightsImage);
void copyrightsChanged(const QString &copyrightsHtml);
void onCopyrightsStyleSheetChanged(const QString &styleSheet);
diff --git a/src/location/declarativemaps/qdeclarativegeomapitembase.cpp b/src/location/declarativemaps/qdeclarativegeomapitembase.cpp
index 1109fde2..78bcfe90 100644
--- a/src/location/declarativemaps/qdeclarativegeomapitembase.cpp
+++ b/src/location/declarativemaps/qdeclarativegeomapitembase.cpp
@@ -87,8 +87,8 @@ QDeclarativeGeoMapItemBase::QDeclarativeGeoMapItemBase(QQuickItem *parent)
: QQuickItem(parent), map_(0), quickMap_(0), parentGroup_(0)
{
setFiltersChildMouseEvents(true);
- connect(this, SIGNAL(childrenChanged()),
- this, SLOT(afterChildrenChanged()));
+ connect(this, &QDeclarativeGeoMapItemBase::childrenChanged,
+ this, &QDeclarativeGeoMapItemBase::afterChildrenChanged);
// Changing opacity on a mapItemGroup should affect also the opacity on the children.
// This must be notified to plugins, if they are to render the item.
connect(this, &QQuickItem::opacityChanged, this, &QDeclarativeGeoMapItemBase::mapItemOpacityChanged);
@@ -96,7 +96,8 @@ QDeclarativeGeoMapItemBase::QDeclarativeGeoMapItemBase(QQuickItem *parent)
QDeclarativeGeoMapItemBase::~QDeclarativeGeoMapItemBase()
{
- disconnect(this, SLOT(afterChildrenChanged()));
+ disconnect(this, &QDeclarativeGeoMapItemBase::childrenChanged,
+ this, &QDeclarativeGeoMapItemBase::afterChildrenChanged);
if (quickMap_)
quickMap_->removeMapItem(this);
}
diff --git a/src/location/declarativemaps/qdeclarativegeomapitemview.cpp b/src/location/declarativemaps/qdeclarativegeomapitemview.cpp
index 85d7a380..f69a1f08 100644
--- a/src/location/declarativemaps/qdeclarativegeomapitemview.cpp
+++ b/src/location/declarativemaps/qdeclarativegeomapitemview.cpp
@@ -431,8 +431,8 @@ void QDeclarativeGeoMapItemView::transitionItemOut(QQuickItem *o)
group->m_transitionManager.swap(manager);
group->m_transitionManager->m_view = this;
}
- connect(group, SIGNAL(removeTransitionFinished()),
- this, SLOT(exitTransitionFinished()));
+ connect(group, &QDeclarativeGeoMapItemGroup::removeTransitionFinished,
+ this, &QDeclarativeGeoMapItemView::exitTransitionFinished);
group->m_transitionManager->transitionExit();
return;
@@ -444,8 +444,8 @@ void QDeclarativeGeoMapItemView::transitionItemOut(QQuickItem *o)
item->m_transitionManager.swap(manager);
item->m_transitionManager->m_view = this;
}
- connect(item, SIGNAL(removeTransitionFinished()),
- this, SLOT(exitTransitionFinished()) );
+ connect(item, &QDeclarativeGeoMapItemBase::removeTransitionFinished,
+ this, &QDeclarativeGeoMapItemView::exitTransitionFinished);
item->m_transitionManager->transitionExit();
return;
diff --git a/src/location/declarativemaps/qdeclarativegeomapquickitem.cpp b/src/location/declarativemaps/qdeclarativegeomapquickitem.cpp
index 20db04e1..548edbd3 100644
--- a/src/location/declarativemaps/qdeclarativegeomapquickitem.cpp
+++ b/src/location/declarativemaps/qdeclarativegeomapquickitem.cpp
@@ -192,8 +192,8 @@ void QDeclarativeGeoMapQuickItem::setMap(QDeclarativeGeoMap *quickMap, QGeoMap *
{
QDeclarativeGeoMapItemBase::setMap(quickMap,map);
if (map && quickMap) {
- connect(map, SIGNAL(cameraDataChanged(QGeoCameraData)),
- this, SLOT(polishAndUpdate()));
+ connect(map, &QGeoMap::cameraDataChanged,
+ this, &QDeclarativeGeoMapQuickItem::polishAndUpdate);
polishAndUpdate();
}
}
@@ -397,14 +397,14 @@ void QDeclarativeGeoMapQuickItem::updatePolish()
mapAndSourceItemSet_ = true;
sourceItem_.data()->setParentItem(opacityContainer_);
sourceItem_.data()->setTransformOrigin(QQuickItem::TopLeft);
- connect(sourceItem_.data(), SIGNAL(xChanged()),
- this, SLOT(polishAndUpdate()));
- connect(sourceItem_.data(), SIGNAL(yChanged()),
- this, SLOT(polishAndUpdate()));
- connect(sourceItem_.data(), SIGNAL(widthChanged()),
- this, SLOT(polishAndUpdate()));
- connect(sourceItem_.data(), SIGNAL(heightChanged()),
- this, SLOT(polishAndUpdate()));
+ connect(sourceItem_.data(), &QQuickItem::xChanged,
+ this, &QDeclarativeGeoMapQuickItem::polishAndUpdate);
+ connect(sourceItem_.data(), &QQuickItem::yChanged,
+ this, &QDeclarativeGeoMapQuickItem::polishAndUpdate);
+ connect(sourceItem_.data(), &QQuickItem::widthChanged,
+ this, &QDeclarativeGeoMapQuickItem::polishAndUpdate);
+ connect(sourceItem_.data(), &QQuickItem::heightChanged,
+ this, &QDeclarativeGeoMapQuickItem::polishAndUpdate);
}
if (!coordinate_.isValid()) {
diff --git a/src/location/declarativemaps/qdeclarativegeoroutemodel.cpp b/src/location/declarativemaps/qdeclarativegeoroutemodel.cpp
index 6bec322b..e23f7c16 100644
--- a/src/location/declarativemaps/qdeclarativegeoroutemodel.cpp
+++ b/src/location/declarativemaps/qdeclarativegeoroutemodel.cpp
@@ -321,10 +321,14 @@ void QDeclarativeGeoRouteModel::setPlugin(QDeclarativeGeoServiceProvider *plugin
reset(); // reset the model
- if (plugin_)
- disconnect(plugin_, SIGNAL(localesChanged()), this, SIGNAL(measurementSystemChanged()));
- if (plugin)
- connect(plugin, SIGNAL(localesChanged()), this, SIGNAL(measurementSystemChanged()));
+ if (plugin_) {
+ disconnect(plugin_, &QDeclarativeGeoServiceProvider::localesChanged,
+ this, &QDeclarativeGeoRouteModel::measurementSystemChanged);
+ }
+ if (plugin) {
+ connect(plugin, &QDeclarativeGeoServiceProvider::localesChanged,
+ this, &QDeclarativeGeoRouteModel::measurementSystemChanged);
+ }
plugin_ = plugin;
@@ -337,8 +341,8 @@ void QDeclarativeGeoRouteModel::setPlugin(QDeclarativeGeoServiceProvider *plugin
if (plugin_->isAttached()) {
pluginReady();
} else {
- connect(plugin_, SIGNAL(attached()),
- this, SLOT(pluginReady()));
+ connect(plugin_, &QDeclarativeGeoServiceProvider::attached,
+ this, &QDeclarativeGeoRouteModel::pluginReady);
}
}
@@ -374,10 +378,10 @@ void QDeclarativeGeoRouteModel::pluginReady()
return;
}
- connect(routingManager, SIGNAL(finished(QGeoRouteReply*)),
- this, SLOT(routingFinished(QGeoRouteReply*)));
- connect(routingManager, SIGNAL(error(QGeoRouteReply*,QGeoRouteReply::Error,QString)),
- this, SLOT(routingError(QGeoRouteReply*,QGeoRouteReply::Error,QString)));
+ connect(routingManager, &QGeoRoutingManager::finished,
+ this, &QDeclarativeGeoRouteModel::routingFinished);
+ connect(routingManager, &QGeoRoutingManager::errorOccurred,
+ this, &QDeclarativeGeoRouteModel::routingError);
}
/*!
@@ -417,7 +421,8 @@ void QDeclarativeGeoRouteModel::setQuery(QDeclarativeGeoRouteQuery *query)
if (routeQuery_)
routeQuery_->disconnect(this);
routeQuery_ = query;
- connect(query, SIGNAL(queryDetailsChanged()), this, SLOT(queryDetailsChanged()));
+ connect(query, &QDeclarativeGeoRouteQuery::queryDetailsChanged,
+ this, &QDeclarativeGeoRouteModel::queryDetailsChanged);
if (complete_) {
emit queryChanged();
if (autoUpdate_)
diff --git a/src/location/declarativemaps/qdeclarativepolygonmapitem.cpp b/src/location/declarativemaps/qdeclarativepolygonmapitem.cpp
index 1a09a518..56ee7895 100644
--- a/src/location/declarativemaps/qdeclarativepolygonmapitem.cpp
+++ b/src/location/declarativemaps/qdeclarativepolygonmapitem.cpp
@@ -627,10 +627,11 @@ QDeclarativePolygonMapItem::QDeclarativePolygonMapItem(QQuickItem *parent)
m_itemType = QGeoMap::MapPolygon;
m_geopoly = QGeoPolygonEager();
setFlag(ItemHasContents, true);
- QObject::connect(&m_border, SIGNAL(colorChanged(QColor)),
- this, SLOT(onLinePropertiesChanged())); // ToDo: fix this, only flag material?
- QObject::connect(&m_border, SIGNAL(widthChanged(qreal)),
- this, SLOT(onLinePropertiesChanged()));
+ // ToDo: fix this, only flag material?
+ QObject::connect(&m_border, &QDeclarativeMapLineProperties::colorChanged,
+ this, &QDeclarativePolygonMapItem::onLinePropertiesChanged);
+ QObject::connect(&m_border, &QDeclarativeMapLineProperties::widthChanged,
+ this, &QDeclarativePolygonMapItem::onLinePropertiesChanged);
setBackend(mapPolygonBackendSelector->backend);
}
diff --git a/src/location/declarativemaps/qdeclarativepolylinemapitem.cpp b/src/location/declarativemaps/qdeclarativepolylinemapitem.cpp
index 649a9ef4..a7a3c21c 100644
--- a/src/location/declarativemaps/qdeclarativepolylinemapitem.cpp
+++ b/src/location/declarativemaps/qdeclarativepolylinemapitem.cpp
@@ -936,10 +936,10 @@ QDeclarativePolylineMapItem::QDeclarativePolylineMapItem(QQuickItem *parent)
m_itemType = QGeoMap::MapPolyline;
m_geopath = QGeoPathEager();
setFlag(ItemHasContents, true);
- QObject::connect(&m_line, SIGNAL(colorChanged(QColor)),
- this, SLOT(updateAfterLinePropertiesChanged()));
- QObject::connect(&m_line, SIGNAL(widthChanged(qreal)),
- this, SLOT(updateAfterLinePropertiesChanged()));
+ QObject::connect(&m_line, &QDeclarativeMapLineProperties::colorChanged,
+ this, &QDeclarativePolylineMapItem::updateAfterLinePropertiesChanged);
+ QObject::connect(&m_line, &QDeclarativeMapLineProperties::widthChanged,
+ this, &QDeclarativePolylineMapItem::updateAfterLinePropertiesChanged);
setBackend(mapPolylineBackendSelector->backend);
}
diff --git a/src/location/declarativemaps/qdeclarativerectanglemapitem.cpp b/src/location/declarativemaps/qdeclarativerectanglemapitem.cpp
index d4e5ce38..5594ef22 100644
--- a/src/location/declarativemaps/qdeclarativerectanglemapitem.cpp
+++ b/src/location/declarativemaps/qdeclarativerectanglemapitem.cpp
@@ -150,10 +150,10 @@ QDeclarativeRectangleMapItem::QDeclarativeRectangleMapItem(QQuickItem *parent)
// ToDo: handle envvar, and switch implementation.
m_itemType = QGeoMap::MapRectangle;
setFlag(ItemHasContents, true);
- QObject::connect(&m_border, SIGNAL(colorChanged(QColor)),
- this, SLOT(onLinePropertiesChanged()));
- QObject::connect(&m_border, SIGNAL(widthChanged(qreal)),
- this, SLOT(onLinePropertiesChanged()));
+ QObject::connect(&m_border, &QDeclarativeMapLineProperties::colorChanged,
+ this, &QDeclarativeRectangleMapItem::onLinePropertiesChanged);
+ QObject::connect(&m_border, &QDeclarativeMapLineProperties::widthChanged,
+ this, &QDeclarativeRectangleMapItem::onLinePropertiesChanged);
setBackend(mapRectangleBackendSelector->backend);
}
diff --git a/src/location/declarativemaps/qdeclarativeroutemapitem.cpp b/src/location/declarativemaps/qdeclarativeroutemapitem.cpp
index 7c7db5d3..a5e90db5 100644
--- a/src/location/declarativemaps/qdeclarativeroutemapitem.cpp
+++ b/src/location/declarativemaps/qdeclarativeroutemapitem.cpp
@@ -123,7 +123,8 @@ void QDeclarativeRouteMapItem::setRoute(QDeclarativeGeoRoute *route)
route_ = route;
- connect(route_, SIGNAL(pathChanged()), this, SLOT(updateRoutePath()));
+ connect(route_, &QDeclarativeGeoRoute::pathChanged,
+ this, &QDeclarativeRouteMapItem::updateRoutePath);
if (route_)
setPathFromGeoList(route_->routePath());