1
0
mirror of https://github.com/emilk/egui.git synced 2026-06-27 23:13:13 -04:00

Update MSRV to Rust 1.70.0 (#3310)

* Update to Rust 1.70

* Fix renamed clippy lint

* Use let-else more

* Code cleanup

* Remove derelict Safety comments

* Enable more clippy lints
This commit is contained in:
Emil Ernerfeldt
2023-09-06 07:59:24 +02:00
committed by GitHub
parent 707ca04c08
commit 82704bebbf
52 changed files with 102 additions and 87 deletions

View File

@@ -35,7 +35,6 @@ pub fn pos_from_touch_event(
// search for the touch we previously used for the position
// (unfortunately, `event.touches()` is not a rust collection):
(0..event.touches().length())
.into_iter()
.map(|i| event.touches().get(i).unwrap())
.find(|touch| egui::TouchId::from(touch.identifier()) == *touch_id_for_pos)
} else {

View File

@@ -148,9 +148,7 @@ impl WebPainter for WebPainterWgpu {
) -> Result<(), JsValue> {
let size_in_pixels = [self.canvas.width(), self.canvas.height()];
let render_state = if let Some(render_state) = &self.render_state {
render_state
} else {
let Some(render_state) = &self.render_state else {
return Err(JsValue::from_str(
"Can't paint, wgpu renderer was already disposed",
));