mirror of
https://github.com/servo/servo.git
synced 2025-08-07 14:35:33 +01:00
Fix #6680
This commit is contained in:
parent
e10a524c81
commit
681b11c08b
7 changed files with 19 additions and 19 deletions
|
@ -32,7 +32,7 @@ use libc::uintptr_t;
|
|||
use msg::compositor_msg::{LayerId, LayerKind};
|
||||
use net_traits::image::base::Image;
|
||||
use paint_task::PaintLayer;
|
||||
use smallvec::SmallVec8;
|
||||
use smallvec::SmallVec;
|
||||
use std::collections::linked_list::{self, LinkedList};
|
||||
use std::fmt;
|
||||
use std::slice::Iter;
|
||||
|
@ -313,7 +313,7 @@ impl StackingContext {
|
|||
}
|
||||
|
||||
// Sort positioned children according to z-index.
|
||||
let mut positioned_children = SmallVec8::new();
|
||||
let mut positioned_children: SmallVec<[Arc<StackingContext>; 8]> = SmallVec::new();
|
||||
for kid in display_list.children.iter() {
|
||||
positioned_children.push((*kid).clone());
|
||||
}
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||
|
||||
use euclid::{Point2D, Rect, Size2D};
|
||||
use smallvec::SmallVec8;
|
||||
use smallvec::SmallVec;
|
||||
use std::borrow::ToOwned;
|
||||
use std::mem;
|
||||
use std::slice;
|
||||
|
@ -204,11 +204,11 @@ impl Font {
|
|||
}
|
||||
|
||||
pub struct FontGroup {
|
||||
pub fonts: SmallVec8<Rc<RefCell<Font>>>,
|
||||
pub fonts: SmallVec<[Rc<RefCell<Font>>; 8]>,
|
||||
}
|
||||
|
||||
impl FontGroup {
|
||||
pub fn new(fonts: SmallVec8<Rc<RefCell<Font>>>) -> FontGroup {
|
||||
pub fn new(fonts: SmallVec<[Rc<RefCell<Font>>; 8]>) -> FontGroup {
|
||||
FontGroup {
|
||||
fonts: fonts,
|
||||
}
|
||||
|
|
|
@ -13,7 +13,7 @@ use font_template::FontTemplateDescriptor;
|
|||
use fnv::FnvHasher;
|
||||
use platform::font::FontHandle;
|
||||
use platform::font_template::FontTemplateData;
|
||||
use smallvec::SmallVec8;
|
||||
use smallvec::SmallVec;
|
||||
use string_cache::Atom;
|
||||
use util::cache::HashCache;
|
||||
use util::geometry::Au;
|
||||
|
@ -159,7 +159,7 @@ impl FontContext {
|
|||
style.font_style == font_style::T::italic ||
|
||||
style.font_style == font_style::T::oblique);
|
||||
|
||||
let mut fonts = SmallVec8::new();
|
||||
let mut fonts: SmallVec<[Rc<RefCell<Font>>; 8]> = SmallVec::new();
|
||||
|
||||
for family in style.font_family.0.iter() {
|
||||
// GWTODO: Check on real pages if this is faster as Vec() or HashMap().
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue