Rename Drawable::boxed to into_element and make containers generic
Multi-element are now generic over any drawable child, which can be converted into an element. Co-Authored-By: Nathan Sobo <nathan@zed.dev> Co-Authored-By: Max Brunsfeld <max@zed.dev>
This commit is contained in:
parent
4d433663bd
commit
03619dfa55
80 changed files with 1132 additions and 1434 deletions
|
@ -45,7 +45,7 @@ impl HighlightedText {
|
|||
pub fn render<V: View>(self, style: impl Into<LabelStyle>) -> Element<V> {
|
||||
Label::new(self.text, style)
|
||||
.with_highlights(self.highlight_positions)
|
||||
.boxed()
|
||||
.into_element()
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -177,6 +177,6 @@ impl PickerDelegate for RecentProjectsDelegate {
|
|||
.flex(1., false)
|
||||
.contained()
|
||||
.with_style(style.container)
|
||||
.named("match")
|
||||
.into_named_element("match")
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue