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
path: root/source
diff options
context:
space:
mode:
authorJulian Eisel <julian_eisel@web.de>2015-04-13 21:27:32 +0300
committerJulian Eisel <julian_eisel@web.de>2015-04-13 21:31:40 +0300
commit86fe894f8624fe64c5acde94de0e5d14e8803a55 (patch)
treead7d5d58c6d8e8fc35a1e62ea3cea0d1e934da80 /source
parentaed97c9efb3c7c035031bf70edd07f2d81e4e3e2 (diff)
Moar precision for Color Stop position slider in Color Ramps
Normal dragging now uses a precision of 0.01 instead of 0.1, shift+dragging now uses 0.001. (0.1 steps can still be done using ctrl) Requested by @venomgfx
Diffstat (limited to 'source')
-rw-r--r--source/blender/editors/interface/interface_templates.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/source/blender/editors/interface/interface_templates.c b/source/blender/editors/interface/interface_templates.c
index c36d25b8030..c3a9d17d255 100644
--- a/source/blender/editors/interface/interface_templates.c
+++ b/source/blender/editors/interface/interface_templates.c
@@ -1561,6 +1561,7 @@ static void colorband_buttons_layout(uiLayout *layout, uiBlock *block, ColorBand
row = uiLayoutRow(split, false);
uiItemR(row, &ptr, "position", 0, IFACE_("Pos"), ICON_NONE);
bt = block->buttons.last;
+ bt->a1 = 1.0f; /* gives a bit more precision for modifying position */
UI_but_func_set(bt, colorband_update_cb, bt, coba);
row = uiLayoutRow(layout, false);
@@ -1578,6 +1579,7 @@ static void colorband_buttons_layout(uiLayout *layout, uiBlock *block, ColorBand
row = uiLayoutRow(subsplit, false);
uiItemR(row, &ptr, "position", UI_ITEM_R_SLIDER, IFACE_("Pos"), ICON_NONE);
bt = block->buttons.last;
+ bt->a1 = 1.0f; /* gives a bit more precision for modifying position */
UI_but_func_set(bt, colorband_update_cb, bt, coba);
row = uiLayoutRow(split, false);