Three fixes;
authorTon Roosendaal <ton@blender.org>
Wed, 14 Dec 2005 20:36:04 +0000 (20:36 +0000)
committerTon Roosendaal <ton@blender.org>
Wed, 14 Dec 2005 20:36:04 +0000 (20:36 +0000)
- On file reading, a check is added to see if a Pose has channels to
  missing bones. Poses are supposed to match an Armature completely.
  (Thanks for crash file, Johnny!... but how did you do it!)

- Own collection: added depsgraph update on setting all layers (with the
  ACCENTGRAVEKEY). This also could potentially crash with modifiers

- Renamed Xkey menu in NLA to more properly tell what it does. :)

source/blender/blenloader/intern/readfile.c
source/blender/src/editnla.c
source/blender/src/header_view3d.c

index 1fb001636444c91f476e3f3480bc08b295b61b62..cb4e7546b53cfeb497311aff24d2b5f9606fbf0a 100644 (file)
@@ -1379,6 +1379,7 @@ static void lib_link_pose(FileData *fd, Object *ob, bPose *pose)
 {
        bPoseChannel *pchan;
        bArmature *arm= ob->data;
+       int rebuild= 0;
        if (!pose)
                return;
 
@@ -1386,6 +1387,12 @@ static void lib_link_pose(FileData *fd, Object *ob, bPose *pose)
                lib_link_constraints(fd, (ID *)ob, &pchan->constraints);
                // hurms... loop in a loop, but yah... later... (ton)
                pchan->bone= get_named_bone(arm, pchan->name);
+               if(pchan->bone==NULL)
+                       rebuild= 1;
+       }
+       if(rebuild) {
+               ob->recalc= OB_RECALC;
+               pose->flag |= POSE_RECALC;
        }
 }
 
index ea7821bc977d421464268c4e2870c50bbc62a671..74e3bbd1d340c185bd2824d263bb447ceb22b4f9 100644 (file)
@@ -1168,7 +1168,7 @@ void delete_nlachannel_keys(void)
        bConstraintChannel *conchan;
        bActionStrip *strip, *nextstrip;
        
-       if (!okee("Erase selected keys"))
+       if (!okee("Erase selected strips and/or keys"))
                return;
        
        for (base = G.scene->base.first; base; base=base->next){
index 2b448348034c3a03222d8396f022da5f1219670b..8a91a60067e10ee50ed8a2488ece6fc9613781b3 100644 (file)
@@ -157,6 +157,9 @@ void do_layer_buttons(short event)
                
                if(G.vd->scenelock) handle_view3d_lock();
                scrarea_queue_winredraw(curarea);
+               
+               /* new layers might need unflushed events events */
+               DAG_scene_update_flags(G.scene, G.vd->lay);     // tags all that moves and flushes
        }
        else {
                if(G.qual & LR_ALTKEY) {