Assorted comment clarification in response to code review notes

This commit is contained in:
Joshua Leung 2011-08-28 11:39:18 +00:00
parent 94b3e83b6c
commit 8e12b7b054
4 changed files with 14 additions and 7 deletions

@ -1168,7 +1168,7 @@ static short animsys_write_rna_setting (PointerRNA *ptr, char *path, int array_i
* for we know that which the updates in RNA were really just for
* flushing property editing via UI/Py
*/
if (RNA_struct_is_a(new_ptr.type, &RNA_PoseBone)) {
if (new_ptr.type == &RNA_PoseBone) {
/* bone transforms - update pose (i.e. tag depsgraph) */
skip_updates_hack = 1;
}

@ -2062,8 +2062,19 @@ static short animdata_use_time(AnimData *adt)
return 1;
}
/* experimental check: if we have drivers, more likely than not, on a frame change
/* If we have drivers, more likely than not, on a frame change
* they'll need updating because their owner changed
*
* This is kindof a hack to get around a whole host of problems
* involving drivers using non-object datablock data (which the
* depsgraph currently has no way of representing let alone correctly
* dependency sort+tagging). By doing this, at least we ensure that
* some commonly attempted drivers (such as scene -> current frame;
* see "Driver updates fail" thread on Bf-committers dated July 2)
* will work correctly, and that other non-object datablocks will have
* their drivers update at least on frame change.
*
* -- Aligorith, July 4 2011
*/
if (adt->drivers.first)
return 1;

@ -383,7 +383,6 @@ short ANIM_paste_driver (ReportList *reports, ID *id, const char rna_path[], int
/* modifiers */
copy_fmodifiers(&fcu->modifiers, &channeldriver_copypaste_buf->modifiers);
/* flags - on a per-relevant-flag basis */
/* extrapolation mode */
fcu->extend= channeldriver_copypaste_buf->extend;

@ -471,10 +471,7 @@ static void nla_draw_strip_text (AnimData *adt, NlaTrack *nlt, NlaStrip *strip,
sprintf(str, "%d) Temp-Meta", index);
}
else {
if (strip->flag & NLASTRIP_FLAG_REVERSE)
sprintf(str, "%s", strip->name);
else
sprintf(str, "%s", strip->name);
sprintf(str, strip->name);
}
/* set text color - if colors (see above) are light, draw black text, otherwise draw white */