diff -r 053479bc23c6 -r e3a85616dbc5 mapeditor.cpp --- a/mapeditor.cpp Wed May 06 11:06:17 2009 +0000 +++ b/mapeditor.cpp Wed Jul 22 11:47:03 2009 +0000 @@ -4973,6 +4973,10 @@ copyingObj=false; if (dst ) { + // Don't unscroll if relinked to a scrolled parent, but + // select parent instead + bool selectParent=false; + // We have a destination, relink to that BranchObj* bsel=xelection.getBranch(); @@ -4994,6 +4998,7 @@ bsel->linkTo ( (BranchObj*)(bdst->getParObj()), bdst->getNum()+1); } else { // Append to dst + if (bdst->isScrolled()) selectParent=true; preDstParStr=model->getSelectString(dst); bsel->linkTo (bdst,-1); if (dst->getDepth()==0) bsel->move (savePos); @@ -5014,6 +5019,8 @@ preSelStr, redoCom, QString("Relink %1 to %2").arg(getName(bsel)).arg(getName(dst)) ); + if (selectParent) select (bdst); + model->reposition(); // not necessary if we undo temporary move below } else {