Skip to content

Commit 03df3f9

Browse files
rayguo17BudiArb
authored andcommitted
saving workspace for input range
Signed-off-by: Tin Tun Aung <tin.tun.aung1@huawei.com>
1 parent ad3ef1d commit 03df3f9

1 file changed

Lines changed: 27 additions & 0 deletions

File tree

style/servo/selector_parser.rs

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -67,6 +67,9 @@ pub enum PseudoElement {
6767
ColorSwatch,
6868
FileSelectorButton,
6969
Placeholder,
70+
ServoRangeProgress,
71+
ServoRangeThumb,
72+
ServoRangeTrack,
7073

7174
// Private, Servo-specific implemented pseudos. Only matchable in UA sheet.
7275
ServoTextControlInnerContainer,
@@ -102,6 +105,9 @@ impl ToCss for PseudoElement {
102105
ColorSwatch => "::color-swatch",
103106
FileSelectorButton => "::file-selector-button",
104107
Placeholder => "::placeholder",
108+
ServoRangeProgress => "::-servo-range-progress",
109+
ServoRangeTrack => "::-servo-range-track",
110+
ServoRangeThumb => "::-servo-range-thumb",
105111
ServoTextControlInnerContainer => "::-servo-text-control-inner-container",
106112
ServoTextControlInnerEditor => "::-servo-text-control-inner-editor",
107113
ServoAnonymousBox => "::-servo-anonymous-box",
@@ -255,6 +261,9 @@ impl PseudoElement {
255261
| PseudoElement::Marker
256262
| PseudoElement::Placeholder
257263
| PseudoElement::DetailsContent
264+
| PseudoElement::ServoRangeProgress
265+
| PseudoElement::ServoRangeThumb
266+
| PseudoElement::ServoRangeTrack
258267
| PseudoElement::ServoTextControlInnerContainer
259268
| PseudoElement::ServoTextControlInnerEditor => PseudoElementCascadeType::Lazy,
260269
PseudoElement::ServoAnonymousBox
@@ -692,6 +701,24 @@ impl<'a, 'i> ::selectors::Parser<'i> for SelectorParser<'a> {
692701
}
693702
ServoTextControlInnerEditor
694703
},
704+
"-servo-range-progress" => {
705+
if !self.in_user_agent_stylesheet() {
706+
return Err(location.new_custom_error(SelectorParseErrorKind::UnexpectedIdent(name.clone())))
707+
}
708+
ServoRangeProgress
709+
},
710+
"-servo-range-thumb" => {
711+
if !self.in_user_agent_stylesheet() {
712+
return Err(location.new_custom_error(SelectorParseErrorKind::UnexpectedIdent(name.clone())))
713+
}
714+
ServoRangeThumb
715+
},
716+
"-servo-range-track" => {
717+
if !self.in_user_agent_stylesheet() {
718+
return Err(location.new_custom_error(SelectorParseErrorKind::UnexpectedIdent(name.clone())))
719+
}
720+
ServoRangeTrack
721+
},
695722
"-servo-anonymous-box" => {
696723
if !self.in_user_agent_stylesheet() {
697724
return Err(location.new_custom_error(SelectorParseErrorKind::UnexpectedIdent(name.clone())))

0 commit comments

Comments
 (0)