Skip to content
Permalink
Browse files

QgsVectorLayer::loadNamedStyle(): make it work with non database URI

Such as OGR GPKG
  • Loading branch information
rouault committed Oct 26, 2016
1 parent 5d7f8e9 commit 77ed6caa442448825d99e0953de8ae3448714c2a
Showing with 1 addition and 1 deletion.
  1. +1 −1 src/core/qgsvectorlayer.cpp
@@ -4394,7 +4394,7 @@ QString QgsVectorLayer::loadNamedStyle( const QString &theURI, bool &theResultFl
QString QgsVectorLayer::loadNamedStyle( const QString &theURI, bool &theResultFlag, bool loadFromLocalDB )
{
QgsDataSourceURI dsUri( theURI );
if ( !loadFromLocalDB && !dsUri.database().isEmpty() )
if ( !loadFromLocalDB && mDataProvider && mDataProvider->isSaveAndLoadStyleToDBSupported() )
{
QgsProviderRegistry * pReg = QgsProviderRegistry::instance();
QLibrary *myLib = pReg->providerLibrary( mProviderKey );

0 comments on commit 77ed6ca

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