Skip to content

Commit

Permalink
Hide expand/collapse functionality when hidden
Browse files Browse the repository at this point in the history
  • Loading branch information
Norlock committed Jul 17, 2024
1 parent 316adf4 commit 539ac54
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion crates/egui_demo_lib/src/demo/demo_app_windows.rs
Original file line number Diff line number Diff line change
Expand Up @@ -326,7 +326,7 @@ impl DemoWindows {
self.about_window_action = Some(WindowAction::ToggleShow);
}

if ui.button("Toggle expand/collapse about").clicked() {
if self.about_is_open && ui.button("Toggle expand/collapse about").clicked() {
self.about_window_action = Some(WindowAction::ToggleExpand);
}
}
Expand Down

0 comments on commit 539ac54

Please sign in to comment.