Skip to content
Permalink
Browse files

Move selectWidget() and dataCapabilities() to data items file where i…

…t belongs
  • Loading branch information
wonder-sk committed Oct 19, 2011
1 parent c219045 commit 2572388c68fd2d27679a123ffd1fee8a66d1cda1
@@ -223,6 +223,17 @@ void QgsPGRootItem::newConnection()

// ---------------------------------------------------------------------------

QGISEXTERN QgsPgSourceSelect * selectWidget( QWidget * parent, Qt::WFlags fl )
{
// TODO: this should be somewhere else
return new QgsPgSourceSelect( parent, fl );
}

QGISEXTERN int dataCapabilities()
{
return QgsDataProvider::Database;
}

QGISEXTERN QgsDataItem * dataItem( QString thePath, QgsDataItem* parentItem )
{
Q_UNUSED( thePath );
@@ -37,7 +37,6 @@

#include "qgspostgresprovider.h"
#include "qgspostgresconnection.h"
#include "qgspgsourceselect.h"

#include "qgslogger.h"

@@ -4395,16 +4394,6 @@ QGISEXTERN bool isProvider()
return true;
}
// ---------------------------------------------------------------------------
QGISEXTERN QgsPgSourceSelect * selectWidget( QWidget * parent, Qt::WFlags fl )
{
// TODO: this should be somewhere else
return new QgsPgSourceSelect( parent, fl );
}

QGISEXTERN int dataCapabilities()
{
return QgsDataProvider::Database;
}

QGISEXTERN QgsVectorLayerImport::ImportError createEmptyLayer(
const QString& uri,
@@ -169,6 +169,12 @@ void QgsWFSRootItem::newConnection()
}
}

// ---------------------------------------------------------------------------

QGISEXTERN QgsWFSSourceSelect * selectWidget( QWidget * parent, Qt::WFlags fl )
{
return new QgsWFSSourceSelect( parent, fl );
}

QGISEXTERN int dataCapabilities()
{
@@ -2301,12 +2301,3 @@ QGISEXTERN bool isProvider()
{
return true;
}

// ---------------------------------------------------------------------------

#include "qgswfssourceselect.h"

QGISEXTERN QgsWFSSourceSelect * selectWidget( QWidget * parent, Qt::WFlags fl )
{
return new QgsWFSSourceSelect( parent, fl );
}
@@ -248,10 +248,19 @@ void QgsWMSRootItem::newConnection()

// ---------------------------------------------------------------------------

QGISEXTERN QgsWMSSourceSelect * selectWidget( QWidget * parent, Qt::WFlags fl )
{
return new QgsWMSSourceSelect( parent, fl );
}

QGISEXTERN int dataCapabilities()
{
return QgsDataProvider::Net;
}

QGISEXTERN QgsDataItem * dataItem( QString thePath, QgsDataItem* parentItem )
{
Q_UNUSED( thePath );

return new QgsWMSRootItem( parentItem, "WMS", "wms:" );
}

@@ -1,6 +1,7 @@
#ifndef QGSWMSDATAITEMS_H
#define QGSWMSDATAITEMS_H

#include "qgsdataitem.h"
#include "qgswmsprovider.h"

class QgsWMSConnectionItem : public QgsDataCollectionItem
@@ -26,7 +26,6 @@
#include "qgslogger.h"
#include "qgswmsprovider.h"
#include "qgswmsconnection.h"
#include "qgswmssourceselect.h"

#include <cmath>

@@ -3155,13 +3154,3 @@ QGISEXTERN bool isProvider()
return true;
}

// ---------------------------------------------------------------------------
QGISEXTERN QgsWMSSourceSelect * selectWidget( QWidget * parent, Qt::WFlags fl )
{
return new QgsWMSSourceSelect( parent, fl );
}

QGISEXTERN int dataCapabilities()
{
return QgsDataProvider::Net;
}
@@ -21,14 +21,14 @@
#define QGSWMSPROVIDER_H

#include "qgsrasterdataprovider.h"
#include "qgsdataitem.h"
#include "qgsrectangle.h"

#include <QString>
#include <QStringList>
#include <QDomElement>
#include <QMap>
#include <QVector>
#include <QUrl>

class QgsCoordinateTransform;
class QNetworkAccessManager;

0 comments on commit 2572388

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