[Bf-blender-cvs] [b99d064e914] master: Cleanup: trailing space

Campbell Barton noreply at git.blender.org
Sun May 13 06:47:06 CEST 2018


Commit: b99d064e9142b2e9d790731f4c4c6c107ca43696
Author: Campbell Barton
Date:   Sun May 13 06:44:03 2018 +0200
Branches: master
https://developer.blender.org/rBb99d064e9142b2e9d790731f4c4c6c107ca43696

Cleanup: trailing space

===================================================================

M	source/blender/editors/transform/transform.c
M	source/blender/editors/transform/transform.h
M	source/blender/editors/transform/transform_constraints.c
M	source/blender/editors/transform/transform_conversions.c
M	source/blender/editors/transform/transform_generics.c
M	source/blender/editors/transform/transform_input.c
M	source/blender/editors/transform/transform_manipulator.c
M	source/blender/editors/transform/transform_ops.c
M	source/blender/editors/transform/transform_orientations.c
M	source/blender/editors/transform/transform_snap.c

===================================================================

diff --git a/source/blender/editors/transform/transform.c b/source/blender/editors/transform/transform.c
index 4a8bd5287df..69e8ebf5ca4 100644
--- a/source/blender/editors/transform/transform.c
+++ b/source/blender/editors/transform/transform.c
@@ -638,7 +638,7 @@ static void viewRedrawForce(const bContext *C, TransInfo *t)
 static void viewRedrawPost(bContext *C, TransInfo *t)
 {
 	ED_area_headerprint(t->sa, NULL);
-	
+
 	if (t->spacetype == SPACE_VIEW3D) {
 		/* if autokeying is enabled, send notifiers that keyframes were added */
 		if (IS_AUTOKEY_ON(t->scene))
@@ -650,12 +650,12 @@ static void viewRedrawPost(bContext *C, TransInfo *t)
 		{
 			WM_event_add_notifier(C, NC_GEOM | ND_DATA, NULL);
 		}
-		
+
 		/* XXX temp, first hack to get auto-render in compositor work (ton) */
 		WM_event_add_notifier(C, NC_SCENE | ND_TRANSFORM_DONE, CTX_data_scene(C));
 
 	}
-	
+
 #if 0 // TRANSFORM_FIX_ME
 	if (t->spacetype == SPACE_VIEW3D) {
 		allqueue(REDRAWBUTSOBJECT, 0);
@@ -831,14 +831,14 @@ wmKeyMap *transform_modal_keymap(wmKeyConfig *keyconf)
 		{TFM_MODAL_INSERTOFS_TOGGLE_DIR, "INSERTOFS_TOGGLE_DIR", 0, "Toggle Direction for Node Auto-offset", ""},
 		{0, NULL, 0, NULL, NULL}
 	};
-	
+
 	wmKeyMap *keymap = WM_modalkeymap_get(keyconf, "Transform Modal Map");
-	
+
 	/* this function is called for each spacetype, only needs to add map once */
 	if (keymap && keymap->modal_items) return NULL;
-	
+
 	keymap = WM_modalkeymap_add(keyconf, "Transform Modal Map", modal_items);
-	
+
 	/* items for modal map */
 	WM_modalkeymap_add_item(keymap, ESCKEY,    KM_PRESS, KM_ANY, 0, TFM_MODAL_CANCEL);
 	WM_modalkeymap_add_item(keymap, LEFTMOUSE, KM_PRESS, KM_ANY, 0, TFM_MODAL_CONFIRM);
@@ -848,7 +848,7 @@ wmKeyMap *transform_modal_keymap(wmKeyConfig *keyconf)
 	WM_modalkeymap_add_item(keymap, GKEY, KM_PRESS, 0, 0, TFM_MODAL_TRANSLATE);
 	WM_modalkeymap_add_item(keymap, RKEY, KM_PRESS, 0, 0, TFM_MODAL_ROTATE);
 	WM_modalkeymap_add_item(keymap, SKEY, KM_PRESS, 0, 0, TFM_MODAL_RESIZE);
-	
+
 	WM_modalkeymap_add_item(keymap, TABKEY, KM_PRESS, KM_SHIFT, 0, TFM_MODAL_SNAP_TOGGLE);
 
 	WM_modalkeymap_add_item(keymap, LEFTCTRLKEY, KM_PRESS, KM_ANY, 0, TFM_MODAL_SNAP_INV_ON);
@@ -856,7 +856,7 @@ wmKeyMap *transform_modal_keymap(wmKeyConfig *keyconf)
 
 	WM_modalkeymap_add_item(keymap, RIGHTCTRLKEY, KM_PRESS, KM_ANY, 0, TFM_MODAL_SNAP_INV_ON);
 	WM_modalkeymap_add_item(keymap, RIGHTCTRLKEY, KM_RELEASE, KM_ANY, 0, TFM_MODAL_SNAP_INV_OFF);
-	
+
 	WM_modalkeymap_add_item(keymap, AKEY, KM_PRESS, 0, 0, TFM_MODAL_ADD_SNAP);
 	WM_modalkeymap_add_item(keymap, AKEY, KM_PRESS, KM_ALT, 0, TFM_MODAL_REMOVE_SNAP);
 
@@ -872,7 +872,7 @@ wmKeyMap *transform_modal_keymap(wmKeyConfig *keyconf)
 
 	WM_modalkeymap_add_item(keymap, WHEELDOWNMOUSE, KM_PRESS, KM_ALT, 0, TFM_MODAL_EDGESLIDE_UP);
 	WM_modalkeymap_add_item(keymap, WHEELUPMOUSE, KM_PRESS, KM_ALT, 0, TFM_MODAL_EDGESLIDE_DOWN);
-	
+
 	WM_modalkeymap_add_item(keymap, PAGEUPKEY, KM_PRESS, KM_SHIFT, 0, TFM_MODAL_AUTOIK_LEN_INC);
 	WM_modalkeymap_add_item(keymap, PAGEDOWNKEY, KM_PRESS, KM_SHIFT, 0, TFM_MODAL_AUTOIK_LEN_DEC);
 	WM_modalkeymap_add_item(keymap, WHEELDOWNMOUSE, KM_PRESS, KM_SHIFT, 0, TFM_MODAL_AUTOIK_LEN_INC);
@@ -891,7 +891,7 @@ static void transform_event_xyz_constraint(TransInfo *t, short key_type, char cm
 		const bool edit_2d = (t->flag & T_2D_EDIT) != 0;
 		const char *msg1 = "", *msg2 = "", *msg3 = "";
 		char axis;
-	
+
 		/* Initialize */
 		switch (key_type) {
 			case XKEY:
@@ -1062,7 +1062,7 @@ int transformEvent(TransInfo *t, const wmEvent *event)
 						restoreTransObjects(t);
 						resetTransModal(t);
 						resetTransRestrictions(t);
-						
+
 						if (t->mode == TFM_ROTATION) {
 							initTrackball(t);
 						}
@@ -1107,7 +1107,7 @@ int transformEvent(TransInfo *t, const wmEvent *event)
 					}
 				}
 				break;
-				
+
 			case TFM_MODAL_SNAP_INV_ON:
 				t->modifiers |= MOD_SNAP_INVERT;
 				t->redraw |= TREDRAW_HARD;
@@ -1683,7 +1683,7 @@ static void drawArc(float size, float angle_start, float angle_end, int segments
 static int helpline_poll(bContext *C)
 {
 	ARegion *ar = CTX_wm_region(C);
-	
+
 	if (ar && ar->regiontype == RGN_TYPE_WINDOW)
 		return 1;
 	return 0;
@@ -1810,7 +1810,7 @@ static void drawHelpline(bContext *UNUSED(C), int x, int y, void *customdata)
 static void drawTransformView(const struct bContext *C, ARegion *UNUSED(ar), void *arg)
 {
 	TransInfo *t = arg;
-	
+
 	glLineWidth(1.0);
 
 	drawConstraint(t);
@@ -1831,12 +1831,12 @@ static void drawAutoKeyWarning(TransInfo *UNUSED(t), ARegion *ar)
 	int xco, yco;
 
 	ED_region_visible_rect(ar, &rect);
-	
+
 	BLF_width_and_height_default(printable, BLF_DRAW_STR_DUMMY_MAX, &printable_size[0], &printable_size[1]);
-	
+
 	xco = (rect.xmax - U.widget_unit) - (int)printable_size[0];
 	yco = (rect.ymax - U.widget_unit);
-	
+
 	/* warning text (to clarify meaning of overlays)
 	 * - original color was red to match the icon, but that clashes badly with a less nasty border
 	 */
@@ -1846,27 +1846,27 @@ static void drawAutoKeyWarning(TransInfo *UNUSED(t), ARegion *ar)
 #else
 	BLF_draw_default_ascii(xco, yco, 0.0f, printable, BLF_DRAW_STR_DUMMY_MAX);
 #endif
-	
+
 	/* autokey recording icon... */
 	glBlendFunc(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA);
 	glEnable(GL_BLEND);
-	
+
 	xco -= U.widget_unit;
 	yco -= (int)printable_size[1] / 2;
 
 	UI_icon_draw(xco, yco, ICON_REC);
-	
+
 	glDisable(GL_BLEND);
 }
 
 static void drawTransformPixel(const struct bContext *UNUSED(C), ARegion *ar, void *arg)
-{	
+{
 	TransInfo *t = arg;
 	Scene *scene = t->scene;
 	Object *ob = OBACT;
-	
-	/* draw autokeyframing hint in the corner 
-	 * - only draw if enabled (advanced users may be distracted/annoyed), 
+
+	/* draw autokeyframing hint in the corner
+	 * - only draw if enabled (advanced users may be distracted/annoyed),
 	 *   for objects that will be autokeyframed (no point ohterwise),
 	 *   AND only for the active region (as showing all is too overwhelming)
 	 */
@@ -1957,7 +1957,7 @@ void saveTransform(bContext *C, TransInfo *t, wmOperator *op)
 				ts->prop_mode = t->prop_mode;
 			}
 		}
-		
+
 		/* do we check for parameter? */
 		if (t->modifiers & MOD_SNAP) {
 			ts->snap_flag |= SCE_SNAP;
@@ -1976,7 +1976,7 @@ void saveTransform(bContext *C, TransInfo *t, wmOperator *op)
 			}
 		}
 	}
-	
+
 	if ((prop = RNA_struct_find_property(op->ptr, "proportional"))) {
 		RNA_property_enum_set(op->ptr, prop, proportional);
 		RNA_enum_set(op->ptr, "proportional_edit_falloff", t->prop_mode);
@@ -2055,7 +2055,7 @@ bool initTransform(bContext *C, TransInfo *t, wmOperator *op, const wmEvent *eve
 			options |= CTX_TEXTURE;
 		}
 	}
-	
+
 	if ((prop = RNA_struct_find_property(op->ptr, "gpencil_strokes")) && RNA_property_is_set(op->ptr, prop)) {
 		if (RNA_property_boolean_get(op->ptr, prop)) {
 			options |= CTX_GPENCIL_STROKES;
@@ -2414,7 +2414,7 @@ int transformEnd(bContext *C, TransInfo *t)
 			else if (t->mode == TFM_VERT_SLIDE) {
 				doVertSlide(t, 0.0f);
 			}
-			
+
 			exit_code = OPERATOR_CANCELLED;
 			restoreTransObjects(t); // calls recalcData()
 		}
@@ -2479,7 +2479,7 @@ static void protectedAxisAngleBits(short protectflag, float axis[3], float *angl
 	/* check that protection flags are set */
 	if ((protectflag & (OB_LOCK_ROTX | OB_LOCK_ROTY | OB_LOCK_ROTZ | OB_LOCK_ROTW)) == 0)
 		return;
-	
+
 	if (protectflag & OB_LOCK_ROT4D) {
 		/* axis-angle getting limited as 4D entities that they are... */
 		if (protectflag & OB_LOCK_ROTW)
@@ -2494,19 +2494,19 @@ static void protectedAxisAngleBits(short protectflag, float axis[3], float *angl
 	else {
 		/* axis-angle get limited with euler... */
 		float eul[3], oldeul[3];
-		
+
 		axis_angle_to_eulO(eul, EULER_ORDER_DEFAULT, axis, *angle);
 		axis_angle_to_eulO(oldeul, EULER_ORDER_DEFAULT, oldAxis, oldAngle);
-		
+
 		if (protectflag & OB_LOCK_ROTX)
 			eul[0] = oldeul[0];
 		if (protectflag & OB_LOCK_ROTY)
 			eul[1] = oldeul[1];
 		if (protectflag & OB_LOCK_ROTZ)
 			eul[2] = oldeul[2];
-		
+
 		eulO_to_axis_angle(axis, angle, eul, EULER_ORDER_DEFAULT);
-		
+
 		/* when converting to axis-angle, we need a special exception for the case when there is no axis */
 		if (IS_EQF(axis[0], axis[1]) && IS_EQF(axis[1], axis[2])) {
 			/* for now, rotate around y-axis then (so that it simply becomes the roll) */
@@ -2521,7 +2521,7 @@ static void protectedQuaternionBits(short protectflag, float quat[4], const floa
 	/* check that protection flags are set */
 	if ((protectflag & (OB_LOCK_ROTX | OB_LOCK_ROTY | OB_LOCK_ROTZ | OB_LOCK_ROTW)) == 0)
 		return;
-	
+
 	if (protectflag & OB_LOCK_ROT4D) {
 		/* quaternions getting limited as 4D entities that they are... */
 		if (protectflag & OB_LOCK_ROTW)
@@ -2555,7 +2555,7 @@ static void protectedQuaternionBits(short protectflag, float quat[4], const floa
 
 		/* restore original quat size */
 		mul_qt_fl(quat, qlen);
-		
+
 		/* quaternions flip w sign to accumulate rotations correctly */
 		if ((nquat[0] < 0.0f && quat[0] > 0.0f) ||
 		    (nquat[0] > 0.0f && quat[0] < 0.0f))
@@ -2572,43 +2572,43 @@ static void constraintTransLim(TransInfo *t, TransData *td)
 	if (td->con) {
 		const bConstraintTypeInfo *ctiLoc = BKE_constraint_typeinfo_from_type(CONSTRAINT_TYPE_LOCLIMIT);
 		const bConstraintTypeInfo *ctiDist = BKE_constraint_typeinfo_from_type(CONSTRAINT_TYPE_DISTLIMIT);
-		
+
 		bConstraintOb cob = {NULL};
 		bConstraint *con;
 		float ctime = (float)(t->scene->r.cfra);
-		
+
 		/* Make a temporary bConstraintOb for using these limit constraints
 		 *  - they only care that cob->matrix is correctly set ;-)
 		 *	- current space should be local
 		 */
 		unit_m4(cob.matrix);
 		copy_v3_v3(cob.matrix[3], td->loc);
-		
+
 		/* Evaluate valid constraints */
 		for (con = td->con; con; con = con->next) {
 			const bConstraintTypeInfo *cti = NULL;
 			ListBase targets = {NULL, NULL};
-			
+
 			/* only consider constraint if enabled */
 			if (con->flag & (CONSTRAINT_DISABLE | CONSTRAINT_OFF)) continue;
 			if (con->enforce == 0.0f) continue;
-			
+
 			/* only use it if it's tagged for this purpose (and the right type) */
 			if (con->type == CONSTRAINT_TYPE_LOCLIMIT) {
 				bLocLimitConstraint *data = con->data;
-				
+
 				if ((data->flag2 & LIMIT_TRANSFORM) == 0)
 					co

@@ Diff output truncated at 10240 characters. @@



More information about the Bf-blender-cvs mailing list