more pyqt6 enum goodness

This commit is contained in:
Kovid Goyal 2022-02-02 22:06:36 +05:30
parent ac2a6393f9
commit 16c3e7bb00
No known key found for this signature in database
GPG Key ID: 06BC317B515ACE7C

View File

@ -1159,7 +1159,7 @@ class GridView(QListView):
return super().selectionCommand(index, event) return super().selectionCommand(index, event)
def wheelEvent(self, ev): def wheelEvent(self, ev):
if ev.phase() not in (Qt.ScrollPhase.ScrollUpdate, 0, Qt.ScrollPhase.ScrollMomentum): if ev.phase() not in (Qt.ScrollPhase.ScrollUpdate, Qt.ScrollPhase.NoScrollPhase, Qt.ScrollPhase.ScrollMomentum):
return return
number_of_pixels = ev.pixelDelta() number_of_pixels = ev.pixelDelta()
number_of_degrees = ev.angleDelta() / 8.0 number_of_degrees = ev.angleDelta() / 8.0