mirror of
https://github.com/servo/servo.git
synced 2025-08-11 08:25:32 +01:00
Remove the extra level of GeckoDeclarationBlock.
This commit is contained in:
parent
f967647226
commit
0b5c6fb701
4 changed files with 64 additions and 148 deletions
|
@ -9,10 +9,11 @@
|
|||
#![allow(unsafe_code)]
|
||||
|
||||
use app_units::Au;
|
||||
use gecko_bindings::bindings::{RawServoStyleSheet, ServoComputedValues};
|
||||
use gecko_bindings::bindings::{RawServoStyleSheet, ServoComputedValues, RawServoDeclarationBlock};
|
||||
use gecko_bindings::structs::nsStyleCoord_CalcValue;
|
||||
use gecko_bindings::sugar::ownership::{HasArcFFI, HasFFI};
|
||||
use properties::ComputedValues;
|
||||
use parking_lot::RwLock;
|
||||
use properties::{ComputedValues, PropertyDeclarationBlock};
|
||||
use stylesheets::Stylesheet;
|
||||
use values::computed::{CalcLengthOrPercentage, LengthOrPercentage, LengthOrPercentageOrAuto};
|
||||
|
||||
|
@ -25,6 +26,11 @@ unsafe impl HasFFI for ComputedValues {
|
|||
}
|
||||
unsafe impl HasArcFFI for ComputedValues {}
|
||||
|
||||
unsafe impl HasFFI for RwLock<PropertyDeclarationBlock> {
|
||||
type FFIType = RawServoDeclarationBlock;
|
||||
}
|
||||
unsafe impl HasArcFFI for RwLock<PropertyDeclarationBlock> {}
|
||||
|
||||
impl From<CalcLengthOrPercentage> for nsStyleCoord_CalcValue {
|
||||
fn from(other: CalcLengthOrPercentage) -> nsStyleCoord_CalcValue {
|
||||
let has_percentage = other.percentage.is_some();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue