Rename the 'other' Apple Pay Button type to 'donate'
authorandersca@apple.com <andersca@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Sat, 19 Nov 2016 02:45:25 +0000 (02:45 +0000)
committerandersca@apple.com <andersca@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Sat, 19 Nov 2016 02:45:25 +0000 (02:45 +0000)
https://bugs.webkit.org/show_bug.cgi?id=164978

Reviewed by Dean Jackson.

* DerivedSources.make:
* WebCorePrefix.h:
* css/CSSPrimitiveValueMappings.h:
(WebCore::CSSPrimitiveValue::CSSPrimitiveValue):
(WebCore::CSSPrimitiveValue::operator ApplePayButtonType):
* css/CSSValueKeywords.in:
* css/parser/CSSParser.cpp:
(WebCore::isValidKeywordPropertyAndValue):
* css/parser/CSSParserFastPaths.cpp:
(WebCore::CSSParserFastPaths::isValidKeywordPropertyAndValue):
* rendering/RenderThemeCocoa.mm:
(WebCore::toPKPaymentButtonType):
* rendering/style/RenderStyleConstants.h:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@208914 268f45cc-cd09-0410-ab3c-d52691b4dbfc

Source/WebCore/ChangeLog
Source/WebCore/DerivedSources.make
Source/WebCore/WebCorePrefix.h
Source/WebCore/css/CSSPrimitiveValueMappings.h
Source/WebCore/css/CSSValueKeywords.in
Source/WebCore/css/parser/CSSParser.cpp
Source/WebCore/css/parser/CSSParserFastPaths.cpp
Source/WebCore/rendering/RenderThemeCocoa.mm
Source/WebCore/rendering/style/RenderStyleConstants.h

index 2dfb704..fd2ad89 100644 (file)
@@ -1,3 +1,24 @@
+2016-11-18  Anders Carlsson  <andersca@apple.com>
+
+        Rename the 'other' Apple Pay Button type to 'donate'
+        https://bugs.webkit.org/show_bug.cgi?id=164978
+
+        Reviewed by Dean Jackson.
+
+        * DerivedSources.make:
+        * WebCorePrefix.h:
+        * css/CSSPrimitiveValueMappings.h:
+        (WebCore::CSSPrimitiveValue::CSSPrimitiveValue):
+        (WebCore::CSSPrimitiveValue::operator ApplePayButtonType):
+        * css/CSSValueKeywords.in:
+        * css/parser/CSSParser.cpp:
+        (WebCore::isValidKeywordPropertyAndValue):
+        * css/parser/CSSParserFastPaths.cpp:
+        (WebCore::CSSParserFastPaths::isValidKeywordPropertyAndValue):
+        * rendering/RenderThemeCocoa.mm:
+        (WebCore::toPKPaymentButtonType):
+        * rendering/style/RenderStyleConstants.h:
+
 2016-11-18  Myles C. Maxfield  <mmaxfield@apple.com>
 
         [WebGL2] Implement texStorage2D()
index 30c1ece..8f6860e 100644 (file)
@@ -833,8 +833,6 @@ ADDITIONAL_EVENT_TARGET_FACTORY =
 
 -include WebCoreDerivedSourcesAdditions.make
 
--include ApplePayWebCoreDerivedSourcesAdditions.make
-
 JS_BINDING_IDLS += $(ADDITIONAL_BINDING_IDLS)
 
 all : $(ADDITIONAL_BINDING_IDLS:%.idl=JS%.h)
index 682b7bc..6ee3020 100644 (file)
 #define delete ("if you use new/delete make sure to include config.h at the top of the file"()) 
 #endif
 
