mirror of
https://github.com/qgis/QGIS.git
synced 2025-03-01 00:46:20 -05:00
Add missing overrides
This commit is contained in:
parent
6a2df335ae
commit
f7b4315f9c
@ -34,7 +34,7 @@ class QgsMapToolNodeTool: public QgsMapToolEdit
|
|||||||
QgsMapToolNodeTool( QgsMapCanvas* canvas );
|
QgsMapToolNodeTool( QgsMapCanvas* canvas );
|
||||||
virtual ~QgsMapToolNodeTool();
|
virtual ~QgsMapToolNodeTool();
|
||||||
|
|
||||||
void canvasDoubleClickEvent( QMouseEvent * e );
|
void canvasDoubleClickEvent( QMouseEvent * e ) override;
|
||||||
|
|
||||||
//! mouse press event in map coordinates (eventually filtered) to be redefined in subclass
|
//! mouse press event in map coordinates (eventually filtered) to be redefined in subclass
|
||||||
void canvasMapPressEvent( QgsMapMouseEvent* e ) override;
|
void canvasMapPressEvent( QgsMapMouseEvent* e ) override;
|
||||||
@ -42,10 +42,10 @@ class QgsMapToolNodeTool: public QgsMapToolEdit
|
|||||||
//! mouse move event in map coordinates (eventually filtered) to be redefined in subclass
|
//! mouse move event in map coordinates (eventually filtered) to be redefined in subclass
|
||||||
void canvasMapMoveEvent( QgsMapMouseEvent* e ) override;
|
void canvasMapMoveEvent( QgsMapMouseEvent* e ) override;
|
||||||
|
|
||||||
void keyPressEvent( QKeyEvent* e );
|
void keyPressEvent( QKeyEvent* e ) override;
|
||||||
|
|
||||||
//! called when map tool is being deactivated
|
//! called when map tool is being deactivated
|
||||||
void deactivate();
|
void deactivate() override;
|
||||||
|
|
||||||
public slots:
|
public slots:
|
||||||
void selectedFeatureDestroyed();
|
void selectedFeatureDestroyed();
|
||||||
|
@ -36,13 +36,15 @@ static const int MinRadiusRole = Qt::UserRole + 1;
|
|||||||
class CoordinateItemDelegate : public QStyledItemDelegate
|
class CoordinateItemDelegate : public QStyledItemDelegate
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
QString displayText( const QVariant & value, const QLocale & locale ) const
|
|
||||||
|
QString displayText( const QVariant & value, const QLocale & locale ) const override
|
||||||
{
|
{
|
||||||
return locale.toString( value.toDouble(), 'f', 4 );
|
return locale.toString( value.toDouble(), 'f', 4 );
|
||||||
}
|
}
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
QWidget* createEditor( QWidget * parent, const QStyleOptionViewItem & /*option*/, const QModelIndex & index ) const
|
|
||||||
|
QWidget* createEditor( QWidget * parent, const QStyleOptionViewItem &, const QModelIndex & index ) const override
|
||||||
{
|
{
|
||||||
QLineEdit* lineEdit = new QLineEdit( parent );
|
QLineEdit* lineEdit = new QLineEdit( parent );
|
||||||
QDoubleValidator* validator = new QDoubleValidator();
|
QDoubleValidator* validator = new QDoubleValidator();
|
||||||
@ -51,7 +53,8 @@ class CoordinateItemDelegate : public QStyledItemDelegate
|
|||||||
lineEdit->setValidator( validator );
|
lineEdit->setValidator( validator );
|
||||||
return lineEdit;
|
return lineEdit;
|
||||||
}
|
}
|
||||||
void setModelData( QWidget *editor, QAbstractItemModel *model, const QModelIndex &index ) const
|
|
||||||
|
void setModelData( QWidget *editor, QAbstractItemModel *model, const QModelIndex &index ) const override
|
||||||
{
|
{
|
||||||
QLineEdit* lineEdit = qobject_cast<QLineEdit*>( editor );
|
QLineEdit* lineEdit = qobject_cast<QLineEdit*>( editor );
|
||||||
if ( lineEdit->hasAcceptableInput() )
|
if ( lineEdit->hasAcceptableInput() )
|
||||||
|
@ -29,7 +29,7 @@ class GUI_EXPORT QgsCheckboxWidgetFactory : public QgsEditorWidgetFactory
|
|||||||
QgsEditorConfigWidget* configWidget( QgsVectorLayer* vl, int fieldIdx, QWidget* parent ) const override;
|
QgsEditorConfigWidget* configWidget( QgsVectorLayer* vl, int fieldIdx, QWidget* parent ) const override;
|
||||||
QgsEditorWidgetConfig readConfig( const QDomElement& configElement, QgsVectorLayer* layer, int fieldIdx ) override;
|
QgsEditorWidgetConfig readConfig( const QDomElement& configElement, QgsVectorLayer* layer, int fieldIdx ) override;
|
||||||
void writeConfig( const QgsEditorWidgetConfig& config, QDomElement& configElement, QDomDocument& doc, const QgsVectorLayer* layer, int fieldIdx ) override;
|
void writeConfig( const QgsEditorWidgetConfig& config, QDomElement& configElement, QDomDocument& doc, const QgsVectorLayer* layer, int fieldIdx ) override;
|
||||||
QMap<const char*, int> supportedWidgetTypes();
|
QMap<const char*, int> supportedWidgetTypes() override;
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif // QGSCHECKBOXWIDGETFACTORY_H
|
#endif // QGSCHECKBOXWIDGETFACTORY_H
|
||||||
|
@ -82,7 +82,7 @@ class GUI_EXPORT QgsGeometryRubberBand: public QgsMapCanvasItem
|
|||||||
void setIconType( IconType iconType ) { mIconType = iconType; }
|
void setIconType( IconType iconType ) { mIconType = iconType; }
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
virtual void paint( QPainter* painter );
|
virtual void paint( QPainter* painter ) override;
|
||||||
|
|
||||||
private:
|
private:
|
||||||
QgsAbstractGeometryV2* mGeometry;
|
QgsAbstractGeometryV2* mGeometry;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user