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:
authorPhilipp Oeser <info@graphics-engineer.com>2021-08-02 15:12:44 +0300
committerPhilipp Oeser <info@graphics-engineer.com>2021-08-03 14:20:50 +0300
commitdbd34a5acb3d0be2bdbad54a427153de49e47f8e (patch)
treecefd0aa443afc6bbbf79fa9e6ef8b34e7259bff2
parentb35a96e195b100dbad68721065f431b168b7945b (diff)
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
-rw-r--r--source/blender/editors/animation/time_scrub_ui.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/source/blender/editors/animation/time_scrub_ui.c b/source/blender/editors/animation/time_scrub_ui.c
index 6af033f3cf2..182e61e53b6 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);