From 5ae726e02c4d6c9889ef7335d9bc80ef1992e34f Mon Sep 17 00:00:00 2001 From: Héctor Ramón Jiménez Date: Tue, 27 Jun 2023 19:41:03 +0200 Subject: Move `Screenshot` inside `window` module --- examples/screenshot/src/main.rs | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) (limited to 'examples') diff --git a/examples/screenshot/src/main.rs b/examples/screenshot/src/main.rs index ef2be4fe..83824535 100644 --- a/examples/screenshot/src/main.rs +++ b/examples/screenshot/src/main.rs @@ -1,16 +1,17 @@ -use ::image as img; -use ::image::ColorType; use iced::alignment; use iced::keyboard::KeyCode; use iced::theme::{Button, Container}; -use iced::widget::runtime::{CropError, Screenshot}; use iced::widget::{button, column, container, image, row, text, text_input}; +use iced::window::screenshot::{self, Screenshot}; use iced::{ event, executor, keyboard, subscription, Alignment, Application, Command, ContentFit, Element, Event, Length, Rectangle, Renderer, Subscription, Theme, }; +use ::image as img; +use ::image::ColorType; + fn main() -> iced::Result { env_logger::builder().format_timestamp(None).init(); @@ -21,7 +22,7 @@ struct Example { screenshot: Option, saved_png_path: Option>, png_saving: bool, - crop_error: Option, + crop_error: Option, x_input_value: Option, y_input_value: Option, width_input_value: Option, -- cgit