Skip to content

Commit

Permalink
fix and sync QgsAttributeEditorContext sip bindings
Browse files Browse the repository at this point in the history
  • Loading branch information
jef-n committed Sep 13, 2014
1 parent 9945a6d commit 17669b5
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 9 deletions.
28 changes: 20 additions & 8 deletions python/gui/qgsattributeeditorcontext.sip
Expand Up @@ -10,19 +10,31 @@ class QgsAttributeEditorContext
#include "qgsattributeeditorcontext.h" #include "qgsattributeeditorcontext.h"
%End %End
public: public:
/**
* Determines in which direction a relation was resolved.
*/
enum RelationMode
{
Undefined, //!< This context is not defined by a relation
EmbedMultiple, //!< When embedding a list of features (e.g. houses as an embedded form in a district form)
EmbedSingle, //!< When embedding a single feature (e.g. district information when looking at the form of a house)
StandaloneSingle //!< When showing a new dialog for a single feature (e.g. district information when looking at the form of a house)
};

QgsAttributeEditorContext(); QgsAttributeEditorContext();


QgsAttributeEditorContext( const QgsAttributeEditorContext& parentContext, const QgsRelation& relation, RelationMode mode );

void setDistanceArea( const QgsDistanceArea& distanceArea ); void setDistanceArea( const QgsDistanceArea& distanceArea );

const QgsDistanceArea& distanceArea(); const QgsDistanceArea& distanceArea();


void setVectorLayerTools( QgsVectorLayerTools* vlTools ); void setVectorLayerTools( QgsVectorLayerTools* vlTools );
QgsVectorLayerTools* vectorLayerTools(); const QgsVectorLayerTools* vectorLayerTools() const;


/** void setRelation( const QgsRelation& relation, RelationMode mode );
* When copying the context for another layer, call this. const QgsRelation& relation() const;
* Will adjast the distance area for this layer RelationMode relationMode() const;
*
* @param layer The layer to adjust for. const QgsAttributeEditorContext* parentContext() const;
*/
// void adjustForLayer( QgsVectorLayer* layer );
}; };
1 change: 0 additions & 1 deletion src/gui/qgsattributeeditorcontext.h
Expand Up @@ -44,7 +44,6 @@ class GUI_EXPORT QgsAttributeEditorContext
StandaloneSingle //!< When showing a new dialog for a single feature (e.g. district information when looking at the form of a house) StandaloneSingle //!< When showing a new dialog for a single feature (e.g. district information when looking at the form of a house)
}; };


public:
QgsAttributeEditorContext() QgsAttributeEditorContext()
: mParentContext( 0 ) : mParentContext( 0 )
, mLayer( 0 ) , mLayer( 0 )
Expand Down

0 comments on commit 17669b5

Please sign in to comment.