From b6805a80063a7a6d115b084bf2b0ddd4e22e010a Mon Sep 17 00:00:00 2001 From: Emil Ernerfeldt Date: Fri, 31 May 2024 17:10:46 +0200 Subject: [PATCH] Fix bug in ray-rect intersection test (#4595) This made submenu popups stay open when they perhaps shouldn't be --- crates/emath/src/rect.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/crates/emath/src/rect.rs b/crates/emath/src/rect.rs index c1a7f603..94422707 100644 --- a/crates/emath/src/rect.rs +++ b/crates/emath/src/rect.rs @@ -628,7 +628,7 @@ impl Rect { tmax = tmax.min(ty1.max(ty2)); } - tmin <= tmax + 0.0 <= tmin && tmin <= tmax } }