Make image::Id actually opaque

This commit is contained in:
Héctor Ramón Jiménez 2024-05-01 01:52:49 +02:00
parent b52c7bb610
commit 58ea914ad2
No known key found for this signature in database
GPG key ID: 7CC46565708259A7
3 changed files with 40 additions and 24 deletions

View file

@ -109,7 +109,7 @@ impl Example {
fn view(&self) -> Element<'_, Message> {
let image: Element<Message> = if let Some(screenshot) = &self.screenshot
{
image(image::Handle::from_pixels(
image(image::Handle::from_rgba(
screenshot.size.width,
screenshot.size.height,
screenshot.clone(),