Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHans Goudey <h.goudey@me.com>2021-01-27 20:19:54 +0300
committerHans Goudey <h.goudey@me.com>2021-01-27 20:19:54 +0300
commitc71a8e837616159735a925bbb82c868646e7d3a1 (patch)
tree1a2baa4562e9c4eb19db8fc7344b30e0bdd59272 /source/blender/editors/metaball
parent0e39c526d856f9807cbb84d816fb6a433ec95095 (diff)
UI: Fix incorrect RNA percentage property definitions
In two cases the percentage property was actually used incorrectly, as pointed out in T82070. The range was [0, 1], but the properties were still displayed as percentages. There is a preference to control whether to display factors or percentages, so it usually doesn't make sense to manually define properties as percentages. Resolves T82070 Differential Revision: https://developer.blender.org/D9344
Diffstat (limited to 'source/blender/editors/metaball')
-rw-r--r--source/blender/editors/metaball/mball_edit.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/source/blender/editors/metaball/mball_edit.c b/source/blender/editors/metaball/mball_edit.c
index 094011ebef1..cf453bf0c32 100644
--- a/source/blender/editors/metaball/mball_edit.c
+++ b/source/blender/editors/metaball/mball_edit.c
@@ -483,7 +483,7 @@ void MBALL_OT_select_similar(wmOperatorType *ot)
static int select_random_metaelems_exec(bContext *C, wmOperator *op)
{
const bool select = (RNA_enum_get(op->ptr, "action") == SEL_SELECT);
- const float randfac = RNA_float_get(op->ptr, "percent") / 100.0f;
+ const float randfac = RNA_float_get(op->ptr, "ratio");
const int seed = WM_operator_properties_select_random_seed_increment_get(op);
ViewLayer *view_layer = CTX_data_view_layer(C);