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:
authorCampbell Barton <ideasman42@gmail.com>2012-06-10 17:34:59 +0400
committerCampbell Barton <ideasman42@gmail.com>2012-06-10 17:34:59 +0400
commitf6e21881f5d0f86725836391d20949fe0343bd19 (patch)
tree12287d7789e683c69ce8c3157293edf7f0f283d2 /source/blender/editors/interface
parent219eca0f515f9a54953566539520fde37f2ea13b (diff)
change RNA_struct_find_function to accept a type rather then a PointerRNA, add a check duplicate functions are not defined.
Diffstat (limited to 'source/blender/editors/interface')
-rw-r--r--source/blender/editors/interface/interface_handlers.c7
1 files changed, 3 insertions, 4 deletions
diff --git a/source/blender/editors/interface/interface_handlers.c b/source/blender/editors/interface/interface_handlers.c
index 8753c427816..a2adbd7a143 100644
--- a/source/blender/editors/interface/interface_handlers.c
+++ b/source/blender/editors/interface/interface_handlers.c
@@ -3819,22 +3819,21 @@ static int ui_numedit_but_HISTOGRAM(uiBut *but, uiHandleButtonData *data, int mx
Histogram *hist = (Histogram *)but->poin;
/* rcti rect; */
int changed = 1;
- float /* dx, */ dy, yfac = 1.f; /* UNUSED */
+ float /* dx, */ dy; /* UNUSED */
/* rect.xmin = but->x1; rect.xmax = but->x2; */
/* rect.ymin = but->y1; rect.ymax = but->y2; */
/* dx = mx - data->draglastx; */ /* UNUSED */
dy = my - data->draglasty;
-
-
+
if (in_scope_resize_zone(but, data->dragstartx, data->dragstarty)) {
/* resize histogram widget itself */
hist->height = (but->y2 - but->y1) + (data->dragstarty - my);
}
else {
/* scale histogram values */
- yfac = MIN2(powf(hist->ymax, 2.f), 1.f) * 0.5f;
+ const float yfac = MIN2(powf(hist->ymax, 2.f), 1.f) * 0.5f;
hist->ymax += dy * yfac;
CLAMP(hist->ymax, 1.f, 100.f);