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:
authorJulian Eisel <julian@blender.org>2022-11-02 19:57:36 +0300
committerJulian Eisel <julian@blender.org>2022-11-02 19:57:36 +0300
commit15fe7f3d936a8f2a0bb82671cdf0a13f943cfdf7 (patch)
tree53465968c1d12b33477a1714b39c4ca420f1c699 /source/blender/editors/interface/interface_region_menu_popup.cc
parent31746e1baa14fd3a64053aec82a40ffc07f95973 (diff)
Fix arrow key menu navigation using wrong direction
Steps to reproduce were: * Right click in 3D View (context menu) press up or down arrow. Or: * Ctrl+Shift+O (Open Recent menu) press up or down arrow.
Diffstat (limited to 'source/blender/editors/interface/interface_region_menu_popup.cc')
-rw-r--r--source/blender/editors/interface/interface_region_menu_popup.cc4
1 files changed, 3 insertions, 1 deletions
diff --git a/source/blender/editors/interface/interface_region_menu_popup.cc b/source/blender/editors/interface/interface_region_menu_popup.cc
index 0d19390d508..b8c8cdf5fa4 100644
--- a/source/blender/editors/interface/interface_region_menu_popup.cc
+++ b/source/blender/editors/interface/interface_region_menu_popup.cc
@@ -189,7 +189,7 @@ static void ui_popup_menu_create_block(bContext *C,
pup->block = UI_block_begin(C, nullptr, block_name, UI_EMBOSS_PULLDOWN);
if (!pup->but) {
- pup->block->flag |= UI_BLOCK_IS_FLIP | UI_BLOCK_NO_FLIP;
+ pup->block->flag |= UI_BLOCK_NO_FLIP;
}
if (title && title[0]) {
pup->block->flag |= UI_BLOCK_POPUP_MEMORY;
@@ -486,6 +486,8 @@ uiPopupMenu *UI_popup_menu_begin_ex(bContext *C,
pup->title = title;
ui_popup_menu_create_block(C, pup, title, block_name);
+ /* Further buttons will be laid out top to bottom by default. */
+ pup->block->flag |= UI_BLOCK_IS_FLIP;
/* create in advance so we can let buttons point to retval already */
pup->block->handle = MEM_cnew<uiPopupBlockHandle>(__func__);