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 25, 2016
1 parent e237963 commit a70d42802f2d25ce20c16fb5d354f278fcd1dbac
Showing with 1 addition and 1 deletion.
  1. +1 −1 src/core/qgsvectorlayer.cpp
@@ -4112,7 +4112,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 a70d428

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