[Bf-blender-cvs] [ff1b35af39e] master: Cleanup: remove OB_MODE_EDIT from GPencil compatibility check

Campbell Barton noreply at git.blender.org
Fri May 7 03:24:40 CEST 2021


Commit: ff1b35af39ec05e248377480e911cf3f6a9e0149
Author: Campbell Barton
Date:   Fri May 7 11:13:50 2021 +1000
Branches: master
https://developer.blender.org/rBff1b35af39ec05e248377480e911cf3f6a9e0149

Cleanup: remove OB_MODE_EDIT from GPencil compatibility check

All callers replace this with OB_MODE_EDIT_GPENCIL.

===================================================================

M	source/blender/editors/object/object_modes.c

===================================================================

diff --git a/source/blender/editors/object/object_modes.c b/source/blender/editors/object/object_modes.c
index 3892e43f0f3..dcb294bcb12 100644
--- a/source/blender/editors/object/object_modes.c
+++ b/source/blender/editors/object/object_modes.c
@@ -150,8 +150,8 @@ bool ED_object_mode_compat_test(const Object *ob, eObjectMode mode)
       }
       break;
     case OB_GPENCIL:
-      if (mode & (OB_MODE_EDIT | OB_MODE_EDIT_GPENCIL | OB_MODE_PAINT_GPENCIL |
-                  OB_MODE_SCULPT_GPENCIL | OB_MODE_WEIGHT_GPENCIL | OB_MODE_VERTEX_GPENCIL)) {
+      if (mode & (OB_MODE_EDIT_GPENCIL | OB_MODE_PAINT_GPENCIL | OB_MODE_SCULPT_GPENCIL |
+                  OB_MODE_WEIGHT_GPENCIL | OB_MODE_VERTEX_GPENCIL)) {
         return true;
       }
       break;



More information about the Bf-blender-cvs mailing list