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:
authorJoshua Leung <aligorith@gmail.com>2015-12-12 07:43:00 +0300
committerJoshua Leung <aligorith@gmail.com>2015-12-12 07:43:00 +0300
commit50fde02b422a1a1dbc71a7bc95a061e46ce73b33 (patch)
tree631d2de1db5a6321241685f8015f740da64c7a85 /source/blender/makesrna/intern/rna_define.c
parent85bbf7e04f2694a160219e07fb44711f157e6237 (diff)
parentdc98a3b0a74b0e91ad424195ce488a9b14f13e73 (diff)
Merge branch 'master' into GPencil_Editing_Stage3
Conflicts: source/blender/editors/transform/transform_manipulator.c
Diffstat (limited to 'source/blender/makesrna/intern/rna_define.c')
-rw-r--r--source/blender/makesrna/intern/rna_define.c14
1 files changed, 13 insertions, 1 deletions
diff --git a/source/blender/makesrna/intern/rna_define.c b/source/blender/makesrna/intern/rna_define.c
index 3b01305110c..f4b2c15b304 100644
--- a/source/blender/makesrna/intern/rna_define.c
+++ b/source/blender/makesrna/intern/rna_define.c
@@ -1315,7 +1315,7 @@ void RNA_def_property_ui_icon(PropertyRNA *prop, int icon, bool consecutive)
* The values hare are a little confusing:
*
* \param step: Used as the value to increase/decrease when clicking on number buttons,
- * \as well as scaling mouse input for click-dragging number buttons.
+ * as well as scaling mouse input for click-dragging number buttons.
* For floats this is (step * UI_PRECISION_FLOAT_SCALE), why? - nobody knows.
* For ints, whole values are used.
*
@@ -2875,6 +2875,18 @@ PropertyRNA *RNA_def_float_rotation(StructOrFunctionRNA *cont_, const char *iden
return prop;
}
+PropertyRNA *RNA_def_float_distance(StructOrFunctionRNA *cont_, const char *identifier,
+ float default_value, float hardmin, float hardmax, const char *ui_name,
+ const char *ui_description, float softmin, float softmax)
+{
+ PropertyRNA *prop = RNA_def_float(cont_, identifier, default_value,
+ hardmin, hardmax, ui_name, ui_description,
+ softmin, softmax);
+ RNA_def_property_subtype(prop, PROP_DISTANCE);
+
+ return prop;
+}
+
PropertyRNA *RNA_def_float_array(StructOrFunctionRNA *cont_, const char *identifier, int len,
const float *default_value, float hardmin, float hardmax, const char *ui_name,
const char *ui_description, float softmin, float softmax)