Skip to content
Browse files

Parse capabilities immediately

... even when the request is sent in a different thread.
  • Loading branch information
m-kuhn committed Jun 14, 2018
1 parent bdcd876 commit 666a0e99b4846d2899fc3330e295db80dab25a91
Showing with 5 additions and 1 deletion.
  1. +5 −1 src/providers/wfs/qgswfscapabilities.cpp
@@ -30,7 +30,11 @@
QgsWfsCapabilities::QgsWfsCapabilities( const QString &uri )
: QgsWfsRequest( QgsWFSDataSourceURI( uri ) )
connect( this, &QgsWfsRequest::downloadFinished, this, &QgsWfsCapabilities::capabilitiesReplyFinished );
// Using Qt::DirectConnection since the download might be running on a different thread.
// In this case, the request was sent from the main thread and is executed with the main
// thread being blocked in future.waitForFinished() so we can run code on this object which
// lives in the main thread without risking havoc.
connect( this, &QgsWfsRequest::downloadFinished, this, &QgsWfsCapabilities::capabilitiesReplyFinished, Qt::DirectConnection );

bool QgsWfsCapabilities::requestCapabilities( bool synchronous, bool forceRefresh )

0 comments on commit 666a0e9

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