git clone https://git.lucas.co/hou-control.git
hc: fix phantom zoom when pressing Ctrl in Network Editor
python3.11libs/nodegraphhooks.py | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/python3.11libs/nodegraphhooks.py b/python3.11libs/nodegraphhooks.py
index 3390fcf..432cffb 100755
--- a/python3.11libs/nodegraphhooks.py
+++ b/python3.11libs/nodegraphhooks.py
@@ -7,7 +7,7 @@ from hc import HCNetworkEditor
def createEventHandler(uievent, pending_actions):
if isinstance(uievent, MouseEvent):
- if uievent.modifierstate.ctrl and uievent.wheelvalue:
+ if uievent.modifierstate.ctrl and uievent.wheelvalue != 0:
network_editor = HCNetworkEditor(uievent.editor)
pivot = uievent.editor.posFromScreen(uievent.mousepos)
network_editor.zoom('in' if uievent.wheelvalue > 0 else 'out', amount=0.03, pivot=pivot)