Fix: Prevented depgraph to execute do_all_actions when you paste a poste.
authorTon Roosendaal <ton@blender.org>
Mon, 11 Jul 2005 15:38:51 +0000 (15:38 +0000)
committerTon Roosendaal <ton@blender.org>
Mon, 11 Jul 2005 15:38:51 +0000 (15:38 +0000)
source/blender/src/editaction.c
source/blender/src/header_action.c

index 91461c4153517bb9c601c46c149495163055adde..df2c6ab2fe5c25fc8de7093a32d70a3cf19e85e3 100644 (file)
@@ -992,6 +992,9 @@ void paste_posebuf (int flip)
                        }
                }
 
+               /* Update event for deformation children */
+               DAG_object_flush_update(G.scene, ob, OB_RECALC_DATA);
+               
                if (G.flags & G_RECORDKEYS) {
                        remake_action_ipos(ob->action);
                        allqueue (REDRAWIPO, 0);
@@ -999,9 +1002,11 @@ void paste_posebuf (int flip)
                        allqueue (REDRAWACTION, 0);             
                        allqueue(REDRAWNLA, 0);
                }
-
-               /* Update deformation children */
-               DAG_object_flush_update(G.scene, G.obpose, OB_RECALC_DATA);
+               else {
+                       /* need to trick depgraph, action is not allowed to execute on pose */
+                       where_is_pose(ob);
+                       ob->recalc= 0;
+               }
 
                BIF_undo_push("Paste Action Pose");
        }
index b918cb9f60b0a9f988e21b142552f7446c19f21e..13a004d14d1bacc423fbebe6e3cc9a904386f658 100644 (file)
@@ -161,12 +161,10 @@ void do_action_buttons(unsigned short event)
                        break;
                case B_ACTPASTE:
                        paste_posebuf(0);
-                       DAG_object_flush_update(G.scene, ob, OB_RECALC_DATA);
                        allqueue(REDRAWVIEW3D, 1);
                        break;
                case B_ACTPASTEFLIP:
                        paste_posebuf(1);
-                       DAG_object_flush_update(G.scene, ob, OB_RECALC_DATA);
                        allqueue(REDRAWVIEW3D, 1);
                        break;