diff options
author | Peter Kim <pk15950@gmail.com> | 2021-08-27 14:05:34 +0300 |
---|---|---|
committer | Peter Kim <pk15950@gmail.com> | 2021-08-27 14:05:34 +0300 |
commit | c88ba461cf7e271de16d6951c7b185b964a252b9 (patch) | |
tree | 2c6880aeda3ef1224ad361a12f21be20444d6d0e /source/blender/editors | |
parent | 59cd9c6da682675c439731781d127b1b02f12a76 (diff) |
Fix "toggle shading" op not updating VR view
Reason was that the notifier did not set the NS_VIEW3D_SHADING
subtype, which the VR view listens for for a shading update.
In the case of "toggle xray", a notifier was absent altogether.
Diffstat (limited to 'source/blender/editors')
-rw-r--r-- | source/blender/editors/space_view3d/view3d_edit.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/source/blender/editors/space_view3d/view3d_edit.c b/source/blender/editors/space_view3d/view3d_edit.c index b055a0fe947..466820353b9 100644 --- a/source/blender/editors/space_view3d/view3d_edit.c +++ b/source/blender/editors/space_view3d/view3d_edit.c @@ -5292,7 +5292,7 @@ static int toggle_shading_exec(bContext *C, wmOperator *op) } ED_view3d_shade_update(bmain, v3d, area); - WM_event_add_notifier(C, NC_SPACE | ND_SPACE_VIEW3D, v3d); + WM_event_add_notifier(C, NC_SPACE | ND_SPACE_VIEW3D | NS_VIEW3D_SHADING, v3d); return OPERATOR_FINISHED; } @@ -5347,6 +5347,7 @@ static int toggle_xray_exec(bContext *C, wmOperator *op) } ED_area_tag_redraw(area); + WM_event_add_notifier(C, NC_SPACE | ND_SPACE_VIEW3D | NS_VIEW3D_SHADING, v3d); return OPERATOR_FINISHED; } |