- removed even more SPI use
authormjs <mjs@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Mon, 6 Jun 2005 11:12:32 +0000 (11:12 +0000)
committermjs <mjs@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Mon, 6 Jun 2005 11:12:32 +0000 (11:12 +0000)
        * Misc.subproj/WebDownload.m:
        * WebCoreSupport.subproj/WebImageData.m:
        (-[WebImageData _imageSourceOptions]):
        * WebCoreSupport.subproj/WebImageRenderer.m:
        (WebCGColorSpaceCreateRGB):
        (WebCGColorSpaceCreateGray):
        * WebView.subproj/WebBaseResourceHandleDelegate.m:
        (-[WebBaseResourceHandleDelegate loadWithRequest:]):
        (-[WebBaseResourceHandleDelegate setDefersCallbacks:]):
        * WebView.subproj/WebMainResourceClient.m:
        (-[WebMainResourceClient didReceiveResponse:]):
        (-[WebMainResourceClient didReceiveData:lengthReceived:]):
        (-[WebMainResourceClient didFinishLoading]):
        (-[WebMainResourceClient didFailWithError:]):

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

WebKit/ChangeLog
WebKit/Misc.subproj/WebDownload.m
WebKit/WebCoreSupport.subproj/WebImageData.m
WebKit/WebCoreSupport.subproj/WebImageRenderer.m
WebKit/WebView.subproj/WebBaseResourceHandleDelegate.m
WebKit/WebView.subproj/WebLoader.m
WebKit/WebView.subproj/WebMainResourceClient.m
WebKit/WebView.subproj/WebMainResourceLoader.m

index b274c196aaa0cd3f281e4e5cd24396e83b009c4a..887073d58fd64fcc4b58ed4f88262af88d11cb41 100644 (file)
@@ -1,3 +1,22 @@
+2005-06-06  Maciej Stachowiak  <mjs@apple.com>
+
+        - removed even more SPI use
+
+        * Misc.subproj/WebDownload.m:
+        * WebCoreSupport.subproj/WebImageData.m:
+        (-[WebImageData _imageSourceOptions]):
+        * WebCoreSupport.subproj/WebImageRenderer.m:
+        (WebCGColorSpaceCreateRGB):
+        (WebCGColorSpaceCreateGray):
+        * WebView.subproj/WebBaseResourceHandleDelegate.m:
+        (-[WebBaseResourceHandleDelegate loadWithRequest:]):
+        (-[WebBaseResourceHandleDelegate setDefersCallbacks:]):
+        * WebView.subproj/WebMainResourceClient.m:
+        (-[WebMainResourceClient didReceiveResponse:]):
+        (-[WebMainResourceClient didReceiveData:lengthReceived:]):
+        (-[WebMainResourceClient didFinishLoading]):
+        (-[WebMainResourceClient didFailWithError:]):
+
 2005-06-05  Darin Adler  <darin@apple.com>
 
         Reviewed by Hyatt.
index 5926f3de622fedfe17bf436f8605e62e062ceaaa..11d9f4c94e08057f52b2fb312f2b8b15ce670a95 100644 (file)
 
 #import <Foundation/NSURLAuthenticationChallenge.h>
 #import <Foundation/NSURLDownload.h>
-#import <Foundation/NSURLDownloadPrivate.h>
 #import <WebKit/WebAssertions.h>
 #import <WebKit/WebPanelAuthenticationHandler.h>
 
+@class NSURLConnectionDelegateProxy;
+
 // FIXME: Remove these declarations because _initWithLoadingConnection is declared in NSURLDownloadPrivate.h
 // and _initWithLoadingResource is obsolete, once we compile only with the new Foundation.
 @interface NSURLDownload (WebDownloadCapability)
                       response:(NSURLResponse *)response
                       delegate:(id)delegate
                          proxy:(NSURLConnectionDelegateProxy *)proxy;
+- (id)_initWithRequest:(NSURLRequest *)request
+                         delegate:(id)delegate
+                        directory:(NSString *)directory;
+                                                
 @end
 
 @interface WebDownloadInternal : NSObject
index 524615e110dbfff45241830e9178f31a1b329f8d..9e3e41457e27c6efba90723cf2aea247808f4ead 100644 (file)
 #import <WebKit/WebImageRenderer.h>
 #import <WebKit/WebImageRendererFactory.h>
 #import <WebKit/WebKitSystemBits.h>
+#import <WebKitSystemInterface.h>
 
 #import <WebCore/WebCoreImageRenderer.h>
 
-#import <CoreGraphics/CGColorSpacePrivate.h>
-
 #ifdef USE_CGIMAGEREF
 
