Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Better behavior of drop onto a group
  • Loading branch information
wonder-sk committed May 21, 2014
1 parent bc49cd4 commit 97642dd
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/gui/layertree/qgslayertreemodel.cpp
Expand Up @@ -645,6 +645,9 @@ bool QgsLayerTreeModel::dropMimeData(const QMimeData* data, Qt::DropAction actio
if (nodes.count() == 0)
return false;

if (parent.isValid() && row == -1)
row = 0; // if dropped directly onto group item, insert at first position

QgsLayerTree::toGroup(nodeParent)->insertChildNodes(row, nodes);

return true;
Expand Down

0 comments on commit 97642dd

Please sign in to comment.