mirror of
https://github.com/servo/servo.git
synced 2025-08-03 04:30:10 +01:00
Don't allocate strings in Debug for DisplayItem
This commit is contained in:
parent
3da51b4d2a
commit
97d6351202
1 changed files with 12 additions and 12 deletions
|
@ -736,20 +736,20 @@ impl fmt::Debug for DisplayItem {
|
|||
f,
|
||||
"{} @ {:?} {:?}",
|
||||
match *self {
|
||||
DisplayItem::Rectangle(_) => "Rectangle".to_owned(),
|
||||
DisplayItem::Text(_) => "Text".to_owned(),
|
||||
DisplayItem::Image(_) => "Image".to_owned(),
|
||||
DisplayItem::Border(_) => "Border".to_owned(),
|
||||
DisplayItem::Gradient(_) => "Gradient".to_owned(),
|
||||
DisplayItem::RadialGradient(_) => "RadialGradient".to_owned(),
|
||||
DisplayItem::Line(_) => "Line".to_owned(),
|
||||
DisplayItem::BoxShadow(_) => "BoxShadow".to_owned(),
|
||||
DisplayItem::PushTextShadow(_) => "PushTextShadow".to_owned(),
|
||||
DisplayItem::PopAllTextShadows(_) => "PopTextShadow".to_owned(),
|
||||
DisplayItem::Iframe(_) => "Iframe".to_owned(),
|
||||
DisplayItem::Rectangle(_) => "Rectangle",
|
||||
DisplayItem::Text(_) => "Text",
|
||||
DisplayItem::Image(_) => "Image",
|
||||
DisplayItem::Border(_) => "Border",
|
||||
DisplayItem::Gradient(_) => "Gradient",
|
||||
DisplayItem::RadialGradient(_) => "RadialGradient",
|
||||
DisplayItem::Line(_) => "Line",
|
||||
DisplayItem::BoxShadow(_) => "BoxShadow",
|
||||
DisplayItem::PushTextShadow(_) => "PushTextShadow",
|
||||
DisplayItem::PopAllTextShadows(_) => "PopTextShadow",
|
||||
DisplayItem::Iframe(_) => "Iframe",
|
||||
DisplayItem::PushStackingContext(_) |
|
||||
DisplayItem::PopStackingContext(_) |
|
||||
DisplayItem::DefineClipScrollNode(_) => "".to_owned(),
|
||||
DisplayItem::DefineClipScrollNode(_) => "",
|
||||
},
|
||||
self.bounds(),
|
||||
self.base().clip_rect
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue