Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'source/blender/editors/space_image')
-rw-r--r--source/blender/editors/space_image/image_buttons.c4
-rw-r--r--source/blender/editors/space_image/image_draw.c2
-rw-r--r--source/blender/editors/space_image/image_edit.c4
-rw-r--r--source/blender/editors/space_image/image_intern.h2
-rw-r--r--source/blender/editors/space_image/image_ops.c26
-rw-r--r--source/blender/editors/space_image/space_image.c2
6 files changed, 20 insertions, 20 deletions
diff --git a/source/blender/editors/space_image/image_buttons.c b/source/blender/editors/space_image/image_buttons.c
index 0cd61f3e330..191f57961c9 100644
--- a/source/blender/editors/space_image/image_buttons.c
+++ b/source/blender/editors/space_image/image_buttons.c
@@ -827,7 +827,7 @@ static void rna_update_cb(bContext *C, void *arg_cb, void *UNUSED(arg))
RNA_property_update(C, &cb->ptr, cb->prop);
}
-void uiTemplateImage(uiLayout *layout, bContext *C, PointerRNA *ptr, const char *propname, PointerRNA *userptr, int compact, int multiview)
+void uiTemplateImage(uiLayout *layout, bContext *C, PointerRNA *ptr, const char *propname, PointerRNA *userptr, bool compact, bool multiview)
{
PropertyRNA *prop;
PointerRNA imaptr;
@@ -1063,7 +1063,7 @@ void uiTemplateImage(uiLayout *layout, bContext *C, PointerRNA *ptr, const char
MEM_freeN(cb);
}
-void uiTemplateImageSettings(uiLayout *layout, PointerRNA *imfptr, int color_management)
+void uiTemplateImageSettings(uiLayout *layout, PointerRNA *imfptr, bool color_management)
{
ImageFormatData *imf = imfptr->data;
ID *id = imfptr->id.data;
diff --git a/source/blender/editors/space_image/image_draw.c b/source/blender/editors/space_image/image_draw.c
index 11e06c168b4..ecd608b707a 100644
--- a/source/blender/editors/space_image/image_draw.c
+++ b/source/blender/editors/space_image/image_draw.c
@@ -582,7 +582,7 @@ void draw_image_sample_line(SpaceImage *sima)
GPU_viewport_size_getf(viewport_size);
immUniform2f("viewport_size", viewport_size[2] / UI_DPI_FAC, viewport_size[3] / UI_DPI_FAC);
- immUniform1i("num_colors", 2); /* Advanced dashes. */
+ immUniform1i("colors_len", 2); /* Advanced dashes. */
immUniformArray4fv("colors", (float *)(float[][4]){{1.0f, 1.0f, 1.0f, 1.0f}, {0.0f, 0.0f, 0.0f, 1.0f}}, 2);
immUniform1f("dash_width", 2.0f);
diff --git a/source/blender/editors/space_image/image_edit.c b/source/blender/editors/space_image/image_edit.c
index 8bbca25538a..4388accc534 100644
--- a/source/blender/editors/space_image/image_edit.c
+++ b/source/blender/editors/space_image/image_edit.c
@@ -388,7 +388,7 @@ bool ED_space_image_check_show_maskedit(SpaceImage *sima, ViewLayer *view_layer)
return (sima->mode == SI_MODE_MASK);
}
-int ED_space_image_maskedit_poll(bContext *C)
+bool ED_space_image_maskedit_poll(bContext *C)
{
SpaceImage *sima = CTX_wm_space_image(C);
@@ -415,7 +415,7 @@ bool ED_space_image_paint_curve(const bContext *C)
}
-int ED_space_image_maskedit_mask_poll(bContext *C)
+bool ED_space_image_maskedit_mask_poll(bContext *C)
{
if (ED_space_image_maskedit_poll(C)) {
SpaceImage *sima = CTX_wm_space_image(C);
diff --git a/source/blender/editors/space_image/image_intern.h b/source/blender/editors/space_image/image_intern.h
index 3725f1d5195..5d9c496d584 100644
--- a/source/blender/editors/space_image/image_intern.h
+++ b/source/blender/editors/space_image/image_intern.h
@@ -54,7 +54,7 @@ void draw_image_grease_pencil(struct bContext *C, bool onlyv2d);
void draw_image_sample_line(struct SpaceImage *sima);
/* image_ops.c */
-int space_image_main_region_poll(struct bContext *C);
+bool space_image_main_region_poll(struct bContext *C);
void IMAGE_OT_view_all(struct wmOperatorType *ot);
void IMAGE_OT_view_pan(struct wmOperatorType *ot);
diff --git a/source/blender/editors/space_image/image_ops.c b/source/blender/editors/space_image/image_ops.c
index 40311594512..3efdce3ea6d 100644
--- a/source/blender/editors/space_image/image_ops.c
+++ b/source/blender/editors/space_image/image_ops.c
@@ -179,13 +179,13 @@ static void sima_zoom_set_from_bounds(SpaceImage *sima, ARegion *ar, const rctf
}
#if 0 // currently unused
-static int image_poll(bContext *C)
+static bool image_poll(bContext *C)
{
return (CTX_data_edit_image(C) != NULL);
}
#endif
-static int space_image_buffer_exists_poll(bContext *C)
+static bool space_image_buffer_exists_poll(bContext *C)
{
SpaceImage *sima = CTX_wm_space_image(C);
if (sima && ED_space_image_has_buffer(sima)) {
@@ -194,7 +194,7 @@ static int space_image_buffer_exists_poll(bContext *C)
return false;
}
-static int image_not_packed_poll(bContext *C)
+static bool image_not_packed_poll(bContext *C)
{
SpaceImage *sima = CTX_wm_space_image(C);
@@ -213,7 +213,7 @@ static bool imbuf_format_writeable(const ImBuf *ibuf)
return (BKE_image_imtype_to_ftype(im_format.imtype, &options_dummy) == ibuf->ftype);
}
-static int space_image_file_exists_poll(bContext *C)
+static bool space_image_file_exists_poll(bContext *C)
{
if (space_image_buffer_exists_poll(C)) {
Main *bmain = CTX_data_main(C);
@@ -249,7 +249,7 @@ static int space_image_file_exists_poll(bContext *C)
}
#if 0 /* UNUSED */
-static int space_image_poll(bContext *C)
+static bool space_image_poll(bContext *C)
{
SpaceImage *sima = CTX_wm_space_image(C);
if (sima && sima->image) {
@@ -259,7 +259,7 @@ static int space_image_poll(bContext *C)
}
#endif
-int space_image_main_region_poll(bContext *C)
+bool space_image_main_region_poll(bContext *C)
{
SpaceImage *sima = CTX_wm_space_image(C);
/* XXX ARegion *ar = CTX_wm_region(C); */
@@ -271,7 +271,7 @@ int space_image_main_region_poll(bContext *C)
}
/* For IMAGE_OT_curves_point_set to avoid sampling when in uv smooth mode or editmode */
-static int space_image_main_area_not_uv_brush_poll(bContext *C)
+static bool space_image_main_area_not_uv_brush_poll(bContext *C)
{
SpaceImage *sima = CTX_wm_space_image(C);
Scene *scene = CTX_data_scene(C);
@@ -284,7 +284,7 @@ static int space_image_main_area_not_uv_brush_poll(bContext *C)
return 0;
}
-static int image_sample_poll(bContext *C)
+static bool image_sample_poll(bContext *C)
{
SpaceImage *sima = CTX_wm_space_image(C);
if (sima) {
@@ -833,7 +833,7 @@ static int image_view_selected_exec(bContext *C, wmOperator *UNUSED(op))
return OPERATOR_FINISHED;
}
-static int image_view_selected_poll(bContext *C)
+static bool image_view_selected_poll(bContext *C)
{
return (space_image_main_region_poll(C) && (ED_operator_uvedit(C) || ED_operator_mask(C)));
}
@@ -2157,7 +2157,7 @@ static void image_save_as_draw(bContext *UNUSED(C), wmOperator *op)
uiTemplateImageFormatViews(layout, &imf_ptr, op->ptr);
}
-static int image_save_as_poll(bContext *C)
+static bool image_save_as_poll(bContext *C)
{
if (space_image_buffer_exists_poll(C)) {
if (G.is_rendering) {
@@ -2600,7 +2600,7 @@ void IMAGE_OT_new(wmOperatorType *ot)
/********************* invert operators *********************/
-static int image_invert_poll(bContext *C)
+static bool image_invert_poll(bContext *C)
{
Image *ima = CTX_data_edit_image(C);
@@ -3444,7 +3444,7 @@ void IMAGE_OT_record_composite(wmOperatorType *ot)
/********************* cycle render slot operator *********************/
-static int image_cycle_render_slot_poll(bContext *C)
+static bool image_cycle_render_slot_poll(bContext *C)
{
Image *ima = CTX_data_edit_image(C);
@@ -3580,7 +3580,7 @@ void IMAGE_OT_remove_render_slot(wmOperatorType *ot)
/********************** change frame operator *********************/
-static int change_frame_poll(bContext *C)
+static bool change_frame_poll(bContext *C)
{
/* prevent changes during render */
if (G.is_rendering)
diff --git a/source/blender/editors/space_image/space_image.c b/source/blender/editors/space_image/space_image.c
index 792dc25981e..907b7e51c42 100644
--- a/source/blender/editors/space_image/space_image.c
+++ b/source/blender/editors/space_image/space_image.c
@@ -387,7 +387,7 @@ static void image_keymap(struct wmKeyConfig *keyconf)
}
/* dropboxes */
-static int image_drop_poll(bContext *UNUSED(C), wmDrag *drag, const wmEvent *UNUSED(event))
+static bool image_drop_poll(bContext *UNUSED(C), wmDrag *drag, const wmEvent *UNUSED(event))
{
if (drag->type == WM_DRAG_PATH)
if (ELEM(drag->icon, 0, ICON_FILE_IMAGE, ICON_FILE_MOVIE, ICON_FILE_BLANK)) /* rule might not work? */