[Bf-blender-cvs] [4444221] master: GPencil: Cleanup - Rename function for better naming
Antonioya
noreply at git.blender.org
Mon Aug 8 11:28:08 CEST 2016
Commit: 444422120f25de84d02abc99b417bd3d6b85d55a
Author: Antonioya
Date: Mon Aug 8 11:26:00 2016 +0200
Branches: master
https://developer.blender.org/rB444422120f25de84d02abc99b417bd3d6b85d55a
GPencil: Cleanup - Rename function for better naming
The old function name was not clear enough
===================================================================
M source/blender/editors/gpencil/gpencil_paint.c
===================================================================
diff --git a/source/blender/editors/gpencil/gpencil_paint.c b/source/blender/editors/gpencil/gpencil_paint.c
index 3afdd57..e7e39a8 100644
--- a/source/blender/editors/gpencil/gpencil_paint.c
+++ b/source/blender/editors/gpencil/gpencil_paint.c
@@ -2287,8 +2287,8 @@ static void gpencil_stroke_end(wmOperator *op)
p->gpf = NULL;
}
-/* if drawing polygon and draw on back is enabled, move the stroke below all previous strokes */
-static void gpencil_move_polygon_stroke_to_back(bContext *C)
+/* Move last stroke in the listbase to the head to be drawn below all previous strokes in the layer */
+static void gpencil_move_last_stroke_to_back(bContext *C)
{
/* move last stroke (the polygon) to head of the listbase stroke to draw on back of all previous strokes */
bGPdata *gpd = ED_gpencil_data_get_active(C);
@@ -2368,7 +2368,7 @@ static int gpencil_draw_modal(bContext *C, wmOperator *op, const wmEvent *event)
/* if drawing polygon and enable on back, must move stroke */
if ((p->scene->toolsettings->gpencil_flags & GP_TOOL_FLAG_PAINT_ONBACK) && (p->paintmode == GP_PAINTMODE_DRAW_POLY)) {
if (p->flags & GP_PAINTFLAG_STROKEADDED) {
- gpencil_move_polygon_stroke_to_back(C);
+ gpencil_move_last_stroke_to_back(C);
}
}
p->status = GP_STATUS_DONE;
@@ -2430,7 +2430,7 @@ static int gpencil_draw_modal(bContext *C, wmOperator *op, const wmEvent *event)
/* if drawing polygon and enable on back, must move stroke */
if ((p->scene->toolsettings->gpencil_flags & GP_TOOL_FLAG_PAINT_ONBACK) && (p->paintmode == GP_PAINTMODE_DRAW_POLY)) {
if (p->flags & GP_PAINTFLAG_STROKEADDED) {
- gpencil_move_polygon_stroke_to_back(C);
+ gpencil_move_last_stroke_to_back(C);
}
}
p->status = GP_STATUS_DONE;
@@ -2516,7 +2516,7 @@ static int gpencil_draw_modal(bContext *C, wmOperator *op, const wmEvent *event)
/* if drawing polygon and enable on back, must move stroke */
if ((p->scene->toolsettings->gpencil_flags & GP_TOOL_FLAG_PAINT_ONBACK) && (p->paintmode == GP_PAINTMODE_DRAW_POLY)) {
if (p->flags & GP_PAINTFLAG_STROKEADDED) {
- gpencil_move_polygon_stroke_to_back(C);
+ gpencil_move_last_stroke_to_back(C);
}
}
p->status = GP_STATUS_DONE;
More information about the Bf-blender-cvs
mailing list