Create iced_widget subcrate and re-organize the whole codebase

This commit is contained in:
Héctor Ramón Jiménez 2023-03-04 05:37:11 +01:00
parent c54409d171
commit 3a0d34c024
No known key found for this signature in database
GPG key ID: 140CC052C94F138E
209 changed files with 1959 additions and 2183 deletions

View file

@ -1,18 +1,11 @@
//! Build window-based GUI applications.
mod action;
mod event;
mod mode;
mod redraw_request;
mod user_attention;
pub use action::Action;
pub use event::Event;
pub use mode::Mode;
pub use redraw_request::RedrawRequest;
pub use user_attention::UserAttention;
use crate::core::time::Instant;
use crate::core::window::Event;
use crate::subscription::{self, Subscription};
use crate::time::Instant;
/// Subscribes to the frames of the window of the running application.
///
@ -24,7 +17,7 @@ use crate::time::Instant;
/// animations without missing any frames.
pub fn frames() -> Subscription<Instant> {
subscription::raw_events(|event, _status| match event {
crate::Event::Window(Event::RedrawRequested(at)) => Some(at),
iced_core::Event::Window(Event::RedrawRequested(at)) => Some(at),
_ => None,
})
}