From 6ffcddc10afa07b073ce01c25884e23fc2b661df Mon Sep 17 00:00:00 2001 From: Campbell Barton Date: Sat, 7 Dec 2019 03:45:50 +1100 Subject: Tool System: experimental fallback tool support Implement T66304 as an experimental option, available under the preferences "Experimental" section. - When enabled most tools in the 3D view have a gizmo. - Dragging outside the gizmo uses the 'fallback' tool. - The fallback tool can be changed or disabled in the tool options or from a pie menu (Alt-W). --- source/blender/windowmanager/gizmo/WM_gizmo_types.h | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'source/blender/windowmanager/gizmo') diff --git a/source/blender/windowmanager/gizmo/WM_gizmo_types.h b/source/blender/windowmanager/gizmo/WM_gizmo_types.h index 7bb77375934..d3aa333daea 100644 --- a/source/blender/windowmanager/gizmo/WM_gizmo_types.h +++ b/source/blender/windowmanager/gizmo/WM_gizmo_types.h @@ -120,6 +120,12 @@ typedef enum eWM_GizmoFlagGroupTypeFlag { * We could even move the options into the key-map item. * ~ campbell. */ WM_GIZMOGROUPTYPE_TOOL_INIT = (1 << 6), + + /** + * This gizmo type supports using the fallback tools keymap. + * #wmGizmoGroup.use_tool_fallback will need to be set too. + */ + WM_GIZMOGROUPTYPE_TOOL_FALLBACK_KEYMAP = (1 << 7), } eWM_GizmoFlagGroupTypeFlag; /** @@ -443,6 +449,8 @@ typedef struct wmGizmoGroup { bool tag_remove; + bool use_fallback_keymap; + void *customdata; /** For freeing customdata from above. */ void (*customdata_free)(void *); -- cgit v1.2.3