mirror of
https://github.com/emilk/egui.git
synced 2026-08-31 05:40:03 -04:00
Use Rust edition 2024 (#7280)
This commit is contained in:
@@ -19,13 +19,13 @@ impl File {
|
||||
return Err(format!(
|
||||
"failed to load {uri:?}: {} {} {response_text}",
|
||||
response.status, response.status_text
|
||||
))
|
||||
));
|
||||
}
|
||||
None => {
|
||||
return Err(format!(
|
||||
"failed to load {uri:?}: {} {}",
|
||||
response.status, response.status_text
|
||||
))
|
||||
));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,9 +1,8 @@
|
||||
use ahash::HashMap;
|
||||
use egui::{
|
||||
decode_animated_image_uri, has_gif_magic_header,
|
||||
ColorImage, FrameDurations, Id, decode_animated_image_uri, has_gif_magic_header,
|
||||
load::{BytesPoll, ImageLoadResult, ImageLoader, ImagePoll, LoadError, SizeHint},
|
||||
mutex::Mutex,
|
||||
ColorImage, FrameDurations, Id,
|
||||
};
|
||||
use image::AnimationDecoder as _;
|
||||
use std::{io::Cursor, mem::size_of, sync::Arc, time::Duration};
|
||||
|
||||
@@ -1,9 +1,8 @@
|
||||
use ahash::HashMap;
|
||||
use egui::{
|
||||
decode_animated_image_uri,
|
||||
ColorImage, decode_animated_image_uri,
|
||||
load::{Bytes, BytesPoll, ImageLoadResult, ImageLoader, ImagePoll, LoadError, SizeHint},
|
||||
mutex::Mutex,
|
||||
ColorImage,
|
||||
};
|
||||
use image::ImageFormat;
|
||||
use std::{mem::size_of, path::Path, sync::Arc, task::Poll};
|
||||
|
||||
@@ -1,17 +1,17 @@
|
||||
use std::{
|
||||
mem::size_of,
|
||||
sync::{
|
||||
atomic::{AtomicU64, Ordering::Relaxed},
|
||||
Arc,
|
||||
atomic::{AtomicU64, Ordering::Relaxed},
|
||||
},
|
||||
};
|
||||
|
||||
use ahash::HashMap;
|
||||
|
||||
use egui::{
|
||||
ColorImage,
|
||||
load::{BytesPoll, ImageLoadResult, ImageLoader, ImagePoll, LoadError, SizeHint},
|
||||
mutex::Mutex,
|
||||
ColorImage,
|
||||
};
|
||||
|
||||
struct Entry {
|
||||
|
||||
@@ -1,11 +1,10 @@
|
||||
use ahash::HashMap;
|
||||
use egui::{
|
||||
decode_animated_image_uri, has_webp_header,
|
||||
ColorImage, FrameDurations, Id, decode_animated_image_uri, has_webp_header,
|
||||
load::{BytesPoll, ImageLoadResult, ImageLoader, ImagePoll, LoadError, SizeHint},
|
||||
mutex::Mutex,
|
||||
ColorImage, FrameDurations, Id,
|
||||
};
|
||||
use image::{codecs::webp::WebPDecoder, AnimationDecoder as _, ColorType, ImageDecoder as _, Rgba};
|
||||
use image::{AnimationDecoder as _, ColorType, ImageDecoder as _, Rgba, codecs::webp::WebPDecoder};
|
||||
use std::{io::Cursor, mem::size_of, sync::Arc, time::Duration};
|
||||
|
||||
#[derive(Clone)]
|
||||
@@ -55,7 +54,7 @@ impl WebP {
|
||||
unreachable => {
|
||||
return Err(format!(
|
||||
"Unreachable WebP color type, expected Rgb8/Rgba8, got {unreachable:?}"
|
||||
))
|
||||
));
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user