diff options
author | Campbell Barton <ideasman42@gmail.com> | 2018-02-06 09:53:19 +0300 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2018-02-06 10:03:29 +0300 |
commit | 2a184f3d2b6cc180fedd0c93c266d847f7d27936 (patch) | |
tree | 5d7472cb10888e6e18dd64bbcdb3c078ac325ca0 /source/blender/editors/object/object_ops.c | |
parent | 906ed54d286d0dd6686aac997883e7dfa4bba792 (diff) |
Object Mode: use eval_ctx for paint & object
Diffstat (limited to 'source/blender/editors/object/object_ops.c')
-rw-r--r-- | source/blender/editors/object/object_ops.c | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/source/blender/editors/object/object_ops.c b/source/blender/editors/object/object_ops.c index 9c321f5cb79..2aa2451b834 100644 --- a/source/blender/editors/object/object_ops.c +++ b/source/blender/editors/object/object_ops.c @@ -47,6 +47,8 @@ #include "ED_screen.h" #include "ED_object.h" +#include "DEG_depsgraph.h" + #include "object_intern.h" @@ -290,8 +292,11 @@ void ED_operatormacros_object(void) static int object_mode_poll(bContext *C) { + EvaluationContext eval_ctx; + CTX_data_eval_ctx(C, &eval_ctx); + Object *ob = CTX_data_active_object(C); - return (!ob || ob->mode == OB_MODE_OBJECT); + return (!ob || eval_ctx.object_mode == OB_MODE_OBJECT); } void ED_keymap_object(wmKeyConfig *keyconf) |