diff options
author | Campbell Barton <ideasman42@gmail.com> | 2011-08-30 13:50:31 +0400 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2011-08-30 13:50:31 +0400 |
commit | 27ec8d5043f544685001aab3552b9b4b56bc1e1a (patch) | |
tree | 2daae712833a6951ae0b3ccf73010202a3b9611d /source/blender/editors | |
parent | c7dcbdb830b3db615df1722922d0d40660ac3b5e (diff) |
fix for some warnings with the recent merge, also tag unused args.
Diffstat (limited to 'source/blender/editors')
-rw-r--r-- | source/blender/editors/animation/anim_channels_defines.c | 2 | ||||
-rw-r--r-- | source/blender/editors/animation/anim_channels_edit.c | 2 | ||||
-rw-r--r-- | source/blender/editors/animation/anim_filter.c | 2 | ||||
-rw-r--r-- | source/blender/editors/armature/poseSlide.c | 6 | ||||
-rw-r--r-- | source/blender/editors/armature/poseobject.c | 4 | ||||
-rw-r--r-- | source/blender/editors/object/object_select.c | 2 | ||||
-rw-r--r-- | source/blender/editors/space_graph/graph_draw.c | 2 | ||||
-rw-r--r-- | source/blender/editors/space_nla/nla_edit.c | 12 | ||||
-rw-r--r-- | source/blender/editors/space_outliner/outliner_tools.c | 2 | ||||
-rw-r--r-- | source/blender/editors/space_view3d/drawobject.c | 33 |
10 files changed, 31 insertions, 36 deletions
diff --git a/source/blender/editors/animation/anim_channels_defines.c b/source/blender/editors/animation/anim_channels_defines.c index 806af4c0ef5..bdc654ff25a 100644 --- a/source/blender/editors/animation/anim_channels_defines.c +++ b/source/blender/editors/animation/anim_channels_defines.c @@ -1273,7 +1273,7 @@ static int acf_dstex_icon(bAnimListElem *UNUSED(ale)) /* offset for texture expanders */ // FIXME: soon to be obsolete? -static short acf_dstex_offset(bAnimContext *UNUSED(ac), bAnimListElem *ale) +static short acf_dstex_offset(bAnimContext *UNUSED(ac), bAnimListElem *UNUSED(ale)) { return 14; // XXX: simply include this in indention instead? } diff --git a/source/blender/editors/animation/anim_channels_edit.c b/source/blender/editors/animation/anim_channels_edit.c index c9d6f9a6420..d58d51c8e08 100644 --- a/source/blender/editors/animation/anim_channels_edit.c +++ b/source/blender/editors/animation/anim_channels_edit.c @@ -2018,7 +2018,7 @@ static void rename_anim_channels (bAnimContext *ac, int channel_index) ED_region_tag_redraw(ac->ar); } -static int animchannels_rename_invoke (bContext *C, wmOperator *op, wmEvent *evt) +static int animchannels_rename_invoke (bContext *C, wmOperator *UNUSED(op), wmEvent *evt) { bAnimContext ac; ARegion *ar; diff --git a/source/blender/editors/animation/anim_filter.c b/source/blender/editors/animation/anim_filter.c index 0472731dd6d..8010a41ccb3 100644 --- a/source/blender/editors/animation/anim_filter.c +++ b/source/blender/editors/animation/anim_filter.c @@ -990,7 +990,7 @@ static size_t animfilter_fcurves (ListBase *anim_data, bDopeSheet *ads, FCurve * return items; } -static size_t animfilter_act_group (bAnimContext *ac, ListBase *anim_data, bDopeSheet *ads, bAction *act, bActionGroup *agrp, int filter_mode, ID *owner_id) +static size_t animfilter_act_group (bAnimContext *ac, ListBase *anim_data, bDopeSheet *ads, bAction *UNUSED(act), bActionGroup *agrp, int filter_mode, ID *owner_id) { ListBase tmp_data = {NULL, NULL}; size_t tmp_items = 0; diff --git a/source/blender/editors/armature/poseSlide.c b/source/blender/editors/armature/poseSlide.c index 3c15ff52a30..b0ff60455cf 100644 --- a/source/blender/editors/armature/poseSlide.c +++ b/source/blender/editors/armature/poseSlide.c @@ -520,7 +520,7 @@ static void pose_slide_reset (tPoseSlideOp *pso) /* ------------------------------------ */ /* draw percentage indicator in header */ -static void pose_slide_draw_status (bContext *C, tPoseSlideOp *pso) +static void pose_slide_draw_status (tPoseSlideOp *pso) { char statusStr[32]; char mode[32]; @@ -615,7 +615,7 @@ static int pose_slide_invoke_common (bContext *C, wmOperator *op, tPoseSlideOp * WM_cursor_modal(win, BC_EW_SCROLLCURSOR); /* header print */ - pose_slide_draw_status(C, pso); + pose_slide_draw_status(pso); /* add a modal handler for this operator */ WM_event_add_modal_handler(C, op); @@ -672,7 +672,7 @@ static int pose_slide_modal (bContext *C, wmOperator *op, wmEvent *evt) RNA_float_set(op->ptr, "percentage", pso->percentage); /* update percentage indicator in header */ - pose_slide_draw_status(C, pso); + pose_slide_draw_status(pso); /* reset transforms (to avoid accumulation errors) */ pose_slide_reset(pso); diff --git a/source/blender/editors/armature/poseobject.c b/source/blender/editors/armature/poseobject.c index d2f32837d6d..3911be02fe7 100644 --- a/source/blender/editors/armature/poseobject.c +++ b/source/blender/editors/armature/poseobject.c @@ -1611,7 +1611,7 @@ static int compare_agroup(const void *sgrp_a_ptr, const void *sgrp_b_ptr) return strcmp(sgrp_a->agrp->name, sgrp_b->agrp->name); } -static int group_sort_exec(bContext *C, wmOperator *op) +static int group_sort_exec(bContext *C, wmOperator *UNUSED(op)) { Object *ob= CTX_data_pointer_get_type(C, "object", &RNA_Object).data; bPose *pose= (ob) ? ob->pose : NULL; @@ -2275,7 +2275,7 @@ void POSE_OT_quaternions_flip (wmOperatorType *ot) /* ********************************************** */ /* Clear User Transforms */ -static int pose_clear_user_transforms_exec (bContext *C, wmOperator *op) +static int pose_clear_user_transforms_exec (bContext *C, wmOperator *UNUSED(op)) { Scene *scene = CTX_data_scene(C); Object *ob = CTX_data_active_object(C); diff --git a/source/blender/editors/object/object_select.c b/source/blender/editors/object/object_select.c index b3c4ffc0ac9..cb1fc7541d0 100644 --- a/source/blender/editors/object/object_select.c +++ b/source/blender/editors/object/object_select.c @@ -600,7 +600,7 @@ static short select_grouped_keyingset(bContext *C, Object *UNUSED(ob)) */ for (ksp = ks->paths.first; ksp; ksp = ksp->next) { /* if id matches, select then stop looping (match found) */ - if (ksp->id == base->object) { + if (ksp->id == (ID *)base->object) { ED_base_object_select(base, BA_SELECT); changed = 1; break; diff --git a/source/blender/editors/space_graph/graph_draw.c b/source/blender/editors/space_graph/graph_draw.c index d65297e068d..dc5e71f0406 100644 --- a/source/blender/editors/space_graph/graph_draw.c +++ b/source/blender/editors/space_graph/graph_draw.c @@ -706,7 +706,7 @@ static void draw_fcurve_curve_bezts (bAnimContext *ac, ID *id, FCurve *fcu, View if (fcu->driver) resol= 32; else - resol= (int)(5.0*len_v2v2(bezt->vec[1], prevbezt->vec[1])); + resol= (int)(5.0f*len_v2v2(bezt->vec[1], prevbezt->vec[1])); if (resol < 2) { /* only draw one */ diff --git a/source/blender/editors/space_nla/nla_edit.c b/source/blender/editors/space_nla/nla_edit.c index 0f87be0f807..1894a9fd651 100644 --- a/source/blender/editors/space_nla/nla_edit.c +++ b/source/blender/editors/space_nla/nla_edit.c @@ -533,7 +533,7 @@ static int nlaedit_add_transition_exec (bContext *C, wmOperator *op) if ELEM(0, (s1->flag & NLASTRIP_FLAG_SELECT), (s2->flag & NLASTRIP_FLAG_SELECT)) continue; /* check if there's space between the two */ - if (IS_EQ(s1->end, s2->start)) + if (IS_EQF(s1->end, s2->start)) continue; /* make sure neither one is a transition * - although this is impossible to create with the standard tools, @@ -613,7 +613,7 @@ void NLA_OT_transition_add (wmOperatorType *ot) /* ******************** Add Sound Clip Operator ***************************** */ /* Add a new sound clip */ -static int nlaedit_add_sound_exec (bContext *C, wmOperator *op) +static int nlaedit_add_sound_exec (bContext *C, wmOperator *UNUSED(op)) { bAnimContext ac; @@ -1013,14 +1013,14 @@ static void nlaedit_split_strip_actclip (AnimData *adt, NlaTrack *nlt, NlaStrip /* strip extents */ len= strip->end - strip->start; - if (IS_EQ(len, 0.0f)) + if (IS_EQF(len, 0.0f)) return; else splitframe= strip->start + (len / 2.0f); /* action range */ len= strip->actend - strip->actstart; - if (IS_EQ(len, 0.0f)) + if (IS_EQF(len, 0.0f)) splitaframe= strip->actend; else splitaframe= strip->actstart + (len / 2.0f); @@ -1858,10 +1858,10 @@ static int nlaedit_snap_exec (bContext *C, wmOperator *op) strip->start= (float)CFRA; break; case NLAEDIT_SNAP_NEAREST_FRAME: /* to nearest frame */ - strip->start= (float)(floor(start+0.5)); + strip->start= floorf(start+0.5); break; case NLAEDIT_SNAP_NEAREST_SECOND: /* to nearest second */ - strip->start= ((float)floor(start/secf + 0.5f) * secf); + strip->start= floorf(start/secf + 0.5f) * secf; break; case NLAEDIT_SNAP_NEAREST_MARKER: /* to nearest marker */ strip->start= (float)ED_markers_find_nearest_marker_time(ac.markers, start); diff --git a/source/blender/editors/space_outliner/outliner_tools.c b/source/blender/editors/space_outliner/outliner_tools.c index 4525ea9c8d9..3ae158bd275 100644 --- a/source/blender/editors/space_outliner/outliner_tools.c +++ b/source/blender/editors/space_outliner/outliner_tools.c @@ -822,7 +822,7 @@ static void outliner_do_id_set_operation(SpaceOops *soops, int type, ListBase *l /* ------------------------------------------ */ -static void actionset_id_cb(TreeElement *te, TreeStoreElem *tselem, TreeStoreElem *tsep, ID *actId) +static void actionset_id_cb(TreeElement *UNUSED(te), TreeStoreElem *tselem, TreeStoreElem *tsep, ID *actId) { bAction *act = (bAction *)actId; diff --git a/source/blender/editors/space_view3d/drawobject.c b/source/blender/editors/space_view3d/drawobject.c index b4ccea71aa2..d573198aa10 100644 --- a/source/blender/editors/space_view3d/drawobject.c +++ b/source/blender/editors/space_view3d/drawobject.c @@ -1493,7 +1493,7 @@ static void drawcamera(Scene *scene, View3D *v3d, RegionView3D *rv3d, Object *ob } /* flag similar to draw_object() */ -static void drawspeaker(Scene *scene, View3D *v3d, RegionView3D *rv3d, Object *ob, int flag) +static void drawspeaker(Scene *UNUSED(scene), View3D *UNUSED(v3d), RegionView3D *UNUSED(rv3d), Object *UNUSED(ob), int UNUSED(flag)) { //Speaker *spk = ob->data; @@ -1502,34 +1502,29 @@ static void drawspeaker(Scene *scene, View3D *v3d, RegionView3D *rv3d, Object *o glEnable(GL_BLEND); - for(j = 0; j < 3; j++) - { - vec[2] = .25f * j -.125f; + for(j = 0; j < 3; j++) { + vec[2] = 0.25f * j -0.125f; glBegin(GL_LINE_LOOP); - for(i = 0; i < 16; i++) - { - vec[0] = cos(M_PI * i / 8.0f) * (j == 0 ? .5f : .25f); - vec[1] = sin(M_PI * i / 8.0f) * (j == 0 ? .5f : .25f); + for(i = 0; i < 16; i++) { + vec[0] = cosf(M_PI * i / 8.0f) * (j == 0 ? 0.5f : 0.25f); + vec[1] = sinf(M_PI * i / 8.0f) * (j == 0 ? 0.5f : 0.25f); glVertex3fv(vec); } glEnd(); } - for(j = 0; j < 4; j++) - { - vec[0] = (((j + 1) % 2) * (j - 1)) * .5f; - vec[1] = ((j % 2) * (j - 2)) * .5f; + for(j = 0; j < 4; j++) { + vec[0] = (((j + 1) % 2) * (j - 1)) * 0.5f; + vec[1] = ((j % 2) * (j - 2)) * 0.5f; glBegin(GL_LINE_STRIP); - for(i = 0; i < 3; i++) - { - if(i == 1) - { - vec[0] *= .5f; - vec[1] *= .5f; + for(i = 0; i < 3; i++) { + if(i == 1) { + vec[0] *= 0.5f; + vec[1] *= 0.5f; } - vec[2] = .25f * i -.125f; + vec[2] = 0.25f * i -0.125f; glVertex3fv(vec); } glEnd(); |