Merging r55547 through r55594 from trunk into soc-2008-mxcurioni
[blender.git] / source / blender / editors / animation / anim_channels_edit.c
index d218cc537da00f4bf327f76a064d659d5fb0d939..481430f37e487b7f9dd6d730c4617b96502517fe 100644 (file)
@@ -124,6 +124,7 @@ void ANIM_set_active_channel(bAnimContext *ac, void *data, short datatype, int f
                        case ANIMTYPE_DSMESH:
                        case ANIMTYPE_DSTEX:
                        case ANIMTYPE_DSLAT:
+                       case ANIMTYPE_DSLINESTYLE:
                        case ANIMTYPE_DSSPK:
                        {
                                /* need to verify that this data is valid for now */
@@ -169,6 +170,7 @@ void ANIM_set_active_channel(bAnimContext *ac, void *data, short datatype, int f
                        case ANIMTYPE_DSARM:
                        case ANIMTYPE_DSMESH:
                        case ANIMTYPE_DSLAT:
+                       case ANIMTYPE_DSLINESTYLE:
                        case ANIMTYPE_DSSPK:
                        {
                                /* need to verify that this data is valid for now */
@@ -249,6 +251,7 @@ void ANIM_deselect_anim_channels(bAnimContext *ac, void *data, short datatype, s
                                case ANIMTYPE_DSNTREE:
                                case ANIMTYPE_DSTEX:
                                case ANIMTYPE_DSLAT:
+                               case ANIMTYPE_DSLINESTYLE:
                                case ANIMTYPE_DSSPK:
                                {
                                        if ((ale->adt) && (ale->adt->flag & ADT_UI_SELECTED))
@@ -343,6 +346,7 @@ void ANIM_deselect_anim_channels(bAnimContext *ac, void *data, short datatype, s
                        case ANIMTYPE_DSNTREE:
                        case ANIMTYPE_DSTEX:
                        case ANIMTYPE_DSLAT:
+                       case ANIMTYPE_DSLINESTYLE:
                        case ANIMTYPE_DSSPK:
                        {
                                /* need to verify that this data is valid for now */
@@ -2260,7 +2264,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 *UNUSED(op), wmEvent *evt)
+static int animchannels_rename_invoke(bContext *C, wmOperator *UNUSED(op), const wmEvent *event)
 {
        bAnimContext ac;
        ARegion *ar;
@@ -2281,7 +2285,7 @@ static int animchannels_rename_invoke(bContext *C, wmOperator *UNUSED(op), wmEve
         *              so that the tops of channels get caught ok. Since ACHANNEL_FIRST is really ACHANNEL_HEIGHT, we simply use
         *              ACHANNEL_HEIGHT_HALF.
         */
-       UI_view2d_region_to_view(v2d, evt->mval[0], evt->mval[1], &x, &y);
+       UI_view2d_region_to_view(v2d, event->mval[0], event->mval[1], &x, &y);
        
        if (ac.datatype == ANIMCONT_NLA) {
                SpaceNla *snla = (SpaceNla *)ac.sl;
@@ -2419,6 +2423,7 @@ static int mouse_anim_channels(bAnimContext *ac, float UNUSED(x), int channel_in
                case ANIMTYPE_DSNTREE:
                case ANIMTYPE_DSTEX:
                case ANIMTYPE_DSLAT:
+               case ANIMTYPE_DSLINESTYLE:
                case ANIMTYPE_DSSPK:
                {
                        /* sanity checking... */
@@ -2594,7 +2599,7 @@ static int mouse_anim_channels(bAnimContext *ac, float UNUSED(x), int channel_in
 /* ------------------- */
 
 /* handle clicking */
-static int animchannels_mouseclick_invoke(bContext *C, wmOperator *op, wmEvent *event)
+static int animchannels_mouseclick_invoke(bContext *C, wmOperator *op, const wmEvent *event)
 {
        bAnimContext ac;
        ARegion *ar;
@@ -2652,7 +2657,7 @@ static void ANIM_OT_channels_click(wmOperatorType *ot)
        ot->poll = animedit_poll_channels_active;
        
        /* flags */
-       ot->flag = OPTYPE_REGISTER | OPTYPE_UNDO;
+       ot->flag = OPTYPE_UNDO;
        
        /* properties */
        /* NOTE: don't save settings, otherwise, can end up with some weird behaviour (sticky extend) */