Fixing compiler warnings, and bad button placement from previous commit for ghosting...
authorJoshua Leung <aligorith@gmail.com>
Mon, 10 Dec 2007 08:53:15 +0000 (08:53 +0000)
committerJoshua Leung <aligorith@gmail.com>
Mon, 10 Dec 2007 08:53:15 +0000 (08:53 +0000)
source/blender/src/buttons_editing.c
source/blender/src/drawarmature.c
source/blender/src/editaction.c

index b86801c61a034b144d58ea9b335dcb19c6dc52e1..ebe7986cd75492018cbb226acd363092713abfa9 100644 (file)
@@ -3990,10 +3990,10 @@ static void editing_panel_armature_visuals(Object *ob, bArmature *arm)
                                                                                                        10, 160, 150, 20, &arm->ghosttype, 0, 0, 0, 0, "Choose range of Ghosts to draw for current Action");    
                
                if (arm->ghosttype != ARM_GHOST_KEYS)
-                       uiDefButS(block, NUM, REDRAWVIEW3D, "GStep: ", 10,120,150,20, &arm->ghostsize, 1.0f, 20.0f, 0, 0, "How many frames between Ghost instances");
+                       uiDefButS(block, NUM, REDRAWVIEW3D, "GStep: ", 10,140,120,20, &arm->ghostsize, 1.0f, 20.0f, 0, 0, "How many frames between Ghost instances");
                else
                        uiDefBut(block, LABEL, REDRAWVIEW3D, "GStep: N/A", 10,140,120,20, NULL, 0.0f, 0.0f, 0, 0, "How many frames between Ghost instances");
-               uiDefButBitS(block, TOG, ARM_GHOST_ONLYSEL, REDRAWVIEW3D, "Sel", 130, 140, 30, 20, &arm->flag, 0, 0, 0, 0, "Only show Ghosts for selected bones");
+               uiDefButBitI(block, TOG, ARM_GHOST_ONLYSEL, REDRAWVIEW3D, "Sel", 130, 140, 30, 20, &arm->flag, 0, 0, 0, 0, "Only show Ghosts for selected bones");
        uiBlockEndAlign(block);
        
        uiBlockBeginAlign(block);
index 0d747fead9ab9d049b5196141b877be37673ac69..9ec688b5d8d754fd0b2ad54d4ee52ba10243d242 100644 (file)
@@ -1944,7 +1944,6 @@ static void ghost_poses_tag_unselected(Object *ob, short unset)
        bArmature *arm= ob->data;
        bPose *pose= ob->pose;
        bPoseChannel *pchan;
-       Bone *bone;
        
        /* don't do anything if no hiding any bones */
        if ((arm->flag & ARM_GHOST_ONLYSEL)==0)
index 8913e6da503129ea1e95d36d256a73fa8db62ef3..9f9a32bd35e97067aac4bf864bba4c7762843259 100644 (file)
@@ -136,7 +136,7 @@ bActionChannel *get_hilighted_action_channel (bAction *action)
                return NULL;
 
        for (achan= action->chanbase.first; achan; achan= achan->next) {
-               if(VISIBLE_ACHAN(achan)) {
+               if (VISIBLE_ACHAN(achan)) {
                        if (SEL_ACHAN(achan) && (achan->flag & ACHAN_HILIGHTED))
                                return achan;
                }
@@ -2129,7 +2129,7 @@ void column_select_action_keys(int mode)
        actdata_filter(&act_data, filter, data, datatype);
        
        for (ale= act_data.first; ale; ale= ale->next) {
-               for(ce= elems.first; ce; ce= ce->next) {
+               for (ce= elems.first; ce; ce= ce->next) {
                        for (icu= ale->key_data; icu; icu= icu->next) {
                                BezTriple *bezt;
                                int verts = 0;
@@ -2691,7 +2691,7 @@ void winqreadactionspace(ScrArea *sa, void *spacedata, BWinEvent *evt)
                case HOMEKEY:
                        do_action_buttons(B_ACTHOME);   // header
                        break;
-
+               
                case AKEY:
                        if (mval[0]<NAMEWIDTH) {
                                deselect_action_channels (1);
@@ -2717,7 +2717,7 @@ void winqreadactionspace(ScrArea *sa, void *spacedata, BWinEvent *evt)
                                }
                        }
                        break;
-
+               
                case BKEY:
                        if (G.qual & LR_CTRLKEY) {
                                borderselect_markers();
@@ -2727,14 +2727,14 @@ void winqreadactionspace(ScrArea *sa, void *spacedata, BWinEvent *evt)
                                        borderselect_action();
                        }
                        break;
-
+               
                case CKEY:
                        /* scroll the window so the current
                         * frame is in the center.
                         */
                        center_currframe();
                        break;
-
+               
                case DKEY:
                        if (mval[0]>ACTWIDTH) {
                                if (G.qual == (LR_CTRLKEY|LR_SHIFTKEY))
@@ -2927,18 +2927,18 @@ void winqreadactionspace(ScrArea *sa, void *spacedata, BWinEvent *evt)
                 * based on user preference USER_LMOUSESELECT
                 */
                case LEFTMOUSE:
-                       if(view2dmove(LEFTMOUSE)) // only checks for sliders
+                       if (view2dmove(LEFTMOUSE)) /* only checks for sliders */
                                break;
                        else if ((G.v2d->mask.xmin==0) || (mval[0]>ACTWIDTH)) {
+                               /* moving time-marker / current frame */
                                do {
                                        getmouseco_areawin(mval);
-                                       
                                        areamouseco_to_ipoco(G.v2d, mval, &dx, &dy);
                                        
                                        cfra= (int)dx;
-                                       if(cfra< 1) cfra= 1;
+                                       if (cfra < 1) cfra= 1;
                                        
-                                       if( cfra!=CFRA ) {
+                                       if (cfra != CFRA) {
                                                CFRA= cfra;
                                                update_for_newframe();
                                                force_draw_all(0);