More options menu in file picker stops callbacks from other elements
This commit is contained in:
parent
d9172f4848
commit
826efee7fb
1 changed files with 5 additions and 3 deletions
|
|
@ -492,9 +492,11 @@ void FileSelectScreen::title_bar() {
|
|||
}
|
||||
}, LayoutElement::Callbacks{
|
||||
.onClick = [&](LayoutElement* l, const InputManager::MouseButtonCallbackArgs& m) {
|
||||
if(!l->mouseHovering && m.down) {
|
||||
moreOptionsMenu = MoreOptionsMenu::CLOSED;
|
||||
main.g.gui.set_to_layout();
|
||||
if(!l->mouseHovering && !m.down) {
|
||||
gui.set_post_callback_func_high_priority([&] { // Cancel actions on other buttons
|
||||
moreOptionsMenu = MoreOptionsMenu::CLOSED;
|
||||
main.g.gui.set_to_layout();
|
||||
});
|
||||
}
|
||||
}
|
||||
});
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue