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 <ideasman42@gmail.com>2011-02-20 18:48:01 +0300
committerCampbell Barton <ideasman42@gmail.com>2011-02-20 18:48:01 +0300
commit06aee2ef0e1c810c24b2559838e46045d708b22f (patch)
tree795408b02937d52440bfcd6fc1aa7a4da8f431d1 /source/blender/makesrna
parent8c4e95da48b3b896f012d7a1b7c89841270c40c6 (diff)
misc warnings/fixes
- WITH_OPENJPEG wasn't defined for creator.c with CMake. - remove shadowed/redefined vars. - remove some unused RNA report args. - re-arrange IMB_FILE_TYPES so IRIS is not the first format tested, since its not very common test JPEG and PNG first.
Diffstat (limited to 'source/blender/makesrna')
-rw-r--r--source/blender/makesrna/intern/rna_main_api.c6
-rw-r--r--source/blender/makesrna/intern/rna_nla.c11
-rw-r--r--source/blender/makesrna/intern/rna_object_api.c3
3 files changed, 11 insertions, 9 deletions
diff --git a/source/blender/makesrna/intern/rna_main_api.c b/source/blender/makesrna/intern/rna_main_api.c
index 56c2f44ed73..ce9785819ca 100644
--- a/source/blender/makesrna/intern/rna_main_api.c
+++ b/source/blender/makesrna/intern/rna_main_api.c
@@ -394,7 +394,7 @@ Group *rna_Main_groups_new(Main *bmain, const char *name)
{
return add_group(name);
}
-void rna_Main_groups_remove(Main *bmain, ReportList *reports, Group *group)
+void rna_Main_groups_remove(Main *bmain, Group *group)
{
unlink_group(group);
free_libblock(&bmain->group, group);
@@ -405,7 +405,7 @@ Text *rna_Main_texts_new(Main *bmain, const char *name)
{
return add_empty_text(name);
}
-void rna_Main_texts_remove(Main *bmain, ReportList *reports, Text *text)
+void rna_Main_texts_remove(Main *bmain, Text *text)
{
unlink_text(bmain, text);
free_libblock(&bmain->text, text);
@@ -1044,7 +1044,6 @@ void RNA_def_main_groups(BlenderRNA *brna, PropertyRNA *cprop)
RNA_def_function_return(func, parm);
func= RNA_def_function(srna, "remove", "rna_Main_groups_remove");
- RNA_def_function_flag(func, FUNC_USE_REPORTS);
RNA_def_function_ui_description(func, "Remove a group from the current blendfile.");
parm= RNA_def_pointer(func, "group", "Group", "", "Group to remove.");
RNA_def_property_flag(parm, PROP_REQUIRED|PROP_NEVER_NULL);
@@ -1072,7 +1071,6 @@ void RNA_def_main_texts(BlenderRNA *brna, PropertyRNA *cprop)
RNA_def_function_return(func, parm);
func= RNA_def_function(srna, "remove", "rna_Main_texts_remove");
- RNA_def_function_flag(func, FUNC_USE_REPORTS);
RNA_def_function_ui_description(func, "Remove a text from the current blendfile.");
parm= RNA_def_pointer(func, "text", "Text", "", "Text to remove.");
RNA_def_property_flag(parm, PROP_REQUIRED|PROP_NEVER_NULL);
diff --git a/source/blender/makesrna/intern/rna_nla.c b/source/blender/makesrna/intern/rna_nla.c
index f28fec75fe2..c2d38aaf038 100644
--- a/source/blender/makesrna/intern/rna_nla.c
+++ b/source/blender/makesrna/intern/rna_nla.c
@@ -317,9 +317,14 @@ static NlaStrip *rna_NlaStrip_new(NlaTrack *track, bContext *C, ReportList *repo
static void rna_NlaStrip_remove(NlaTrack *track, bContext *C, ReportList *reports, NlaStrip *strip)
{
- free_nlastrip(&track->strips, strip);
-
- WM_event_add_notifier(C, NC_ANIMATION|ND_NLA|NA_REMOVED, NULL);
+ if(BLI_findindex(&track->strips, strip) == -1) {
+ BKE_reportf(reports, RPT_ERROR, "NLA's Strip '%s' not found in track '%s'", strip->name, track->name);
+ return;
+ }
+ else {
+ free_nlastrip(&track->strips, strip);
+ WM_event_add_notifier(C, NC_ANIMATION|ND_NLA|NA_REMOVED, NULL);
+ }
}
#else
diff --git a/source/blender/makesrna/intern/rna_object_api.c b/source/blender/makesrna/intern/rna_object_api.c
index 9f1ef7396c0..43113fed2c4 100644
--- a/source/blender/makesrna/intern/rna_object_api.c
+++ b/source/blender/makesrna/intern/rna_object_api.c
@@ -302,7 +302,7 @@ static void rna_Object_create_duplilist(Object *ob, ReportList *reports, Scene *
/* ob->duplilist should now be freed with Object.free_duplilist */
}
-static void rna_Object_free_duplilist(Object *ob, ReportList *reports)
+static void rna_Object_free_duplilist(Object *ob)
{
if (ob->duplilist) {
free_object_duplilist(ob->duplilist);
@@ -451,7 +451,6 @@ void RNA_api_object(StructRNA *srna)
func= RNA_def_function(srna, "free_dupli_list", "rna_Object_free_duplilist");
RNA_def_function_ui_description(func, "Free the list of dupli objects.");
- RNA_def_function_flag(func, FUNC_USE_REPORTS);
/* Armature */
func= RNA_def_function(srna, "find_armature", "modifiers_isDeformedByArmature");