diff --git a/crates/egui/src/containers/popup.rs b/crates/egui/src/containers/popup.rs index a9c00661d23..bd91a170d9a 100644 --- a/crates/egui/src/containers/popup.rs +++ b/crates/egui/src/containers/popup.rs @@ -594,7 +594,7 @@ impl<'a> Popup<'a> { }); // If the popup was just opened with a click, we don't want to immediately close it again. - let close_click = was_open_last_frame && ctx.input(|i| i.pointer.any_click()); + let close_click = was_open_last_frame && ctx.input(|i| i.pointer.any_pressed()); let closed_by_click = match close_behavior { PopupCloseBehavior::CloseOnClick => close_click,