[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [41302] trunk/blender/source/blender: Typos and formatting fixes
Joshua Leung
aligorith at gmail.com
Thu Oct 27 03:05:57 CEST 2011
Revision: 41302
http://projects.blender.org/scm/viewvc.php?view=rev&root=bf-blender&revision=41302
Author: aligorith
Date: 2011-10-27 01:05:55 +0000 (Thu, 27 Oct 2011)
Log Message:
-----------
Typos and formatting fixes
Modified Paths:
--------------
trunk/blender/source/blender/editors/gpencil/gpencil_paint.c
trunk/blender/source/blender/makesrna/intern/rna_action.c
Modified: trunk/blender/source/blender/editors/gpencil/gpencil_paint.c
===================================================================
--- trunk/blender/source/blender/editors/gpencil/gpencil_paint.c 2011-10-26 22:46:06 UTC (rev 41301)
+++ trunk/blender/source/blender/editors/gpencil/gpencil_paint.c 2011-10-27 01:05:55 UTC (rev 41302)
@@ -385,9 +385,10 @@
pt->y= mval[1];
pt->pressure= pressure;
- /* if there's stroke fir this poly line session add (or replace last) point
- to stroke. This allows to draw lines more interactively (see new segment
- during mouse slide, i.e.) */
+ /* if there's stroke for this poly line session add (or replace last) point
+ * to stroke. This allows to draw lines more interactively (see new segment
+ * during mouse slide, i.e.)
+ */
if (p->flags & GP_PAINTFLAG_STROKEADDED) {
bGPDstroke *gps= p->gpf->strokes.last;
bGPDspoint *pts;
@@ -401,7 +402,8 @@
pts = &gps->points[gps->totpoints-1];
/* special case for poly lines: normally, depth is needed only when creating new stroke from buffer,
- but poly lines are converting to stroke instantly, so initialize depth buffer before converting coordinates */
+ * but poly lines are converting to stroke instantly, so initialize depth buffer before converting coordinates
+ */
if (gpencil_project_check(p)) {
View3D *v3d= p->sa->spacedata.first;
@@ -1122,7 +1124,7 @@
p->gpd= *gpd_ptr;
}
- if(ED_gpencil_session_active()==0) {
+ if (ED_gpencil_session_active()==0) {
/* initialize undo stack,
also, existing undo stack would make buffer drawn */
gpencil_undo_init(p->gpd);
@@ -1693,9 +1695,11 @@
bScreen *sc= CTX_wm_screen(C);
ScrArea *sa;
- for(sa= sc->areabase.first; sa; sa= sa->next)
- if(sa==satest)
+ for (sa= sc->areabase.first; sa; sa= sa->next) {
+ if (sa==satest)
return 1;
+ }
+
return 0;
}
@@ -1781,9 +1785,9 @@
/* basically, this should be mouse-button up = end stroke
* BUT what happens next depends on whether we 'painting sessions' is enabled
*/
- sketch|= GPENCIL_SKETCH_SESSIONS_ON(p->scene);
- /* polyline drawig is also 'sketching' -- all knots should be added during one session */
- sketch|= p->paintmode == GP_PAINTMODE_DRAW_POLY;
+ sketch |= GPENCIL_SKETCH_SESSIONS_ON(p->scene);
+ /* polyline drawing is also 'sketching' -- all knots should be added during one session */
+ sketch |= p->paintmode == GP_PAINTMODE_DRAW_POLY;
if (sketch) {
/* end stroke only, and then wait to resume painting soon */
@@ -1804,13 +1808,13 @@
}
else if (event->val == KM_PRESS) {
/* not painting, so start stroke (this should be mouse-button down) */
-
p= gpencil_stroke_begin(C, op);
if (p->status == GP_STATUS_ERROR) {
estate = OPERATOR_CANCELLED;
}
- } else {
+ }
+ else {
p->status = GP_STATUS_IDLING;
}
}
@@ -1845,7 +1849,7 @@
}
/* gpencil modal operator stores area, which can be removed while using it (like fullscreen) */
- if(0==gpencil_area_exists(C, p->sa))
+ if (0==gpencil_area_exists(C, p->sa))
estate= OPERATOR_CANCELLED;
else
/* update status indicators - cursor, header, etc. */
Modified: trunk/blender/source/blender/makesrna/intern/rna_action.c
===================================================================
--- trunk/blender/source/blender/makesrna/intern/rna_action.c 2011-10-26 22:46:06 UTC (rev 41301)
+++ trunk/blender/source/blender/makesrna/intern/rna_action.c 2011-10-27 01:05:55 UTC (rev 41302)
@@ -95,15 +95,15 @@
static FCurve *rna_Action_fcurve_new(bAction *act, ReportList *reports, const char *data_path, int index, const char *group)
{
- if(group && group[0]=='\0') group= NULL;
+ if (group && group[0]=='\0') group= NULL;
- if(data_path[0] == '\0') {
+ if (data_path[0] == '\0') {
BKE_report(reports, RPT_ERROR, "F-Curve data path empty, invalid argument");
return NULL;
}
/* annoying, check if this exists */
- if(verify_fcurve(act, group, data_path, index, 0)) {
+ if (verify_fcurve(act, group, data_path, index, 0)) {
BKE_reportf(reports, RPT_ERROR, "F-Curve '%s[%d]' already exists in action '%s'", data_path, index, act->id.name+2);
return NULL;
}
More information about the Bf-blender-cvs
mailing list