diff options
author | Campbell Barton <ideasman42@gmail.com> | 2020-11-06 04:30:59 +0300 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2020-11-06 04:32:54 +0300 |
commit | aa3a4973a30ff668a62447e18ac41f6c916b4a8b (patch) | |
tree | 1b24cc55995ba8b3d72aaabd9400a3e1e030d540 /source/blender/editors/gpencil/gpencil_data.c | |
parent | 7cb20d841da16d0bffb63154403267500e9941f5 (diff) |
Cleanup: use ELEM macro
Diffstat (limited to 'source/blender/editors/gpencil/gpencil_data.c')
-rw-r--r-- | source/blender/editors/gpencil/gpencil_data.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/source/blender/editors/gpencil/gpencil_data.c b/source/blender/editors/gpencil/gpencil_data.c index 07a1b34fa84..2cee06c36ad 100644 --- a/source/blender/editors/gpencil/gpencil_data.c +++ b/source/blender/editors/gpencil/gpencil_data.c @@ -1557,14 +1557,14 @@ static int gpencil_stroke_arrange_exec(bContext *C, wmOperator *op) continue; } /* some stroke is already at front*/ - if ((direction == GP_STROKE_MOVE_TOP) || (direction == GP_STROKE_MOVE_UP)) { + if (ELEM(direction, GP_STROKE_MOVE_TOP, GP_STROKE_MOVE_UP)) { if (gps == gpf->strokes.last) { gpf_lock = true; continue; } } /* some stroke is already at botom */ - if ((direction == GP_STROKE_MOVE_BOTTOM) || (direction == GP_STROKE_MOVE_DOWN)) { + if (ELEM(direction, GP_STROKE_MOVE_BOTTOM, GP_STROKE_MOVE_DOWN)) { if (gps == gpf->strokes.first) { gpf_lock = true; continue; @@ -3035,7 +3035,7 @@ static int gpencil_material_isolate_exec(bContext *C, wmOperator *op) for (short i = 0; i < *totcol; i++) { ma = BKE_gpencil_material(ob, i + 1); /* Skip if this is the active one */ - if ((ma == NULL) || (ma == active_ma)) { + if (ELEM(ma, NULL, active_ma)) { continue; } |