diff options
Diffstat (limited to 'source/blender/editors/animation')
-rw-r--r-- | source/blender/editors/animation/anim_channels_defines.c | 14 | ||||
-rw-r--r-- | source/blender/editors/animation/anim_channels_edit.c | 34 | ||||
-rw-r--r-- | source/blender/editors/animation/anim_draw.c | 4 | ||||
-rw-r--r-- | source/blender/editors/animation/anim_filter.c | 2 | ||||
-rw-r--r-- | source/blender/editors/animation/anim_ipo_utils.c | 4 | ||||
-rw-r--r-- | source/blender/editors/animation/anim_markers.c | 4 | ||||
-rw-r--r-- | source/blender/editors/animation/anim_ops.c | 9 | ||||
-rw-r--r-- | source/blender/editors/animation/drivers.c | 13 | ||||
-rw-r--r-- | source/blender/editors/animation/keyframing.c | 4 | ||||
-rw-r--r-- | source/blender/editors/animation/keyingsets.c | 4 |
10 files changed, 49 insertions, 43 deletions
diff --git a/source/blender/editors/animation/anim_channels_defines.c b/source/blender/editors/animation/anim_channels_defines.c index b2ee2f008f5..583f2f151ac 100644 --- a/source/blender/editors/animation/anim_channels_defines.c +++ b/source/blender/editors/animation/anim_channels_defines.c @@ -464,7 +464,7 @@ static void *acf_summary_setting_ptr(bAnimListElem *ale, int setting, short *typ else { /* can't return anything useful - unsupported */ *type= 0; - return 0; + return NULL; } } @@ -565,7 +565,7 @@ static void *acf_scene_setting_ptr(bAnimListElem *ale, int setting, short *type) return NULL; default: /* unsupported */ - return 0; + return NULL; } } @@ -709,7 +709,7 @@ static void *acf_object_setting_ptr(bAnimListElem *ale, int setting, short *type return NULL; default: /* unsupported */ - return 0; + return NULL; } } @@ -990,13 +990,13 @@ static void *acf_fillactd_setting_ptr(bAnimListElem *ale, int setting, short *ty GET_ACF_FLAG_PTR(adt->flag); } else - return 0; + return NULL; case ACHANNEL_SETTING_EXPAND: /* expanded */ GET_ACF_FLAG_PTR(act->flag); default: /* unsupported */ - return 0; + return NULL; } } @@ -1074,7 +1074,7 @@ static void *acf_filldrivers_setting_ptr(bAnimListElem *ale, int setting, short GET_ACF_FLAG_PTR(adt->flag); default: /* unsupported */ - return 0; + return NULL; } } @@ -2564,7 +2564,7 @@ static bAnimChannelType *animchannelTypeInfo[ANIMTYPE_NUM_TYPES]; static short ACF_INIT= 1; /* when non-zero, the list needs to be updated */ /* Initialise type info definitions */ -void ANIM_init_channel_typeinfo_data (void) +static void ANIM_init_channel_typeinfo_data (void) { int type= 0; diff --git a/source/blender/editors/animation/anim_channels_edit.c b/source/blender/editors/animation/anim_channels_edit.c index 31209459bde..f08aa4c53e9 100644 --- a/source/blender/editors/animation/anim_channels_edit.c +++ b/source/blender/editors/animation/anim_channels_edit.c @@ -527,7 +527,7 @@ void ANIM_fcurve_delete_from_animdata (bAnimContext *ac, AnimData *adt, FCurve * /* ****************** Operator Utilities ********************************** */ /* poll callback for being in an Animation Editor channels list region */ -int animedit_poll_channels_active (bContext *C) +static int animedit_poll_channels_active (bContext *C) { ScrArea *sa= CTX_wm_area(C); @@ -543,7 +543,7 @@ int animedit_poll_channels_active (bContext *C) } /* poll callback for Animation Editor channels list region + not in NLA-tweakmode for NLA */ -int animedit_poll_channels_nla_tweakmode_off (bContext *C) +static int animedit_poll_channels_nla_tweakmode_off (bContext *C) { ScrArea *sa= CTX_wm_area(C); Scene *scene = CTX_data_scene(C); @@ -1067,7 +1067,7 @@ static int animchannels_rearrange_exec(bContext *C, wmOperator *op) return OPERATOR_FINISHED; } -void ANIM_OT_channels_move (wmOperatorType *ot) +static void ANIM_OT_channels_move (wmOperatorType *ot) { /* identifiers */ ot->name= "Move Channels"; @@ -1170,7 +1170,7 @@ static int animchannels_delete_exec(bContext *C, wmOperator *UNUSED(op)) return OPERATOR_FINISHED; } -void ANIM_OT_channels_delete (wmOperatorType *ot) +static void ANIM_OT_channels_delete (wmOperatorType *ot) { /* identifiers */ ot->name= "Delete Channels"; @@ -1247,7 +1247,7 @@ static int animchannels_visibility_set_exec(bContext *C, wmOperator *UNUSED(op)) return OPERATOR_FINISHED; } -void ANIM_OT_channels_visibility_set (wmOperatorType *ot) +static void ANIM_OT_channels_visibility_set (wmOperatorType *ot) { /* identifiers */ ot->name= "Set Visibility"; @@ -1320,7 +1320,7 @@ static int animchannels_visibility_toggle_exec(bContext *C, wmOperator *UNUSED(o return OPERATOR_FINISHED; } -void ANIM_OT_channels_visibility_toggle (wmOperatorType *ot) +static void ANIM_OT_channels_visibility_toggle (wmOperatorType *ot) { /* identifiers */ ot->name= "Toggle Visibility"; @@ -1452,7 +1452,7 @@ static int animchannels_setflag_exec(bContext *C, wmOperator *op) } -void ANIM_OT_channels_setting_enable (wmOperatorType *ot) +static void ANIM_OT_channels_setting_enable (wmOperatorType *ot) { /* identifiers */ ot->name= "Enable Channel Setting"; @@ -1474,7 +1474,7 @@ void ANIM_OT_channels_setting_enable (wmOperatorType *ot) ot->prop= RNA_def_enum(ot->srna, "type", prop_animchannel_settings_types, 0, "Type", ""); } -void ANIM_OT_channels_setting_disable (wmOperatorType *ot) +static void ANIM_OT_channels_setting_disable (wmOperatorType *ot) { /* identifiers */ ot->name= "Disable Channel Setting"; @@ -1496,7 +1496,7 @@ void ANIM_OT_channels_setting_disable (wmOperatorType *ot) ot->prop= RNA_def_enum(ot->srna, "type", prop_animchannel_settings_types, 0, "Type", ""); } -void ANIM_OT_channels_setting_invert (wmOperatorType *ot) +static void ANIM_OT_channels_setting_invert (wmOperatorType *ot) { /* identifiers */ ot->name= "Invert Channel Setting"; @@ -1518,7 +1518,7 @@ void ANIM_OT_channels_setting_invert (wmOperatorType *ot) ot->prop= RNA_def_enum(ot->srna, "type", prop_animchannel_settings_types, 0, "Type", ""); } -void ANIM_OT_channels_setting_toggle (wmOperatorType *ot) +static void ANIM_OT_channels_setting_toggle (wmOperatorType *ot) { /* identifiers */ ot->name= "Toggle Channel Setting"; @@ -1540,7 +1540,7 @@ void ANIM_OT_channels_setting_toggle (wmOperatorType *ot) ot->prop= RNA_def_enum(ot->srna, "type", prop_animchannel_settings_types, 0, "Type", ""); } -void ANIM_OT_channels_editable_toggle (wmOperatorType *ot) +static void ANIM_OT_channels_editable_toggle (wmOperatorType *ot) { /* identifiers */ ot->name= "Toggle Channel Editability"; @@ -1585,7 +1585,7 @@ static int animchannels_expand_exec (bContext *C, wmOperator *op) return OPERATOR_FINISHED; } -void ANIM_OT_channels_expand (wmOperatorType *ot) +static void ANIM_OT_channels_expand (wmOperatorType *ot) { /* identifiers */ ot->name= "Expand Channels"; @@ -1627,7 +1627,7 @@ static int animchannels_collapse_exec (bContext *C, wmOperator *op) return OPERATOR_FINISHED; } -void ANIM_OT_channels_collapse (wmOperatorType *ot) +static void ANIM_OT_channels_collapse (wmOperatorType *ot) { /* identifiers */ ot->name= "Collapse Channels"; @@ -1694,7 +1694,7 @@ static int animchannels_enable_exec (bContext *C, wmOperator *UNUSED(op)) return OPERATOR_FINISHED; } -void ANIM_OT_channels_fcurves_enable (wmOperatorType *ot) +static void ANIM_OT_channels_fcurves_enable (wmOperatorType *ot) { /* identifiers */ ot->name= "Revive Disabled F-Curves"; @@ -1731,7 +1731,7 @@ static int animchannels_deselectall_exec (bContext *C, wmOperator *op) return OPERATOR_FINISHED; } -void ANIM_OT_channels_select_all_toggle (wmOperatorType *ot) +static void ANIM_OT_channels_select_all_toggle (wmOperatorType *ot) { /* identifiers */ ot->name= "Select All"; @@ -1856,7 +1856,7 @@ static int animchannels_borderselect_exec(bContext *C, wmOperator *op) return OPERATOR_FINISHED; } -void ANIM_OT_channels_select_border(wmOperatorType *ot) +static void ANIM_OT_channels_select_border(wmOperatorType *ot) { /* identifiers */ ot->name= "Border Select"; @@ -2177,7 +2177,7 @@ static int animchannels_mouseclick_invoke(bContext *C, wmOperator *op, wmEvent * return OPERATOR_FINISHED; } -void ANIM_OT_channels_click (wmOperatorType *ot) +static void ANIM_OT_channels_click (wmOperatorType *ot) { /* identifiers */ ot->name= "Mouse Click on Channels"; diff --git a/source/blender/editors/animation/anim_draw.c b/source/blender/editors/animation/anim_draw.c index dd27de883b3..8a165b9c71b 100644 --- a/source/blender/editors/animation/anim_draw.c +++ b/source/blender/editors/animation/anim_draw.c @@ -232,7 +232,7 @@ void ANIM_draw_cfra (const bContext *C, View2D *v2d, short flag) /* Draw dark green line if slow-parenting/time-offset is enabled */ if (flag & DRAWCFRA_SHOW_TIMEOFS) { - Object *ob= (scene->basact) ? (scene->basact->object) : 0; + Object *ob= OBACT; if(ob) { float timeoffset= give_timeoffset(ob); // XXX ob->ipoflag is depreceated! @@ -352,7 +352,7 @@ static short bezt_nlamapping_apply(KeyframeEditData *ked, BezTriple *bezt) */ void ANIM_nla_mapping_apply_fcurve (AnimData *adt, FCurve *fcu, short restore, short only_keys) { - KeyframeEditData ked= {{0}}; + KeyframeEditData ked= {{NULL}}; KeyframeEditFunc map_cb; /* init edit data diff --git a/source/blender/editors/animation/anim_filter.c b/source/blender/editors/animation/anim_filter.c index 6d36daa854c..af168955e32 100644 --- a/source/blender/editors/animation/anim_filter.c +++ b/source/blender/editors/animation/anim_filter.c @@ -427,7 +427,7 @@ short ANIM_animdata_get_context (const bContext *C, bAnimContext *ac) /* this function allocates memory for a new bAnimListElem struct for the * provided animation channel-data. */ -bAnimListElem *make_new_animlistelem (void *data, short datatype, void *owner, short ownertype, ID *owner_id) +static bAnimListElem *make_new_animlistelem (void *data, short datatype, void *owner, short ownertype, ID *owner_id) { bAnimListElem *ale= NULL; diff --git a/source/blender/editors/animation/anim_ipo_utils.c b/source/blender/editors/animation/anim_ipo_utils.c index 3e2212c15bb..023fd7e4efe 100644 --- a/source/blender/editors/animation/anim_ipo_utils.c +++ b/source/blender/editors/animation/anim_ipo_utils.c @@ -41,10 +41,10 @@ #include "DNA_anim_types.h" - - #include "RNA_access.h" +#include "ED_anim_api.h" + /* ----------------------- Getter functions ----------------------- */ /* Write into "name" buffer, the name of the property (retrieved using RNA from the curve's settings), diff --git a/source/blender/editors/animation/anim_markers.c b/source/blender/editors/animation/anim_markers.c index 7e9b52cd4e0..5708c584964 100644 --- a/source/blender/editors/animation/anim_markers.c +++ b/source/blender/editors/animation/anim_markers.c @@ -205,7 +205,7 @@ void ED_markers_get_minmax (ListBase *markers, short sel, float *first, float *l /* --------------------------------- */ /* Adds a marker to list of cfra elems */ -void add_marker_to_cfra_elem(ListBase *lb, TimeMarker *marker, short only_sel) +static void add_marker_to_cfra_elem(ListBase *lb, TimeMarker *marker, short only_sel) { CfraElem *ce, *cen; @@ -269,7 +269,7 @@ TimeMarker *ED_markers_get_first_selected(ListBase *markers) /* Print debugging prints of list of markers * BSI's: do NOT make static or put in if-defs as "unused code". That's too much trouble when we need to use for quick debuggging! */ -void debug_markers_print_list(ListBase *markers) +static void debug_markers_print_list(ListBase *markers) { TimeMarker *marker; diff --git a/source/blender/editors/animation/anim_ops.c b/source/blender/editors/animation/anim_ops.c index 6b0fa30b096..a641b3d1db4 100644 --- a/source/blender/editors/animation/anim_ops.c +++ b/source/blender/editors/animation/anim_ops.c @@ -47,6 +47,7 @@ #include "WM_api.h" #include "WM_types.h" +#include "ED_anim_api.h" #include "ED_screen.h" #include "anim_intern.h" @@ -153,7 +154,7 @@ static int change_frame_modal(bContext *C, wmOperator *op, wmEvent *event) return OPERATOR_RUNNING_MODAL; } -void ANIM_OT_change_frame(wmOperatorType *ot) +static void ANIM_OT_change_frame(wmOperatorType *ot) { /* identifiers */ ot->name= "Change frame"; @@ -208,7 +209,7 @@ static int previewrange_define_exec(bContext *C, wmOperator *op) return OPERATOR_FINISHED; } -void ANIM_OT_previewrange_set(wmOperatorType *ot) +static void ANIM_OT_previewrange_set(wmOperatorType *ot) { /* identifiers */ ot->name= "Set Preview Range"; @@ -255,7 +256,7 @@ static int previewrange_clear_exec(bContext *C, wmOperator *UNUSED(op)) return OPERATOR_FINISHED; } -void ANIM_OT_previewrange_clear(wmOperatorType *ot) +static void ANIM_OT_previewrange_clear(wmOperatorType *ot) { /* identifiers */ ot->name= "Clear Preview Range"; @@ -323,7 +324,7 @@ static int toggle_time_exec(bContext *C, wmOperator *UNUSED(op)) return OPERATOR_FINISHED; } -void ANIM_OT_time_toggle(wmOperatorType *ot) +static void ANIM_OT_time_toggle(wmOperatorType *ot) { /* identifiers */ ot->name= "Toggle Frames/Seconds"; diff --git a/source/blender/editors/animation/drivers.c b/source/blender/editors/animation/drivers.c index 8d74e7b1b59..e5edce4414a 100644 --- a/source/blender/editors/animation/drivers.c +++ b/source/blender/editors/animation/drivers.c @@ -60,6 +60,11 @@ #include "RNA_access.h" #include "RNA_define.h" +#include "anim_intern.h" + +/* called by WM */ +void free_anim_drivers_copybuf (void); + /* ************************************************** */ /* Animation Data Validation */ @@ -475,7 +480,7 @@ static char *get_driver_path_hack (bContext *C, PointerRNA *ptr, PropertyRNA *pr static int add_driver_button_exec (bContext *C, wmOperator *op) { - PointerRNA ptr= {{0}}; + PointerRNA ptr= {{NULL}}; PropertyRNA *prop= NULL; short success= 0; int index, all= RNA_boolean_get(op->ptr, "all"); @@ -531,7 +536,7 @@ void ANIM_OT_driver_button_add (wmOperatorType *ot) static int remove_driver_button_exec (bContext *C, wmOperator *op) { - PointerRNA ptr= {{0}}; + PointerRNA ptr= {{NULL}}; PropertyRNA *prop= NULL; short success= 0; int index, all= RNA_boolean_get(op->ptr, "all"); @@ -583,7 +588,7 @@ void ANIM_OT_driver_button_remove (wmOperatorType *ot) static int copy_driver_button_exec (bContext *C, wmOperator *op) { - PointerRNA ptr= {{0}}; + PointerRNA ptr= {{NULL}}; PropertyRNA *prop= NULL; short success= 0; int index; @@ -627,7 +632,7 @@ void ANIM_OT_copy_driver_button (wmOperatorType *ot) static int paste_driver_button_exec (bContext *C, wmOperator *op) { - PointerRNA ptr= {{0}}; + PointerRNA ptr= {{NULL}}; PropertyRNA *prop= NULL; short success= 0; int index; diff --git a/source/blender/editors/animation/keyframing.c b/source/blender/editors/animation/keyframing.c index 39deb417b26..67be382e600 100644 --- a/source/blender/editors/animation/keyframing.c +++ b/source/blender/editors/animation/keyframing.c @@ -1367,7 +1367,7 @@ static int insert_key_button_exec (bContext *C, wmOperator *op) { Main *bmain= CTX_data_main(C); Scene *scene= CTX_data_scene(C); - PointerRNA ptr= {{0}}; + PointerRNA ptr= {{NULL}}; PropertyRNA *prop= NULL; char *path; float cfra= (float)CFRA; // XXX for now, don't bother about all the yucky offset crap @@ -1456,7 +1456,7 @@ static int delete_key_button_exec (bContext *C, wmOperator *op) { Main *bmain= CTX_data_main(C); Scene *scene= CTX_data_scene(C); - PointerRNA ptr= {{0}}; + PointerRNA ptr= {{NULL}}; PropertyRNA *prop= NULL; char *path; float cfra= (float)CFRA; // XXX for now, don't bother about all the yucky offset crap diff --git a/source/blender/editors/animation/keyingsets.c b/source/blender/editors/animation/keyingsets.c index 2df7d21e907..40c2f3c3797 100644 --- a/source/blender/editors/animation/keyingsets.c +++ b/source/blender/editors/animation/keyingsets.c @@ -288,7 +288,7 @@ static int add_keyingset_button_exec (bContext *C, wmOperator *op) Scene *scene= CTX_data_scene(C); KeyingSet *ks = NULL; PropertyRNA *prop= NULL; - PointerRNA ptr= {{0}}; + PointerRNA ptr= {{NULL}}; char *path = NULL; short success= 0; int index=0, pflag=0; @@ -388,7 +388,7 @@ static int remove_keyingset_button_exec (bContext *C, wmOperator *op) Scene *scene= CTX_data_scene(C); KeyingSet *ks = NULL; PropertyRNA *prop= NULL; - PointerRNA ptr= {{0}}; + PointerRNA ptr= {{NULL}}; char *path = NULL; short success= 0; int index=0; |