diff options
author | Campbell Barton <ideasman42@gmail.com> | 2019-05-31 15:51:19 +0300 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2019-05-31 15:55:15 +0300 |
commit | d8dbd49a2f23b7637f05fc058f39bdf6ab706624 (patch) | |
tree | 0805b9372c82ae6505d87e879824efe1d3e32f8e /source/blender/collada/collada_utils.h | |
parent | 8987f7987d8160e1f6e79e8c85d6ce65b885ab25 (diff) |
Cleanup: style, use braces in source/
Automated using clang-tidy.
Diffstat (limited to 'source/blender/collada/collada_utils.h')
-rw-r--r-- | source/blender/collada/collada_utils.h | 15 |
1 files changed, 10 insertions, 5 deletions
diff --git a/source/blender/collada/collada_utils.h b/source/blender/collada/collada_utils.h index ca40de6fc1d..240e6200cf3 100644 --- a/source/blender/collada/collada_utils.h +++ b/source/blender/collada/collada_utils.h @@ -92,8 +92,9 @@ inline bAction *bc_getSceneObjectAction(Object *ob) /* Returns Light Action or NULL */ inline bAction *bc_getSceneLightAction(Object *ob) { - if (ob->type != OB_LAMP) + if (ob->type != OB_LAMP) { return NULL; + } Light *lamp = (Light *)ob->data; return (lamp->adt && lamp->adt->action) ? lamp->adt->action : NULL; @@ -102,8 +103,9 @@ inline bAction *bc_getSceneLightAction(Object *ob) /* Return Camera Action or NULL */ inline bAction *bc_getSceneCameraAction(Object *ob) { - if (ob->type != OB_CAMERA) + if (ob->type != OB_CAMERA) { return NULL; + } Camera *camera = (Camera *)ob->data; return (camera->adt && camera->adt->action) ? camera->adt->action : NULL; @@ -112,16 +114,18 @@ inline bAction *bc_getSceneCameraAction(Object *ob) /* returns material action or NULL */ inline bAction *bc_getSceneMaterialAction(Material *ma) { - if (ma == NULL) + if (ma == NULL) { return NULL; + } return (ma->adt && ma->adt->action) ? ma->adt->action : NULL; } inline void bc_setSceneObjectAction(bAction *action, Object *ob) { - if (ob->adt) + if (ob->adt) { ob->adt->action = action; + } } std::string bc_get_action_id(std::string action_name, @@ -167,8 +171,9 @@ inline std::string bc_string_after(const std::string &s, const char c) inline bool bc_startswith(std::string const &value, std::string const &starting) { - if (starting.size() > value.size()) + if (starting.size() > value.size()) { return false; + } return (value.substr(0, starting.size()) == starting); } |