From ad3d9256821c197c44c6565ef2797cf361f12ec9 Mon Sep 17 00:00:00 2001 From: Jacques Lucke Date: Mon, 18 Mar 2019 17:28:36 +0100 Subject: Fix T62636: Overlapping scrollbar in driver editor Instead of only `ymin` and `ymax`, `ANIM_channel_draw_widgets` has a rectangle as input now. This allows the caller to set a custom width for the channel. Some space types need the extra space for the scrollbar (drivers, graph), but the other don't have a scrollbar. Reviewers: brecht Differential Revision: https://developer.blender.org/D4543 --- source/blender/editors/space_action/action_draw.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'source/blender/editors/space_action') diff --git a/source/blender/editors/space_action/action_draw.c b/source/blender/editors/space_action/action_draw.c index 68d4e4f8ef0..997b18f2013 100644 --- a/source/blender/editors/space_action/action_draw.c +++ b/source/blender/editors/space_action/action_draw.c @@ -128,7 +128,9 @@ void draw_channel_names(bContext *C, bAnimContext *ac, ARegion *ar) IN_RANGE(ymaxc, v2d->cur.ymin, v2d->cur.ymax) ) { /* draw all channels using standard channel-drawing API */ - ANIM_channel_draw_widgets(C, ac, ale, block, yminc, ymaxc, channel_index); + rctf channel_rect; + BLI_rctf_init(&channel_rect, 0, v2d->cur.xmax, yminc, ymaxc); + ANIM_channel_draw_widgets(C, ac, ale, block, &channel_rect, channel_index); } /* adjust y-position for next one */ -- cgit v1.2.3