diff options
author | Campbell Barton <ideasman42@gmail.com> | 2019-12-18 03:32:26 +0300 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2019-12-18 03:32:26 +0300 |
commit | 87dba476fb2b6f03b24ce9d65ae0f88db6f3d156 (patch) | |
tree | c949c1e45db59c36f5ac545b3b08387b9bb58be9 | |
parent | 0149b76dc61e11f3f42899a386d1c2a2a325af63 (diff) |
Cleanup: use ELEM macro
-rw-r--r-- | source/blender/makesrna/intern/rna_particle.c | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/source/blender/makesrna/intern/rna_particle.c b/source/blender/makesrna/intern/rna_particle.c index b65ef1bdda2..f3ca10e332a 100644 --- a/source/blender/makesrna/intern/rna_particle.c +++ b/source/blender/makesrna/intern/rna_particle.c @@ -952,14 +952,14 @@ static float rna_PartSetting_linelenhead_get(struct PointerRNA *ptr) static int rna_PartSettings_is_fluid_get(PointerRNA *ptr) { - ParticleSettings *part = (ParticleSettings *)ptr->data; - - if (part->type == PART_FLUID || part->type == PART_FLUID_FLIP || part->type == PART_FLUID_FOAM || - part->type == PART_FLUID_SPRAY || part->type == PART_FLUID_BUBBLE || - part->type == PART_FLUID_TRACER) { - return true; - } - return false; + ParticleSettings *part = ptr->data; + return (ELEM(part->type, + PART_FLUID, + PART_FLUID_FLIP, + PART_FLUID_FOAM, + PART_FLUID_SPRAY, + PART_FLUID_BUBBLE, + PART_FLUID_TRACER)); } static void rna_ParticleSettings_use_clump_curve_update(Main *bmain, Scene *scene, PointerRNA *ptr) |