diff options
author | Joshua Leung <aligorith@gmail.com> | 2016-02-08 16:22:16 +0300 |
---|---|---|
committer | Joshua Leung <aligorith@gmail.com> | 2016-02-08 16:45:36 +0300 |
commit | 4bc070a5193f927551a7c2aebb8c6306308bee4e (patch) | |
tree | f0bf1ff31f20d191ac91c147ac1671a59cc2d8fc /source/blender/editors/gpencil | |
parent | 3419ffdf498cd5ba27433bd64d9da3939a4b13d2 (diff) |
Code Cleanup: Use bool instead of int for "setactive" param
Diffstat (limited to 'source/blender/editors/gpencil')
-rw-r--r-- | source/blender/editors/gpencil/gpencil_data.c | 2 | ||||
-rw-r--r-- | source/blender/editors/gpencil/gpencil_edit.c | 2 | ||||
-rw-r--r-- | source/blender/editors/gpencil/gpencil_paint.c | 2 |
3 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 f70ffaee7b2..746497f0ff5 100644 --- a/source/blender/editors/gpencil/gpencil_data.c +++ b/source/blender/editors/gpencil/gpencil_data.c @@ -182,7 +182,7 @@ static int gp_layer_add_exec(bContext *C, wmOperator *op) *gpd_ptr = gpencil_data_addnew(DATA_("GPencil")); /* add new layer now */ - gpencil_layer_addnew(*gpd_ptr, DATA_("GP_Layer"), 1); + gpencil_layer_addnew(*gpd_ptr, DATA_("GP_Layer"), true); /* notifiers */ WM_event_add_notifier(C, NC_GPENCIL | ND_DATA | NA_EDITED, NULL); diff --git a/source/blender/editors/gpencil/gpencil_edit.c b/source/blender/editors/gpencil/gpencil_edit.c index 302d4da4b59..4852723c747 100644 --- a/source/blender/editors/gpencil/gpencil_edit.c +++ b/source/blender/editors/gpencil/gpencil_edit.c @@ -389,7 +389,7 @@ static int gp_strokes_paste_exec(bContext *C, wmOperator *op) } else if (gpl == NULL) { /* no active layer - let's just create one */ - gpl = gpencil_layer_addnew(gpd, DATA_("GP_Layer"), 1); + gpl = gpencil_layer_addnew(gpd, DATA_("GP_Layer"), true); } else if (gpl->flag & (GP_LAYER_HIDE | GP_LAYER_LOCKED)) { BKE_report(op->reports, RPT_ERROR, "Can not paste strokes when active layer is hidden or locked"); diff --git a/source/blender/editors/gpencil/gpencil_paint.c b/source/blender/editors/gpencil/gpencil_paint.c index c05446a9d30..ab6253c5cdb 100644 --- a/source/blender/editors/gpencil/gpencil_paint.c +++ b/source/blender/editors/gpencil/gpencil_paint.c @@ -1198,7 +1198,7 @@ static void gp_paint_initstroke(tGPsdata *p, eGPencil_PaintModes paintmode) /* get active layer (or add a new one if non-existent) */ p->gpl = gpencil_layer_getactive(p->gpd); if (p->gpl == NULL) { - p->gpl = gpencil_layer_addnew(p->gpd, "GP_Layer", 1); + p->gpl = gpencil_layer_addnew(p->gpd, "GP_Layer", true); if (p->custom_color[3]) copy_v3_v3(p->gpl->color, p->custom_color); |