Commit: b9893a8f6a333cb79e15807db4e518a4cc613a5b
Author: Grigory Revzin
Date:   Fri Jul 18 21:44:42 2014 +0400
https://developer.blender.org/rBb9893a8f6a333cb79e15807db4e518a4cc613a5b

Fixed compilation under GCC

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

M       source/blender/editors/mesh/editmesh_tools.c

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

diff --git a/source/blender/editors/mesh/editmesh_tools.c 
b/source/blender/editors/mesh/editmesh_tools.c
index 9f1e04a..a0fb155 100644
--- a/source/blender/editors/mesh/editmesh_tools.c
+++ b/source/blender/editors/mesh/editmesh_tools.c
@@ -91,12 +91,12 @@ static int edbm_subdivide_exec(bContext *C, wmOperator *op)
        const float fractal = RNA_float_get(op->ptr, "fractal") / 2.5f;
        const float along_normal = RNA_float_get(op->ptr, 
"fractal_along_normal");
 
-       if (RNA_boolean_get(op->ptr, "quadtri") && 
+       if (RNA_boolean_get(op->ptr, "quadtri") &&
            RNA_enum_get(op->ptr, "quadcorner") == SUBD_STRAIGHT_CUT)
        {
                RNA_enum_set(op->ptr, "quadcorner", SUBD_INNERVERT);
        }
-       
+
        BM_mesh_esubdivide(em->bm, BM_ELEM_SELECT,
                           smooth, SUBD_FALLOFF_ROOT, false,
                           fractal, along_normal,
@@ -366,7 +366,7 @@ static int edbm_delete_exec(bContext *C, wmOperator *op)
        EDBM_flag_disable_all(em, BM_ELEM_SELECT);
 
        EDBM_update_generic(em, true, true);
-       
+
        return OPERATOR_FINISHED;
 }
 
@@ -376,13 +376,13 @@ void MESH_OT_delete(wmOperatorType *ot)
        ot->name = "Delete";
        ot->description = "Delete selected vertices, edges or faces";
        ot->idname = "MESH_OT_delete";
-       
+
        /* api callbacks */
        ot->invoke = WM_menu_invoke;
        ot->exec = edbm_delete_exec;
-       
+
        ot->poll = ED_operator_editmesh;
-       
+
        /* flags */
        ot->flag = OPTYPE_REGISTER | OPTYPE_UNDO;
 
@@ -705,7 +705,7 @@ static int edbm_add_edge_face_exec(bContext *C, wmOperator 
*op)
        {
                return OPERATOR_CANCELLED;
        }
-       
+
        BMO_op_exec(em->bm, &bmop);
 
        /* cancel if nothing was done */
@@ -747,11 +747,11 @@ void MESH_OT_edge_face_add(wmOperatorType *ot)
        ot->name = "Make Edge/Face";
        ot->description = "Add an edge or face to selected";
        ot->idname = "MESH_OT_edge_face_add";
-       
+
        /* api callbacks */
        ot->exec = edbm_add_edge_face_exec;
        ot->poll = ED_operator_editmesh;
-       
+
        /* flags */
        ot->flag = OPTYPE_REGISTER | OPTYPE_UNDO;
 }
@@ -768,7 +768,7 @@ static int edbm_mark_seam_exec(bContext *C, wmOperator *op)
        BMEdge *eed;
        BMIter iter;
        const bool clear = RNA_boolean_get(op->ptr, "clear");
-       
+
        /* auto-enable seams drawing */
        if (clear == 0) {
                me->drawflag |= ME_DRAWSEAMS;
@@ -778,7 +778,7 @@ static int edbm_mark_seam_exec(bContext *C, wmOperator *op)
                BM_ITER_MESH (eed, &iter, bm, BM_EDGES_OF_MESH) {
                        if (!BM_elem_flag_test(eed, BM_ELEM_SELECT) || 
BM_elem_flag_test(eed, BM_ELEM_HIDDEN))
                                continue;
-                       
+
                        BM_elem_flag_disable(eed, BM_ELEM_SEAM);
                }
        }
@@ -804,14 +804,14 @@ void MESH_OT_mark_seam(wmOperatorType *ot)
        ot->name = "Mark Seam";
        ot->idname = "MESH_OT_mark_seam";
        ot->description = "(Un)mark selected edges as a seam";
-       
+
        /* api callbacks */
        ot->exec = edbm_mark_seam_exec;
        ot->poll = ED_operator_editmesh;
-       
+
        /* flags */
        ot->flag = OPTYPE_REGISTER | OPTYPE_UNDO;
-       
+
        prop = RNA_def_boolean(ot->srna, "clear", 0, "Clear", "");
        RNA_def_property_flag(prop, PROP_SKIP_SAVE);
 }
@@ -858,14 +858,14 @@ void MESH_OT_mark_sharp(wmOperatorType *ot)
        ot->name = "Mark Sharp";
        ot->idname = "MESH_OT_mark_sharp";
        ot->description = "(Un)mark selected edges as sharp";
-       
+
        /* api callbacks */
        ot->exec = edbm_mark_sharp_exec;
        ot->poll = ED_operator_editmesh;
