mirror of
https://github.com/servo/servo.git
synced 2025-08-06 14:10:11 +01:00
Implemented fullscreen top layer
This commit is contained in:
parent
a34c8f952e
commit
386c0f80ed
6 changed files with 38 additions and 7 deletions
|
@ -34,6 +34,17 @@ ${helpers.single_keyword(
|
|||
spec="Internal (not web-exposed)",
|
||||
)}
|
||||
|
||||
// An internal-only attribute for elements in a top layer
|
||||
// https://fullscreen.spec.whatwg.org/#top-layer
|
||||
${helpers.single_keyword(
|
||||
"-servo-top-layer",
|
||||
"none top",
|
||||
products="servo",
|
||||
animation_value_type="none",
|
||||
enabled_in="ua",
|
||||
spec="Internal (not web-exposed)",
|
||||
)}
|
||||
|
||||
${helpers.single_keyword(
|
||||
"position",
|
||||
"static absolute relative fixed sticky",
|
||||
|
|
|
@ -3627,11 +3627,12 @@ impl<'a> StyleBuilder<'a> {
|
|||
Position::Absolute | Position::Fixed)
|
||||
}
|
||||
|
||||
/// Whether this style has a top-layer style. That's implemented in Gecko
|
||||
/// via the -moz-top-layer property, but servo doesn't have any concept of a
|
||||
/// top layer (yet, it's needed for fullscreen).
|
||||
/// Whether this style has a top-layer style.
|
||||
#[cfg(feature = "servo")]
|
||||
pub fn in_top_layer(&self) -> bool { false }
|
||||
pub fn in_top_layer(&self) -> bool {
|
||||
matches!(self.get_box().clone__servo_top_layer(),
|
||||
longhands::_servo_top_layer::computed_value::T::Top)
|
||||
}
|
||||
|
||||
/// Whether this style has a top-layer style.
|
||||
#[cfg(feature = "gecko")]
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue