Skip to content
Permalink
Browse files

Ensure progress dialogue shows for WFS GML requests - especially in t…

…he case that the geometry type is not determined from the server describe feature type request and we need to inspect the featuretype first feature
  • Loading branch information
palmerj committed Jul 14, 2013
1 parent 0210b72 commit 738b7e3cdbcfb7e84a4427f222d2ccbfe500439e
Showing with 10 additions and 1 deletion.
  1. +10 −1 src/core/qgsgml.cpp
@@ -85,7 +85,16 @@ int QgsGml::getFeatures( const QString& uri, QGis::WkbType* wkbType, QgsRectangl

//find out if there is a QGIS main window. If yes, display a progress dialog
QProgressDialog* progressDialog = 0;
QWidget* mainWindow = qApp->activeWindow();
QWidget* mainWindow = 0;
QWidgetList topLevelWidgets = qApp->topLevelWidgets();
for ( QWidgetList::iterator it = topLevelWidgets.begin(); it != topLevelWidgets.end(); ++it )
{
if (( *it )->objectName() == "QgisApp" )
{
mainWindow = *it;
break;
}
}
if ( mainWindow )
{
progressDialog = new QProgressDialog( tr( "Loading GML data\n%1" ).arg( mTypeName ), tr( "Abort" ), 0, 0, mainWindow );

0 comments on commit 738b7e3

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