summaryrefslogtreecommitdiffstats
path: root/src/window/icon.rs
diff options
context:
space:
mode:
authorLibravatar Héctor <hector@hecrj.dev>2025-01-14 11:56:51 +0000
committerLibravatar GitHub <noreply@github.com>2025-01-14 11:56:51 +0000
commita773e44b6139fae917e7040fabed8797bb75933c (patch)
tree1e87ea9c3143119bf29ba845b0b9151f114576ee /src/window/icon.rs
parent28797977584fcc42ae2c29b7adee4725e5aac1c5 (diff)
parent1a2e55ea6045cc7bc49bc5fb74474320f1d50079 (diff)
downloadiced-a773e44b6139fae917e7040fabed8797bb75933c.tar.gz
iced-a773e44b6139fae917e7040fabed8797bb75933c.tar.bz2
iced-a773e44b6139fae917e7040fabed8797bb75933c.zip
Merge pull request #2716 from Zarthus/master
Bump image from `0.24` to `0.25`
Diffstat (limited to 'src/window/icon.rs')
-rw-r--r--src/window/icon.rs4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/window/icon.rs b/src/window/icon.rs
index 7fe4ca7b..f453d580 100644
--- a/src/window/icon.rs
+++ b/src/window/icon.rs
@@ -13,7 +13,7 @@ use std::path::Path;
/// This will return an error in case the file is missing at run-time. You may prefer [`from_file_data`] instead.
#[cfg(feature = "image")]
pub fn from_file<P: AsRef<Path>>(icon_path: P) -> Result<Icon, Error> {
- let icon = image::io::Reader::open(icon_path)?.decode()?.to_rgba8();
+ let icon = image::ImageReader::open(icon_path)?.decode()?.to_rgba8();
Ok(icon::from_rgba(icon.to_vec(), icon.width(), icon.height())?)
}
@@ -27,7 +27,7 @@ pub fn from_file_data(
data: &[u8],
explicit_format: Option<image::ImageFormat>,
) -> Result<Icon, Error> {
- let mut icon = image::io::Reader::new(std::io::Cursor::new(data));
+ let mut icon = image::ImageReader::new(std::io::Cursor::new(data));
let icon_with_format = match explicit_format {
Some(format) => {