Skip to content

Commit 1b4ca62

Browse files
committed
add cppcheck fixes
1 parent e694474 commit 1b4ca62

File tree

202 files changed

+348
-343
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

202 files changed

+348
-343
lines changed

doc/CODING.t2t

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -831,7 +831,7 @@ The class **must** inherit from QObject and include the Q_OBJECT macro.
831831
```
832832
class TestQgsRasterLayer: public QObject
833833
{
834-
Q_OBJECT;
834+
Q_OBJECT
835835
```
836836

837837
All our test methods are implemented as **private slots**. The QtTest framework

src/app/composer/qgsattributeselectiondialog.h

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ class QgsComposerColumnAlignmentDelegate : public QItemDelegate
4444
Q_OBJECT
4545

4646
public:
47-
QgsComposerColumnAlignmentDelegate( QObject *parent = 0 );
47+
explicit QgsComposerColumnAlignmentDelegate( QObject *parent = 0 );
4848
QWidget *createEditor( QWidget *parent, const QStyleOptionViewItem &option, const QModelIndex &index ) const override;
4949
void setEditorData( QWidget *editor, const QModelIndex &index ) const override;
5050
void setModelData( QWidget *editor, QAbstractItemModel *model, const QModelIndex &index ) const override;
@@ -81,7 +81,7 @@ class QgsComposerColumnWidthDelegate : public QItemDelegate
8181
Q_OBJECT
8282

8383
public:
84-
QgsComposerColumnWidthDelegate( QObject *parent = 0 );
84+
explicit QgsComposerColumnWidthDelegate( QObject *parent = 0 );
8585
QWidget *createEditor( QWidget *parent, const QStyleOptionViewItem &option, const QModelIndex &index ) const override;
8686
void setEditorData( QWidget *editor, const QModelIndex &index ) const override;
8787
void setModelData( QWidget *editor, QAbstractItemModel *model, const QModelIndex &index ) const override;
@@ -98,7 +98,7 @@ class QgsComposerColumnSortOrderDelegate : public QItemDelegate
9898
Q_OBJECT
9999

100100
public:
101-
QgsComposerColumnSortOrderDelegate( QObject *parent = 0 );
101+
explicit QgsComposerColumnSortOrderDelegate( QObject *parent = 0 );
102102
QWidget *createEditor( QWidget *parent, const QStyleOptionViewItem &option, const QModelIndex &index ) const override;
103103
void setEditorData( QWidget *editor, const QModelIndex &index ) const override;
104104
void setModelData( QWidget *editor, QAbstractItemModel *model, const QModelIndex &index ) const override;

