summaryrefslogtreecommitdiffstats
path: root/native/src/widget.rs
diff options
context:
space:
mode:
authorLibravatar Héctor Ramón <hector0193@gmail.com>2020-07-16 05:00:37 +0200
committerLibravatar GitHub <noreply@github.com>2020-07-16 05:00:37 +0200
commitda5da3958e3b7fe85e371846a795c4ae05cb2df7 (patch)
treecd9f353e005ebc9c49d987125ba168a87982c629 /native/src/widget.rs
parent62ec03a0afe8566a8f0b06675990a83fd65de1a9 (diff)
parent31c30fedd5e5ad74cc1f66162d7e5c0e5e3cf420 (diff)
downloadiced-da5da3958e3b7fe85e371846a795c4ae05cb2df7.tar.gz
iced-da5da3958e3b7fe85e371846a795c4ae05cb2df7.tar.bz2
iced-da5da3958e3b7fe85e371846a795c4ae05cb2df7.zip
Merge pull request #444 from hecrj/feature/overlay
Overlay support and `PickList` widget
Diffstat (limited to 'native/src/widget.rs')
-rw-r--r--native/src/widget.rs15
1 files changed, 14 insertions, 1 deletions
diff --git a/native/src/widget.rs b/native/src/widget.rs
index 4453145b..8539e519 100644
--- a/native/src/widget.rs
+++ b/native/src/widget.rs
@@ -26,6 +26,7 @@ pub mod column;
pub mod container;
pub mod image;
pub mod pane_grid;
+pub mod pick_list;
pub mod progress_bar;
pub mod radio;
pub mod row;
@@ -49,6 +50,8 @@ pub use image::Image;
#[doc(no_inline)]
pub use pane_grid::PaneGrid;
#[doc(no_inline)]
+pub use pick_list::PickList;
+#[doc(no_inline)]
pub use progress_bar::ProgressBar;
#[doc(no_inline)]
pub use radio::Radio;
@@ -67,7 +70,7 @@ pub use text::Text;
#[doc(no_inline)]
pub use text_input::TextInput;
-use crate::{layout, Clipboard, Event, Hasher, Layout, Length, Point};
+use crate::{layout, overlay, Clipboard, Event, Hasher, Layout, Length, Point};
/// A component that displays information and allows interaction.
///
@@ -175,4 +178,14 @@ where
_clipboard: Option<&dyn Clipboard>,
) {
}
+
+ /// Returns the overlay of the [`Element`], if there is any.
+ ///
+ /// [`Element`]: struct.Element.html
+ fn overlay(
+ &mut self,
+ _layout: Layout<'_>,
+ ) -> Option<overlay::Element<'_, Message, Renderer>> {
+ None
+ }
}