Show tiled scene layers in layer styling dock

This commit is contained in:
Nyall Dawson 2023-08-06 19:04:44 +10:00
parent c6a4a71bd9
commit a9cd6b8992
4 changed files with 6 additions and 2 deletions

View File

@ -37,6 +37,7 @@ The :py:class:`QgsMapLayerProxyModel` class provides an easy to use model to dis
VectorTileLayer,
PointCloudLayer,
AnnotationLayer,
TiledSceneLayer,
All,
SpatialLayer
};

View File

@ -112,6 +112,7 @@ QgsLayerStylingWidget::QgsLayerStylingWidget( QgsMapCanvas *canvas, QgsMessageBa
| QgsMapLayerProxyModel::Filter::MeshLayer
| QgsMapLayerProxyModel::Filter::VectorTileLayer
| QgsMapLayerProxyModel::Filter::PointCloudLayer
| QgsMapLayerProxyModel::Filter::TiledSceneLayer
| QgsMapLayerProxyModel::Filter::AnnotationLayer );
mLayerCombo->setAdditionalLayers( { QgsProject::instance()->mainAnnotationLayer() } );

View File

@ -50,6 +50,7 @@ bool QgsMapLayerProxyModel::layerMatchesFilters( const QgsMapLayer *layer, const
( filters.testFlag( VectorTileLayer ) && layer->type() == Qgis::LayerType::VectorTile ) ||
( filters.testFlag( PointCloudLayer ) && layer->type() == Qgis::LayerType::PointCloud ) ||
( filters.testFlag( AnnotationLayer ) && layer->type() == Qgis::LayerType::Annotation ) ||
( filters.testFlag( TiledSceneLayer ) && layer->type() == Qgis::LayerType::TiledScene ) ||
( filters.testFlag( PluginLayer ) && layer->type() == Qgis::LayerType::Plugin ) )
return true;

View File

@ -55,8 +55,9 @@ class CORE_EXPORT QgsMapLayerProxyModel : public QSortFilterProxyModel
VectorTileLayer = 256, //!< QgsVectorTileLayer \since QGIS 3.14
PointCloudLayer = 512, //!< QgsPointCloudLayer \since QGIS 3.18
AnnotationLayer = 1024, //!< QgsAnnotationLayer \since QGIS 3.22
All = RasterLayer | VectorLayer | PluginLayer | MeshLayer | VectorTileLayer | PointCloudLayer | AnnotationLayer,
SpatialLayer = RasterLayer | HasGeometry | PluginLayer | MeshLayer | VectorTileLayer | PointCloudLayer | AnnotationLayer //!< \since QGIS 3.24
TiledSceneLayer = 2048, //!< QgsTiledSceneLayer \since QGIS 3.34
All = RasterLayer | VectorLayer | PluginLayer | MeshLayer | VectorTileLayer | PointCloudLayer | AnnotationLayer | TiledSceneLayer,
SpatialLayer = RasterLayer | HasGeometry | PluginLayer | MeshLayer | VectorTileLayer | PointCloudLayer | AnnotationLayer | TiledSceneLayer //!< \since QGIS 3.24
};
Q_DECLARE_FLAGS( Filters, Filter )
Q_FLAG( Filters )