[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [14610] trunk/blender/source/blender/src/ drawipo.c: Bugfix #9676; Assigning Driver to Own Object when Pinning IPO Editor
Joshua Leung
aligorith at gmail.com
Tue Apr 29 05:19:15 CEST 2008
Revision: 14610
http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=rev&root=bf-blender&revision=14610
Author: aligorith
Date: 2008-04-29 05:19:11 +0200 (Tue, 29 Apr 2008)
Log Message:
-----------
Bugfix #9676; Assigning Driver to Own Object when Pinning IPO Editor
When the IPO Editor is pinned, drivers will now be handled as if they belonged to the object that the ipo-belonged to when the ipo was pinned. This behaviour is more predictable than using the active object.
Modified Paths:
--------------
trunk/blender/source/blender/src/drawipo.c
Modified: trunk/blender/source/blender/src/drawipo.c
===================================================================
--- trunk/blender/source/blender/src/drawipo.c 2008-04-28 22:19:03 UTC (rev 14609)
+++ trunk/blender/source/blender/src/drawipo.c 2008-04-29 03:19:11 UTC (rev 14610)
@@ -1851,11 +1851,17 @@
void do_ipobuts(unsigned short event)
{
- Object *ob= OBACT;
+ Object *ob;
EditIpo *ei;
if(G.sipo->from==NULL) return;
+ /* use G.sipo->from (which should be an object) so that pinning ipo's will still work ok */
+ if(GS(G.sipo->from->name) == ID_OB)
+ ob= (Object *)(G.sipo->from);
+ else
+ ob= OBACT;
+
switch(event) {
case B_IPO_REDR:
ei= get_active_editipo();
More information about the Bf-blender-cvs
mailing list