Commit ee5a88d 1 parent e0ddc1c commit ee5a88d Copy full SHA for ee5a88d
File tree 1 file changed +12
-0
lines changed
1 file changed +12
-0
lines changed Original file line number Diff line number Diff line change @@ -164,3 +164,15 @@ PROJECT_SCALES = Qgis.defaultProjectScales()
164
164
GEOPROJ4 = geoProj4()
165
165
GEO_EPSG_CRS_AUTHID = geoEpsgCrsAuthId()
166
166
GEO_NONE = geoNone()
167
+
168
+
169
+ from enum import Enum
170
+
171
+ def _force_int(v): return int(v.value) if isinstance(v, Enum) else v
172
+
173
+ QgsFeatureRequest.Flags = Qgis.FeatureRequestFlags
174
+ Qgis.FeatureRequestFlag.__bool__ = lambda flag: bool(_force_int(flag))
175
+ Qgis.FeatureRequestFlag.__eq__ = lambda flag1, flag2: _force_int(flag1) == _force_int(flag2)
176
+ Qgis.FeatureRequestFlag.__and__ = lambda flag1, flag2: _force_int(flag1) & _force_int(flag2)
177
+ Qgis.FeatureRequestFlag.__or__ = lambda flag1, flag2: Qgis.FeatureRequestFlags(_force_int(flag1) | _force_int(flag2))
178
+
You can’t perform that action at this time.
0 commit comments