diff options
author | Hans Goudey <h.goudey@me.com> | 2020-07-03 17:28:13 +0300 |
---|---|---|
committer | Hans Goudey <h.goudey@me.com> | 2020-07-03 17:28:13 +0300 |
commit | 53d41e1a6fc4c521e412fba57913f93fadeb3735 (patch) | |
tree | fb7f0415ebd64240111637c53484b6325e9600ef /source/blender/modifiers | |
parent | 2a39b34a09702e4e64e27befc97dd6154b75ccc0 (diff) |
UI: Use sliders and [0, 1] ranges in ocean modifier
The ocean modifier has two properties that use a [0, 10] hard min and
hard max. The values act as factors though, so it makes more sense to
use sliders and a 0 to 1 range.
This commit also bumps the file subversion to avoid repeatedly applying
the change to the properties' range.
Differential Revision: https://developer.blender.org/D8186
Diffstat (limited to 'source/blender/modifiers')
-rw-r--r-- | source/blender/modifiers/intern/MOD_ocean.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/source/blender/modifiers/intern/MOD_ocean.c b/source/blender/modifiers/intern/MOD_ocean.c index cb5c67087c4..0773a81127a 100644 --- a/source/blender/modifiers/intern/MOD_ocean.c +++ b/source/blender/modifiers/intern/MOD_ocean.c @@ -598,7 +598,7 @@ static void waves_panel_draw(const bContext *C, Panel *panel) uiItemS(layout); col = uiLayoutColumn(layout, false); - uiItemR(col, &ptr, "wave_alignment", 0, IFACE_("Alignment"), ICON_NONE); + uiItemR(col, &ptr, "wave_alignment", UI_ITEM_R_SLIDER, IFACE_("Alignment"), ICON_NONE); sub = uiLayoutColumn(col, false); uiLayoutSetActive(sub, RNA_float_get(&ptr, "wave_alignment") > 0.0f); uiItemR(sub, &ptr, "wave_direction", 0, IFACE_("Direction"), ICON_NONE); @@ -682,7 +682,7 @@ static void spectrum_panel_draw(const bContext *C, Panel *panel) col = uiLayoutColumn(layout, false); uiItemR(col, &ptr, "spectrum", 0, NULL, ICON_NONE); if (ELEM(spectrum, MOD_OCEAN_SPECTRUM_TEXEL_MARSEN_ARSLOE, MOD_OCEAN_SPECTRUM_JONSWAP)) { - uiItemR(col, &ptr, "sharpen_peak_jonswap", 0, NULL, ICON_NONE); + uiItemR(col, &ptr, "sharpen_peak_jonswap", UI_ITEM_R_SLIDER, NULL, ICON_NONE); uiItemR(col, &ptr, "fetch_jonswap", 0, NULL, ICON_NONE); } } |