-#import <ImageIO/CGImageSourcePrivate.h>
-
 // Forward declarations of internal methods.
 @interface WebImageData (WebInternal)
 - (void)_commonTermination;
 {
     static CFDictionaryRef imageSourceOptions;
     if (!imageSourceOptions) {
-        const void * keys[2] = { kCGImageSourceShouldCache, kCGImageSourceShouldPreferRGB32 };
+        const void * keys[2] = { kCGImageSourceShouldCache, 0 };
+               keys[1] = WKPreferRGB32Key();
         const void * values[2] = { kCFBooleanTrue, kCFBooleanTrue };
         imageSourceOptions = CFDictionaryCreate (NULL, keys, values, 2, 
                 &kCFTypeDictionaryKeyCallBacks, &kCFTypeDictionaryValueCallBacks);
        
        if (colorModel) {
            if (CFStringCompare (colorModel, CFSTR("RGB"), 0) == kCFCompareEqualTo)
-               uncorrectedColorSpace = CGColorSpaceCreateDisplayRGB();
+               uncorrectedColorSpace = WKCreateUncorrectedRGBColorSpace();
            else if (CFStringCompare (colorModel, CFSTR("Gray"), 0) == kCFCompareEqualTo)
-               uncorrectedColorSpace = CGColorSpaceCreateDisplayGray();
+               uncorrectedColorSpace = WKCreateUncorrectedGrayColorSpace();
        }
        
        if (uncorrectedColorSpace) {
index 4651e2236ef0bb5efdaab5561900fa1fae09f465..8755e76a908d1817778199cfa125ef45fcba5d3b 100644 (file)
@@ -34,6 +34,7 @@
 #import <WebKit/WebHTMLView.h>
 #import <WebKit/WebImageView.h>
 #import <WebKit/WebNSObjectExtras.h>
+#import <WebKitSystemInterface.h>
 
 #import <WebCore/WebCoreImageRenderer.h>
 
@@ -1538,7 +1539,7 @@ CGColorSpaceRef WebCGColorSpaceCreateRGB(void)
 #if BUILDING_ONPANTHER
     return CGColorSpaceCreateDeviceRGB();
 #else // !BUILDING_ON_PANTHER
-    return CGColorSpaceCreateDisplayRGB();
+    return WKCreateUncorrectedRGBColorSpace();
 #endif // BUILDING_ON_PANTHER
 #endif    
 }
@@ -1555,7 +1556,7 @@ CGColorSpaceRef WebCGColorSpaceCreateGray(void)
 #if BUILDING_ONPANTHER
     return CGColorSpaceCreateDeviceGray();
 #else // !BUILDING_ON_PANTHER
-    return CGColorSpaceCreateDisplayGray();
+    return WKCreateUncorrectedGrayColorSpace();
 #endif // BUILDING_ON_PANTHER
 #endif    
 }
index 6721c063b7b2d35f019515b24cb9cabfe8ef58a4..6f1e8690d03d20ed9111c9c12bc30014b0bc5293 100644 (file)
@@ -30,7 +30,6 @@
 
 #import <Foundation/NSURLAuthenticationChallenge.h>
 #import <Foundation/NSURLConnection.h>
-#import <Foundation/NSURLConnectionPrivate.h>
 #import <Foundation/NSURLRequest.h>
 #import <Foundation/NSURLResponse.h>
 
@@ -269,7 +268,7 @@ static BOOL NSURLConnectionSupportsBufferedData;
     isInitializingConnection = NO;
 #endif
     if (defersCallbacks) {
-        [connection setDefersCallbacks:YES];
+               WKSetNSURLConnectionDefersCallbacks(connection, YES);
     }
 
     return YES;
@@ -278,7 +277,7 @@ static BOOL NSURLConnectionSupportsBufferedData;
 - (void)setDefersCallbacks:(BOOL)defers
 {
     defersCallbacks = defers;
-    [connection setDefersCallbacks:defers];
+       WKSetNSURLConnectionDefersCallbacks(connection, defers);
     // Deliver the resource after a delay because callers don't expect to receive callbacks while calling this method.
     [self deliverResourceAfterDelay];
 }
index 6721c063b7b2d35f019515b24cb9cabfe8ef58a4..6f1e8690d03d20ed9111c9c12bc30014b0bc5293 100644 (file)
@@ -30,7 +30,6 @@
 
 #import <Foundation/NSURLAuthenticationChallenge.h>
 #import <Foundation/NSURLConnection.h>
-#import <Foundation/NSURLConnectionPrivate.h>
 #import <Foundation/NSURLRequest.h>
 #import <Foundation/NSURLResponse.h>
 
@@ -269,7 +268,7 @@ static BOOL NSURLConnectionSupportsBufferedData;
     isInitializingConnection = NO;
 #endif
     if (defersCallbacks) {
-        [connection setDefersCallbacks:YES];
+               WKSetNSURLConnectionDefersCallbacks(connection, YES);
     }
 
     return YES;
@@ -278,7 +277,7 @@ static BOOL NSURLConnectionSupportsBufferedData;
 - (void)setDefersCallbacks:(BOOL)defers
 {
     defersCallbacks = defers;
-    [connection setDefersCallbacks:defers];
+       WKSetNSURLConnectionDefersCallbacks(connection, defers);
     // Deliver the resource after a delay because callers don't expect to receive callbacks while calling this method.
     [self deliverResourceAfterDelay];
 }
index b1e25a5b1dab8c886fa215be1a03a6958d09249f..cdefb3587d1d08f5377aed2f45645f6aee53f3a1 100644 (file)
@@ -30,7 +30,6 @@
 
 #import <Foundation/NSHTTPCookie.h>
 #import <Foundation/NSURLConnection.h>
-#import <Foundation/NSURLConnectionPrivate.h>
 #import <Foundation/NSURLDownloadPrivate.h>
 #import <Foundation/NSURLRequest.h>
 #import <Foundation/NSURLResponse.h>
 
 - (void)didReceiveResponse:(NSURLResponse *)r
 {
-    ASSERT([[r URL] _webkit_shouldLoadAsEmptyDocument] || ![connection defersCallbacks]);
     ASSERT([[r URL] _webkit_shouldLoadAsEmptyDocument] || ![self defersCallbacks]);
     ASSERT([[r URL] _webkit_shouldLoadAsEmptyDocument] || ![[dataSource _webView] defersCallbacks]);
 
 {
     ASSERT(data);
     ASSERT([data length] != 0);
-    ASSERT(![connection defersCallbacks]);
     ASSERT(![self defersCallbacks]);
     ASSERT(![[dataSource _webView] defersCallbacks]);
  
 
 - (void)didFinishLoading
 {
-    ASSERT([[dataSource _URL] _webkit_shouldLoadAsEmptyDocument] || ![connection defersCallbacks]);
     ASSERT([[dataSource _URL] _webkit_shouldLoadAsEmptyDocument] || ![self defersCallbacks]);
     ASSERT([[dataSource _URL] _webkit_shouldLoadAsEmptyDocument] || ![[dataSource _webView] defersCallbacks]);
 
 
 - (void)didFailWithError:(NSError *)error
 {
-    ASSERT(![connection defersCallbacks]);
     ASSERT(![self defersCallbacks]);
     ASSERT(![[dataSource _webView] defersCallbacks]);
 
index b1e25a5b1dab8c886fa215be1a03a6958d09249f..cdefb3587d1d08f5377aed2f45645f6aee53f3a1 100644 (file)
@@ -30,7 +30,6 @@
 
 #import <Foundation/NSHTTPCookie.h>
 #import <Foundation/NSURLConnection.h>
-#import <Foundation/NSURLConnectionPrivate.h>
 #import <Foundation/NSURLDownloadPrivate.h>
 #import <Foundation/NSURLRequest.h>
 #import <Foundation/NSURLResponse.h>
 
 - (void)didReceiveResponse:(NSURLResponse *)r
 {
-    ASSERT([[r URL] _webkit_shouldLoadAsEmptyDocument] || ![connection defersCallbacks]);
     ASSERT([[r URL] _webkit_shouldLoadAsEmptyDocument] || ![self defersCallbacks]);
     ASSERT([[r URL] _webkit_shouldLoadAsEmptyDocument] || ![[dataSource _webView] defersCallbacks]);
 
 {
     ASSERT(data);
     ASSERT([data length] != 0);
-    ASSERT(![connection defersCallbacks]);
     ASSERT(![self defersCallbacks]);
     ASSERT(![[dataSource _webView] defersCallbacks]);
  
 
 - (void)didFinishLoading
 {
-    ASSERT([[dataSource _URL] _webkit_shouldLoadAsEmptyDocument] || ![connection defersCallbacks]);
     ASSERT([[dataSource _URL] _webkit_shouldLoadAsEmptyDocument] || ![self defersCallbacks]);
     ASSERT([[dataSource _URL] _webkit_shouldLoadAsEmptyDocument] || ![[dataSource _webView] defersCallbacks]);
 
 
 - (void)didFailWithError:(NSError *)error
 {
-    ASSERT(![connection defersCallbacks]);
     ASSERT(![self defersCallbacks]);
     ASSERT(![[dataSource _webView] defersCallbacks]);