diff options
author | Campbell Barton <ideasman42@gmail.com> | 2018-05-16 19:41:11 +0300 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2018-05-17 16:57:33 +0300 |
commit | edf6676a77b30290918e60547544bc1a6f7a8838 (patch) | |
tree | 26012f315c75686553e6be87b73ad270b98eb01a /source/blender/editors/sculpt_paint | |
parent | 20cc14e2b7551bb043472174b8be79d8aaa4df3d (diff) |
Tool System: per space/mode tool support
This patch adds support for:
- Per space-type tools (3D view and edit).
- Per mode tools (object, edit, weight-paint .. etc).
The top-bar shows the last activated tools options, this is a design
issue with using a global topbar to show per-space settings.
See D3395
Diffstat (limited to 'source/blender/editors/sculpt_paint')
-rw-r--r-- | source/blender/editors/sculpt_paint/paint_image.c | 2 | ||||
-rw-r--r-- | source/blender/editors/sculpt_paint/paint_vertex.c | 4 | ||||
-rw-r--r-- | source/blender/editors/sculpt_paint/sculpt.c | 2 |
3 files changed, 8 insertions, 0 deletions
diff --git a/source/blender/editors/sculpt_paint/paint_image.c b/source/blender/editors/sculpt_paint/paint_image.c index cbf755d26b5..6a32fdecfad 100644 --- a/source/blender/editors/sculpt_paint/paint_image.c +++ b/source/blender/editors/sculpt_paint/paint_image.c @@ -1136,6 +1136,8 @@ static int texture_paint_toggle_exec(bContext *C, wmOperator *op) WM_msg_publish_rna_prop(mbus, &ob->id, ob, Object, mode); + WM_toolsystem_update_from_context_view3d(C); + return OPERATOR_FINISHED; } diff --git a/source/blender/editors/sculpt_paint/paint_vertex.c b/source/blender/editors/sculpt_paint/paint_vertex.c index 196505c9542..3c3df2067ab 100644 --- a/source/blender/editors/sculpt_paint/paint_vertex.c +++ b/source/blender/editors/sculpt_paint/paint_vertex.c @@ -1252,6 +1252,8 @@ static int wpaint_mode_toggle_exec(bContext *C, wmOperator *op) WM_msg_publish_rna_prop(mbus, &ob->id, ob, Object, mode); + WM_toolsystem_update_from_context_view3d(C); + return OPERATOR_FINISHED; } @@ -2386,6 +2388,8 @@ static int vpaint_mode_toggle_exec(bContext *C, wmOperator *op) WM_msg_publish_rna_prop(mbus, &ob->id, ob, Object, mode); + WM_toolsystem_update_from_context_view3d(C); + return OPERATOR_FINISHED; } diff --git a/source/blender/editors/sculpt_paint/sculpt.c b/source/blender/editors/sculpt_paint/sculpt.c index 048555d3fcc..709d6d4c690 100644 --- a/source/blender/editors/sculpt_paint/sculpt.c +++ b/source/blender/editors/sculpt_paint/sculpt.c @@ -5820,6 +5820,8 @@ static int sculpt_mode_toggle_exec(bContext *C, wmOperator *op) WM_msg_publish_rna_prop(mbus, &ob->id, ob, Object, mode); + WM_toolsystem_update_from_context_view3d(C); + return OPERATOR_FINISHED; } |