1
0
mirror of https://github.com/emilk/egui.git synced 2026-08-30 05:10:03 -04:00

Deprecate old Slider constructors in favor of Slider::new

This commit is contained in:
Emil Ernerfeldt
2021-03-27 16:07:18 +01:00
parent 5481aa8d98
commit de439b6e21
16 changed files with 58 additions and 55 deletions

View File

@@ -28,7 +28,7 @@ impl epi::App for MyApp {
ui.label("Your name: ");
ui.text_edit_singleline(name);
});
ui.add(egui::Slider::u32(age, 0..=120).text("age"));
ui.add(egui::Slider::new(age, 0..=120).text("age"));
if ui.button("Click each year").clicked() {
*age += 1;
}