Skip to content

Commit

Permalink
fix building without gui (#8561)
Browse files Browse the repository at this point in the history
  • Loading branch information
3nids committed Nov 27, 2018
1 parent a6d2344 commit 6e7d56c
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
5 changes: 3 additions & 2 deletions src/providers/ogr/qgsgeopackagedataitems.cpp
Expand Up @@ -31,6 +31,7 @@
#include "qgsogrprovider.h"
#include "qgsogrdataitems.h"
#ifdef HAVE_GUI
#include "qgsnewnamedialog.h"
#include "qgsnewgeopackagelayerdialog.h"
#endif
#include "qgsmessageoutput.h"
Expand All @@ -39,7 +40,7 @@
#include "qgstaskmanager.h"
#include "qgsproviderregistry.h"
#include "qgsproxyprogresstask.h"
#include "qgsnewnamedialog.h"


QGISEXTERN bool deleteLayer( const QString &uri, const QString &errCause );

Expand Down Expand Up @@ -781,6 +782,7 @@ QList<QString> QgsGeoPackageAbstractLayerItem::tableNames()
return names;
}


QList<QgsMapLayer *> QgsGeoPackageAbstractLayerItem::layersInProject() const
{
// Check if the layer(s) are in the registry
Expand All @@ -796,7 +798,6 @@ QList<QgsMapLayer *> QgsGeoPackageAbstractLayerItem::layersInProject() const
return layersList;
}


QgsGeoPackageVectorLayerItem::QgsGeoPackageVectorLayerItem( QgsDataItem *parent, const QString &name, const QString &path, const QString &uri, LayerType layerType )
: QgsGeoPackageAbstractLayerItem( parent, name, path, uri, layerType, QStringLiteral( "ogr" ) )
{
Expand Down
3 changes: 1 addition & 2 deletions src/providers/ogr/qgsgeopackagedataitems.h
Expand Up @@ -43,11 +43,10 @@ class QgsGeoPackageAbstractLayerItem : public QgsLayerItem
*/
QList<QString> tableNames();

#ifdef HAVE_GUI

//! Checks if the data source has any layer in the current project returns them
QList<QgsMapLayer *> layersInProject() const;

#ifdef HAVE_GUI
QList<QAction *> actions( QWidget *menu ) override;

public slots:
Expand Down

0 comments on commit 6e7d56c

Please sign in to comment.