-       
+
        /* flags */
        ot->flag = OPTYPE_REGISTER | OPTYPE_UNDO;
-       
+
        prop = RNA_def_boolean(ot->srna, "clear", false, "Clear", "");
        RNA_def_property_flag(prop, PROP_SKIP_SAVE);
        prop = RNA_def_boolean(ot->srna, "use_verts", false, "Vertices",
@@ -881,7 +881,7 @@ static int edbm_vert_connect_exec(bContext *C, wmOperator 
*op)
        BMOperator bmop;
        const bool is_pair = (bm->totvertsel == 2);
        int len;
-       
+
        if (is_pair) {
                if (!EDBM_op_init(em, &bmop, op, "connect_vert_pair verts=%hv", 
BM_ELEM_SELECT)) {
                        return OPERATOR_CANCELLED;
@@ -921,11 +921,11 @@ void MESH_OT_vert_connect(wmOperatorType *ot)
        ot->name = "Vertex Connect";
        ot->idname = "MESH_OT_vert_connect";
        ot->description = "Connect 2 vertices of a face by an edge, splitting 
the face in two";
-       
+
        /* api callbacks */
        ot->exec = edbm_vert_connect_exec;
        ot->poll = ED_operator_editmesh;
-       
+
        /* flags */
        ot->flag = OPTYPE_REGISTER | OPTYPE_UNDO;
 }
@@ -988,7 +988,7 @@ static int edbm_edge_split_exec(bContext *C, wmOperator *op)
        {
                return OPERATOR_CANCELLED;
        }
-       
+
        if (em->selectmode == SCE_SELECT_FACE) {
                EDBM_select_flush(em);
        }
@@ -1004,11 +1004,11 @@ void MESH_OT_edge_split(wmOperatorType *ot)
        ot->name = "Edge Split";
        ot->idname = "MESH_OT_edge_split";
        ot->description = "Split selected edges so that each neighbor face gets 
its own copy";
-       
+
        /* api callbacks */
        ot->exec = edbm_edge_split_exec;
        ot->poll = ED_operator_editmesh;
-       
+
        /* flags */
        ot->flag = OPTYPE_REGISTER | OPTYPE_UNDO;
 }
@@ -1027,7 +1027,7 @@ static int edbm_duplicate_exec(bContext *C, wmOperator 
*op)
        SWAP(ListBase, bm->selected, bm_selected_store);
 
        EDBM_op_init(em, &bmop, op, "duplicate geom=%hvef", BM_ELEM_SELECT);
-       
+
        BMO_op_exec(bm, &bmop);
        EDBM_flag_disable_all(em, BM_ELEM_SELECT);
 
@@ -1049,7 +1049,7 @@ static int edbm_duplicate_exec(bContext *C, wmOperator 
*op)
        }
 
        EDBM_update_generic(em, true, true);
-       
+
        return OPERATOR_FINISHED;
 }
 
@@ -1058,7 +1058,7 @@ static int edbm_duplicate_invoke(bContext *C, wmOperator 
*op, const wmEvent *UNU
        WM_cursor_wait(1);
        edbm_duplicate_exec(C, op);
        WM_cursor_wait(0);
-       
+
        return OPERATOR_FINISHED;
 }
 
@@ -1068,13 +1068,13 @@ void MESH_OT_duplicate(wmOperatorType *ot)
        ot->name = "Duplicate";
        ot->description = "Duplicate selected vertices, edges or faces";
        ot->idname = "MESH_OT_duplicate";
-       
+
        /* api callbacks */
        ot->invoke = edbm_duplicate_invoke;
        ot->exec = edbm_duplicate_exec;
-       
+
        ot->poll = ED_operator_editmesh;
-       
+
        /* to give to transform */
        RNA_def_int(ot->srna, "mode", TFM_TRANSLATION, 0, INT_MAX, "Mode", "", 
0, INT_MAX);
 }
@@ -1083,10 +1083,10 @@ static int edbm_flip_normals_exec(bContext *C, 
wmOperator *op)
 {
        Object *obedit = CTX_data_edit_object(C);
        BMEditMesh *em = BKE_editmesh_from_object(obedit);
-       
+
        if (!EDBM_op_callf(em, op, "reverse_faces faces=%hf", BM_ELEM_SELECT))
                return OPERATOR_CANCELLED;
-       
+
        EDBM_update_generic(em, true, false);
 
        return OPERATOR_FINISHED;
@@ -1098,11 +1098,11 @@ void MESH_OT_flip_normals(wmOperatorType *ot)
        ot->name = "Flip Normals";
        ot->description = "Flip the direction of selected faces' normals (and 
of their vertices)";
        ot->idname = "MESH_OT_flip_normals";
-       
+
        /* api callbacks */
        ot->exec = edbm_flip_normals_exec;
        ot->poll = ED_operator_editmesh;
-       
+
        /* flags */
        ot->flag = OPTYPE_REGISTER | OPTYPE_UNDO;
 }
