new version of egui

master
aintercourse 2 years ago
parent 434f0caa32
commit 8e5cd4d778

1463
Cargo.lock generated

File diff suppressed because it is too large Load Diff

@ -9,7 +9,7 @@ publish = false
[dependencies]
eframe = "0.19.0"
eframe = "0.21.3"
serialport= "4.1.0"
async-std = "*"
local-encoding="*"

@ -29,6 +29,7 @@ enum ScreenCurrent {
Diagnosis,
WorkCycle,
PortSelection,
CalibrationStend,
}
impl Default for ScreenCurrent {
@ -44,7 +45,7 @@ struct Screen {
#[derive(Debug)]
struct ScreenSelector {
screen: [Screen; 5],
screen: [Screen; 6],
}
impl Default for ScreenSelector {
@ -71,6 +72,10 @@ impl Default for ScreenSelector {
id: (ScreenCurrent::PortSelection),
name: ("Выбор порта".to_string()),
},
Screen {
id: (ScreenCurrent::CalibrationStend),
name: ("Калибровочный стенд".to_string()),
},
],
}
}
@ -157,9 +162,9 @@ struct MyApp {
}
impl eframe::App for MyApp {
fn clear_color(&self, _visuals: &egui::Visuals) -> egui::Rgba {
egui::Rgba::TRANSPARENT // Make sure we don't paint anything behind the rounded corners
}
//fn clear_color(&self, _visuals: &egui::Visuals) -> egui::Rgba {
// egui::Rgba::TRANSPARENT // Make sure we don't paint anything behind the rounded corners
//}
fn update(&mut self, ctx: &egui::Context, frame: &mut eframe::Frame) {
let (tx, rx): (Sender<u8>, Receiver<u8>) = mpsc::channel();

Loading…
Cancel
Save