From 826efee7fbf0657c171b1c824b9870f724e9b733 Mon Sep 17 00:00:00 2001 From: Yousef Khadadeh Date: Tue, 28 Apr 2026 21:35:09 +0300 Subject: [PATCH] More options menu in file picker stops callbacks from other elements --- src/Screens/FileSelectScreen.cpp | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/src/Screens/FileSelectScreen.cpp b/src/Screens/FileSelectScreen.cpp index 65a0ab8..85cdc86 100644 --- a/src/Screens/FileSelectScreen.cpp +++ b/src/Screens/FileSelectScreen.cpp @@ -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(); + }); } } });