Bug 1268749 part 3 - Hide :fullscreen pseudo-class from content when unprefixed API is disabled. r=heycam draft
authorXidorn Quan <quanxunzhen@gmail.com>
Mon, 02 May 2016 14:24:38 +1000
changeset 363183 3fbdf8fcde0064316b821d1ffde98e9e3f8185a1
parent 363182 e059616e5ec853c17614d119d58d3aeb5cb6c7af
child 363184 43eebf0398c3accbe2f901d482f9d4399bdf03e6
push id17127
push userxquan@mozilla.com
push dateWed, 04 May 2016 05:11:05 +0000
reviewersheycam
bugs1268749
milestone49.0a1
Bug 1268749 part 3 - Hide :fullscreen pseudo-class from content when unprefixed API is disabled. r=heycam MozReview-Commit-ID: 78hlOGCDKn0
layout/style/nsCSSPseudoClassList.h
--- a/layout/style/nsCSSPseudoClassList.h
+++ b/layout/style/nsCSSPseudoClassList.h
@@ -156,17 +156,20 @@ CSS_STATE_PSEUDO_CLASS(target, ":target"
 CSS_STATE_PSEUDO_CLASS(indeterminate, ":indeterminate", 0, "",
                        NS_EVENT_STATE_INDETERMINATE)
 
 CSS_STATE_PSEUDO_CLASS(mozDevtoolsHighlighted, ":-moz-devtools-highlighted", 0, "",
                        NS_EVENT_STATE_DEVTOOLS_HIGHLIGHTED)
 
 // Matches the element which is being displayed full-screen, and
 // any containing frames.
-CSS_STATE_PSEUDO_CLASS(fullscreen, ":fullscreen", 0, "", NS_EVENT_STATE_FULL_SCREEN)
+CSS_STATE_PSEUDO_CLASS(fullscreen, ":fullscreen",
+                       CSS_PSEUDO_CLASS_ENABLED_IN_UA_SHEETS_AND_CHROME,
+                       "full-screen-api.unprefix.enabled",
+                       NS_EVENT_STATE_FULL_SCREEN)
 CSS_STATE_PSEUDO_CLASS(mozFullScreen, ":-moz-full-screen", 0, "", NS_EVENT_STATE_FULL_SCREEN)
 
 // Matches any element which is an ancestor of the DOM full-screen element,
 // or an ancestor of a containing frame of the full-screen element.
 CSS_STATE_PSEUDO_CLASS(mozFullScreenAncestor, ":-moz-full-screen-ancestor", 0, "", NS_EVENT_STATE_FULL_SCREEN_ANCESTOR)
 
 // Matches if the element is focused and should show a focus ring
 CSS_STATE_PSEUDO_CLASS(mozFocusRing, ":-moz-focusring", 0, "", NS_EVENT_STATE_FOCUSRING)