Skip to content

Commit

Permalink
Fix broken compatibility with QGIS 3.18
Browse files Browse the repository at this point in the history
  • Loading branch information
nirvn committed Sep 14, 2024
1 parent 561f4cf commit 8ea6606
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions qfieldsync/gui/mapthemes_config_widget.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
***************************************************************************/
"""

from qgis.core import Qgis
from qgis.core import QgsMapLayerProxyModel
from qgis.gui import QgsMapLayerComboBox

from qgis.PyQt.QtCore import Qt
Expand Down Expand Up @@ -61,7 +61,7 @@ def reload(self, configuration):
cmb = QgsMapLayerComboBox()
cmb.setAllowEmptyLayer(True)
cmb.setProject(self.project)
cmb.setFilters(Qgis.LayerFilter.VectorLayer)
cmb.setFilters(QgsMapLayerProxyModel.VectorLayer)
if map_theme in configuration:
cmb.setLayer(self.project.mapLayer(configuration[map_theme]))
self.setCellWidget(count, 1, cmb)
Expand Down

0 comments on commit 8ea6606

Please sign in to comment.