diff options
Diffstat (limited to 'source/blender/makesrna')
-rw-r--r-- | source/blender/makesrna/intern/rna_ID.c | 2 | ||||
-rw-r--r-- | source/blender/makesrna/intern/rna_animation.c | 4 | ||||
-rw-r--r-- | source/blender/makesrna/intern/rna_gpencil.c | 2 | ||||
-rw-r--r-- | source/blender/makesrna/intern/rna_lattice.c | 2 | ||||
-rw-r--r-- | source/blender/makesrna/intern/rna_material.c | 2 | ||||
-rw-r--r-- | source/blender/makesrna/intern/rna_nla.c | 2 | ||||
-rw-r--r-- | source/blender/makesrna/intern/rna_space.c | 2 | ||||
-rw-r--r-- | source/blender/makesrna/intern/rna_vfont.c | 4 |
8 files changed, 10 insertions, 10 deletions
diff --git a/source/blender/makesrna/intern/rna_ID.c b/source/blender/makesrna/intern/rna_ID.c index 88065d29a50..f0119c7d665 100644 --- a/source/blender/makesrna/intern/rna_ID.c +++ b/source/blender/makesrna/intern/rna_ID.c @@ -126,7 +126,7 @@ static int rna_ID_name_editable(PointerRNA *ptr) return false; } - return true; + return PROP_EDITABLE; } short RNA_type_to_ID_code(StructRNA *type) diff --git a/source/blender/makesrna/intern/rna_animation.c b/source/blender/makesrna/intern/rna_animation.c index ac30c615438..165c969ebc2 100644 --- a/source/blender/makesrna/intern/rna_animation.c +++ b/source/blender/makesrna/intern/rna_animation.c @@ -97,7 +97,7 @@ static int rna_AnimData_action_editable(PointerRNA *ptr) if ((adt->flag & ADT_NLA_EDIT_ON) || (adt->actstrip) || (adt->tmpact)) return 0; else - return 1; + return PROP_EDITABLE; } static void rna_AnimData_action_set(PointerRNA *ptr, PointerRNA value) @@ -381,7 +381,7 @@ static int rna_KeyingSet_active_ksPath_editable(PointerRNA *ptr) KeyingSet *ks = (KeyingSet *)ptr->data; /* only editable if there are some paths to change to */ - return (BLI_listbase_is_empty(&ks->paths) == false); + return (BLI_listbase_is_empty(&ks->paths) == false) ? PROP_EDITABLE : 0; } static PointerRNA rna_KeyingSet_active_ksPath_get(PointerRNA *ptr) diff --git a/source/blender/makesrna/intern/rna_gpencil.c b/source/blender/makesrna/intern/rna_gpencil.c index 333220146d6..80a52a0a3d1 100644 --- a/source/blender/makesrna/intern/rna_gpencil.c +++ b/source/blender/makesrna/intern/rna_gpencil.c @@ -73,7 +73,7 @@ static int rna_GPencilLayer_active_frame_editable(PointerRNA *ptr) if (gpl->flag & GP_LAYER_LOCKED) return 0; else - return 1; + return PROP_EDITABLE; } static void rna_GPencilLayer_line_width_range(PointerRNA *ptr, int *min, int *max, diff --git a/source/blender/makesrna/intern/rna_lattice.c b/source/blender/makesrna/intern/rna_lattice.c index 60e5f6d205c..035e9d15641 100644 --- a/source/blender/makesrna/intern/rna_lattice.c +++ b/source/blender/makesrna/intern/rna_lattice.c @@ -175,7 +175,7 @@ static int rna_Lattice_size_editable(PointerRNA *ptr) { Lattice *lt = (Lattice *)ptr->data; - return lt->key == NULL; + return (lt->key == NULL) ? PROP_EDITABLE : 0; } static void rna_Lattice_points_u_set(PointerRNA *ptr, int value) diff --git a/source/blender/makesrna/intern/rna_material.c b/source/blender/makesrna/intern/rna_material.c index a1fa6ab13be..d7e566ff431 100644 --- a/source/blender/makesrna/intern/rna_material.c +++ b/source/blender/makesrna/intern/rna_material.c @@ -237,7 +237,7 @@ static int rna_Material_active_texture_editable(PointerRNA *ptr) { Material *ma = (Material *)ptr->id.data; - return has_current_material_texture(ma); + return has_current_material_texture(ma) ? PROP_EDITABLE : 0; } static PointerRNA rna_Material_active_node_material_get(PointerRNA *ptr) diff --git a/source/blender/makesrna/intern/rna_nla.c b/source/blender/makesrna/intern/rna_nla.c index 22d0144250e..0e8ed5eea8d 100644 --- a/source/blender/makesrna/intern/rna_nla.c +++ b/source/blender/makesrna/intern/rna_nla.c @@ -290,7 +290,7 @@ static int rna_NlaStrip_action_editable(PointerRNA *ptr) return 0; /* should be ok, though we may still miss some cases */ - return 1; + return PROP_EDITABLE; } static void rna_NlaStrip_action_start_frame_set(PointerRNA *ptr, float value) diff --git a/source/blender/makesrna/intern/rna_space.c b/source/blender/makesrna/intern/rna_space.c index cee98261e23..d73b2315434 100644 --- a/source/blender/makesrna/intern/rna_space.c +++ b/source/blender/makesrna/intern/rna_space.c @@ -1617,7 +1617,7 @@ static int rna_FileBrowser_FSMenuEntry_name_get_editable(PointerRNA *ptr) { FSMenuEntry *fsm = ptr->data; - return fsm->save; + return fsm->save ? PROP_EDITABLE : 0; } static void rna_FileBrowser_FSMenu_next(CollectionPropertyIterator *iter) diff --git a/source/blender/makesrna/intern/rna_vfont.c b/source/blender/makesrna/intern/rna_vfont.c index 0879f4d355d..e9ba0c78439 100644 --- a/source/blender/makesrna/intern/rna_vfont.c +++ b/source/blender/makesrna/intern/rna_vfont.c @@ -48,9 +48,9 @@ static int rna_VectorFont_filepath_editable(PointerRNA *ptr) { VFont *vfont = ptr->id.data; if (BKE_vfont_is_builtin(vfont)) { - return false; + return 0; } - return true; + return PROP_EDITABLE; } static void rna_VectorFont_reload_update(Main *UNUSED(bmain), Scene *UNUSED(scene), PointerRNA *ptr) |