Rename new_with_children to with_children

This commit is contained in:
Héctor Ramón Jiménez 2020-03-17 00:50:23 +01:00
parent ae123d8f14
commit a146e53eb0
2 changed files with 8 additions and 4 deletions

View File

@ -42,10 +42,12 @@ impl<'a, Message, Renderer> Column<'a, Message, Renderer> {
}
}
/// Creates a [`Column`] with children.
/// Creates a [`Column`] with the given elements.
///
/// [`Column`]: struct.Column.html
pub fn new_with_children(children: Vec<Element<'a, Message, Renderer>>) -> Self {
pub fn with_children(
children: Vec<Element<'a, Message, Renderer>>,
) -> Self {
Column {
spacing: 0,
padding: 0,

View File

@ -42,10 +42,12 @@ impl<'a, Message, Renderer> Row<'a, Message, Renderer> {
}
}
/// Creates a [`Row`] with children.
/// Creates a [`Row`] with the given elements.
///
/// [`Row`]: struct.Row.html
pub fn new_with_children(children: Vec<Element<'a, Message, Renderer>>) -> Self {
pub fn with_children(
children: Vec<Element<'a, Message, Renderer>>,
) -> Self {
Row {
spacing: 0,
padding: 0,