diff options
author | Campbell Barton <ideasman42@gmail.com> | 2012-09-28 05:47:45 +0400 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2012-09-28 05:47:45 +0400 |
commit | e1897f8c4adedac01fc00e0514cb22054106ed58 (patch) | |
tree | fda5c53289559b9251ea81c51ec3f65891d98624 | |
parent | 1418f69df3ff719be7e9d814149f18dddb56f8d3 (diff) |
fix [#32678] Changing RGB Curve via 'X' or 'Y' coordinates does not update
-rw-r--r-- | source/blender/editors/interface/interface_templates.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/source/blender/editors/interface/interface_templates.c b/source/blender/editors/interface/interface_templates.c index 2027bd84bb0..d3d4e01bc75 100644 --- a/source/blender/editors/interface/interface_templates.c +++ b/source/blender/editors/interface/interface_templates.c @@ -1749,11 +1749,11 @@ static void curvemap_buttons_redraw(bContext *C, void *UNUSED(arg1), void *UNUSE ED_region_tag_redraw(CTX_wm_region(C)); } -static void curvemap_buttons_update(bContext *UNUSED(C), void *UNUSED(arg1), void *cumap_v) +static void curvemap_buttons_update(bContext *C, void *arg1_v, void *cumap_v) { CurveMapping *cumap = cumap_v; - curvemapping_changed(cumap, TRUE); + rna_update_cb(C, arg1_v, NULL); } static void curvemap_buttons_reset(bContext *C, void *cb_v, void *cumap_v) @@ -1900,9 +1900,9 @@ static void curvemap_buttons_layout(uiLayout *layout, PointerRNA *ptr, char labe if (cmp) { uiLayoutRow(layout, TRUE); - uiBlockSetNFunc(block, curvemap_buttons_update, NULL, cumap); - uiDefButF(block, NUM, 0, "X", 0, 2 * UI_UNIT_Y, UI_UNIT_X * 10, UI_UNIT_Y, &cmp->x, 0.0f, 1.0f, 1, 5, ""); - uiDefButF(block, NUM, 0, "Y", 0, 1 * UI_UNIT_Y, UI_UNIT_X * 10, UI_UNIT_Y, &cmp->y, 0.0f, 1.0f, 1, 5, ""); + uiBlockSetNFunc(block, curvemap_buttons_update, MEM_dupallocN(cb), cumap); + bt = uiDefButF(block, NUM, 0, "X", 0, 2 * UI_UNIT_Y, UI_UNIT_X * 10, UI_UNIT_Y, &cmp->x, 0.0f, 1.0f, 1, 5, ""); + bt = uiDefButF(block, NUM, 0, "Y", 0, 1 * UI_UNIT_Y, UI_UNIT_X * 10, UI_UNIT_Y, &cmp->y, 0.0f, 1.0f, 1, 5, ""); } /* black/white levels */ |