Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEthan-Hall <Ethan1080>2022-04-11 23:30:37 +0300
committerGermano Cavalcante <germano.costa@ig.com.br>2022-04-11 23:32:24 +0300
commitb3525c3487ca893aac5bb8241ce154f491508224 (patch)
tree9b70d3b7af2ef03ea23824320a8045d95d6e25a9
parent4aa9888854d77ae7377aad1faf98f88fc7363b08 (diff)
UI: make snap self inactive if proportional editing
When using proportional editing, the 'project onto self' snap setting is ignored since proportional editing does not allow snapping to self. The UI should reflect this fact. This patch makes 'project onto self' active only when proportional editing is off. Reviewed By: mano-wii Differential Revision: https://developer.blender.org/D14496
-rw-r--r--release/scripts/startup/bl_ui/space_view3d.py6
1 files changed, 4 insertions, 2 deletions
diff --git a/release/scripts/startup/bl_ui/space_view3d.py b/release/scripts/startup/bl_ui/space_view3d.py
index 2e924d5b4c9..ecd48aab697 100644
--- a/release/scripts/startup/bl_ui/space_view3d.py
+++ b/release/scripts/startup/bl_ui/space_view3d.py
@@ -6746,8 +6746,10 @@ class VIEW3D_PT_snapping(Panel):
col.prop(tool_settings, "use_snap_backface_culling")
if obj:
- if object_mode == 'EDIT':
- col.prop(tool_settings, "use_snap_self")
+ if object_mode == 'EDIT' and obj.type not in {'LATTICE', 'META', 'FONT'}:
+ sub = col.column()
+ sub.active = not (tool_settings.use_proportional_edit and obj.type == 'MESH')
+ sub.prop(tool_settings, "use_snap_self")
if object_mode in {'OBJECT', 'POSE', 'EDIT', 'WEIGHT_PAINT'}:
col.prop(tool_settings, "use_snap_align_rotation")