@@ -1138,7 +1138,7 @@ static int edbm_edge_rotate_selected_exec(bContext *C, 
wmOperator *op)
                        }
                }
        }
-       
+
        /* ok, we don't have two adjacent faces, but we do have two selected 
ones.
         * that's an error condition.*/
        if (tot == 0) {
@@ -1190,7 +1190,7 @@ static int edbm_hide_exec(bContext *C, wmOperator *op)
 {
        Object *obedit = CTX_data_edit_object(C);
        BMEditMesh *em = BKE_editmesh_from_object(obedit);
-       
+
        EDBM_mesh_hide(em, RNA_boolean_get(op->ptr, "unselected"));
 
        EDBM_update_generic(em, true, false);
@@ -1204,14 +1204,14 @@ void MESH_OT_hide(wmOperatorType *ot)
        ot->name = "Hide Selection";
        ot->idname = "MESH_OT_hide";
        ot->description = "Hide (un)selected vertices, edges or faces";
-       
+
        /* api callbacks */
        ot->exec = edbm_hide_exec;
        ot->poll = ED_operator_editmesh;
 
        /* flags */
        ot->flag = OPTYPE_REGISTER | OPTYPE_UNDO;
-       
+
        /* props */
        RNA_def_boolean(ot->srna, "unselected", 0, "Unselected", "Hide 
unselected rather than selected");
 }
@@ -1220,7 +1220,7 @@ static int edbm_reveal_exec(bContext *C, wmOperator 
*UNUSED(op))
 {
        Object *obedit = CTX_data_edit_object(C);
        BMEditMesh *em = BKE_editmesh_from_object(obedit);
-       
+
        EDBM_mesh_reveal(em);
 
        EDBM_update_generic(em, true, false);
@@ -1234,11 +1234,11 @@ void MESH_OT_reveal(wmOperatorType *ot)
        ot->name = "Reveal Hidden";
        ot->idname = "MESH_OT_reveal";
        ot->description = "Reveal all hidden vertices, edges and faces";
-       
+
        /* api callbacks */
        ot->exec = edbm_reveal_exec;
        ot->poll = ED_operator_editmesh;
-       
+
        /* flags */
        ot->flag = OPTYPE_REGISTER | OPTYPE_UNDO;
 }
@@ -1247,7 +1247,7 @@ static int edbm_normals_make_consistent_exec(bContext *C, 
wmOperator *op)
 {
        Object *obedit = CTX_data_edit_object(C);
        BMEditMesh *em = BKE_editmesh_from_object(obedit);
-       
+
        /* doflip has to do with bmesh_rationalize_normals, it's an internal
         * thing */
        if (!EDBM_op_callf(em, op, "recalc_face_normals faces=%hf", 
BM_ELEM_SELECT))
@@ -1267,14 +1267,14 @@ void MESH_OT_normals_make_consistent(wmOperatorType *ot)
        ot->name = "Make Normals Consistent";
        ot->description = "Make face and vertex normals point either outside or 
inside the mesh";
        ot->idname = "MESH_OT_normals_make_consistent";
-       
+
        /* api callbacks */
        ot->exec = edbm_normals_make_consistent_exec;
        ot->poll = ED_operator_editmesh;
-       
+
        /* flags */
        ot->flag = OPTYPE_REGISTER | OPTYPE_UNDO;
-       
+
        RNA_def_boolean(ot->srna, "inside", 0, "Inside", "");
 }
 
@@ -1301,12 +1301,12 @@ static int edbm_do_smooth_vertex_exec(bContext *C, 
wmOperator *op)
        }
 
        /* if there is a mirror modifier with clipping, flag the verts that
-        * are within tolerance of the plane(s) of reflection 
+        * are within tolerance of the plane(s) of reflection
         */
        for (md = obedit->modifiers.first; md; md = md->next) {
                if (md->type == eModifierType_Mirror && (md->mode & 
eModifierMode_Realtime)) {
                        MirrorModifierData *mmd = (MirrorModifierData *)md;
-               
+
                        if (mmd->flag & MOD_MIR_CLIPPING) {
                                if (mmd->flag & MOD_MIR_AXIS_X)
                                        mirrx = true;
@@ -1323,7 +1323,7 @@ static int edbm_do_smooth_vertex_exec(bContext *C, 
wmOperator *op)
        repeat = RNA_int_get(op->ptr, "repeat");
        if (!repeat)
                repeat = 1;
-       
+
        for (i = 0; i < repeat; i++) {
                if (!EDBM_op_callf(em, op,
                                   "smooth_vert verts=%hv mirror_clip_x=%b 
mirror_clip_y=%b mirror_clip_z=%b clip_dist=%f "
@@ -1343,19 +1343,19 @@ static int edbm_do_smooth_vertex_exec(bContext *C, 
wmOperator *op)
        EDBM_update_generic(em, true, false);
 
        return OPERATOR_FINISHED;
-}      
-       
+}
+
 void

@@ Diff output truncated at 10240 characters. @@

_______________________________________________
Bf-blender-cvs mailing list
[email protected]
http://lists.blender.org/mailman/listinfo/bf-blender-cvs

Reply via email to