qweqwe
parent
a1cc8e4e86
commit
903ebaec95
|
|
@ -69,21 +69,23 @@ impl RecipeTabViewer {
|
||||||
egui::ComboBox::new("material_select_combobox", "")
|
egui::ComboBox::new("material_select_combobox", "")
|
||||||
.selected_text(&self.process_element_status.element.material.name)
|
.selected_text(&self.process_element_status.element.material.name)
|
||||||
.show_ui(ui, |ui| {
|
.show_ui(ui, |ui| {
|
||||||
if ui.button("<-").clicked() {
|
ui.horizontal(|ui| {
|
||||||
if self.mat_page > 0 {
|
if ui.button("<-").clicked() {
|
||||||
self.mat_page -= 1;
|
if self.mat_page > 0 {
|
||||||
self.update_materials();
|
self.mat_page -= 1;
|
||||||
|
self.update_materials();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
ui.monospace(self.mat_page.to_string());
|
||||||
ui.monospace(self.mat_page.to_string());
|
if ui.button("->").clicked() {
|
||||||
if ui.button("->").clicked() {
|
if self.materials.read().len().to_i32().unwrap()
|
||||||
if self.materials.read().len().to_i32().unwrap()
|
== misc::ELEMENTS_PER_PAGE
|
||||||
== misc::ELEMENTS_PER_PAGE
|
{
|
||||||
{
|
self.mat_page += 1;
|
||||||
self.mat_page += 1;
|
self.update_materials();
|
||||||
self.update_materials();
|
}
|
||||||
}
|
}
|
||||||
}
|
});
|
||||||
for mat in self.materials.read().clone().iter() {
|
for mat in self.materials.read().clone().iter() {
|
||||||
ui.selectable_value(
|
ui.selectable_value(
|
||||||
&mut self.process_element_status.element.material,
|
&mut self.process_element_status.element.material,
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue