Skip to content

Commit

Permalink
#51. avoid cloning
Browse files Browse the repository at this point in the history
  • Loading branch information
wtholliday committed Aug 19, 2023
1 parent 9dc981e commit e45a5b4
Showing 1 changed file with 4 additions and 7 deletions.
11 changes: 4 additions & 7 deletions src/views/clip.rs
Original file line number Diff line number Diff line change
Expand Up @@ -49,13 +49,10 @@ path.pop();
path.push(0);
self.child.layout(path, args);
path.pop();
args.cx.layout.insert(
path.clone(),
LayoutBox {
rect: LocalRect::new(LocalPoint::zero(), args.sz),
offset: LocalOffset::zero(),
},
);
args.cx.update_layout(path, LayoutBox {
rect: LocalRect::new(LocalPoint::zero(), args.sz),
offset: LocalOffset::zero(),
});
// XXX: should this expand to the available space?
args.sz
}
Expand Down

0 comments on commit e45a5b4

Please sign in to comment.