Various fixes in rna_*_api.c files to remove compiler warnings.
authorArystanbek Dyussenov <arystan.d@gmail.com>
Wed, 19 Aug 2009 09:52:13 +0000 (09:52 +0000)
committerArystanbek Dyussenov <arystan.d@gmail.com>
Wed, 19 Aug 2009 09:52:13 +0000 (09:52 +0000)
13 files changed:
source/blender/editors/include/ED_mesh.h
source/blender/editors/mesh/editmesh_mods.c
source/blender/makesrna/intern/rna_action_api.c
source/blender/makesrna/intern/rna_image_api.c
source/blender/makesrna/intern/rna_internal.h
source/blender/makesrna/intern/rna_mesh_api.c
source/blender/makesrna/intern/rna_object_api.c
source/blender/makesrna/intern/rna_pose_api.c
source/blender/makesrna/intern/rna_scene_api.c
source/blender/python/SConscript
source/creator/creator.c
source/creator/tests/test.c [moved from source/creator/tests/alltest.c with 100% similarity]
source/creator/tests/test.h [new file with mode: 0644]

index cceebeadc968c1ef2efb83da7751dcc13d88d71e..696e8f823eb76d4c0db9354a2b8a968a81e889df 100644 (file)
@@ -118,6 +118,7 @@ void                EM_select_face(struct EditFace *efa, int sel);
 void           EM_select_face_fgon(struct EditMesh *em, struct EditFace *efa, int val);
 void           EM_select_swap(struct EditMesh *em);
 void           EM_toggle_select_all(struct EditMesh *em);
+void EM_select_all(struct EditMesh *em);
 void           EM_selectmode_flush(struct EditMesh *em);
 void           EM_deselect_flush(struct EditMesh *em);
 void           EM_selectmode_set(struct EditMesh *em);
index d27aa3f7e3a31ef90b4af956b115b4cf0eeabab7..363b6ecc4e4d00748bada132e189315ac6a44194 100644 (file)
@@ -3288,6 +3288,11 @@ void EM_toggle_select_all(EditMesh *em) /* exported for UV */
                EM_set_flag_all(em, SELECT);
 }
 
