diff options
author | Campbell Barton <ideasman42@gmail.com> | 2019-04-22 02:19:45 +0300 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2019-04-22 12:48:16 +0300 |
commit | 620b960d3d8cfd90b9f0df6ba3671c33eccb8309 (patch) | |
tree | 64f69db4bf9d44f0a32d1c92b0714bf2dc98ff2d /source/blender/editors/physics/rigidbody_object.c | |
parent | bba60bb564cf5a16cfcac744d4ba82cf8eba3da9 (diff) |
Cleanup: style, use braces for editors
Diffstat (limited to 'source/blender/editors/physics/rigidbody_object.c')
-rw-r--r-- | source/blender/editors/physics/rigidbody_object.c | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/source/blender/editors/physics/rigidbody_object.c b/source/blender/editors/physics/rigidbody_object.c index 2914127f8d8..ed6d31dfd9b 100644 --- a/source/blender/editors/physics/rigidbody_object.c +++ b/source/blender/editors/physics/rigidbody_object.c @@ -66,8 +66,9 @@ static bool ED_operator_rigidbody_active_poll(bContext *C) Object *ob = ED_object_active_context(C); return (ob && ob->rigidbody_object); } - else + else { return 0; + } } static bool ED_operator_rigidbody_add_poll(bContext *C) @@ -76,8 +77,9 @@ static bool ED_operator_rigidbody_add_poll(bContext *C) Object *ob = ED_object_active_context(C); return (ob && ob->type == OB_MESH); } - else + else { return 0; + } } /* ----------------- */ @@ -506,8 +508,9 @@ static int rigidbody_objects_calc_mass_exec(bContext *C, wmOperator *op) /* get density (kg/m^3) to apply */ if (material >= 0) { /* get density from table, and store in props for later repeating */ - if (material >= NUM_RB_MATERIAL_PRESETS) + if (material >= NUM_RB_MATERIAL_PRESETS) { material = 0; + } density = RB_MATERIAL_DENSITY_TABLE[material].density; RNA_float_set(op->ptr, "density", density); |