diff options
author | 2022-07-28 02:46:51 +0200 | |
---|---|---|
committer | 2022-07-28 02:46:51 +0200 | |
commit | 80688689aa4b15bc23824df899974a9094a77b07 (patch) | |
tree | bbfce1c91b9ee22990503a55d31d04cadf4093b7 /native/src/widget.rs | |
parent | a003e797e8a1bb5d365c1db5de6af88e61a47329 (diff) | |
download | iced-80688689aa4b15bc23824df899974a9094a77b07.tar.gz iced-80688689aa4b15bc23824df899974a9094a77b07.tar.bz2 iced-80688689aa4b15bc23824df899974a9094a77b07.zip |
Draft widget operations
Diffstat (limited to '')
-rw-r--r-- | native/src/widget.rs | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/native/src/widget.rs b/native/src/widget.rs index 9a4f373a..79f6ae3a 100644 --- a/native/src/widget.rs +++ b/native/src/widget.rs @@ -17,6 +17,7 @@ pub mod column; pub mod container; pub mod helpers; pub mod image; +pub mod operation; pub mod pane_grid; pub mod pick_list; pub mod progress_bar; @@ -26,6 +27,7 @@ pub mod rule; pub mod scrollable; pub mod slider; pub mod space; +pub mod state; pub mod svg; pub mod text; pub mod text_input; @@ -33,6 +35,9 @@ pub mod toggler; pub mod tooltip; pub mod tree; +mod action; +mod id; + #[doc(no_inline)] pub use button::Button; #[doc(no_inline)] @@ -76,6 +81,10 @@ pub use tooltip::Tooltip; #[doc(no_inline)] pub use tree::Tree; +pub use action::Action; +pub use id::Id; +pub use operation::Operation; + use crate::event::{self, Event}; use crate::layout; use crate::mouse; @@ -159,6 +168,14 @@ where /// Reconciliates the [`Widget`] with the provided [`Tree`]. fn diff(&self, _tree: &mut Tree) {} + /// Applies an [`Operation`] to the [`Widget`]. + fn operate( + &self, + _layout: Layout<'_>, + _operation: &mut dyn Operation<Message>, + ) { + } + /// Processes a runtime [`Event`]. /// /// By default, it does nothing. |