Skip to content

Commit e85740c

Browse files
andreasneumannnyalldawson
authored andcommittedMay 7, 2018
Fixes Centos7 issues due to old gcc compiler (gcc 4.8.5)
1 parent 52b9b9c commit e85740c

File tree

6 files changed

+15
-15
lines changed

6 files changed

+15
-15
lines changed
 

‎src/core/layertree/qgslayertreelayer.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -69,8 +69,8 @@ void QgsLayerTreeLayer::attachToLayer()
6969
if ( !mRef )
7070
return;
7171

72-
connect( mRef.layer, &QgsMapLayer::nameChanged, this, &QgsLayerTreeLayer::layerNameChanged );
73-
connect( mRef.layer, &QgsMapLayer::willBeDeleted, this, &QgsLayerTreeLayer::layerWillBeDeleted );
72+
connect( mRef.layer.data(), &QgsMapLayer::nameChanged, this, &QgsLayerTreeLayer::layerNameChanged );
73+
connect( mRef.layer.data(), &QgsMapLayer::willBeDeleted, this, &QgsLayerTreeLayer::layerWillBeDeleted );
7474
}
7575

7676

‎src/core/layout/qgslayoutitemmap.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1367,7 +1367,7 @@ void QgsLayoutItemMap::connectUpdateSlot()
13671367
} );
13681368

13691369
}
1370-
connect( mLayout, &QgsLayout::refreshed, this, &QgsLayoutItemMap::invalidateCache );
1370+
connect( mLayout.data(), &QgsLayout::refreshed, this, &QgsLayoutItemMap::invalidateCache );
13711371

13721372
connect( project->mapThemeCollection(), &QgsMapThemeCollection::mapThemeChanged, this, &QgsLayoutItemMap::mapThemeChanged );
13731373
}

‎src/core/layout/qgslayoutitemmapoverview.cpp

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -217,8 +217,8 @@ void QgsLayoutItemMapOverview::setLinkedMap( QgsLayoutItemMap *map )
217217
//disconnect old map
218218
if ( mFrameMap )
219219
{
220-
disconnect( mFrameMap, &QgsLayoutItemMap::extentChanged, this, &QgsLayoutItemMapOverview::overviewExtentChanged );
221-
disconnect( mFrameMap, &QgsLayoutItemMap::mapRotationChanged, this, &QgsLayoutItemMapOverview::overviewExtentChanged );
220+
disconnect( mFrameMap.data(), &QgsLayoutItemMap::extentChanged, this, &QgsLayoutItemMapOverview::overviewExtentChanged );
221+
disconnect( mFrameMap.data(), &QgsLayoutItemMap::mapRotationChanged, this, &QgsLayoutItemMapOverview::overviewExtentChanged );
222222
}
223223
mFrameMap = map;
224224
//connect to new map signals
@@ -240,8 +240,8 @@ void QgsLayoutItemMapOverview::connectSignals()
240240

241241
if ( mFrameMap )
242242
{
243-
connect( mFrameMap, &QgsLayoutItemMap::extentChanged, this, &QgsLayoutItemMapOverview::overviewExtentChanged );
244-
connect( mFrameMap, &QgsLayoutItemMap::mapRotationChanged, this, &QgsLayoutItemMapOverview::overviewExtentChanged );
243+
connect( mFrameMap.data(), &QgsLayoutItemMap::extentChanged, this, &QgsLayoutItemMapOverview::overviewExtentChanged );
244+
connect( mFrameMap.data(), &QgsLayoutItemMap::mapRotationChanged, this, &QgsLayoutItemMapOverview::overviewExtentChanged );
245245
}
246246
}
247247

‎src/core/layout/qgslayoutitempicture.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -839,12 +839,12 @@ void QgsLayoutItemPicture::finalizeRestoreFromXml()
839839
{
840840
if ( mRotationMap )
841841
{
842-
disconnectMap( mRotationMap );
842+
disconnectMap( mRotationMap.data() );
843843
}
844844
if ( ( mRotationMap = qobject_cast< QgsLayoutItemMap * >( mLayout->itemByUuid( mRotationMapUuid, true ) ) ) )
845845
{
846-
connect( mRotationMap, &QgsLayoutItemMap::mapRotationChanged, this, &QgsLayoutItemPicture::updateMapRotation );
847-
connect( mRotationMap, &QgsLayoutItemMap::extentChanged, this, &QgsLayoutItemPicture::updateMapRotation );
846+
connect( mRotationMap.data(), &QgsLayoutItemMap::mapRotationChanged, this, &QgsLayoutItemPicture::updateMapRotation );
847+
connect( mRotationMap.data(), &QgsLayoutItemMap::extentChanged, this, &QgsLayoutItemPicture::updateMapRotation );
848848
}
849849
}
850850

‎src/core/layout/qgslayoutobject.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -93,7 +93,7 @@ QgsLayoutObject::QgsLayoutObject( QgsLayout *layout )
9393

9494
if ( mLayout )
9595
{
96-
connect( mLayout, &QgsLayout::refreshed, this, &QgsLayoutObject::refresh );
96+
connect( mLayout.data(), &QgsLayout::refreshed, this, &QgsLayoutObject::refresh );
9797
connect( &mLayout->reportContext(), &QgsLayoutReportContext::changed, this, &QgsLayoutObject::refresh );
9898
}
9999
}

‎tests/src/core/testqgstaskmanager.cpp

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -537,8 +537,8 @@ void TestQgsTaskManager::subTask()
537537
}
538538

539539
QSignalSpy parentTerminated( parent, &QgsTask::taskTerminated );
540-
QSignalSpy subTerminated( subTask, &QgsTask::taskTerminated );
541-
QSignalSpy subsubTerminated( subsubTask, &QgsTask::taskTerminated );
540+
QSignalSpy subTerminated( subTask.data(), &QgsTask::taskTerminated );
541+
QSignalSpy subsubTerminated( subsubTask.data(), &QgsTask::taskTerminated );
542542

543543
subsubTask->terminate();
544544
while ( subsubTask->status() == QgsTask::Running
@@ -577,8 +577,8 @@ void TestQgsTaskManager::subTask()
577577
QCOMPARE( ( int )subTask->status(), ( int )QgsTask::Running );
578578

579579
QSignalSpy parentFinished( parent, &QgsTask::taskCompleted );
580-
QSignalSpy subFinished( subTask, &QgsTask::taskCompleted );
581-
QSignalSpy subsubFinished( subsubTask, &QgsTask::taskCompleted );
580+
QSignalSpy subFinished( subTask.data(), &QgsTask::taskCompleted );
581+
QSignalSpy subsubFinished( subsubTask.data(), &QgsTask::taskCompleted );
582582

583583
subsubTask->finish();
584584
while ( subsubTask->status() == QgsTask::Running

0 commit comments

Comments
 (0)
Please sign in to comment.