Skip to content

Commit

Permalink
Another object cast
Browse files Browse the repository at this point in the history
  • Loading branch information
elpaso committed May 24, 2022
1 parent dc9864d commit cfa49c2
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/app/qgisapp.cpp
Original file line number Diff line number Diff line change
@@ -5737,7 +5737,7 @@ QList< QgsMapLayer * > QgisApp::addSublayers( const QList<QgsProviderSublayerDet
{
const QList<QgsLayerTreeNode *> currentNodeSiblings { currentNode->parent()->children() };
int nodeIdx { 0 };
for ( const QgsLayerTreeNode* child : std::as_const( currentNodeSiblings ) )
for ( const QgsLayerTreeNode *child : std::as_const( currentNodeSiblings ) )
{
nodeIdx++;
if ( child == currentNode )
@@ -5746,7 +5746,7 @@ QList< QgsMapLayer * > QgisApp::addSublayers( const QList<QgsProviderSublayerDet
break;
}
}
group = static_cast<QgsLayerTreeGroup *>( currentNode->parent() )->insertGroup( index, groupName );
group = qobject_cast<QgsLayerTreeGroup *>( currentNode->parent() )->insertGroup( index, groupName );
}
else
{

0 comments on commit cfa49c2

Please sign in to comment.