[Mac] Add a feature flag for 'view-mode' Media Feature, disable it on Mac
https://bugs.webkit.org/show_bug.cgi?id=111297

Reviewed by Kenneth Rohde Christiansen.

Source/WebCore: 

The 'view-mode' Media Feature spec is implemented in WebCore but
there is no WebKit support for it on Mac.
Because of this, we always lie and report a windowed view mode.

This patch add a feature flag for the feature and disable it on
Mac so that we stop reporting incorrect default values.

* WebCore.exp.in:
* css/CSSValueKeywords.in:
* css/MediaFeatureNames.h:
(MediaFeatureNames):
* css/MediaQueryEvaluator.cpp:
* css/MediaQueryExp.cpp:
(WebCore::featureWithCSSValueID):
(WebCore::featureWithoutValue):
* page/Page.cpp:
(WebCore::Page::Page):
* page/Page.h:
(Page):

Source/WebKit2: 

* WebProcess/InjectedBundle/API/c/WKBundlePage.cpp:
* WebProcess/InjectedBundle/API/c/WKBundlePagePrivate.h:
* WebProcess/WebPage/WebPage.cpp:
* WebProcess/WebPage/WebPage.h:

Source/WTF: 

* wtf/FeatureDefines.h: Add a new feature flag for the view-mode
CSS media: ENABLE_VIEW_MODE_CSS_MEDIA.

Tools: 

* WebKitTestRunner/InjectedBundle/TestRunner.cpp:
(WTR::TestRunner::setViewModeMediaFeature):

LayoutTests: 

* platform/mac/TestExpectations:
Mark the view-mode tests as failing to track any regression
or crash in this area.


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@145255 268f45cc-cd09-0410-ab3c-d52691b4dbfc
diff --git a/Source/WebCore/css/CSSValueKeywords.in b/Source/WebCore/css/CSSValueKeywords.in
index 9bdb2f4..3df68cb 100644
--- a/Source/WebCore/css/CSSValueKeywords.in
+++ b/Source/WebCore/css/CSSValueKeywords.in
@@ -841,12 +841,14 @@
 //default
 sRGB
 
+#if defined(ENABLE_VIEW_MODE_CSS_MEDIA) && ENABLE_VIEW_MODE_CSS_MEDIA
 // (-webkit-view-mode:) media feature:
 floating
 fullscreen
 maximized
 minimized
 windowed
+#endif // ENABLE_VIEW_MODE_CSS_MEDIA
 
 // -webkit-hyphenate-limit-lines
 no-limit