mirror of
https://github.com/servo/servo.git
synced 2025-08-05 13:40:08 +01:00
Switch Arc<Box<Image>> to Arc<Image> for perf boost.
Image used to be a trait, but no longer is, so boxing it is no longer necessary.
This commit is contained in:
parent
a8b0fb1e79
commit
5b593a3d32
7 changed files with 13 additions and 13 deletions
|
@ -414,7 +414,7 @@ impl FragmentDisplayListBuilding for Fragment {
|
|||
|
||||
// Use `background-size` to get the size.
|
||||
let mut bounds = *absolute_bounds;
|
||||
let image_size = self.compute_background_image_size(style, &bounds, &**image);
|
||||
let image_size = self.compute_background_image_size(style, &bounds, &*image);
|
||||
|
||||
// Clip.
|
||||
//
|
||||
|
@ -1016,7 +1016,7 @@ impl FragmentDisplayListBuilding for Fragment {
|
|||
&*self.style,
|
||||
Cursor::DefaultCursor),
|
||||
(*clip).clone()),
|
||||
image: Arc::new(box png::Image {
|
||||
image: Arc::new(png::Image {
|
||||
width: width as u32,
|
||||
height: height as u32,
|
||||
pixels: PixelsByColorType::RGBA8(canvas_data),
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue