Diff
Modified: trunk/Source/WebCore/ChangeLog (133693 => 133694)
--- trunk/Source/WebCore/ChangeLog 2012-11-07 00:37:45 UTC (rev 133693)
+++ trunk/Source/WebCore/ChangeLog 2012-11-07 00:41:30 UTC (rev 133694)
@@ -1,3 +1,49 @@
+2012-11-06 Alexey Proskuryakov <[email protected]>
+
+ Clean up which storage cookie jar functions use
+ https://bugs.webkit.org/show_bug.cgi?id=101395
+
+ Reviewed by Brady Eidson.
+
+ * WebCore.exp.in:
+ * platform/mac/WebCoreSystemInterface.h:
+ * platform/mac/WebCoreSystemInterface.mm:
+ Updated for two new WKSI functions.
+
+ * platform/CookieJar.h: Added explanatory comments.
+
+ * platform/mac/CookieJar.mm:
+ (WebCore::cookies): Removed fallback on NSHTTPCookieStorage, the WKSI function
+ already implements it.
+ (WebCore::cookieRequestHeaderFieldValue): Ditto.
+ (WebCore::setCookies): Ditto.
+ (WebCore::cookiesEnabled): Ditto.
+ (WebCore::getRawCookies): Ditto.
+ (WebCore::deleteCookie): Ditto.
+ (WebCore::getHostnamesWithCookies): This function used to look at NSHTTPCookieStorage
+ exclusively. While it makes sense to bypass private storage session, default storage
+ session (currently only used for testing on Mac) is never OK to bypass. Changed to
+ use a WKSI function that supports both.
+ (WebCore::deleteCookiesForHostname): Ditto.
+ (WebCore::deleteAllCookies): Ditto.
+
+ * platform/network/cf/CookieJarCFNet.cpp:
+ (WebCore::getHostnamesWithCookies):
+ (WebCore::deleteCookiesForHostname):
+ (WebCore::deleteAllCookies):
+ Updated to match Foundation, so now these functions bypass private session.
+
+ * platform/network/cf/CookieStorageCFNet.cpp:
+ (WebCore::currentCFHTTPCookieStorage): Updated a comment.
+ (WebCore::defaultCFHTTPCookieStorage): Added a function that returns cookie storage
+ for non-private session (or null if that would be an NSHTTPCookieStorage).
+ (WebCore::startObservingCookieChanges): We do not want to observe private cookies
+ here, and we certainly don't want a mismatch between start/stop due to private
+ browsing mode changes.
+ (WebCore::stopObservingCookieChanges): Ditto.
+
+ * platform/network/cf/CookieStorageCFNet.h: Added defaultCFHTTPCookieStorage().
+
2012-11-06 Huang Dongsung <[email protected]>
Build fix. r133601 broke the Windows build.
Modified: trunk/Source/WebCore/WebCore.exp.in (133693 => 133694)
--- trunk/Source/WebCore/WebCore.exp.in 2012-11-07 00:37:45 UTC (rev 133693)
+++ trunk/Source/WebCore/WebCore.exp.in 2012-11-07 00:41:30 UTC (rev 133694)
@@ -1520,6 +1520,7 @@
_wkCreateCustomCFReadStream
_wkCreateNSURLConnectionDelegateProxy
_wkCreatePrivateStorageSession
+_wkDeleteAllHTTPCookies
_wkDeleteHTTPCookie
_wkGetCFURLResponseHTTPResponse
_wkGetCFURLResponseMIMEType
@@ -1529,6 +1530,7 @@
_wkGetMIMETypeForExtension
_wkGetNSURLResponseLastModifiedDate
_wkGetUserToBaseCTM
+_wkHTTPCookies
_wkHTTPCookiesForURL
_wkInitializeMaximumHTTPConnectionCountPerHost
_wkSetBaseCTM
Modified: trunk/Source/WebCore/platform/CookieJar.h (133693 => 133694)
--- trunk/Source/WebCore/platform/CookieJar.h 2012-11-07 00:37:45 UTC (rev 133693)
+++ trunk/Source/WebCore/platform/CookieJar.h 2012-11-07 00:41:30 UTC (rev 133694)
@@ -41,11 +41,13 @@
String cookies(const Document*, const KURL&);
void setCookies(Document*, const KURL&, const String&);
+// These methods use current cookie storage, thus taking private browsing mode into account.
bool cookiesEnabled(const Document*);
String cookieRequestHeaderFieldValue(const Document*, const KURL&);
bool getRawCookies(const Document*, const KURL&, Vector<Cookie>&);
void deleteCookie(const Document*, const KURL&, const String&);
+// These functions always access default cookie storage, not taking private browsing mode into account.
void getHostnamesWithCookies(HashSet<String>& hostnames);
void deleteCookiesForHostname(const String& hostname);
void deleteAllCookies();
Modified: trunk/Source/WebCore/platform/mac/CookieJar.mm (133693 => 133694)
--- trunk/Source/WebCore/platform/mac/CookieJar.mm 2012-11-07 00:37:45 UTC (rev 133693)
+++ trunk/Source/WebCore/platform/mac/CookieJar.mm 2012-11-07 00:41:30 UTC (rev 133694)
@@ -65,12 +65,7 @@
{
BEGIN_BLOCK_OBJC_EXCEPTIONS;
- NSArray *cookies;
- if (RetainPtr<CFHTTPCookieStorageRef> cfCookieStorage = currentCFHTTPCookieStorage())
- cookies = wkHTTPCookiesForURL(cfCookieStorage.get(), url);
- else
- cookies = [[NSHTTPCookieStorage sharedHTTPCookieStorage] cookiesForURL:url];
-
+ NSArray *cookies = wkHTTPCookiesForURL(currentCFHTTPCookieStorage().get(), url);
return [[NSHTTPCookie requestHeaderFieldsWithCookies:filterCookies(cookies).get()] objectForKey:@"Cookie"];
END_BLOCK_OBJC_EXCEPTIONS;
@@ -81,12 +76,7 @@
{
BEGIN_BLOCK_OBJC_EXCEPTIONS;
- NSArray *cookies;
- if (RetainPtr<CFHTTPCookieStorageRef> cfCookieStorage = currentCFHTTPCookieStorage())
- cookies = wkHTTPCookiesForURL(cfCookieStorage.get(), url);
- else
- cookies = [[NSHTTPCookieStorage sharedHTTPCookieStorage] cookiesForURL:url];
-
+ NSArray *cookies = wkHTTPCookiesForURL(currentCFHTTPCookieStorage().get(), url);
return [[NSHTTPCookie requestHeaderFieldsWithCookies:cookies] objectForKey:@"Cookie"];
END_BLOCK_OBJC_EXCEPTIONS;
@@ -110,10 +100,7 @@
RetainPtr<NSArray> filteredCookies = filterCookies([NSHTTPCookie cookiesWithResponseHeaderFields:[NSDictionary dictionaryWithObject:cookieString forKey:@"Set-Cookie"] forURL:cookieURL]);
ASSERT([filteredCookies.get() count] <= 1);
- if (RetainPtr<CFHTTPCookieStorageRef> cfCookieStorage = currentCFHTTPCookieStorage())
- wkSetHTTPCookiesForURL(cfCookieStorage.get(), filteredCookies.get(), cookieURL, document->firstPartyForCookies());
- else
- [[NSHTTPCookieStorage sharedHTTPCookieStorage] setCookies:filteredCookies.get() forURL:cookieURL mainDocumentURL:document->firstPartyForCookies()];
+ wkSetHTTPCookiesForURL(currentCFHTTPCookieStorage().get(), filteredCookies.get(), cookieURL, document->firstPartyForCookies());
END_BLOCK_OBJC_EXCEPTIONS;
}
@@ -122,12 +109,7 @@
{
BEGIN_BLOCK_OBJC_EXCEPTIONS;
- NSHTTPCookieAcceptPolicy cookieAcceptPolicy;
- if (RetainPtr<CFHTTPCookieStorageRef> cfCookieStorage = currentCFHTTPCookieStorage())
- cookieAcceptPolicy = static_cast<NSHTTPCookieAcceptPolicy>(wkGetHTTPCookieAcceptPolicy(cfCookieStorage.get()));
- else
- cookieAcceptPolicy = [[NSHTTPCookieStorage sharedHTTPCookieStorage] cookieAcceptPolicy];
-
+ NSHTTPCookieAcceptPolicy cookieAcceptPolicy = static_cast<NSHTTPCookieAcceptPolicy>(wkGetHTTPCookieAcceptPolicy(currentCFHTTPCookieStorage().get()));
return cookieAcceptPolicy == NSHTTPCookieAcceptPolicyAlways || cookieAcceptPolicy == NSHTTPCookieAcceptPolicyOnlyFromMainDocumentDomain;
END_BLOCK_OBJC_EXCEPTIONS;
@@ -139,12 +121,7 @@
rawCookies.clear();
BEGIN_BLOCK_OBJC_EXCEPTIONS;
- NSArray *cookies;
- if (RetainPtr<CFHTTPCookieStorageRef> cfCookieStorage = currentCFHTTPCookieStorage())
- cookies = wkHTTPCookiesForURL(cfCookieStorage.get(), url);
- else
- cookies = [[NSHTTPCookieStorage sharedHTTPCookieStorage] cookiesForURL:url];
-
+ NSArray *cookies = wkHTTPCookiesForURL(currentCFHTTPCookieStorage().get(), url);
NSUInteger count = [cookies count];
rawCookies.reserveCapacity(count);
for (NSUInteger i = 0; i < count; ++i) {
@@ -163,26 +140,16 @@
BEGIN_BLOCK_OBJC_EXCEPTIONS;
NSURL *cookieURL = url;
- NSHTTPCookieStorage *cookieStorage = [NSHTTPCookieStorage sharedHTTPCookieStorage];
- NSArray *cookies;
- RetainPtr<CFHTTPCookieStorageRef> cfCookieStorage = currentCFHTTPCookieStorage();
- if (cfCookieStorage)
- cookies = wkHTTPCookiesForURL(cfCookieStorage.get(), cookieURL);
- else
- cookies = [cookieStorage cookiesForURL:cookieURL];
+ RetainPtr<CFHTTPCookieStorageRef> cookieStorage = currentCFHTTPCookieStorage();
+ NSArray *cookies = wkHTTPCookiesForURL(cookieStorage.get(), cookieURL);
- NSString *cookieNameString = (NSString *) cookieName;
+ NSString *cookieNameString = cookieName;
NSUInteger count = [cookies count];
for (NSUInteger i = 0; i < count; ++i) {
NSHTTPCookie *cookie = (NSHTTPCookie *)[cookies objectAtIndex:i];
- if ([[cookie name] isEqualToString:cookieNameString]) {
- if (cfCookieStorage)
- wkDeleteHTTPCookie(cfCookieStorage.get(), cookie);
- else
- [cookieStorage deleteCookie:cookie];
- break;
- }
+ if ([[cookie name] isEqualToString:cookieNameString])
+ wkDeleteHTTPCookie(cookieStorage.get(), cookie);
}
END_BLOCK_OBJC_EXCEPTIONS;
@@ -191,10 +158,9 @@
void getHostnamesWithCookies(HashSet<String>& hostnames)
{
BEGIN_BLOCK_OBJC_EXCEPTIONS;
+
+ NSArray *cookies = wkHTTPCookies(defaultCFHTTPCookieStorage().get());
- NSHTTPCookieStorage *cookieStorage = [NSHTTPCookieStorage sharedHTTPCookieStorage];
- NSArray *cookies = [cookieStorage cookies];
-
for (NSHTTPCookie* cookie in cookies)
hostnames.add([cookie domain]);
@@ -204,15 +170,15 @@
void deleteCookiesForHostname(const String& hostname)
{
BEGIN_BLOCK_OBJC_EXCEPTIONS;
-
- NSHTTPCookieStorage *cookieStorage = [NSHTTPCookieStorage sharedHTTPCookieStorage];
- NSArray *cookies = [cookieStorage cookies];
+
+ RetainPtr<CFHTTPCookieStorageRef> cookieStorage = defaultCFHTTPCookieStorage();
+ NSArray *cookies = wkHTTPCookies(cookieStorage.get());
if (!cookies)
return;
for (NSHTTPCookie* cookie in cookies) {
if (hostname == String([cookie domain]))
- [cookieStorage deleteCookie:cookie];
+ wkDeleteHTTPCookie(cookieStorage.get(), cookie);
}
END_BLOCK_OBJC_EXCEPTIONS;
@@ -220,17 +186,7 @@
void deleteAllCookies()
{
- BEGIN_BLOCK_OBJC_EXCEPTIONS;
-
- NSHTTPCookieStorage *cookieStorage = [NSHTTPCookieStorage sharedHTTPCookieStorage];
- NSArray *cookies = [cookieStorage cookies];
- if (!cookies)
- return;
-
- for (NSHTTPCookie* cookie in cookies)
- [cookieStorage deleteCookie:cookie];
-
- END_BLOCK_OBJC_EXCEPTIONS;
+ wkDeleteAllHTTPCookies(defaultCFHTTPCookieStorage().get());
}
}
Modified: trunk/Source/WebCore/platform/mac/WebCoreSystemInterface.h (133693 => 133694)
--- trunk/Source/WebCore/platform/mac/WebCoreSystemInterface.h 2012-11-07 00:37:45 UTC (rev 133693)
+++ trunk/Source/WebCore/platform/mac/WebCoreSystemInterface.h 2012-11-07 00:41:30 UTC (rev 133694)
@@ -290,9 +290,11 @@
extern CFHTTPCookieStorageRef (*wkCopyHTTPCookieStorage)(CFURLStorageSessionRef);
extern unsigned (*wkGetHTTPCookieAcceptPolicy)(CFHTTPCookieStorageRef);
extern void (*wkSetHTTPCookieAcceptPolicy)(CFHTTPCookieStorageRef, unsigned);
+extern NSArray *(*wkHTTPCookies)(CFHTTPCookieStorageRef);
extern NSArray *(*wkHTTPCookiesForURL)(CFHTTPCookieStorageRef, NSURL *);
extern void (*wkSetHTTPCookiesForURL)(CFHTTPCookieStorageRef, NSArray *, NSURL *, NSURL *);
extern void (*wkDeleteHTTPCookie)(CFHTTPCookieStorageRef, NSHTTPCookie *);
+extern void (*wkDeleteAllHTTPCookies)(CFHTTPCookieStorageRef);
extern CFStringRef (*wkGetCFURLResponseMIMEType)(CFURLResponseRef);
extern CFURLRef (*wkGetCFURLResponseURL)(CFURLResponseRef);
Modified: trunk/Source/WebCore/platform/mac/WebCoreSystemInterface.mm (133693 => 133694)
--- trunk/Source/WebCore/platform/mac/WebCoreSystemInterface.mm 2012-11-07 00:37:45 UTC (rev 133693)
+++ trunk/Source/WebCore/platform/mac/WebCoreSystemInterface.mm 2012-11-07 00:41:30 UTC (rev 133694)
@@ -174,8 +174,10 @@
CFHTTPCookieStorageRef (*wkCopyHTTPCookieStorage)(CFURLStorageSessionRef);
unsigned (*wkGetHTTPCookieAcceptPolicy)(CFHTTPCookieStorageRef);
void (*wkSetHTTPCookieAcceptPolicy)(CFHTTPCookieStorageRef, unsigned);
+NSArray *(*wkHTTPCookies)(CFHTTPCookieStorageRef);
NSArray *(*wkHTTPCookiesForURL)(CFHTTPCookieStorageRef, NSURL *);
void (*wkSetHTTPCookiesForURL)(CFHTTPCookieStorageRef, NSArray *, NSURL *, NSURL *);
+void (*wkDeleteAllHTTPCookies)(CFHTTPCookieStorageRef);
void (*wkDeleteHTTPCookie)(CFHTTPCookieStorageRef, NSHTTPCookie *);
CFStringRef (*wkGetCFURLResponseMIMEType)(CFURLResponseRef);
Modified: trunk/Source/WebCore/platform/network/cf/CookieJarCFNet.cpp (133693 => 133694)
--- trunk/Source/WebCore/platform/network/cf/CookieJarCFNet.cpp 2012-11-07 00:37:45 UTC (rev 133693)
+++ trunk/Source/WebCore/platform/network/cf/CookieJarCFNet.cpp 2012-11-07 00:41:30 UTC (rev 133694)
@@ -216,7 +216,7 @@
void getHostnamesWithCookies(HashSet<String>& hostnames)
{
- RetainPtr<CFHTTPCookieStorageRef> cookieStorage = currentCFHTTPCookieStorage();
+ RetainPtr<CFHTTPCookieStorageRef> cookieStorage = defaultCFHTTPCookieStorage();
if (!cookieStorage)
return;
@@ -234,7 +234,7 @@
void deleteCookiesForHostname(const String& hostname)
{
- RetainPtr<CFHTTPCookieStorageRef> cookieStorage = currentCFHTTPCookieStorage();
+ RetainPtr<CFHTTPCookieStorageRef> cookieStorage = defaultCFHTTPCookieStorage();
if (!cookieStorage)
return;
@@ -253,7 +253,7 @@
void deleteAllCookies()
{
- RetainPtr<CFHTTPCookieStorageRef> cookieStorage = currentCFHTTPCookieStorage();
+ RetainPtr<CFHTTPCookieStorageRef> cookieStorage = defaultCFHTTPCookieStorage();
if (!cookieStorage)
return;
Modified: trunk/Source/WebCore/platform/network/cf/CookieStorageCFNet.cpp (133693 => 133694)
--- trunk/Source/WebCore/platform/network/cf/CookieStorageCFNet.cpp 2012-11-07 00:37:45 UTC (rev 133693)
+++ trunk/Source/WebCore/platform/network/cf/CookieStorageCFNet.cpp 2012-11-07 00:41:30 UTC (rev 133694)
@@ -69,13 +69,31 @@
#if USE(CFNETWORK)
return wkGetDefaultHTTPCookieStorage();
#else
- // When using NSURLConnection, we also use its default cookie storage.
+ // When using NSURLConnection, we also use its shared cookie storage.
return 0;
#endif
}
+RetainPtr<CFHTTPCookieStorageRef> defaultCFHTTPCookieStorage()
+{
#if PLATFORM(WIN)
+ if (RetainPtr<CFHTTPCookieStorageRef>& override = cookieStorageOverride())
+ return override;
+#endif
+ if (CFURLStorageSessionRef session = ResourceHandle::defaultStorageSession())
+ return RetainPtr<CFHTTPCookieStorageRef>(AdoptCF, wkCopyHTTPCookieStorage(session));
+
+#if USE(CFNETWORK)
+ return wkGetDefaultHTTPCookieStorage();
+#else
+ // When using NSURLConnection, we also use its shared cookie storage.
+ return 0;
+#endif
+}
+
+#if PLATFORM(WIN)
+
void overrideCookieStorage(CFHTTPCookieStorageRef cookieStorage)
{
ASSERT(isMainThread());
@@ -115,7 +133,7 @@
CFRunLoopRef runLoop = cookieStorageObserverRunLoop();
ASSERT(runLoop);
- RetainPtr<CFHTTPCookieStorageRef> cookieStorage = currentCFHTTPCookieStorage();
+ RetainPtr<CFHTTPCookieStorageRef> cookieStorage = defaultCFHTTPCookieStorage();
ASSERT(cookieStorage);
CFHTTPCookieStorageScheduleWithRunLoop(cookieStorage.get(), runLoop, kCFRunLoopCommonModes);
@@ -129,7 +147,7 @@
CFRunLoopRef runLoop = cookieStorageObserverRunLoop();
ASSERT(runLoop);
- RetainPtr<CFHTTPCookieStorageRef> cookieStorage = currentCFHTTPCookieStorage();
+ RetainPtr<CFHTTPCookieStorageRef> cookieStorage = defaultCFHTTPCookieStorage();
ASSERT(cookieStorage);
CFHTTPCookieStorageRemoveObserver(cookieStorage.get(), runLoop, kCFRunLoopDefaultMode, notifyCookiesChanged, 0);
Modified: trunk/Source/WebCore/platform/network/cf/CookieStorageCFNet.h (133693 => 133694)
--- trunk/Source/WebCore/platform/network/cf/CookieStorageCFNet.h 2012-11-07 00:37:45 UTC (rev 133693)
+++ trunk/Source/WebCore/platform/network/cf/CookieStorageCFNet.h 2012-11-07 00:41:30 UTC (rev 133694)
@@ -33,6 +33,7 @@
namespace WebCore {
RetainPtr<CFHTTPCookieStorageRef> currentCFHTTPCookieStorage(); // Will be null when using shared NSHTTPCookieStorage.
+RetainPtr<CFHTTPCookieStorageRef> defaultCFHTTPCookieStorage(); // Doesn't take current session into account.
#if PLATFORM(WIN)
// Needed for WebKit1 API only.
Modified: trunk/Source/WebKit/mac/ChangeLog (133693 => 133694)
--- trunk/Source/WebKit/mac/ChangeLog 2012-11-07 00:37:45 UTC (rev 133693)
+++ trunk/Source/WebKit/mac/ChangeLog 2012-11-07 00:41:30 UTC (rev 133694)
@@ -1,3 +1,13 @@
+2012-11-06 Alexey Proskuryakov <[email protected]>
+
+ Clean up which storage cookie jar functions use
+ https://bugs.webkit.org/show_bug.cgi?id=101395
+
+ Reviewed by Brady Eidson.
+
+ * WebCoreSupport/WebSystemInterface.mm: (InitWebCoreSystemInterface): Updated for
+ two new functions.
+
2012-11-06 Andrey Lushnikov <[email protected]>
Added console.clear() method
Modified: trunk/Source/WebKit/mac/WebCoreSupport/WebSystemInterface.mm (133693 => 133694)
--- trunk/Source/WebKit/mac/WebCoreSupport/WebSystemInterface.mm 2012-11-07 00:37:45 UTC (rev 133693)
+++ trunk/Source/WebKit/mac/WebCoreSupport/WebSystemInterface.mm 2012-11-07 00:41:30 UTC (rev 133694)
@@ -165,8 +165,10 @@
INIT(CopyRequestWithStorageSession);
INIT(CopyHTTPCookieStorage);
INIT(GetHTTPCookieAcceptPolicy);
+ INIT(HTTPCookies);
INIT(HTTPCookiesForURL);
INIT(SetHTTPCookiesForURL);
+ INIT(DeleteAllHTTPCookies);
INIT(DeleteHTTPCookie);
INIT(GetCFURLResponseMIMEType);
Modified: trunk/Source/WebKit2/ChangeLog (133693 => 133694)
--- trunk/Source/WebKit2/ChangeLog 2012-11-07 00:37:45 UTC (rev 133693)
+++ trunk/Source/WebKit2/ChangeLog 2012-11-07 00:41:30 UTC (rev 133694)
@@ -1,3 +1,13 @@
+2012-11-06 Alexey Proskuryakov <[email protected]>
+
+ Clean up which storage cookie jar functions use
+ https://bugs.webkit.org/show_bug.cgi?id=101395
+
+ Reviewed by Brady Eidson.
+
+ * WebProcess/WebCoreSupport/mac/WebSystemInterface.mm: (InitWebCoreSystemInterface):
+ Updated for two new functions.
+
2012-11-06 Jihye Kang <[email protected]>
[EFL][WK2] Add ewk_database_manager APIs
Modified: trunk/Source/WebKit2/WebProcess/WebCoreSupport/mac/WebSystemInterface.mm (133693 => 133694)
--- trunk/Source/WebKit2/WebProcess/WebCoreSupport/mac/WebSystemInterface.mm 2012-11-07 00:37:45 UTC (rev 133693)
+++ trunk/Source/WebKit2/WebProcess/WebCoreSupport/mac/WebSystemInterface.mm 2012-11-07 00:41:30 UTC (rev 133694)
@@ -116,8 +116,10 @@
INIT(CopyHTTPCookieStorage);
INIT(GetHTTPCookieAcceptPolicy);
INIT(SetHTTPCookieAcceptPolicy);
+ INIT(HTTPCookies);
INIT(HTTPCookiesForURL);
INIT(SetHTTPCookiesForURL);
+ INIT(DeleteAllHTTPCookies);
INIT(DeleteHTTPCookie);
INIT(SetMetadataURL);
Modified: trunk/WebKitLibraries/ChangeLog (133693 => 133694)
--- trunk/WebKitLibraries/ChangeLog 2012-11-07 00:37:45 UTC (rev 133693)
+++ trunk/WebKitLibraries/ChangeLog 2012-11-07 00:41:30 UTC (rev 133694)
@@ -1,5 +1,18 @@
2012-11-06 Alexey Proskuryakov <[email protected]>
+ Clean up which storage cookie jar functions use
+ https://bugs.webkit.org/show_bug.cgi?id=101395
+
+ Reviewed by Brady Eidson.
+
+ * WebKitSystemInterface.h:
+ * libWebKitSystemInterfaceLion.a:
+ * libWebKitSystemInterfaceMountainLion.a:
+ Added WKHTTPCookies() and WKDeleteAllHTTPCookies(). Updated ifdefs for currently
+ supported OS versions.
+
+2012-11-06 Alexey Proskuryakov <[email protected]>
+
Delete Leopard and Snow Leopard versions of WKSI. These have not been updated in ages.
Rubber-stampted by Mark Rowe.
Modified: trunk/WebKitLibraries/WebKitSystemInterface.h (133693 => 133694)
--- trunk/WebKitLibraries/WebKitSystemInterface.h 2012-11-07 00:37:45 UTC (rev 133693)
+++ trunk/WebKitLibraries/WebKitSystemInterface.h 2012-11-07 00:41:30 UTC (rev 133694)
@@ -7,6 +7,7 @@
#import <Cocoa/Cocoa.h>
#import <Carbon/Carbon.h>
+#import <dispatch/dispatch.h>
@class AVAsset;
@class QTMovie;
@@ -163,12 +164,10 @@
bool WKCTFontTransformGlyphs(CTFontRef font, CGGlyph glyphs[], CGSize advances[], CFIndex count, WKCTFontTransformOptions options);
#endif
-#if MAC_OS_X_VERSION_MIN_REQUIRED >= 1070
CTTypesetterRef WKCreateCTTypesetterWithUniCharProviderAndOptions(const UniChar* (*provide)(CFIndex stringIndex, CFIndex* charCount, CFDictionaryRef* attributes, void*), void (*dispose)(const UniChar* chars, void*), void*, CFDictionaryRef options);
CGContextRef WKIOSurfaceContextCreate(IOSurfaceRef, unsigned width, unsigned height, CGColorSpaceRef);
CGImageRef WKIOSurfaceContextCreateImage(CGContextRef context);
-#endif
typedef enum {
WKPatternTilingNoDistortion,
@@ -237,11 +236,7 @@
CFStringRef WKCopyFoundationCacheDirectory(void);
-#if MAC_OS_X_VERSION_MIN_REQUIRED == 1060
-typedef struct __CFURLStorageSession* CFURLStorageSessionRef;
-#else
typedef const struct __CFURLStorageSession* CFURLStorageSessionRef;
-#endif
CFURLStorageSessionRef WKCreatePrivateStorageSession(CFStringRef);
NSURLRequest *WKCopyRequestWithStorageSession(CFURLStorageSessionRef, NSURLRequest*);
NSCachedURLResponse *WKCachedResponseForRequest(CFURLStorageSessionRef, NSURLRequest*);
@@ -251,8 +246,10 @@
CFHTTPCookieStorageRef WKCopyHTTPCookieStorage(CFURLStorageSessionRef);
unsigned WKGetHTTPCookieAcceptPolicy(CFHTTPCookieStorageRef);
void WKSetHTTPCookieAcceptPolicy(CFHTTPCookieStorageRef, unsigned policy);
+NSArray *WKHTTPCookies(CFHTTPCookieStorageRef);
NSArray *WKHTTPCookiesForURL(CFHTTPCookieStorageRef, NSURL *);
void WKSetHTTPCookiesForURL(CFHTTPCookieStorageRef, NSArray *, NSURL *, NSURL *);
+void WKDeleteAllHTTPCookies(CFHTTPCookieStorageRef);
void WKDeleteHTTPCookie(CFHTTPCookieStorageRef, NSHTTPCookie *);
CFHTTPCookieStorageRef WKGetDefaultHTTPCookieStorage(void);
@@ -362,9 +359,7 @@
void WKCAContextSetColorSpace(WKCAContextRef, CGColorSpaceRef);
CGColorSpaceRef WKCAContextGetColorSpace(WKCAContextRef);
-#if MAC_OS_X_VERSION_MIN_REQUIRED >= 1070
void WKCALayerEnumerateRectsBeingDrawnWithBlock(CALayer *layer, CGContextRef context, void (^block)(CGRect rect));
-#endif
@class CARenderer;
@@ -400,17 +395,6 @@
void WKSetCONNECTProxyAuthorizationForStream(CFReadStreamRef, CFStringRef proxyAuthorizationString);
CFHTTPMessageRef WKCopyCONNECTProxyResponse(CFReadStreamRef, CFURLRef responseURL);
-#if MAC_OS_X_VERSION_MIN_REQUIRED == 1060
-typedef enum {
- WKEventPhaseNone = 0,
- WKEventPhaseBegan = 1,
- WKEventPhaseChanged = 2,
- WKEventPhaseEnded = 3,
-} WKEventPhase;
-
-int WKGetNSEventMomentumPhase(NSEvent *);
-#endif
-
void WKWindowSetAlpha(NSWindow *window, float alphaValue);
void WKWindowSetScaledFrame(NSWindow *window, NSRect scaleFrame, NSRect nonScaledFrame);
@@ -428,10 +412,6 @@
ScriptCode WKGetScriptCodeFromCurrentKeyboardInputSource(void);
#endif
-#if MAC_OS_X_VERSION_MIN_REQUIRED == 1060
-CFIndex WKGetHyphenationLocationBeforeIndex(CFStringRef string, CFIndex index);
-#endif
-
CFArrayRef WKCFURLCacheCopyAllHostNamesInPersistentStore(void);
void WKCFURLCacheDeleteHostNamesInPersistentStore(CFArrayRef hostArray);
@@ -443,8 +423,6 @@
CIFormat WKCIGetRGBA8Format(void);
-#if MAC_OS_X_VERSION_MIN_REQUIRED >= 1070
-
typedef enum {
WKSandboxExtensionTypeReadOnly,
WKSandboxExtensionTypeWriteOnly,
@@ -481,28 +459,16 @@
NSCursor *WKCursor(const char *name);
-#endif
-
-#if MAC_OS_X_VERSION_MIN_REQUIRED >= 1070
-
-#import <dispatch/dispatch.h>
-
dispatch_source_t WKCreateVMPressureDispatchOnMainQueue(void);
-#endif
-
#if MAC_OS_X_VERSION_MIN_REQUIRED >= 1080
NSString *WKGetMacOSXVersionString(void);
bool WKExecutableWasLinkedOnOrBeforeLion(void);
#endif
-#if MAC_OS_X_VERSION_MIN_REQUIRED >= 1070
void WKCGPathAddRoundedRect(CGMutablePathRef path, const CGAffineTransform* matrix, CGRect rect, CGFloat cornerWidth, CGFloat cornerHeight);
-#endif
-#if MAC_OS_X_VERSION_MIN_REQUIRED >= 1070
void WKCFURLRequestAllowAllPostCaching(CFURLRequestRef);
-#endif
#if MAC_OS_X_VERSION_MIN_REQUIRED >= 1080
@class WebFilterEvaluator;
@@ -519,10 +485,8 @@
CGFloat WKNSReboundDeltaForElasticDelta(CGFloat delta);
#endif
-#if MAC_OS_X_VERSION_MIN_REQUIRED >= 1070
Boolean WKJLIsRuntimeAndWebComponentsInstalled(void);
void WKJLReportWebComponentsUsed(void);
-#endif
typedef enum {
WKCaptionFontStyleDefault = 0,
Modified: trunk/WebKitLibraries/libWebKitSystemInterfaceLion.a
(Binary files differ)
Modified: trunk/WebKitLibraries/libWebKitSystemInterfaceMountainLion.a
(Binary files differ)