diff options
author | Campbell Barton <ideasman42@gmail.com> | 2012-07-29 05:41:46 +0400 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2012-07-29 05:41:46 +0400 |
commit | 0cfd402a7f7783dd29aab802b6d34412c1c11492 (patch) | |
tree | b1a48bdb3778daefe1e2d75902278524ac282d5d /source | |
parent | 4fc078001de26260b7871bc467fd32b70eba0873 (diff) |
scale down histogram button movement by 10, was very sensitive
Diffstat (limited to 'source')
-rw-r--r-- | source/blender/editors/interface/interface_handlers.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/source/blender/editors/interface/interface_handlers.c b/source/blender/editors/interface/interface_handlers.c index 314a36fb3f0..ce9e63076fb 100644 --- a/source/blender/editors/interface/interface_handlers.c +++ b/source/blender/editors/interface/interface_handlers.c @@ -3868,9 +3868,9 @@ static int ui_numedit_but_HISTOGRAM(uiBut *but, uiHandleButtonData *data, int mx hist->height = (but->y2 - but->y1) + (data->dragstarty - my); } else { - /* scale histogram values */ + /* scale histogram values (dy / 10 for better control) */ const float yfac = minf(powf(hist->ymax, 2.0f), 1.0f) * 0.5f; - hist->ymax += dy * yfac; + hist->ymax += (dy * 0.1f) * yfac; /* 0.1 allows us to see HDR colors up to 10 */ CLAMP(hist->ymax, 0.1f, 100.f); |