Inline helper functions in widget modules

This commit is contained in:
Héctor Ramón Jiménez 2024-03-08 13:34:36 +01:00
parent 7161cb40c7
commit 288025f514
No known key found for this signature in database
GPG key ID: 7CC46565708259A7
4 changed files with 553 additions and 669 deletions

View file

@ -717,8 +717,7 @@ where
}
}
/// Search list of options for a given query.
pub fn search<'a, T, A>(
fn search<'a, T, A>(
options: impl IntoIterator<Item = T> + 'a,
option_matchers: impl IntoIterator<Item = &'a A> + 'a,
query: &'a str,
@ -745,8 +744,7 @@ where
})
}
/// Build matchers from given list of options.
pub fn build_matchers<'a, T>(
fn build_matchers<'a, T>(
options: impl IntoIterator<Item = T> + 'a,
) -> Vec<String>
where
@ -769,6 +767,8 @@ pub struct Style<Theme> {
pub text_input: fn(&Theme, text_input::Status) -> text_input::Appearance,
/// The style of the [`Menu`] of the [`ComboBox`].
///
/// [`Menu`]: menu::Menu
pub menu: menu::Style<Theme>,
}