eric6/IconEditor/IconEditorWindow.py

branch
without_py2_and_pyqt4
changeset 7198
684261ef2165
parent 6942
2602857055c5
child 7229
53054eb5b15a
equal deleted inserted replaced
7197:331569d44b19 7198:684261ef2165
26 26
27 import UI.PixmapCache 27 import UI.PixmapCache
28 import UI.Config 28 import UI.Config
29 29
30 import Preferences 30 import Preferences
31 from Globals import qVersionTuple
32 31
33 32
34 class IconEditorWindow(E5MainWindow): 33 class IconEditorWindow(E5MainWindow):
35 """ 34 """
36 Class implementing the web browser main window. 35 Class implementing the web browser main window.
1351 Protected method to handle wheel events. 1350 Protected method to handle wheel events.
1352 1351
1353 @param evt reference to the wheel event (QWheelEvent) 1352 @param evt reference to the wheel event (QWheelEvent)
1354 """ 1353 """
1355 if evt.modifiers() & Qt.ControlModifier: 1354 if evt.modifiers() & Qt.ControlModifier:
1356 if qVersionTuple() >= (5, 0, 0): 1355 delta = evt.angleDelta().y()
1357 delta = evt.angleDelta().y()
1358 else:
1359 delta = evt.delta()
1360 if delta < 0: 1356 if delta < 0:
1361 self.__zoomOut() 1357 self.__zoomOut()
1362 elif delta > 0: 1358 elif delta > 0:
1363 self.__zoomIn() 1359 self.__zoomIn()
1364 evt.accept() 1360 evt.accept()

eric ide

mercurial