diff options
Diffstat (limited to 'source/blender/editors/gpencil')
-rw-r--r-- | source/blender/editors/gpencil/gpencil_brush.c | 2 | ||||
-rw-r--r-- | source/blender/editors/gpencil/gpencil_convert.c | 2 | ||||
-rw-r--r-- | source/blender/editors/gpencil/gpencil_data.c | 6 | ||||
-rw-r--r-- | source/blender/editors/gpencil/gpencil_edit.c | 16 | ||||
-rw-r--r-- | source/blender/editors/gpencil/gpencil_intern.h | 12 | ||||
-rw-r--r-- | source/blender/editors/gpencil/gpencil_interpolate.c | 4 | ||||
-rw-r--r-- | source/blender/editors/gpencil/gpencil_ops.c | 2 | ||||
-rw-r--r-- | source/blender/editors/gpencil/gpencil_paint.c | 2 | ||||
-rw-r--r-- | source/blender/editors/gpencil/gpencil_select.c | 2 | ||||
-rw-r--r-- | source/blender/editors/gpencil/gpencil_utils.c | 10 |
10 files changed, 29 insertions, 29 deletions
diff --git a/source/blender/editors/gpencil/gpencil_brush.c b/source/blender/editors/gpencil/gpencil_brush.c index c35b64de991..0f51f12793a 100644 --- a/source/blender/editors/gpencil/gpencil_brush.c +++ b/source/blender/editors/gpencil/gpencil_brush.c @@ -1174,7 +1174,7 @@ static void gpsculpt_brush_exit(bContext *C, wmOperator *op) } /* poll callback for stroke sculpting operator(s) */ -static int gpsculpt_brush_poll(bContext *C) +static bool gpsculpt_brush_poll(bContext *C) { /* NOTE: this is a bit slower, but is the most accurate... */ return CTX_DATA_COUNT(C, editable_gpencil_strokes) != 0; diff --git a/source/blender/editors/gpencil/gpencil_convert.c b/source/blender/editors/gpencil/gpencil_convert.c index 67d3272a90d..0c148710e3e 100644 --- a/source/blender/editors/gpencil/gpencil_convert.c +++ b/source/blender/editors/gpencil/gpencil_convert.c @@ -1282,7 +1282,7 @@ static void gp_convert_set_end_frame(struct Main *UNUSED(main), struct Scene *UN } } -static int gp_convert_poll(bContext *C) +static bool gp_convert_poll(bContext *C) { bGPdata *gpd = ED_gpencil_data_get_active(C); bGPDlayer *gpl = NULL; diff --git a/source/blender/editors/gpencil/gpencil_data.c b/source/blender/editors/gpencil/gpencil_data.c index 9f437f28f0f..c28fea0fc41 100644 --- a/source/blender/editors/gpencil/gpencil_data.c +++ b/source/blender/editors/gpencil/gpencil_data.c @@ -131,7 +131,7 @@ void GPENCIL_OT_data_add(wmOperatorType *ot) /* ******************* Unlink Data ************************ */ /* poll callback for adding data/layers - special */ -static int gp_data_unlink_poll(bContext *C) +static bool gp_data_unlink_poll(bContext *C) { bGPdata **gpd_ptr = ED_gpencil_data_get_pointers(C, NULL); @@ -420,7 +420,7 @@ void GPENCIL_OT_hide(wmOperatorType *ot) /* ********************** Show All Layers ***************************** */ /* poll callback for showing layers */ -static int gp_reveal_poll(bContext *C) +static bool gp_reveal_poll(bContext *C) { return ED_gpencil_data_get_active(C) != NULL; } @@ -1811,7 +1811,7 @@ void GPENCIL_OT_palettecolor_hide(wmOperatorType *ot) /* ********************** Show All Colors ***************************** */ /* poll callback for showing colors */ -static int gp_palettecolor_reveal_poll(bContext *C) +static bool gp_palettecolor_reveal_poll(bContext *C) { return ED_gpencil_data_get_active(C) != NULL; } diff --git a/source/blender/editors/gpencil/gpencil_edit.c b/source/blender/editors/gpencil/gpencil_edit.c index cdd8d571400..936cf571b4a 100644 --- a/source/blender/editors/gpencil/gpencil_edit.c +++ b/source/blender/editors/gpencil/gpencil_edit.c @@ -84,7 +84,7 @@ /* ************************************************ */ /* Stroke Edit Mode Management */ -static int gpencil_editmode_toggle_poll(bContext *C) +static bool gpencil_editmode_toggle_poll(bContext *C) { return ED_gpencil_data_get_active(C) != NULL; } @@ -129,7 +129,7 @@ void GPENCIL_OT_editmode_toggle(wmOperatorType *ot) /* Stroke Editing Operators */ /* poll callback for all stroke editing operators */ -static int gp_stroke_edit_poll(bContext *C) +static bool gp_stroke_edit_poll(bContext *C) { /* NOTE: this is a bit slower, but is the most accurate... */ return CTX_DATA_COUNT(C, editable_gpencil_strokes) != 0; @@ -515,7 +515,7 @@ void GPENCIL_OT_copy(wmOperatorType *ot) /* --------------------- */ /* Paste selected strokes */ -static int gp_strokes_paste_poll(bContext *C) +static bool gp_strokes_paste_poll(bContext *C) { /* 1) Must have GP datablock to paste to * - We don't need to have an active layer though, as that can easily get added @@ -782,7 +782,7 @@ void GPENCIL_OT_move_to_layer(wmOperatorType *ot) /* ********************* Add Blank Frame *************************** */ /* Basically the same as the drawing op */ -static int UNUSED_FUNCTION(gp_blank_frame_add_poll)(bContext *C) +static bool UNUSED_FUNCTION(gp_blank_frame_add_poll)(bContext *C) { if (ED_operator_regionactive(C)) { /* check if current context can support GPencil data */ @@ -862,7 +862,7 @@ void GPENCIL_OT_blank_frame_add(wmOperatorType *ot) /* ******************* Delete Active Frame ************************ */ -static int gp_actframe_delete_poll(bContext *C) +static bool gp_actframe_delete_poll(bContext *C) { bGPdata *gpd = ED_gpencil_data_get_active(C); bGPDlayer *gpl = BKE_gpencil_layer_getactive(gpd); @@ -914,7 +914,7 @@ void GPENCIL_OT_active_frame_delete(wmOperatorType *ot) /* **************** Delete All Active Frames ****************** */ -static int gp_actframe_delete_all_poll(bContext *C) +static bool gp_actframe_delete_all_poll(bContext *C) { bGPdata *gpd = ED_gpencil_data_get_active(C); @@ -1368,7 +1368,7 @@ void GPENCIL_OT_dissolve(wmOperatorType *ot) /* NOTE: For now, we only allow these in the 3D view, as other editors do not * define a cursor or gridstep which can be used */ -static int gp_snap_poll(bContext *C) +static bool gp_snap_poll(bContext *C) { bGPdata *gpd = CTX_data_gpencil_data(C); ScrArea *sa = CTX_wm_area(C); @@ -2088,7 +2088,7 @@ typedef enum eGP_ReprojectModes { GP_REPROJECT_SURFACE, } eGP_ReprojectModes; -static int gp_strokes_reproject_poll(bContext *C) +static bool gp_strokes_reproject_poll(bContext *C) { /* 2 Requirements: * - 1) Editable GP data diff --git a/source/blender/editors/gpencil/gpencil_intern.h b/source/blender/editors/gpencil/gpencil_intern.h index 33af6cab915..d7e60d2a0ce 100644 --- a/source/blender/editors/gpencil/gpencil_intern.h +++ b/source/blender/editors/gpencil/gpencil_intern.h @@ -93,12 +93,12 @@ bool gp_point_xy_to_3d(GP_SpaceConversion *gsc, struct Scene *scene, const float /* Poll Callbacks ------------------------------------ */ /* gpencil_utils.c */ -int gp_add_poll(struct bContext *C); -int gp_active_layer_poll(struct bContext *C); -int gp_active_brush_poll(struct bContext *C); -int gp_active_palette_poll(struct bContext *C); -int gp_active_palettecolor_poll(struct bContext *C); -int gp_brush_crt_presets_poll(bContext *C); +bool gp_add_poll(struct bContext *C); +bool gp_active_layer_poll(struct bContext *C); +bool gp_active_brush_poll(struct bContext *C); +bool gp_active_palette_poll(struct bContext *C); +bool gp_active_palettecolor_poll(struct bContext *C); +bool gp_brush_crt_presets_poll(bContext *C); /* Copy/Paste Buffer --------------------------------- */ /* gpencil_edit.c */ diff --git a/source/blender/editors/gpencil/gpencil_interpolate.c b/source/blender/editors/gpencil/gpencil_interpolate.c index ff3f5b20858..e2d70803695 100644 --- a/source/blender/editors/gpencil/gpencil_interpolate.c +++ b/source/blender/editors/gpencil/gpencil_interpolate.c @@ -85,7 +85,7 @@ /* Core/Shared Utilities */ /* Poll callback for interpolation operators */ -static int gpencil_view3d_poll(bContext *C) +static bool gpencil_view3d_poll(bContext *C) { bGPdata *gpd = CTX_data_gpencil_data(C); bGPDlayer *gpl = CTX_data_active_gpencil_layer(C); @@ -1032,7 +1032,7 @@ void GPENCIL_OT_interpolate_sequence(wmOperatorType *ot) /* ******************** Remove Breakdowns ************************ */ -static int gpencil_interpolate_reverse_poll(bContext *C) +static bool gpencil_interpolate_reverse_poll(bContext *C) { if (!gpencil_view3d_poll(C)) { return 0; diff --git a/source/blender/editors/gpencil/gpencil_ops.c b/source/blender/editors/gpencil/gpencil_ops.c index 84a106856b3..2a575c02046 100644 --- a/source/blender/editors/gpencil/gpencil_ops.c +++ b/source/blender/editors/gpencil/gpencil_ops.c @@ -114,7 +114,7 @@ static void ed_keymap_gpencil_general(wmKeyConfig *keyconf) /* ==================== */ /* Poll callback for stroke editing mode */ -static int gp_stroke_editmode_poll(bContext *C) +static bool gp_stroke_editmode_poll(bContext *C) { bGPdata *gpd = CTX_data_gpencil_data(C); return (gpd && (gpd->flag & GP_DATA_STROKE_EDITMODE)); diff --git a/source/blender/editors/gpencil/gpencil_paint.c b/source/blender/editors/gpencil/gpencil_paint.c index 2471ba76ae2..fd1ff857317 100644 --- a/source/blender/editors/gpencil/gpencil_paint.c +++ b/source/blender/editors/gpencil/gpencil_paint.c @@ -195,7 +195,7 @@ static void gp_session_validatebuffer(tGPsdata *p); /* Context Wrangling... */ /* check if context is suitable for drawing */ -static int gpencil_draw_poll(bContext *C) +static bool gpencil_draw_poll(bContext *C) { if (ED_operator_regionactive(C)) { /* check if current context can support GPencil data */ diff --git a/source/blender/editors/gpencil/gpencil_select.c b/source/blender/editors/gpencil/gpencil_select.c index ac0b046e499..dd556e99264 100644 --- a/source/blender/editors/gpencil/gpencil_select.c +++ b/source/blender/editors/gpencil/gpencil_select.c @@ -67,7 +67,7 @@ /* ********************************************** */ /* Polling callbacks */ -static int gpencil_select_poll(bContext *C) +static bool gpencil_select_poll(bContext *C) { bGPdata *gpd = ED_gpencil_data_get_active(C); diff --git a/source/blender/editors/gpencil/gpencil_utils.c b/source/blender/editors/gpencil/gpencil_utils.c index 0a35dd90f02..e6f3b40024f 100644 --- a/source/blender/editors/gpencil/gpencil_utils.c +++ b/source/blender/editors/gpencil/gpencil_utils.c @@ -260,14 +260,14 @@ bool ED_gpencil_has_keyframe_v3d(Scene *scene, Object *ob, int cfra) /* Poll Callbacks */ /* poll callback for adding data/layers - special */ -int gp_add_poll(bContext *C) +bool gp_add_poll(bContext *C) { /* the base line we have is that we have somewhere to add Grease Pencil data */ return ED_gpencil_data_get_pointers(C, NULL) != NULL; } /* poll callback for checking if there is an active layer */ -int gp_active_layer_poll(bContext *C) +bool gp_active_layer_poll(bContext *C) { bGPdata *gpd = ED_gpencil_data_get_active(C); bGPDlayer *gpl = BKE_gpencil_layer_getactive(gpd); @@ -276,7 +276,7 @@ int gp_active_layer_poll(bContext *C) } /* poll callback for checking if there is an active brush */ -int gp_active_brush_poll(bContext *C) +bool gp_active_brush_poll(bContext *C) { ToolSettings *ts = CTX_data_tool_settings(C); bGPDbrush *brush = BKE_gpencil_brush_getactive(ts); @@ -285,7 +285,7 @@ int gp_active_brush_poll(bContext *C) } /* poll callback for checking if there is an active palette */ -int gp_active_palette_poll(bContext *C) +bool gp_active_palette_poll(bContext *C) { bGPdata *gpd = ED_gpencil_data_get_active(C); bGPDpalette *palette = BKE_gpencil_palette_getactive(gpd); @@ -294,7 +294,7 @@ int gp_active_palette_poll(bContext *C) } /* poll callback for checking if there is an active palette color */ -int gp_active_palettecolor_poll(bContext *C) +bool gp_active_palettecolor_poll(bContext *C) { bGPdata *gpd = ED_gpencil_data_get_active(C); bGPDpalette *palette = BKE_gpencil_palette_getactive(gpd); |