mirror of
https://github.com/zen-browser/desktop.git
synced 2025-07-10 02:06:24 +02:00
feat: add backwards compatibility for moz-bool-pref after removal
This commit is contained in:
parent
12bdf7541f
commit
7abae9d69e
3 changed files with 124 additions and 0 deletions
20
src/servo/components/style/queries/feature-rs.patch
Normal file
20
src/servo/components/style/queries/feature-rs.patch
Normal file
|
@ -0,0 +1,20 @@
|
|||
diff --git a/servo/components/style/queries/feature.rs b/servo/components/style/queries/feature.rs
|
||||
index a9a4decb178234037a6d285ddd3206bd52f214e5..18ea220a14cbb59ef3c9809cb679f8fdb5352f98 100644
|
||||
--- a/servo/components/style/queries/feature.rs
|
||||
+++ b/servo/components/style/queries/feature.rs
|
||||
@@ -6,6 +6,7 @@
|
||||
|
||||
use crate::parser::ParserContext;
|
||||
use crate::values::computed::{self, CSSPixelLength, Ratio, Resolution};
|
||||
+use crate::values::AtomString;
|
||||
use crate::Atom;
|
||||
use cssparser::Parser;
|
||||
use selectors::kleene_value::KleeneValue;
|
||||
@@ -44,6 +45,7 @@ pub enum Evaluator {
|
||||
OptionalNumberRatio(QueryFeatureGetter<Option<Ratio>>),
|
||||
/// A resolution.
|
||||
Resolution(QueryFeatureGetter<Resolution>),
|
||||
+ String(fn(&computed::Context, Option<&AtomString>) -> KleeneValue),
|
||||
/// A keyword value.
|
||||
Enumerated {
|
||||
/// The parser to get a discriminant given a string.
|
Loading…
Add table
Add a link
Reference in a new issue