Skip to content
Permalink
Browse files
Better behavior of drop onto a group
  • Loading branch information
wonder-sk committed May 21, 2014
1 parent bc49cd4 commit 97642ddd43154de7e4a73545fa00b5a6b768e8e5
Showing with 3 additions and 0 deletions.
  1. +3 −0 src/gui/layertree/qgslayertreemodel.cpp
@@ -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;

0 comments on commit 97642dd

Please sign in to comment.