add comment

This commit is contained in:
Simon Gardling 2022-02-24 22:34:59 -05:00
parent 0ab9c6d17b
commit 3e778a39f4

View File

@ -150,6 +150,7 @@ impl epi::App for MathApp {
let max_x_old = *max_x;
let max_x_response = ui.add(egui::Slider::new(max_x, X_RANGE).text("Max X"));
// Checks bounds, and if they are invalid, fix them
if min_x >= max_x {
if max_x_response.changed() {
*max_x = max_x_old;