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:
authorCampbell Barton <campbell@blender.org>2022-02-15 12:07:54 +0300
committerFabian Schempp <fabianschempp@googlemail.com>2022-04-11 01:29:35 +0300
commitfafeb063d7b494f77c6b3397db27f242d4982307 (patch)
tree06971f9ec849f34485ff1fa7372adec199be94e8 /source/blender/editors/space_clip/clip_ops.c
parentfddaef10cfb6162d4daf7180581f3dbc2be3e8e0 (diff)
RNA: add RNA_collection_is_empty & RNA_property_collection_is_empty
Some collections needed to be iterated over to count their length. Provide a function to check if the collection is empty to avoid this.
Diffstat (limited to 'source/blender/editors/space_clip/clip_ops.c')
-rw-r--r--source/blender/editors/space_clip/clip_ops.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/source/blender/editors/space_clip/clip_ops.c b/source/blender/editors/space_clip/clip_ops.c
index 64ac20123d9..311f3719864 100644
--- a/source/blender/editors/space_clip/clip_ops.c
+++ b/source/blender/editors/space_clip/clip_ops.c
@@ -186,7 +186,7 @@ static int open_exec(bContext *C, wmOperator *op)
MovieClip *clip = NULL;
char str[FILE_MAX];
- if (RNA_collection_length(op->ptr, "files")) {
+ if (!RNA_collection_is_empty(op->ptr, "files")) {
PointerRNA fileptr;
PropertyRNA *prop;
char dir_only[FILE_MAX], file_only[FILE_MAX];