diff options
author | Bastien Montagne <bastien@blender.org> | 2022-05-09 17:32:09 +0300 |
---|---|---|
committer | Bastien Montagne <bastien@blender.org> | 2022-05-09 17:34:11 +0300 |
commit | 43e31d26a955034882035d2e0ec320dfab8f1375 (patch) | |
tree | 835c99ab083acf3c0d1ded7cd4273c7e41fde3e5 /source/blender/blenkernel/BKE_unit.h | |
parent | 6f773b1a4f8a21d8b3d36769f148d88e9a4eebcb (diff) |
Fix T97927: bpy.utils.units.to_string uses wrong units for velocity, acceleration, lens length, and power
`TEMPERATURE` type was also missing, not only the new-ish
`TIME_ABSOLUTE` one...
Added a static assert on the size of the `bpyunits_ucategories_items`
array, and a comment on anonymous enum of `B_UNIT_`, in the hope this
won't happen again in the future.
Diffstat (limited to 'source/blender/blenkernel/BKE_unit.h')
-rw-r--r-- | source/blender/blenkernel/BKE_unit.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/source/blender/blenkernel/BKE_unit.h b/source/blender/blenkernel/BKE_unit.h index d6de95a19b7..823d32f83ba 100644 --- a/source/blender/blenkernel/BKE_unit.h +++ b/source/blender/blenkernel/BKE_unit.h @@ -91,7 +91,7 @@ const char *BKE_unit_identifier_get(const void *usys_pt, int index); double BKE_unit_scalar_get(const void *usys_pt, int index); bool BKE_unit_is_suppressed(const void *usys_pt, int index); -/** Aligned with #PropertyUnit. */ +/** Aligned with #PropertyUnit and `bpyunits_ucategories_items` in `bpy_utils_units.c`. */ enum { B_UNIT_NONE = 0, B_UNIT_LENGTH = 1, |