src/app/composer/qgscomposerarrowwidget.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ class QgsComposerArrowWidget: public QgsComposerItemBaseWidget, private Ui::QgsC
2727
{
2828
Q_OBJECT
2929
public:
30-
QgsComposerArrowWidget( QgsComposerArrow* arrow );
30+
explicit QgsComposerArrowWidget( QgsComposerArrow* arrow );
3131
~QgsComposerArrowWidget();
3232

3333
private:

src/app/composer/qgscomposerlabelwidget.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ class QgsComposerLabelWidget: public QgsComposerItemBaseWidget, private Ui::QgsC
3030
{
3131
Q_OBJECT
3232
public:
33-
QgsComposerLabelWidget( QgsComposerLabel* label );
33+
explicit QgsComposerLabelWidget( QgsComposerLabel* label );
3434

3535
public slots:
3636
void on_mHtmlCheckBox_stateChanged( int i );

src/app/composer/qgscomposerlegendwidget.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ class QgsComposerLegendWidget: public QgsComposerItemBaseWidget, private Ui::Qgs
3434
Q_OBJECT
3535

3636
public:
37-
QgsComposerLegendWidget( QgsComposerLegend* legend );
37+
explicit QgsComposerLegendWidget( QgsComposerLegend* legend );
3838
~QgsComposerLegendWidget();
3939

4040
/** Updates the legend layers and groups*/

src/app/composer/qgscomposermanager.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ class QgsComposerNameDelegate : public QItemDelegate
3030
Q_OBJECT
3131

3232
public:
33-
QgsComposerNameDelegate( QObject *parent = 0 );
33+
explicit QgsComposerNameDelegate( QObject *parent = 0 );
3434

3535
QWidget *createEditor( QWidget *parent, const QStyleOptionViewItem &option,
3636
const QModelIndex &index ) const override;

src/app/composer/qgscomposermapwidget.h

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -33,8 +33,7 @@ class QgsComposerMapWidget: public QgsComposerItemBaseWidget, private Ui::QgsCom
3333
Q_OBJECT
3434

3535
public:
36-
37-
QgsComposerMapWidget( QgsComposerMap* composerMap );
36+
explicit QgsComposerMapWidget( QgsComposerMap* composerMap );
3837
virtual ~QgsComposerMapWidget();
3938

4039
public slots:

src/app/composer/qgscomposerpicturewidget.h

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -31,8 +31,7 @@ class QgsComposerPictureWidget: public QgsComposerItemBaseWidget, private Ui::Qg
3131
Q_OBJECT
3232

3333
public:
34-
35-
QgsComposerPictureWidget( QgsComposerPicture* picture );
34+
explicit QgsComposerPictureWidget( QgsComposerPicture* picture );
3635
~QgsComposerPictureWidget();
3736

3837
/** Add the icons of the standard directories to the preview*/

src/app/composer/qgscomposerscalebarwidget.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ class QgsComposerScaleBarWidget: public QgsComposerItemBaseWidget, private Ui::Q
3030
Q_OBJECT
3131

3232
public:
33-
QgsComposerScaleBarWidget( QgsComposerScaleBar* scaleBar );
33+
explicit QgsComposerScaleBarWidget( QgsComposerScaleBar* scaleBar );
3434
~QgsComposerScaleBarWidget();
3535

3636
public slots:

src/app/composer/qgscomposershapewidget.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ class QgsComposerShapeWidget: public QgsComposerItemBaseWidget, private Ui::QgsC
2828
{
2929
Q_OBJECT
3030
public:
31-
QgsComposerShapeWidget( QgsComposerShape* composerShape );
31+
explicit QgsComposerShapeWidget( QgsComposerShape* composerShape );
3232
~QgsComposerShapeWidget();
3333

3434
private:

src/app/composer/qgscomposertablewidget.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ class QgsComposerTableWidget: public QgsComposerItemBaseWidget, private Ui::QgsC
2727
{
2828
Q_OBJECT
2929
public:
30-
QgsComposerTableWidget( QgsComposerAttributeTable* table );
30+
explicit QgsComposerTableWidget( QgsComposerAttributeTable* table );
3131
~QgsComposerTableWidget();
3232

3333
protected:

src/app/gps/qgsgpsmarker.h

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -29,8 +29,7 @@ class QPainter;
2929
class QgsGpsMarker : public QgsMapCanvasItem
3030
{
3131
public:
32-
33-
QgsGpsMarker( QgsMapCanvas* mapCanvas );
32+
explicit QgsGpsMarker( QgsMapCanvas* mapCanvas );
3433

3534
void setCenter( const QgsPoint& point );
3635

src/app/nodetool/qgsmaptoolnodetool.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ class QgsMapToolNodeTool: public QgsMapToolEdit
3131
{
3232
Q_OBJECT
3333
public:
34-
QgsMapToolNodeTool( QgsMapCanvas* canvas );
34+
explicit QgsMapToolNodeTool( QgsMapCanvas* canvas );
3535
virtual ~QgsMapToolNodeTool();
3636

3737
void canvasMoveEvent( QgsMapMouseEvent* e ) override;

src/app/pluginmanager/qgspluginitemdelegate.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ class QgsPluginItemDelegate : public QStyledItemDelegate
2626
{
2727
Q_OBJECT
2828
public:
29-
QgsPluginItemDelegate( QObject * parent = 0 );
29+
explicit QgsPluginItemDelegate( QObject * parent = 0 );
3030
QSize sizeHint( const QStyleOptionViewItem & theOption, const QModelIndex & theIndex ) const override;
3131
void paint( QPainter *painter, const QStyleOptionViewItem &option, const QModelIndex &index ) const override;
3232
};

src/app/pluginmanager/qgspluginsortfilterproxymodel.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ class QgsPluginSortFilterProxyModel : public QSortFilterProxyModel
4242
Q_OBJECT
4343

4444
public:
45-
QgsPluginSortFilterProxyModel( QObject *parent = 0 );
45+
explicit QgsPluginSortFilterProxyModel( QObject *parent = 0 );
4646

4747
//! (Re)configire the status filter
4848
void setAcceptedStatuses( QStringList statuses );

src/app/qgisapp.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7176,7 +7176,7 @@ QList<QgsMapLayer *> QgisApp::editableLayers( bool modified ) const
71767176
if ( !vl )
71777177
continue;
71787178

7179-
if ( vl->isEditable() && ( !modified || ( modified && vl->isModified() ) ) )
7179+
if ( vl->isEditable() && ( !modified || vl->isModified() ) )
71807180
editLayers << vl;
71817181
}
71827182
return editLayers;
@@ -7760,7 +7760,7 @@ void QgisApp::showPluginManager()
77607760
class QgsPythonRunnerImpl : public QgsPythonRunner
77617761
{
77627762
public:
7763-
QgsPythonRunnerImpl( QgsPythonUtils* pythonUtils ) : mPythonUtils( pythonUtils ) {}
7763+
explicit QgsPythonRunnerImpl( QgsPythonUtils* pythonUtils ) : mPythonUtils( pythonUtils ) {}
77647764

77657765
virtual bool runCommand( QString command, QString messageOnError = QString() ) override
77667766
{

src/app/qgsalignrasterdialog.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ static QString _rasterLayerName( const QString& filename )
4444
/** Helper class to report progress */
4545
struct QgsAlignRasterDialogProgress : public QgsAlignRaster::ProgressHandler
4646
{
47-
QgsAlignRasterDialogProgress( QProgressBar* pb ) : mPb( pb ) {}
47+
explicit QgsAlignRasterDialogProgress( QProgressBar* pb ) : mPb( pb ) {}
4848
virtual bool progress( double complete ) override
4949
{
5050
mPb->setValue(( int ) qRound( complete * 100 ) );

src/app/qgsbrowserdockwidget.cpp

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ items on the tree view although the drop is actually managed by qgis app.
4949
class QgsDockBrowserTreeView : public QgsBrowserTreeView
5050
{
5151
public:
52-
QgsDockBrowserTreeView( QWidget* parent ) : QgsBrowserTreeView( parent )
52+
explicit QgsDockBrowserTreeView( QWidget* parent ) : QgsBrowserTreeView( parent )
5353
{
5454
setDragDropMode( QTreeView::DragDrop ); // sets also acceptDrops + dragEnabled
5555
setSelectionMode( QAbstractItemView::ExtendedSelection );
@@ -91,8 +91,7 @@ Utility class for filtering browser items
9191
class QgsBrowserTreeFilterProxyModel : public QSortFilterProxyModel
9292
{
9393
public:
94-
95-
QgsBrowserTreeFilterProxyModel( QObject *parent )
94+
explicit QgsBrowserTreeFilterProxyModel( QObject *parent )
9695
: QSortFilterProxyModel( parent ), mModel( 0 )
9796
, mFilter( "" ), mPatternSyntax( "normal" ), mCaseSensitivity( Qt::CaseInsensitive )
9897
{

src/app/qgsbrowserdockwidget.h

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ class QgsBrowserPropertiesWidget : public QWidget
4545
{
4646
Q_OBJECT
4747
public:
48-
QgsBrowserPropertiesWidget( QWidget* parent = 0 );
48+
explicit QgsBrowserPropertiesWidget( QWidget* parent = 0 );
4949
static QgsBrowserPropertiesWidget* createWidget( QgsDataItem* item, QWidget* parent = 0 );
5050
virtual void setItem( QgsDataItem* item ) { Q_UNUSED( item ) }
5151
/** Set content widget, usually item paramWidget. Takes ownership. */
@@ -63,7 +63,7 @@ class QgsBrowserLayerProperties : public QgsBrowserPropertiesWidget, private Ui:
6363
{
6464
Q_OBJECT
6565
public:
66-
QgsBrowserLayerProperties( QWidget* parent = 0 );
66+
explicit QgsBrowserLayerProperties( QWidget* parent = 0 );
6767
void setItem( QgsDataItem* item ) override;
6868

6969
virtual void setCondensedMode( bool condensedMode ) override;
@@ -76,7 +76,7 @@ class QgsBrowserDirectoryProperties : public QgsBrowserPropertiesWidget , privat
7676
{
7777
Q_OBJECT
7878
public:
79-
QgsBrowserDirectoryProperties( QWidget* parent = 0 );
79+
explicit QgsBrowserDirectoryProperties( QWidget* parent = 0 );
8080

8181
void setItem( QgsDataItem* item ) override;
8282
private:

src/app/qgsdxfexportdialog.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ class FieldSelectorDelegate : public QItemDelegate
3434
{
3535
Q_OBJECT
3636
public:
37-
FieldSelectorDelegate( QObject *parent = 0 );
37+
explicit FieldSelectorDelegate( QObject *parent = 0 );
3838

3939
QWidget *createEditor( QWidget *parent, const QStyleOptionViewItem &option, const QModelIndex &index ) const override;
4040
void setEditorData( QWidget *editor, const QModelIndex &index ) const override;

src/app/qgsfieldsproperties.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,7 @@ class APP_EXPORT QgsFieldsProperties : public QWidget, private Ui_QgsFieldsPrope
8080
class DragList : public QTableWidget
8181
{
8282
public:
83-
DragList( QWidget* parent = 0 )
83+
explicit DragList( QWidget* parent = 0 )
8484
: QTableWidget( parent )
8585
{}
8686

@@ -98,7 +98,7 @@ class APP_EXPORT QgsFieldsProperties : public QWidget, private Ui_QgsFieldsPrope
9898
class DesignerTree : public QTreeWidget
9999
{
100100
public:
101-
DesignerTree( QWidget* parent = 0 )
101+
explicit DesignerTree( QWidget* parent = 0 )
102102
: QTreeWidget( parent )
103103
{}
104104
QTreeWidgetItem* addItem( QTreeWidgetItem* parent, DesignerTreeItemData data );

src/app/qgsmaptooladdcircularstring.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ class QgsMapToolAddCircularString: public QgsMapToolCapture
3838
void setParentTool( QgsMapTool* newTool, QgsMapTool* oldTool );
3939

4040
protected:
41-
QgsMapToolAddCircularString( QgsMapCanvas* canvas ); //forbidden
41+
explicit QgsMapToolAddCircularString( QgsMapCanvas* canvas ); //forbidden
4242

4343
QgsMapToolCapture* mParentTool;
4444
/** Circular string points (in map coordinates)*/

src/app/qgsmaptoolpinlabels.cpp

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -233,9 +233,8 @@ void QgsMapToolPinLabels::removePinnedHighlights()
233233

234234
void QgsMapToolPinLabels::pinUnpinLabels( const QgsRectangle& ext, QMouseEvent * e )
235235
{
236-
237-
bool doUnpin = e->modifiers() & Qt::ShiftModifier ? true : false;
238-
bool toggleUnpinOrPin = e->modifiers() & Qt::ControlModifier ? true : false;
236+
bool doUnpin = e->modifiers() & Qt::ShiftModifier;
237+
bool toggleUnpinOrPin = e->modifiers() & Qt::ControlModifier;
239238

240239
// get list of all drawn labels from all layers within, or touching, chosen extent
241240
bool labelChanged = false;

src/app/qgsmaptoolselect.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ void QgsMapToolSelect::canvasReleaseEvent( QgsMapMouseEvent* e )
5151
QgsMapToolSelectUtils::expandSelectRectangle( selectRect, vlayer, e->pos() );
5252
QgsMapToolSelectUtils::setRubberBand( mCanvas, selectRect, &rubberBand );
5353
QgsGeometry* selectGeom = rubberBand.asGeometry();
54-
bool doDifference = e->modifiers() & Qt::ControlModifier ? true : false;
54+
bool doDifference = e->modifiers() & Qt::ControlModifier;
5555
QgsMapToolSelectUtils::setSelectFeatures( mCanvas, selectGeom, false, doDifference, true );
5656
delete selectGeom;
5757
rubberBand.reset( QGis::Polygon );

src/app/qgsmaptoolselectrectangle.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -106,7 +106,7 @@ void QgsMapToolSelectFeatures::canvasReleaseEvent( QgsMapMouseEvent* e )
106106
QgsGeometry* selectGeom = mRubberBand->asGeometry();
107107
if ( !mDragging )
108108
{
109-
bool doDifference = e->modifiers() & Qt::ControlModifier ? true : false;
109+
bool doDifference = e->modifiers() & Qt::ControlModifier;
110110
QgsMapToolSelectUtils::setSelectFeatures( mCanvas, selectGeom, false, doDifference, true );
111111
}
112112
else

src/app/qgsmaptoolselectutils.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -233,7 +233,7 @@ void QgsMapToolSelectUtils::setSelectFeatures( QgsMapCanvas* canvas,
233233

234234
void QgsMapToolSelectUtils::setSelectFeatures( QgsMapCanvas* canvas, QgsGeometry* selectGeometry, QMouseEvent * e )
235235
{
236-
bool doContains = e->modifiers() & Qt::ShiftModifier ? true : false;
237-
bool doDifference = e->modifiers() & Qt::ControlModifier ? true : false;
236+
bool doContains = e->modifiers() & Qt::ShiftModifier;
237+
bool doDifference = e->modifiers() & Qt::ControlModifier;
238238
setSelectFeatures( canvas, selectGeometry, doContains, doDifference );
239239
}

src/app/qgsmaptoolshowhidelabels.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -118,7 +118,7 @@ void QgsMapToolShowHideLabels::showHideLabels( QMouseEvent * e )
118118
return;
119119
}
120120

121-
bool doHide = e->modifiers() & Qt::ShiftModifier ? true : false;
121+
bool doHide = e->modifiers() & Qt::ShiftModifier;
122122

123123
QgsFeatureIds selectedFeatIds;
124124

src/app/qgsmaptoolsplitparts.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ class QgsMapToolSplitParts: public QgsMapToolCapture
2424
{
2525
Q_OBJECT
2626
public:
27-
QgsMapToolSplitParts( QgsMapCanvas* canvas );
27+
explicit QgsMapToolSplitParts( QgsMapCanvas* canvas );
2828
virtual ~QgsMapToolSplitParts();
2929
void cadCanvasReleaseEvent( QgsMapMouseEvent * e ) override;
3030
};

src/app/qgsnewspatialitelayerdialog.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -154,7 +154,7 @@ QString QgsNewSpatialiteLayerDialog::selectedType() const
154154
return "MULTIPOLYGON";
155155
}
156156

157-
Q_ASSERT( "no type selected" == 0 );
157+
Q_ASSERT( !"no type selected" );
158158
return "";
159159
}
160160

src/app/qgssettingstree.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@ class QgsSettingsTree : public QTreeWidget
5252
Q_OBJECT
5353

5454
public:
55-
QgsSettingsTree( QWidget *parent = 0 );
55+
explicit QgsSettingsTree( QWidget *parent = 0 );
5656

5757
void setSettingsObject( QSettings *settings );
5858
QSize sizeHint() const override;

src/app/qgsvariantdelegate.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ class QgsVariantDelegate : public QItemDelegate
4949
Q_OBJECT
5050

5151
public:
52-
QgsVariantDelegate( QObject* parent = 0 );
52+
explicit QgsVariantDelegate( QObject* parent = 0 );
5353

5454
void paint( QPainter* painter, const QStyleOptionViewItem& option,
5555
const QModelIndex& index ) const override;

src/app/qgsvectorlayerproperties.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -490,7 +490,7 @@ void QgsVectorLayerProperties::syncToLayer( void )
490490
// NOTE: this is not ideal, but a quick fix for QGIS 2.0 release
491491
bool ok;
492492
bool dl = QgsProject::instance()->readBoolEntry( "DeprecatedLabels", "/Enabled", false, &ok );
493-
if ( !ok || ( ok && !dl ) ) // project not flagged or set to use deprecated labels
493+
if ( !ok || !dl ) // project not flagged or set to use deprecated labels
494494
{
495495
if ( mOptsPage_LabelsOld )
496496
{

src/app/qgswelcomepage.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ class QgsWelcomePage : public QWidget
2828
Q_OBJECT
2929

3030
public:
31-
QgsWelcomePage( QWidget* parent = 0 );
31+
explicit QgsWelcomePage( QWidget* parent = 0 );
3232

3333
~QgsWelcomePage();
3434

src/app/qgswelcomepageitemsmodel.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ class QgsWelcomePageItemDelegate : public QStyledItemDelegate
2525
Q_OBJECT
2626

2727
public:
28-
QgsWelcomePageItemDelegate( QObject * parent = 0 );
28+
explicit QgsWelcomePageItemDelegate( QObject * parent = 0 );
2929
void paint( QPainter * painter, const QStyleOptionViewItem & option, const QModelIndex & index ) const override;
3030
QSize sizeHint( const QStyleOptionViewItem & option, const QModelIndex & index ) const override;
3131
};
@@ -51,7 +51,7 @@ class QgsWelcomePageItemsModel : public QAbstractListModel
5151
QString crs;
5252
};
5353

54-
QgsWelcomePageItemsModel( QObject* parent = 0 );
54+
explicit QgsWelcomePageItemsModel( QObject* parent = 0 );
5555

5656
void setRecentProjects( const QList<RecentProjectData>& recentProjects );
5757

0 commit comments

Comments
 (0)