QgsMapLayerConfigWidget/QgsRendererRasterPropertiesWidget: suppress -Woverloaded-virtual warning related to syncToLayer() method

This commit is contained in:
Even Rouault 2024-11-30 13:56:00 +01:00 committed by Nyall Dawson
parent 6c861c4be6
commit cf868f8f4c
4 changed files with 15 additions and 5 deletions

View File

@ -123,6 +123,7 @@ be called for the layer after applying changes. This is ``True`` by default, but
.. versionadded:: 3.8
%End
virtual void syncToLayer( QgsMapLayer *layer );
%Docstring
Reset to original (vector layer) values

View File

@ -123,6 +123,7 @@ be called for the layer after applying changes. This is ``True`` by default, but
.. versionadded:: 3.8
%End
virtual void syncToLayer( QgsMapLayer *layer );
%Docstring
Reset to original (vector layer) values

View File

@ -134,11 +134,19 @@ class GUI_EXPORT QgsMapLayerConfigWidget : public QgsPanelWidget
*/
virtual bool shouldTriggerLayerRepaint() const { return true; }
#ifdef __GNUC__
#pragma GCC diagnostic push
#pragma GCC diagnostic ignored "-Woverloaded-virtual"
#endif
/**
* Reset to original (vector layer) values
* \since QGIS 3.14
*/
virtual void syncToLayer( QgsMapLayer *layer ) { Q_UNUSED( layer ) }
#ifdef __GNUC__
#pragma GCC diagnostic pop
#endif
/**
* Sets the \a context under which the widget is being shown.

View File

@ -67,9 +67,9 @@ class GUI_EXPORT QgsRendererRasterPropertiesWidget : public QgsMapLayerConfigWid
void apply() override;
#ifdef __clang__
#pragma clang diagnostic push
#pragma clang diagnostic ignored "-Woverloaded-virtual"
#ifdef __GNUC__
#pragma GCC diagnostic push
#pragma GCC diagnostic ignored "-Woverloaded-virtual"
#endif
/**
@ -77,8 +77,8 @@ class GUI_EXPORT QgsRendererRasterPropertiesWidget : public QgsMapLayerConfigWid
* \param layer The layer to use for the widget
*/
void syncToLayer( QgsRasterLayer *layer );
#ifdef __clang__
#pragma clang diagnostic pop
#ifdef __GNUC__
#pragma GCC diagnostic pop
#endif
private slots: