forked from StudioInfinity/dyna3
Rename the Element
structure to Sphere
This makes way for an `Element` trait. Some `Sphere` variables, like the arguments of the sphere insertion methods, have been renamed to show that they refer specifically to spheres. Others, like the argument of `ElementOutlineItem`, have kept their general names, because I expect them to become `Element` trait objects.
This commit is contained in:
parent
68abc2ad44
commit
a1e23543cb
4 changed files with 41 additions and 41 deletions
|
@ -141,7 +141,7 @@ fn RegulatorOutlineItem(regulator_key: RegulatorKey, element_key: ElementKey) ->
|
|||
|
||||
// a list item that shows an element in an outline view of an assembly
|
||||
#[component(inline_props)]
|
||||
fn ElementOutlineItem(key: ElementKey, element: assembly::Element) -> View {
|
||||
fn ElementOutlineItem(key: ElementKey, element: assembly::Sphere) -> View {
|
||||
let state = use_context::<AppState>();
|
||||
let class = state.selection.map(
|
||||
move |sel| if sel.contains(&key) { "selected" } else { "" }
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue