Remove some PLATFORM(IOS) code in Color.h/cpp
authorsimon.fraser@apple.com <simon.fraser@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 5 Sep 2014 18:57:06 +0000 (18:57 +0000)
committersimon.fraser@apple.com <simon.fraser@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 5 Sep 2014 18:57:06 +0000 (18:57 +0000)
https://bugs.webkit.org/show_bug.cgi?id=136582

Reviewed by Dan Bates.
Source/WebCore:

Remove Color::tap which is unused, and remove createCGColorWithDeviceWhite()
which was only called in one file in WebKit.

* WebCore.exp.in:
* platform/graphics/Color.h:
* platform/graphics/cg/ColorCG.cpp:
(WebCore::createCGColorWithDeviceWhite): Deleted.

Source/WebKit/ios:

createCGColorWithDeviceWhite() is only used here so make it a local static function.

* WebView/WebPDFViewIOS.mm:
(createCGColorWithDeviceWhite):

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

Source/WebCore/ChangeLog
Source/WebCore/WebCore.exp.in
Source/WebCore/platform/graphics/Color.h
Source/WebCore/platform/graphics/cg/ColorCG.cpp
Source/WebKit/ios/ChangeLog
Source/WebKit/ios/WebView/WebPDFViewIOS.mm

index 3c9576a167670c9d9a8dd9d831f0a0f377581306..b3389b66e363f4ffa7ee9d8480626a521320f217 100644 (file)
@@ -1,3 +1,18 @@
+2014-09-05  Simon Fraser  <simon.fraser@apple.com>
+
+        Remove some PLATFORM(IOS) code in Color.h/cpp
+        https://bugs.webkit.org/show_bug.cgi?id=136582
+
+        Reviewed by Dan Bates.
+
+        Remove Color::tap which is unused, and remove createCGColorWithDeviceWhite()
+        which was only called in one file in WebKit.
+
+        * WebCore.exp.in:
+        * platform/graphics/Color.h:
+        * platform/graphics/cg/ColorCG.cpp:
+        (WebCore::createCGColorWithDeviceWhite): Deleted.
+
 2014-09-05  Beth Dakin  <bdakin@apple.com>
 
         ScrollablArea::handleWheelEvent() should return early if the ScrollableArea is not 
index d6c6cb5f047656bacd926b453e74d4438d0b4b7b..0f3f0a3b21f5ea6da377b79b7aad5cc41fd22a27 100644 (file)
@@ -2811,14 +2811,6 @@ _wkSetLayerContentsScale
 __ZN7WebCore20ResourceHandleClient22willCacheResponseAsyncEPNS_14ResourceHandleEPK20_CFCachedURLResponse
 #endif
 
-#if PLATFORM(IOS) && defined(__LP64__) && __LP64__
-__ZN7WebCore28createCGColorWithDeviceWhiteEdd
-#endif
-
-#if PLATFORM(IOS) && !(defined(__LP64__) && __LP64__)
-__ZN7WebCore28createCGColorWithDeviceWhiteEff
-#endif
-
 #if PLATFORM(IOS) || __MAC_OS_X_VERSION_MIN_REQUIRED >= 1090
 __ZN7WebCore15ProtectionSpace28encodingRequiresPlatformDataEP20NSURLProtectionSpace
 __ZN7WebCore16DiskCacheMonitorC2ERKNS_15ResourceRequestENS_9SessionIDEPK20_CFCachedURLResponse
index 3f2ded4913924cf75f4affa09d37a199ad3638b5..7bf3cea1748569419408e8e07b8857c068fbc015 100644 (file)
@@ -153,8 +153,6 @@ public:
     static const RGBA32 cyan = 0xFF00FFFF;
 
 #if PLATFORM(IOS)
-    static const RGBA32 tap = 0x4D1A1A1A;
-
     // FIXME: This color shouldn't be iOS-specific. Once we fix up its usage in InlineTextBox::paintCompositionBackground()
     // we should move it outside the PLATFORM(IOS)-guard. See <https://bugs.webkit.org/show_bug.cgi?id=126296>.
     static const RGBA32 compositionFill = 0x3CAFC0E3;
@@ -189,9 +187,6 @@ inline uint16_t fastDivideBy255(uint16_t value)
 
 #if USE(CG)
 WEBCORE_EXPORT CGColorRef cachedCGColor(const Color&, ColorSpace);
-#if PLATFORM(IOS)
-WEBCORE_EXPORT CGColorRef createCGColorWithDeviceWhite(CGFloat white, CGFloat alpha);
-#endif // PLATFORM(IOS)
 #endif
 
 } // namespace WebCore
index bca830ffd5a97e64098c2c0da79a4bcf6a61833e..0756691136d7e56afdbf0edb31fb9f78d9ff9297 100644 (file)
 namespace WebCore {
 
 #if PLATFORM(IOS)
-CGColorRef createCGColorWithDeviceWhite(CGFloat white, CGFloat alpha)
-{
-    static CGColorSpaceRef graySpace = CGColorSpaceCreateDeviceGray();
-    const CGFloat components[] = { white, alpha };
-    return CGColorCreate(graySpace, components);
-}
-
 static CGColorRef createCGColorWithDeviceRGBA(CGColorRef sourceColor)
 {
     if (!sourceColor || CFEqual(CGColorGetColorSpace(sourceColor), deviceRGBColorSpaceRef()))
index 465c013fe4e884c07c998deb605f29a09a940343..f012aaa7403de389d82286a4507295c7865b9a98 100644 (file)
@@ -1,3 +1,15 @@
+2014-09-05  Simon Fraser  <simon.fraser@apple.com>
+
+        Remove some PLATFORM(IOS) code in Color.h/cpp
+        https://bugs.webkit.org/show_bug.cgi?id=136582
+
+        Reviewed by Dan Bates.
+        
+        createCGColorWithDeviceWhite() is only used here so make it a local static function.
+
+        * WebView/WebPDFViewIOS.mm:
+        (createCGColorWithDeviceWhite):
+
 2014-09-04  Pratik Solanki  <psolanki@apple.com>
 
         Remove iOS specific disk image cache
index dab0941dde642456dcd3ce5a771b8b8be2c7c742..f1e74993ac78420e51569801417808e8aedba36c 100644 (file)
@@ -61,6 +61,13 @@ static int comparePageRects(const void *key, const void *array);
 static const float PAGE_WIDTH_INSET     = 4.0 * 2.0;
 static const float PAGE_HEIGHT_INSET    = 4.0 * 2.0;
 
+static CGColorRef createCGColorWithDeviceWhite(CGFloat white, CGFloat alpha)
+{
+    static CGColorSpaceRef graySpace = CGColorSpaceCreateDeviceGray();
+    const CGFloat components[] = { white, alpha };
+    return CGColorCreate(graySpace, components);
+}
+
 @implementation WebPDFView
 
 + (NSArray *)supportedMIMETypes