[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [52496] trunk/blender/source/blender/ editors/curve/editcurve.c: Style: AnimData vars should be named "adt" NOT " ad"

Joshua Leung aligorith at gmail.com
Thu Nov 22 23:58:02 CET 2012


Revision: 52496
          http://projects.blender.org/scm/viewvc.php?view=rev&root=bf-blender&revision=52496
Author:   aligorith
Date:     2012-11-22 22:58:01 +0000 (Thu, 22 Nov 2012)
Log Message:
-----------
Style: AnimData vars should be named "adt" NOT "ad"

Modified Paths:
--------------
    trunk/blender/source/blender/editors/curve/editcurve.c

Modified: trunk/blender/source/blender/editors/curve/editcurve.c
===================================================================
--- trunk/blender/source/blender/editors/curve/editcurve.c	2012-11-22 22:38:31 UTC (rev 52495)
+++ trunk/blender/source/blender/editors/curve/editcurve.c	2012-11-22 22:58:01 UTC (rev 52496)
@@ -1069,7 +1069,7 @@
 	Nurb *nu = editnurb->nurbs.first;
 	CVKeyIndex *keyIndex;
 	char rna_path[64], orig_rna_path[64];
-	AnimData *ad = BKE_animdata_from_id(&cu->id);
+	AnimData *adt = BKE_animdata_from_id(&cu->id);
 	ListBase curves = {NULL, NULL};
 	FCurve *fcu, *next;
 
@@ -1089,14 +1089,14 @@
 						char handle_path[64], orig_handle_path[64];
 						BLI_snprintf(orig_handle_path, sizeof(orig_rna_path), "%s.handle_left", orig_rna_path);
 						BLI_snprintf(handle_path, sizeof(rna_path), "%s.handle_right", rna_path);
-						fcurve_path_rename(ad, orig_handle_path, handle_path, orig_curves, &curves);
+						fcurve_path_rename(adt, orig_handle_path, handle_path, orig_curves, &curves);
 
 						BLI_snprintf(orig_handle_path, sizeof(orig_rna_path), "%s.handle_right", orig_rna_path);
 						BLI_snprintf(handle_path, sizeof(rna_path), "%s.handle_left", rna_path);
-						fcurve_path_rename(ad, orig_handle_path, handle_path, orig_curves, &curves);
+						fcurve_path_rename(adt, orig_handle_path, handle_path, orig_curves, &curves);
 					}
 
-					fcurve_path_rename(ad, orig_rna_path, rna_path, orig_curves, &curves);
+					fcurve_path_rename(adt, orig_rna_path, rna_path, orig_curves, &curves);
 
 					keyIndex->nu_index = nu_index;
 					keyIndex->pt_index = pt_index;
@@ -1116,7 +1116,7 @@
 				if (keyIndex) {
 					BLI_snprintf(rna_path, sizeof(rna_path), "splines[%d].points[%d]", nu_index, pt_index);
 					BLI_snprintf(orig_rna_path, sizeof(orig_rna_path), "splines[%d].points[%d]", keyIndex->nu_index, keyIndex->pt_index);
-					fcurve_path_rename(ad, orig_rna_path, rna_path, orig_curves, &curves);
+					fcurve_path_rename(adt, orig_rna_path, rna_path, orig_curves, &curves);
 
 					keyIndex->nu_index = nu_index;
 					keyIndex->pt_index = pt_index;
@@ -1140,7 +1140,7 @@
 			char *ch = strchr(fcu->rna_path, '.');
 
 			if (ch && (!strncmp(ch, ".bezier_points", 14) || !strncmp(ch, ".points", 7)))
-				fcurve_remove(ad, orig_curves, fcu);
+				fcurve_remove(adt, orig_curves, fcu);
 		}
 	}
 
@@ -1156,7 +1156,7 @@
 		if (keyIndex) {
 			BLI_snprintf(rna_path, sizeof(rna_path), "splines[%d]", nu_index);
 			BLI_snprintf(orig_rna_path, sizeof(orig_rna_path), "splines[%d]", keyIndex->nu_index);
-			fcurve_path_rename(ad, orig_rna_path, rna_path, orig_curves, &curves);
+			fcurve_path_rename(adt, orig_rna_path, rna_path, orig_curves, &curves);
 		}
 
 		nu_index++;
@@ -1168,7 +1168,7 @@
 	for (fcu = orig_curves->first; fcu; fcu = next) {
 		next = fcu->next;
 
-		if (!strncmp(fcu->rna_path, "splines", 7)) fcurve_remove(ad, orig_curves, fcu);
+		if (!strncmp(fcu->rna_path, "splines", 7)) fcurve_remove(adt, orig_curves, fcu);
 		else BLI_addtail(&curves, fcu);
 	}
 
@@ -1178,14 +1178,14 @@
 /* return 0 if animation data wasn't changed, 1 otherwise */
 int ED_curve_updateAnimPaths(Curve *cu)
 {
-	AnimData *ad = BKE_animdata_from_id(&cu->id);
+	AnimData *adt = BKE_animdata_from_id(&cu->id);
 
 	if (!curve_is_animated(cu)) return 0;
 
-	if (ad->action)
-		curve_rename_fcurves(cu, &ad->action->curves);
+	if (adt->action)
+		curve_rename_fcurves(cu, &adt->action->curves);
 
-	curve_rename_fcurves(cu, &ad->drivers);
+	curve_rename_fcurves(cu, &adt->drivers);
 
 	return 1;
 }




More information about the Bf-blender-cvs mailing list