Skip to content
Permalink
Browse files

Revert redundant changes to ows provider

  • Loading branch information
nyalldawson committed Sep 6, 2017
1 parent b657c1a commit 5f82705c55d106e2d71b825074cff6f183ae4f50
Showing with 13 additions and 23 deletions.
  1. +0 −1 src/providers/ows/CMakeLists.txt
  2. +13 −8 src/providers/ows/qgsowsdataitems.cpp
  3. +0 −14 src/providers/ows/qgsowsdataitems.h
@@ -30,7 +30,6 @@ ADD_LIBRARY (owsprovider MODULE ${OWS_SRCS} ${OWS_MOC_SRCS})

TARGET_LINK_LIBRARIES (owsprovider
qgis_core
qgis_gui
)

IF (WITH_GUI)
@@ -259,21 +259,26 @@ void QgsOWSRootItem::newConnection()
static QStringList extensions = QStringList();
static QStringList wildcards = QStringList();

QGISEXTERN QList<QgsDataItemProvider *> *dataItemProviders()
QGISEXTERN int dataCapabilities()
{
QList<QgsDataItemProvider *> *providers = new QList<QgsDataItemProvider *>();

*providers
<< new QgsOwsDataItemProvider;

return providers;
return QgsDataProvider::Net;
}

QgsDataItem *QgsOwsDataItemProvider::createDataItem( const QString &path, QgsDataItem *parentItem )
QGISEXTERN QgsDataItem *dataItem( QString path, QgsDataItem *parentItem )
{
if ( path.isEmpty() )
{
return new QgsOWSRootItem( parentItem, QStringLiteral( "OWS" ), QStringLiteral( "ows:" ) );
}
return nullptr;
}

//QGISEXTERN QgsOWSSourceSelect * selectWidget( QWidget * parent, Qt::WindowFlags fl )
QGISEXTERN QDialog *selectWidget( QWidget *parent, Qt::WindowFlags fl, QgsProviderRegistry::WidgetMode widgetMode )
{
Q_UNUSED( parent );
Q_UNUSED( fl );
Q_UNUSED( widgetMode );
//return new QgsOWSSourceSelect( parent, fl, widgetMode );
return nullptr;
}
@@ -16,10 +16,7 @@
#define QGSOWSDATAITEMS_H

#include "qgsdataitem.h"
#include "qgsdataitemprovider.h"
#include "qgsdataprovider.h"
#include "qgsdatasourceuri.h"

class QgsOWSConnectionItem : public QgsDataCollectionItem
{
Q_OBJECT
@@ -66,15 +63,4 @@ class QgsOWSRootItem : public QgsDataCollectionItem
#endif
};

//! Provider for ows root data item
class QgsOwsDataItemProvider : public QgsDataItemProvider
{
public:
virtual QString name() override { return QStringLiteral( "OWS" ); }

virtual int capabilities() override { return QgsDataProvider::Net; }

virtual QgsDataItem *createDataItem( const QString &path, QgsDataItem *parentItem ) override;
};

#endif // QGSOWSDATAITEMS_H

0 comments on commit 5f82705

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