[Bf-blender-cvs] [f5e0ae655e5] master: Python Templates: Small fix for gizmo custom geometry
Dalai Felinto
noreply at git.blender.org
Fri Jun 28 14:57:41 CEST 2019
Commit: f5e0ae655e5182de3ee9cfedfbdc2a20f9b047fb
Author: Dalai Felinto
Date: Fri Jun 28 09:54:27 2019 -0300
Branches: master
https://developer.blender.org/rBf5e0ae655e5182de3ee9cfedfbdc2a20f9b047fb
Python Templates: Small fix for gizmo custom geometry
The mouse offset was inverted (the widget was going the opposite direction as the
mouse movement).
===================================================================
M release/scripts/templates_py/gizmo_custom_geometry.py
===================================================================
diff --git a/release/scripts/templates_py/gizmo_custom_geometry.py b/release/scripts/templates_py/gizmo_custom_geometry.py
index fba2b0269c4..b8621c834ab 100644
--- a/release/scripts/templates_py/gizmo_custom_geometry.py
+++ b/release/scripts/templates_py/gizmo_custom_geometry.py
@@ -106,7 +106,7 @@ class MyCustomShapeWidget(Gizmo):
delta = round(delta)
if 'PRECISE' in tweak:
delta /= 10.0
- value = self.init_value + delta
+ value = self.init_value - delta
self.target_set_value("offset", value)
context.area.header_text_set("My Gizmo: %.4f" % value)
return {'RUNNING_MODAL'}
More information about the Bf-blender-cvs
mailing list