+void EM_select_all(EditMesh *em)
+{
+       EM_set_flag_all(em, SELECT);
+}
+
 static int toggle_select_all_exec(bContext *C, wmOperator *op)
 {
        Object *obedit= CTX_data_edit_object(C);
index 2b51a424fcf4ca3306d2d1068572ae783252e9d8..11efa6d5f8ab6458e3373be2b9243f60ef7de2e3 100644 (file)
@@ -36,6 +36,8 @@
 
 #ifdef RNA_RUNTIME
 
+#include "BKE_action.h"
+
 #include "DNA_anim_types.h"
 #include "DNA_curve_types.h"
 
index ccc9846600dfdb3d7e822132d5a345e94cba425d..fee379cd285939c2f0a790898acbdede383229ea 100644 (file)
@@ -41,6 +41,8 @@
 #include "BKE_utildefines.h"
 #include "BKE_image.h"
 
+#include "MEM_guardedalloc.h"
+
 /*
   User should check if returned path exists before copying a file there.
 
index cff77fbb34b3a8d82d3ab19fbaebd493137d639e..af94f0ccc6fb3c9388b85dd5d020fb6541a177d8 100644 (file)
@@ -197,13 +197,15 @@ void rna_Object_update_data(struct bContext *C, struct PointerRNA *ptr);
 
 /* API functions */
 
+void RNA_api_action(StructRNA *srna);
+void RNA_api_image(struct StructRNA *srna);
 void RNA_api_main(struct StructRNA *srna);
+void RNA_api_material(StructRNA *srna);
 void RNA_api_mesh(struct StructRNA *srna);
 void RNA_api_object(struct StructRNA *srna);
+void RNA_api_scene(struct StructRNA *srna); 
 void RNA_api_ui_layout(struct StructRNA *srna);
 void RNA_api_wm(struct StructRNA *srna);
-void RNA_api_scene(struct StructRNA *srna); 
-void RNA_api_material(StructRNA *srna);
 
 /* ID Properties */
 
index 9d4dad1fb5b4e0c671fe6c752007892079d4589d..1db2f155d145b1375c8fad9d1009645959736c96 100644 (file)
@@ -42,6 +42,7 @@
 #include "BKE_DerivedMesh.h"
 #include "BKE_main.h"
 #include "BKE_mesh.h"
+#include "BKE_material.h"
 
 #include "DNA_mesh_types.h"
 #include "DNA_scene_types.h"
@@ -52,6 +53,8 @@
 #include "WM_api.h"
 #include "WM_types.h"
 
+#include "MEM_guardedalloc.h"
+
 static void rna_Mesh_calc_edges(Mesh *mesh)
 {
        CustomData edata;
index f0a42987848836a9787dfea1d563bf15e244e196..3c79c1cbc212ddf15be13137a8342d84a6a0ca12 100644 (file)
@@ -273,7 +273,7 @@ static void rna_Object_convert_to_triface(Object *ob, bContext *C, ReportList *r
                make_editMesh(sce, ob);
 
        /* select all */
-       EM_set_flag_all(me->edit_mesh, SELECT);
+       EM_select_all(me->edit_mesh);
 
        convert_to_triface(me->edit_mesh, 0);
 
index 9ac7713b2e90342d7510b06dbb173c1496cae505..42bb52d854485f4f6e66d60d90eb650885faf715 100644 (file)
@@ -45,8 +45,8 @@
 
 void RNA_api_pose(StructRNA *srna)
 {
-       FunctionRNA *func;
-       PropertyRNA *parm;
+       /* FunctionRNA *func; */
+       /* PropertyRNA *parm; */
 
 }
 
index f3cbb630df5a07b6b4cb94f64b95b443ae17aef6..076fe38ed2fdfa53c4455fddedb70d6486b1f87f 100644 (file)
 #ifdef RNA_RUNTIME
 
 #include "BKE_scene.h"
+#include "BKE_depsgraph.h"
+
 #include "ED_object.h"
 
+#include "WM_api.h"
+
 static void rna_Scene_add_object(Scene *sce, ReportList *reports, Object *ob)
 {
        Base *base= object_in_scene(ob, sce);
index 357d2c99d3bfc01d8e7771e219c7a453b9730321..d44cf762a0f2b42ecfac2c5c0851bfe66dacb799 100644 (file)
@@ -3,7 +3,7 @@ Import ('env')
 
 sources = env.Glob('intern/*.c')
 
-incs = '. ../editors/include ../makesdna ../makesrna ../makesrna/intern ../blenlib ../blenkernel ../nodes'
+incs = '. ../editors/include ../makesdna ../makesrna ../blenlib ../blenkernel ../nodes'
 incs += ' ../imbuf ../blenloader ../render/extern/include ../windowmanager'
 incs += ' #intern/guardedalloc #intern/memutil #extern/glew/include'
 incs += ' ' + env['BF_PYTHON_INC']
index e196213c94503d5b5866e0bd925aea1accba4810..6ecde9e5546e5b7d4bb07e82a01b1f66588b6df9 100644 (file)
 #include "binreloc.h"
 #endif
 
+#ifdef WITH_UNIT_TEST
+#include "tests/test.h"
+#endif
+
 // from buildinfo.c
 #ifdef BUILD_DATE
 extern char * build_date;
diff --git a/source/creator/tests/test.h b/source/creator/tests/test.h
new file mode 100644 (file)
index 0000000..37bdab3
--- /dev/null
@@ -0,0 +1,6 @@
+#ifndef _BF_UNIT_TEST
+#define _BF_UNIT_TEST
+
+int run_tests();
+
+#endif  /* _BF_UNIT_TEST */