Implement focus_previous operation

This commit is contained in:
Héctor Ramón Jiménez 2022-08-04 03:24:44 +02:00
parent 54ad92ce91
commit 6eb3dd7e5e
No known key found for this signature in database
GPG key ID: 140CC052C94F138E
3 changed files with 60 additions and 12 deletions

View file

@ -215,6 +215,14 @@ pub use svg::Svg;
use crate::Command;
use iced_native::widget::operation;
/// Focuses the previous focusable widget.
pub fn focus_previous<Message>() -> Command<Message>
where
Message: 'static,
{
Command::widget(operation::focus_previous())
}
/// Focuses the next focusable widget.
pub fn focus_next<Message>() -> Command<Message>
where