[Bf-blender-cvs] [06e3e2f21c9] blender-v2.93-release: Fix T90364: buttons (partially) behind animchannel search block search

Philipp Oeser noreply at git.blender.org
Mon Aug 23 09:35:49 CEST 2021


Commit: 06e3e2f21c92f672b3b88f8f0e028c02e9cfc013
Author: Philipp Oeser
Date:   Mon Aug 2 14:12:44 2021 +0200
Branches: blender-v2.93-release
https://developer.blender.org/rB06e3e2f21c92f672b3b88f8f0e028c02e9cfc013

Fix T90364: buttons (partially) behind animchannel search block search

When channels are scrolled to be (partially) behind the search bar,
their widget buttons would still be interactive, preventing the seach
buttons to be usable.

We have to make sure the events are consumed from the search and dont
reach other UI blocks.
We can do so by flagging the block `UI_BLOCK_CLIP_EVENTS` -- but also
have to make sure the bounds are calculated correctly (otherwise the
check relating `UI_BLOCK_CLIP_EVENTS` in `ui_but_find_mouse_over_ex` wont
trigger properly.

Maniphest Tasks: T90364

Differential Revision: https://developer.blender.org/D12103

===================================================================

M	source/blender/editors/animation/time_scrub_ui.c

===================================================================

diff --git a/source/blender/editors/animation/time_scrub_ui.c b/source/blender/editors/animation/time_scrub_ui.c
index 034378399b9..c814e494b30 100644
--- a/source/blender/editors/animation/time_scrub_ui.c
+++ b/source/blender/editors/animation/time_scrub_ui.c
@@ -244,6 +244,10 @@ void ED_time_scrub_channel_search_draw(const bContext *C, ARegion *region, bDope
   UI_block_align_end(block);
   UI_block_layout_resolve(block, NULL, NULL);
 
+  /* Make sure the events are consumed from the search and dont reach other UI blocks since this is
+   * drawn on top of animchannels. */
+  UI_block_flag_enable(block, UI_BLOCK_CLIP_EVENTS);
+  UI_block_bounds_set_normal(block, 0);
   UI_block_end(C, block);
   UI_block_draw(C, block);



More information about the Bf-blender-cvs mailing list