-#if USE(APPLE_INTERNAL_SDK) && __has_include(<WebKitAdditions/ApplePayWebCorePrefixAdditions.h>)
-#include <WebKitAdditions/ApplePayWebCorePrefixAdditions.h>
-#endif
-
 /* When C++ exceptions are disabled, the C++ library defines |try| and |catch|
  * to allow C++ code that expects exceptions to build. These definitions
  * interfere with Objective-C++ uses of Objective-C exception handlers, which
index e9bd81c..40721f7 100644 (file)
@@ -5488,8 +5488,8 @@ template<> inline CSSPrimitiveValue::CSSPrimitiveValue(ApplePayButtonType e)
     case ApplePayButtonType::SetUp:
         m_value.valueID = CSSValueSetUp;
         break;
-    case ApplePayButtonType::Other:
-        m_value.valueID = CSSValueOther;
+    case ApplePayButtonType::Donate:
+        m_value.valueID = CSSValueDonate;
         break;
 
     default:
@@ -5508,8 +5508,8 @@ template<> inline CSSPrimitiveValue::operator ApplePayButtonType() const
         return ApplePayButtonType::Buy;
     case CSSValueSetUp:
         return ApplePayButtonType::SetUp;
-    case CSSValueOther:
-        return ApplePayButtonType::Other;
+    case CSSValueDonate:
+        return ApplePayButtonType::Donate;
     default:
         break;
     }
index b69aec2..2f9bf91 100644 (file)
@@ -1292,7 +1292,7 @@ white-outline
 plain
 buy
 set-up
-other
+donate
 #endif
 
 // font-synthesis
index 5a08db3..0d8bbbe 100644 (file)
@@ -1057,8 +1057,8 @@ static inline bool isValidKeywordPropertyAndValue(CSSPropertyID propertyId, int
         if (valueID == CSSValueWhite || valueID == CSSValueWhiteOutline || valueID == CSSValueBlack)
             return true;
         break;
-    case CSSPropertyApplePayButtonType: // plain | buy | set-up | other
-        if (valueID == CSSValuePlain || valueID == CSSValueBuy || valueID == CSSValueSetUp || valueID == CSSValueOther)
+    case CSSPropertyApplePayButtonType: // plain | buy | set-up | donate
+        if (valueID == CSSValuePlain || valueID == CSSValueBuy || valueID == CSSValueSetUp || valueID == CSSValueDonate)
             return true;
         break;
 #endif
index bb91292..f0a7ec5 100644 (file)
@@ -781,8 +781,8 @@ bool CSSParserFastPaths::isValidKeywordPropertyAndValue(CSSPropertyID propertyId
 #if ENABLE(APPLE_PAY)
     case CSSPropertyApplePayButtonStyle: // white | white-outline | black
         return valueID == CSSValueWhite || valueID == CSSValueWhiteOutline || valueID == CSSValueBlack;
-    case CSSPropertyApplePayButtonType: // plain | buy | set-up | other
-        return valueID == CSSValuePlain || valueID == CSSValueBuy || valueID == CSSValueSetUp || valueID == CSSValueOther;
+    case CSSPropertyApplePayButtonType: // plain | buy | set-up | donate
+        return valueID == CSSValuePlain || valueID == CSSValueBuy || valueID == CSSValueSetUp || valueID == CSSValueDonate;
 #endif
     case CSSPropertyWebkitNbspMode: // normal | space
         return valueID == CSSValueNormal || valueID == CSSValueSpace;
index ae6ec5a..8a98bd3 100644 (file)
@@ -78,7 +78,7 @@ static PKPaymentButtonType toPKPaymentButtonType(ApplePayButtonType type)
         return PKPaymentButtonTypeBuy;
     case ApplePayButtonType::SetUp:
         return PKPaymentButtonTypeSetUp;
-    case ApplePayButtonType::Other:
+    case ApplePayButtonType::Donate:
         // FIXME: Use a named constant here.
         return (PKPaymentButtonType)4;
     }
index 3bfec9c..24f8008 100644 (file)
@@ -706,7 +706,7 @@ enum class ApplePayButtonType {
     Plain,
     Buy,
     SetUp,
-    Other,
+    Donate,
 };
 #endif