Stylo: Bug 1355408 - add support for @-moz-document

This commit is contained in:
Fernando Jiménez Moreno 2017-05-09 10:41:03 +02:00
parent 9c9bd17871
commit b22e0e9494
12 changed files with 338 additions and 24 deletions

View file

@ -194,6 +194,7 @@ use gecko_bindings::structs::EffectCompositor_CascadeLevel;
use gecko_bindings::structs::UpdateAnimationsTasks;
use gecko_bindings::structs::LengthParsingMode;
use gecko_bindings::structs::InheritTarget;
use gecko_bindings::structs::URLMatchingFunction;
pub type nsTArrayBorrowed_uintptr_t<'a> = &'a mut ::gecko_bindings::structs::nsTArray<usize>;
pub type ServoCssRulesStrong = ::gecko_bindings::sugar::ownership::Strong<ServoCssRules>;
pub type ServoCssRulesBorrowed<'a> = &'a ServoCssRules;
@ -1549,6 +1550,14 @@ extern "C" {
extern "C" {
pub fn Gecko_UnregisterProfilerThread();
}
extern "C" {
pub fn Gecko_DocumentRule_UseForPresentation(arg1:
RawGeckoPresContextBorrowed,
aPattern: *const nsACString,
aURLMatchingFunction:
URLMatchingFunction)
-> bool;
}
extern "C" {
pub fn Servo_Element_ClearData(node: RawGeckoElementBorrowed);
}

View file

@ -2130,6 +2130,18 @@ pub mod root {
ComplexColorValue ) , "::" , stringify ! (
_mOwningThread ) ));
}
#[repr(i32)]
/**
* Enum defining the type of URL matching function for a @-moz-document rule
* condition.
*/
#[derive(Debug, Copy, Clone, PartialEq, Eq, Hash)]
pub enum URLMatchingFunction {
eURL = 0,
eURLPrefix = 1,
eDomain = 2,
eRegExp = 3,
}
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct DocumentRule {

View file

@ -2036,6 +2036,18 @@ pub mod root {
ComplexColorValue ) , "::" , stringify ! ( mRefCnt
) ));
}
#[repr(i32)]
/**
* Enum defining the type of URL matching function for a @-moz-document rule
* condition.
*/
#[derive(Debug, Copy, Clone, PartialEq, Eq, Hash)]
pub enum URLMatchingFunction {
eURL = 0,
eURLPrefix = 1,
eDomain = 2,
eRegExp = 3,
}
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct DocumentRule {