diff --git a/components/style/properties/longhand/box.mako.rs b/components/style/properties/longhand/box.mako.rs index 580926889be..381ca4df1d9 100644 --- a/components/style/properties/longhand/box.mako.rs +++ b/components/style/properties/longhand/box.mako.rs @@ -94,8 +94,7 @@ ${helpers.single_keyword("position", "static absolute relative fixed", <%helpers:single_keyword_computed name="float" values="none left right" animatable="False" - need_clone="True" - gecko_ffi_name="mFloats"> + need_clone="True"> impl ToComputedValue for SpecifiedValue { type ComputedValue = computed_value::T; diff --git a/ports/geckolib/gecko_bindings/bindings.rs b/ports/geckolib/gecko_bindings/bindings.rs index 6edc03d88ff..5014e701cf4 100644 --- a/ports/geckolib/gecko_bindings/bindings.rs +++ b/ports/geckolib/gecko_bindings/bindings.rs @@ -169,6 +169,25 @@ extern "C" { pub fn Gecko_LocalName(element: *mut RawGeckoElement) -> *mut nsIAtom; pub fn Gecko_Namespace(element: *mut RawGeckoElement) -> *mut nsIAtom; pub fn Gecko_GetElementId(element: *mut RawGeckoElement) -> *mut nsIAtom; + pub fn Gecko_HasAttr(element: *mut RawGeckoElement, ns: *mut nsIAtom, + name: *mut nsIAtom) -> bool; + pub fn Gecko_AttrEquals(element: *mut RawGeckoElement, ns: *mut nsIAtom, + name: *mut nsIAtom, str: *mut nsIAtom, + ignoreCase: bool) -> bool; + pub fn Gecko_AttrDashEquals(element: *mut RawGeckoElement, + ns: *mut nsIAtom, name: *mut nsIAtom, + str: *mut nsIAtom) -> bool; + pub fn Gecko_AttrIncludes(element: *mut RawGeckoElement, ns: *mut nsIAtom, + name: *mut nsIAtom, str: *mut nsIAtom) -> bool; + pub fn Gecko_AttrHasSubstring(element: *mut RawGeckoElement, + ns: *mut nsIAtom, name: *mut nsIAtom, + str: *mut nsIAtom) -> bool; + pub fn Gecko_AttrHasPrefix(element: *mut RawGeckoElement, + ns: *mut nsIAtom, name: *mut nsIAtom, + str: *mut nsIAtom) -> bool; + pub fn Gecko_AttrHasSuffix(element: *mut RawGeckoElement, + ns: *mut nsIAtom, name: *mut nsIAtom, + str: *mut nsIAtom) -> bool; pub fn Gecko_ClassOrClassList(element: *mut RawGeckoElement, class_: *mut *mut nsIAtom, classList: *mut *mut *mut nsIAtom) -> u32; @@ -182,7 +201,6 @@ extern "C" { -> *mut nsIAtom; pub fn Gecko_AddRefAtom(aAtom: *mut nsIAtom); pub fn Gecko_ReleaseAtom(aAtom: *mut nsIAtom); - pub fn Gecko_HashAtom(aAtom: *mut nsIAtom) -> u32; pub fn Gecko_GetAtomAsUTF16(aAtom: *mut nsIAtom, aLength: *mut u32) -> *const u16; pub fn Gecko_AtomEqualsUTF8(aAtom: *mut nsIAtom, @@ -209,9 +227,6 @@ extern "C" { pub fn Gecko_CreateGradient(shape: u8, size: u8, repeating: bool, legacy_syntax: bool, stops: u32) -> *mut nsStyleGradient; - pub fn Gecko_SetGradientStop(gradient: *mut nsStyleGradient, index: u32, - location: *const nsStyleCoord, - color: nscolor, is_interpolation_hint: bool); pub fn Gecko_AddRefPrincipalArbitraryThread(aPtr: *mut ThreadSafePrincipalHolder); pub fn Gecko_ReleasePrincipalArbitraryThread(aPtr: @@ -282,6 +297,7 @@ extern "C" { set: *mut RawServoStyleSet); pub fn Servo_RestyleSubtree(node: *mut RawGeckoNode, set: *mut RawServoStyleSet); + pub fn Servo_StyleWorkerThreadCount() -> u32; pub fn Gecko_GetAttrAsUTF8(element: *mut RawGeckoElement, ns: *mut nsIAtom, name: *mut nsIAtom, length: *mut u32) diff --git a/ports/geckolib/gecko_bindings/structs_debug.rs b/ports/geckolib/gecko_bindings/structs_debug.rs index 4a21baf0a99..b08a42d5084 100644 --- a/ports/geckolib/gecko_bindings/structs_debug.rs +++ b/ports/geckolib/gecko_bindings/structs_debug.rs @@ -188,8 +188,6 @@ pub const NS_ERROR_MODULE_BASE_OFFSET: ::std::os::raw::c_uint = 69; pub const MOZ_STRING_WITH_OBSOLETE_API: ::std::os::raw::c_uint = 1; pub const NSID_LENGTH: ::std::os::raw::c_uint = 39; pub const NS_NUMBER_OF_FLAGS_IN_REFCNT: ::std::os::raw::c_uint = 2; -pub const _STL_PAIR_H: ::std::os::raw::c_uint = 1; -pub const _GLIBCXX_UTILITY: ::std::os::raw::c_uint = 1; pub const TWIPS_PER_POINT_INT: ::std::os::raw::c_uint = 20; pub const POINTS_PER_INCH_INT: ::std::os::raw::c_uint = 72; pub const NS_FONT_VARIANT_NORMAL: ::std::os::raw::c_uint = 0; @@ -2903,6 +2901,16 @@ pub struct pair<_T1, _T2> { pub first: _T1, pub second: _T2, } +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct __make_pair_return_impl<_Tp> { + pub _phantom0: ::std::marker::PhantomData<_Tp>, +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct __make_pair_return<_Tp> { + pub _phantom0: ::std::marker::PhantomData<_Tp>, +} pub type Float = f32; #[repr(i8)] #[derive(Debug, Copy, Clone, Eq, PartialEq, Hash)] @@ -2931,12 +2939,17 @@ pub enum SurfaceFormat { R8G8B8X8 = 3, A8R8G8B8 = 4, X8R8G8B8 = 5, - R5G6B5_UINT16 = 6, - A8 = 7, - YUV = 8, - NV12 = 9, - YUV422 = 10, - UNKNOWN = 11, + R8G8B8 = 6, + B8G8R8 = 7, + R5G6B5_UINT16 = 8, + A8 = 9, + YUV = 10, + NV12 = 11, + YUV422 = 12, + HSV = 13, + Lab = 14, + Depth = 15, + UNKNOWN = 16, } #[repr(i8)] #[derive(Debug, Copy, Clone, Eq, PartialEq, Hash)] @@ -3072,7 +3085,7 @@ pub enum FillRule { FILL_WINDING = 0, FILL_EVEN_ODD = 1, } pub enum AntialiasMode { NONE = 0, GRAY = 1, SUBPIXEL = 2, DEFAULT = 3, } #[repr(i8)] #[derive(Debug, Copy, Clone, Eq, PartialEq, Hash)] -pub enum Filter { GOOD = 0, LINEAR = 1, POINT = 2, SENTINEL = 3, } +pub enum SamplingFilter { GOOD = 0, LINEAR = 1, POINT = 2, SENTINEL = 3, } #[repr(i8)] #[derive(Debug, Copy, Clone, Eq, PartialEq, Hash)] pub enum PatternType { @@ -3159,16 +3172,6 @@ pub enum SideBits { eSideBitsLeftRight = 10, eSideBitsAll = 15, } -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct tuple_size<_Tp> { - pub _phantom0: ::std::marker::PhantomData<_Tp>, -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct tuple_element<_Tp> { - pub _phantom0: ::std::marker::PhantomData<_Tp>, -} pub type nscoord = i32; #[repr(C)] pub struct nsIntPoint { @@ -3269,7 +3272,7 @@ pub const eFamily_generic_count: FontFamilyType = * generic (e.g. serif, sans-serif), with the ability to distinguish * between unquoted and quoted names for serializaiton */ -#[repr(u32)] +#[repr(i32)] #[derive(Debug, Copy, Clone, Eq, PartialEq, Hash)] pub enum FontFamilyType { eFamily_none = 0, @@ -3389,7 +3392,7 @@ fn bindgen_test_layout_nsFont() { } #[repr(i8)] #[derive(Debug, Copy, Clone, Eq, PartialEq, Hash)] -pub enum StyleBoxSizing { Content = 0, Padding = 1, Border = 2, } +pub enum StyleBoxSizing { Content = 0, Border = 1, } #[repr(i32)] #[derive(Debug, Copy, Clone, Eq, PartialEq, Hash)] pub enum PlaybackDirection { _BindgenOpaqueEnum = 0, } @@ -5069,6 +5072,9 @@ pub enum nsStyleImageLayers_nsStyleStruct_h_unnamed_19 { maskMode = 10, composite = 11, } +#[repr(i8)] +#[derive(Debug, Copy, Clone, Eq, PartialEq, Hash)] +pub enum nsStyleImageLayers_LayerType { Background = 0, Mask = 1, } #[repr(C)] #[derive(Debug, Copy)] pub struct nsStyleImageLayers_Position { @@ -5645,8 +5651,8 @@ pub struct nsStyleDisplay { pub mContain: u8, pub mAppearance: u8, pub mPosition: u8, - pub mFloats: u8, - pub mOriginalFloats: u8, + pub mFloat: u8, + pub mOriginalFloat: u8, pub mBreakType: u8, pub mBreakInside: u8, pub mBreakBefore: bool, diff --git a/ports/geckolib/gecko_bindings/structs_release.rs b/ports/geckolib/gecko_bindings/structs_release.rs index 457f8c17295..c7559d71b43 100644 --- a/ports/geckolib/gecko_bindings/structs_release.rs +++ b/ports/geckolib/gecko_bindings/structs_release.rs @@ -188,8 +188,6 @@ pub const NS_ERROR_MODULE_BASE_OFFSET: ::std::os::raw::c_uint = 69; pub const MOZ_STRING_WITH_OBSOLETE_API: ::std::os::raw::c_uint = 1; pub const NSID_LENGTH: ::std::os::raw::c_uint = 39; pub const NS_NUMBER_OF_FLAGS_IN_REFCNT: ::std::os::raw::c_uint = 2; -pub const _STL_PAIR_H: ::std::os::raw::c_uint = 1; -pub const _GLIBCXX_UTILITY: ::std::os::raw::c_uint = 1; pub const TWIPS_PER_POINT_INT: ::std::os::raw::c_uint = 20; pub const POINTS_PER_INCH_INT: ::std::os::raw::c_uint = 72; pub const NS_FONT_VARIANT_NORMAL: ::std::os::raw::c_uint = 0; @@ -2882,6 +2880,16 @@ pub struct pair<_T1, _T2> { pub first: _T1, pub second: _T2, } +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct __make_pair_return_impl<_Tp> { + pub _phantom0: ::std::marker::PhantomData<_Tp>, +} +#[repr(C)] +#[derive(Debug, Copy, Clone)] +pub struct __make_pair_return<_Tp> { + pub _phantom0: ::std::marker::PhantomData<_Tp>, +} pub type Float = f32; #[repr(i8)] #[derive(Debug, Copy, Clone, Eq, PartialEq, Hash)] @@ -2910,12 +2918,17 @@ pub enum SurfaceFormat { R8G8B8X8 = 3, A8R8G8B8 = 4, X8R8G8B8 = 5, - R5G6B5_UINT16 = 6, - A8 = 7, - YUV = 8, - NV12 = 9, - YUV422 = 10, - UNKNOWN = 11, + R8G8B8 = 6, + B8G8R8 = 7, + R5G6B5_UINT16 = 8, + A8 = 9, + YUV = 10, + NV12 = 11, + YUV422 = 12, + HSV = 13, + Lab = 14, + Depth = 15, + UNKNOWN = 16, } #[repr(i8)] #[derive(Debug, Copy, Clone, Eq, PartialEq, Hash)] @@ -3051,7 +3064,7 @@ pub enum FillRule { FILL_WINDING = 0, FILL_EVEN_ODD = 1, } pub enum AntialiasMode { NONE = 0, GRAY = 1, SUBPIXEL = 2, DEFAULT = 3, } #[repr(i8)] #[derive(Debug, Copy, Clone, Eq, PartialEq, Hash)] -pub enum Filter { GOOD = 0, LINEAR = 1, POINT = 2, SENTINEL = 3, } +pub enum SamplingFilter { GOOD = 0, LINEAR = 1, POINT = 2, SENTINEL = 3, } #[repr(i8)] #[derive(Debug, Copy, Clone, Eq, PartialEq, Hash)] pub enum PatternType { @@ -3138,16 +3151,6 @@ pub enum SideBits { eSideBitsLeftRight = 10, eSideBitsAll = 15, } -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct tuple_size<_Tp> { - pub _phantom0: ::std::marker::PhantomData<_Tp>, -} -#[repr(C)] -#[derive(Debug, Copy, Clone)] -pub struct tuple_element<_Tp> { - pub _phantom0: ::std::marker::PhantomData<_Tp>, -} pub type nscoord = i32; #[repr(C)] pub struct nsIntPoint { @@ -3248,7 +3251,7 @@ pub const eFamily_generic_count: FontFamilyType = * generic (e.g. serif, sans-serif), with the ability to distinguish * between unquoted and quoted names for serializaiton */ -#[repr(u32)] +#[repr(i32)] #[derive(Debug, Copy, Clone, Eq, PartialEq, Hash)] pub enum FontFamilyType { eFamily_none = 0, @@ -3368,7 +3371,7 @@ fn bindgen_test_layout_nsFont() { } #[repr(i8)] #[derive(Debug, Copy, Clone, Eq, PartialEq, Hash)] -pub enum StyleBoxSizing { Content = 0, Padding = 1, Border = 2, } +pub enum StyleBoxSizing { Content = 0, Border = 1, } #[repr(i32)] #[derive(Debug, Copy, Clone, Eq, PartialEq, Hash)] pub enum PlaybackDirection { _BindgenOpaqueEnum = 0, } @@ -5047,6 +5050,9 @@ pub enum nsStyleImageLayers_nsStyleStruct_h_unnamed_19 { maskMode = 10, composite = 11, } +#[repr(i8)] +#[derive(Debug, Copy, Clone, Eq, PartialEq, Hash)] +pub enum nsStyleImageLayers_LayerType { Background = 0, Mask = 1, } #[repr(C)] #[derive(Debug, Copy)] pub struct nsStyleImageLayers_Position { @@ -5623,8 +5629,8 @@ pub struct nsStyleDisplay { pub mContain: u8, pub mAppearance: u8, pub mPosition: u8, - pub mFloats: u8, - pub mOriginalFloats: u8, + pub mFloat: u8, + pub mOriginalFloat: u8, pub mBreakType: u8, pub mBreakInside: u8, pub mBreakBefore: bool,