mirror of
https://github.com/servo/servo.git
synced 2025-08-05 13:40:08 +01:00
WR multi-document update
This commit is contained in:
parent
8db39f8fde
commit
101c426eb7
14 changed files with 119 additions and 86 deletions
|
@ -21,10 +21,20 @@ extern crate euclid;
|
|||
#[cfg(feature = "servo")] #[macro_use] extern crate heapsize_derive;
|
||||
extern crate selectors;
|
||||
#[cfg(feature = "servo")] #[macro_use] extern crate serde;
|
||||
#[cfg(feature = "servo")] extern crate webrender_api;
|
||||
|
||||
#[cfg(feature = "servo")] pub use webrender_api::DevicePixel;
|
||||
|
||||
use cssparser::{CowRcStr, Token};
|
||||
use selectors::parser::SelectorParseError;
|
||||
|
||||
/// One hardware pixel.
|
||||
///
|
||||
/// This unit corresponds to the smallest addressable element of the display hardware.
|
||||
#[cfg(not(feature = "servo"))]
|
||||
#[derive(Copy, Clone, Debug)]
|
||||
pub enum DevicePixel {}
|
||||
|
||||
/// Opaque type stored in type-unsafe work queues for parallel layout.
|
||||
/// Must be transmutable to and from `TNode`.
|
||||
pub type UnsafeNode = (usize, usize);
|
||||
|
@ -59,12 +69,6 @@ impl PinchZoomFactor {
|
|||
#[derive(Clone, Copy, Debug)]
|
||||
pub enum CSSPixel {}
|
||||
|
||||
/// One hardware pixel.
|
||||
///
|
||||
/// This unit corresponds to the smallest addressable element of the display hardware.
|
||||
#[derive(Copy, Clone, Debug)]
|
||||
pub enum DevicePixel {}
|
||||
|
||||
// In summary, the hierarchy of pixel units and the factors to convert from one to the next:
|
||||
//
|
||||
// DevicePixel
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue