From c567bc3706e57145749730501621034794d4f600 Mon Sep 17 00:00:00 2001 From: Robert Garrett Date: Tue, 26 Aug 2025 12:54:46 -0500 Subject: [PATCH] Fix: Filter for `BigRedButton` in it's observers There was no BRB component so the Observer systems would only filter for `Button`, which matched against the close button by accident. --- src/widgets/mod.rs | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/src/widgets/mod.rs b/src/widgets/mod.rs index 845b548..367090a 100644 --- a/src/widgets/mod.rs +++ b/src/widgets/mod.rs @@ -95,6 +95,7 @@ impl BigRedButton { fn spawn_big_red_button(commands: &mut ChildSpawnerCommands, text: impl Into) { let mut builder = commands.spawn(( Button, + BigRedButton, Node { width: Px(60.0), height: Px(60.0), @@ -124,7 +125,7 @@ impl BigRedButton { event: Trigger>, // Get button background and border colors so we can change them. // Filter for *changed* interactions, and only entities with a [`Button`] - mut button_colors: Query<(&mut BackgroundColor, &mut BorderColor), With