mirror of
https://github.com/servo/servo.git
synced 2025-08-04 21:20:23 +01:00
style: Fix Gecko build.
This commit is contained in:
parent
3d909132ba
commit
da5283d066
4 changed files with 14 additions and 3 deletions
|
@ -15,6 +15,7 @@ servo = [
|
||||||
"mozjs",
|
"mozjs",
|
||||||
"serde",
|
"serde",
|
||||||
"serde_bytes",
|
"serde_bytes",
|
||||||
|
"servo_channel",
|
||||||
"string_cache",
|
"string_cache",
|
||||||
"time",
|
"time",
|
||||||
"url",
|
"url",
|
||||||
|
@ -34,7 +35,7 @@ selectors = { path = "../selectors" }
|
||||||
serde = { version = "1.0.27", optional = true }
|
serde = { version = "1.0.27", optional = true }
|
||||||
serde_bytes = { version = "0.10", optional = true }
|
serde_bytes = { version = "0.10", optional = true }
|
||||||
servo_arc = { path = "../servo_arc" }
|
servo_arc = { path = "../servo_arc" }
|
||||||
servo_channel = {path = "../channel"}
|
servo_channel = { path = "../channel", optional = true }
|
||||||
smallbitvec = "2.1.0"
|
smallbitvec = "2.1.0"
|
||||||
smallvec = "0.6"
|
smallvec = "0.6"
|
||||||
string_cache = { version = "0.7", optional = true }
|
string_cache = { version = "0.7", optional = true }
|
||||||
|
|
|
@ -59,6 +59,7 @@ extern crate serde;
|
||||||
#[cfg(feature = "servo")]
|
#[cfg(feature = "servo")]
|
||||||
extern crate serde_bytes;
|
extern crate serde_bytes;
|
||||||
extern crate servo_arc;
|
extern crate servo_arc;
|
||||||
|
#[cfg(feature = "servo")]
|
||||||
extern crate servo_channel;
|
extern crate servo_channel;
|
||||||
extern crate smallbitvec;
|
extern crate smallbitvec;
|
||||||
extern crate smallvec;
|
extern crate smallvec;
|
||||||
|
@ -1024,6 +1025,7 @@ where
|
||||||
|
|
||||||
// Placeholder for unique case where internals of Sender cannot be measured.
|
// Placeholder for unique case where internals of Sender cannot be measured.
|
||||||
// malloc size of is 0 macro complains about type supplied!
|
// malloc size of is 0 macro complains about type supplied!
|
||||||
|
#[cfg(feature = "servo")]
|
||||||
impl<T> MallocSizeOf for servo_channel::Sender<T> {
|
impl<T> MallocSizeOf for servo_channel::Sender<T> {
|
||||||
fn size_of(&self, _ops: &mut MallocSizeOfOps) -> usize {
|
fn size_of(&self, _ops: &mut MallocSizeOfOps) -> usize {
|
||||||
0
|
0
|
||||||
|
|
|
@ -4,6 +4,10 @@
|
||||||
|
|
||||||
//! CSS transitions and animations.
|
//! CSS transitions and animations.
|
||||||
|
|
||||||
|
// NOTE(emilio): This code isn't really executed in Gecko, but we don't want to
|
||||||
|
// compile it out so that people remember it exists, thus the cfg'd Sender
|
||||||
|
// import.
|
||||||
|
|
||||||
use Atom;
|
use Atom;
|
||||||
use bezier::Bezier;
|
use bezier::Bezier;
|
||||||
use context::SharedStyleContext;
|
use context::SharedStyleContext;
|
||||||
|
@ -15,8 +19,11 @@ use properties::longhands::animation_direction::computed_value::single_value::T
|
||||||
use properties::longhands::animation_play_state::computed_value::single_value::T as AnimationPlayState;
|
use properties::longhands::animation_play_state::computed_value::single_value::T as AnimationPlayState;
|
||||||
use rule_tree::CascadeLevel;
|
use rule_tree::CascadeLevel;
|
||||||
use servo_arc::Arc;
|
use servo_arc::Arc;
|
||||||
|
#[cfg(feature = "servo")]
|
||||||
use servo_channel::Sender;
|
use servo_channel::Sender;
|
||||||
use std::fmt;
|
use std::fmt;
|
||||||
|
#[cfg(feature = "gecko")]
|
||||||
|
use std::sync::mpsc::Sender;
|
||||||
use stylesheets::keyframes_rule::{KeyframesAnimation, KeyframesStep, KeyframesStepValue};
|
use stylesheets::keyframes_rule::{KeyframesAnimation, KeyframesStep, KeyframesStepValue};
|
||||||
use timer::Timer;
|
use timer::Timer;
|
||||||
use values::computed::Time;
|
use values::computed::Time;
|
||||||
|
@ -25,6 +32,7 @@ use values::computed::transform::TimingFunction;
|
||||||
use values::generics::box_::AnimationIterationCount;
|
use values::generics::box_::AnimationIterationCount;
|
||||||
use values::generics::transform::{StepPosition, TimingFunction as GenericTimingFunction};
|
use values::generics::transform::{StepPosition, TimingFunction as GenericTimingFunction};
|
||||||
|
|
||||||
|
|
||||||
/// This structure represents a keyframes animation current iteration state.
|
/// This structure represents a keyframes animation current iteration state.
|
||||||
///
|
///
|
||||||
/// If the iteration count is infinite, there's no other state, otherwise we
|
/// If the iteration count is infinite, there's no other state, otherwise we
|
||||||
|
|
|
@ -322,7 +322,7 @@ fn all_pointer_capabilities(device: &Device) -> PointerCapabilities {
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|
||||||
#[derive(Debug, Copy, Clone, FromPrimitive, ToCss, Parse)]
|
#[derive(Clone, Copy, Debug, FromPrimitive, Parse, ToCss)]
|
||||||
#[repr(u8)]
|
#[repr(u8)]
|
||||||
enum Pointer {
|
enum Pointer {
|
||||||
None,
|
None,
|
||||||
|
@ -356,7 +356,7 @@ fn eval_any_pointer(device: &Device, query_value: Option<Pointer>) -> bool {
|
||||||
eval_pointer_capabilities(query_value, all_pointer_capabilities(device))
|
eval_pointer_capabilities(query_value, all_pointer_capabilities(device))
|
||||||
}
|
}
|
||||||
|
|
||||||
#[derive(Debug, Copy, Clone, FromPrimitive, ToCss, Parse)]
|
#[derive(Clone, Copy, Debug, FromPrimitive, Parse, ToCss)]
|
||||||
#[repr(u8)]
|
#[repr(u8)]
|
||||||
enum Hover {
|
enum Hover {
|
||||||
None,
|
None,
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue