Skip to content
Permalink
Browse files

Merge pull request #3440 from nirvn/qt5_fix_freeze

Remove composer window visibiliy state restoration upon project load (fixes #15495)
  • Loading branch information
nyalldawson committed Aug 31, 2016
2 parents d5377db + 08f5ae6 commit 7a8ab407173e82f03deb5ba6c237e7a819b0d521
Showing with 0 additions and 14 deletions.
  1. +0 −9 src/app/composer/qgscomposer.cpp
  2. +0 −5 src/app/qgisapp.cpp
@@ -3479,15 +3479,6 @@ void QgsComposer::writeXml( QDomNode& parentNode, QDomDocument& doc )
}
mMapsToRestore.clear();

//store if composer is open or closed
if ( isVisible() )
{
composerElem.setAttribute( "visible", 1 );
}
else
{
composerElem.setAttribute( "visible", 0 );
}
parentNode.appendChild( composerElem );

//store composition
@@ -6606,18 +6606,13 @@ bool QgisApp::loadComposersFromProject( const QDomDocument& doc )
mPrintComposersMenu->addAction( composer->windowAction() );
#ifndef Q_OS_MACX
composer->setWindowState( Qt::WindowMinimized );
composer->show();
#endif
composer->zoomFull();
QgsComposerView* composerView = composer->view();
if ( composerView )
{
composerView->updateRulers();
}
if ( composerNodes.at( i ).toElement().attribute( "visible", "1" ).toInt() < 1 )
{
composer->close();
}
emit composerAdded( composer->view() );
connect( composer, SIGNAL( composerAdded( QgsComposerView* ) ), this, SIGNAL( composerAdded( QgsComposerView* ) ) );
connect( composer, SIGNAL( composerWillBeRemoved( QgsComposerView* ) ), this, SIGNAL( composerWillBeRemoved( QgsComposerView* ) ) );

0 comments on commit 7a8ab40

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