Skip to content
Permalink
Browse files

Fix bug in case of embeding from other projects with relative path

  • Loading branch information
mhugent committed Jun 20, 2011
1 parent fdb41a6 commit 16e872f79fc92e1f1ce05a38c7d74b356d75601a
Showing with 2 additions and 2 deletions.
  1. +2 −2 src/app/legend/qgslegend.cpp
@@ -1055,7 +1055,7 @@ bool QgsLegend::writeXML( QList<QTreeWidgetItem *> items, QDomNode &node, QDomDo
if ( embedIt != mEmbeddedGroups.constEnd() )
{
legendgroupnode.setAttribute( "embedded", 1 );
legendgroupnode.setAttribute( "project", embedIt.value() );
legendgroupnode.setAttribute( "project", QgsProject::instance()->writePath( embedIt.value() ) );
}
else
{
@@ -1174,7 +1174,7 @@ bool QgsLegend::readXML( QgsLegendGroup *parent, const QDomNode &node )
QgsLegendGroup* theGroup = 0;
if ( childelem.attribute( "embedded" ) == "1" )
{
theGroup = addEmbeddedGroup( name, childelem.attribute( "project" ) );
theGroup = addEmbeddedGroup( name, QgsProject::instance()->readPath( childelem.attribute( "project" ) ) );
}
else
{

0 comments on commit 16e872f

Please sign in to comment.
You can’t perform that action at this time.