2013-10-04 14:47:59 +02:00
|
|
|
#ifndef QGSRELATIONADDDLG_H
|
|
|
|
#define QGSRELATIONADDDLG_H
|
|
|
|
|
2015-06-10 13:59:08 +02:00
|
|
|
#include <QDialog>
|
2015-06-10 14:54:12 +02:00
|
|
|
#include "ui_qgsrelationadddlgbase.h"
|
2013-10-04 14:47:59 +02:00
|
|
|
|
|
|
|
class QgsVectorLayer;
|
|
|
|
|
2015-12-09 16:18:07 +10:00
|
|
|
class APP_EXPORT QgsRelationAddDlg : public QDialog, private Ui::QgsRelationAddDlgBase
|
2013-10-04 14:47:59 +02:00
|
|
|
{
|
|
|
|
Q_OBJECT
|
|
|
|
|
|
|
|
public:
|
|
|
|
explicit QgsRelationAddDlg( QWidget *parent = 0 );
|
|
|
|
|
2015-10-07 11:55:34 +11:00
|
|
|
void addLayers( const QList<QgsVectorLayer*>& layers );
|
2013-10-04 14:47:59 +02:00
|
|
|
|
|
|
|
QString referencingLayerId();
|
|
|
|
QString referencedLayerId();
|
|
|
|
QList< QPair< QString, QString > > references();
|
|
|
|
QString relationId();
|
|
|
|
QString relationName();
|
|
|
|
|
|
|
|
|
|
|
|
private slots:
|
|
|
|
void on_mCbxReferencingLayer_currentIndexChanged( int index );
|
|
|
|
void on_mCbxReferencedLayer_currentIndexChanged( int index );
|
|
|
|
|
|
|
|
private:
|
|
|
|
void loadLayerAttributes( QComboBox* cbx, QgsVectorLayer* layer );
|
|
|
|
|
|
|
|
QMap< QString, QgsVectorLayer* > mLayers;
|
|
|
|
|
|
|
|
};
|
|
|
|
|
|
|
|
#endif // QGSRELATIONADDDLG_H
|