From ef25c584eeec04372a83d6366ee97ee281a84ced Mon Sep 17 00:00:00 2001 From: Nyall Dawson Date: Sat, 20 May 2023 11:49:48 +1000 Subject: [PATCH] Don't try to create database connections for dxf files in browser This is very slow to do, and can grind the browser to a halt for folders with many dxf files --- src/core/browser/qgsfilebaseddataitemprovider.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/core/browser/qgsfilebaseddataitemprovider.cpp b/src/core/browser/qgsfilebaseddataitemprovider.cpp index c09048b2c3ca..fbe7356d4650 100644 --- a/src/core/browser/qgsfilebaseddataitemprovider.cpp +++ b/src/core/browser/qgsfilebaseddataitemprovider.cpp @@ -370,7 +370,8 @@ QgsAbstractDatabaseProviderConnection *QgsFileDataCollectionItem::databaseConnec } const QString driverName = GDALGetDriverShortName( hDriver ); - if ( driverName == QLatin1String( "PDF" ) ) + if ( driverName == QLatin1String( "PDF" ) + || driverName == QLatin1String( "DXF" ) ) { // unwanted drivers -- it's slow to create connections for these, and we don't really want // to expose database capabilities for them (even though they kind of are database formats)