| OLD | NEW |
| (Empty) | |
| 1 /* |
| 2 WebKitSystemInterface.h |
| 3 Copyright (C) 2005, 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All rights
reserved. |
| 4 |
| 5 Public header file. |
| 6 |
| 7 Redistribution and use in source and binary forms, with or without |
| 8 modification, are permitted provided that the following conditions |
| 9 are met: |
| 10 1. Redistributions of source code must retain the above copyright |
| 11 notice, this list of conditions and the following disclaimer. |
| 12 2. Redistributions in binary form must reproduce the above copyright |
| 13 notice, this list of conditions and the following disclaimer in the |
| 14 documentation and/or other materials provided with the distribution. |
| 15 |
| 16 THIS SOFTWARE IS PROVIDED BY APPLE INC. AND ITS CONTRIBUTORS ``AS IS'' AND ANY |
| 17 EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED |
| 18 WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE |
| 19 DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR ITS CONTRIBUTORS BE LIABLE FOR ANY |
| 20 DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES |
| 21 (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; |
| 22 LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON |
| 23 ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT |
| 24 (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS |
| 25 SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
| 26 */ |
| 27 |
| 28 #import <Cocoa/Cocoa.h> |
| 29 #import <Carbon/Carbon.h> |
| 30 |
| 31 @class AVAsset; |
| 32 @class QTMovie; |
| 33 @class QTMovieView; |
| 34 |
| 35 #ifdef __cplusplus |
| 36 extern "C" { |
| 37 #endif |
| 38 |
| 39 typedef struct _CFURLResponse* CFURLResponseRef; |
| 40 typedef const struct _CFURLRequest* CFURLRequestRef; |
| 41 typedef struct _CFURLRequest* CFMutableURLRequestRef; |
| 42 |
| 43 typedef struct _CFURLCredential* WKCFURLCredentialRef; |
| 44 typedef struct _CFURLProtectionSpace* CFURLProtectionSpaceRef; |
| 45 |
| 46 typedef enum { |
| 47 WKCertificateParseResultSucceeded = 0, |
| 48 WKCertificateParseResultFailed = 1, |
| 49 WKCertificateParseResultPKCS7 = 2, |
| 50 } WKCertificateParseResult; |
| 51 |
| 52 CFStringRef WKCopyCFLocalizationPreferredName(CFStringRef localization); |
| 53 void WKSetDefaultLocalization(CFStringRef localization); |
| 54 |
| 55 CFStringRef WKSignedPublicKeyAndChallengeString(unsigned keySize, CFStringRef ch
allenge, CFStringRef keyDescription); |
| 56 WKCertificateParseResult WKAddCertificatesToKeychainFromData(const void *bytes,
unsigned length); |
| 57 |
| 58 NSString *WKGetPreferredExtensionForMIMEType(NSString *type); |
| 59 NSArray *WKGetExtensionsForMIMEType(NSString *type); |
| 60 NSString *WKGetMIMETypeForExtension(NSString *extension); |
| 61 |
| 62 NSDate *WKGetNSURLResponseLastModifiedDate(NSURLResponse *response); |
| 63 NSTimeInterval WKGetNSURLResponseFreshnessLifetime(NSURLResponse *response); |
| 64 NSString *WKCopyNSURLResponseStatusLine(NSURLResponse *response); |
| 65 |
| 66 #ifndef BUILDING_ON_LEOPARD |
| 67 CFArrayRef WKCopyNSURLResponseCertificateChain(NSURLResponse *response); |
| 68 #endif |
| 69 |
| 70 CFStringEncoding WKGetWebDefaultCFStringEncoding(void); |
| 71 |
| 72 void WKSetMetadataURL(NSString *URLString, NSString *referrer, NSString *path); |
| 73 void WKSetNSURLConnectionDefersCallbacks(NSURLConnection *connection, BOOL defer
s); |
| 74 |
| 75 void WKShowKeyAndMain(void); |
| 76 #ifndef __LP64__ |
| 77 OSStatus WKSyncWindowWithCGAfterMove(WindowRef); |
| 78 unsigned WKCarbonWindowMask(void); |
| 79 void *WKGetNativeWindowFromWindowRef(WindowRef); |
| 80 OSType WKCarbonWindowPropertyCreator(void); |
| 81 OSType WKCarbonWindowPropertyTag(void); |
| 82 #endif |
| 83 |
| 84 typedef id WKNSURLConnectionDelegateProxyPtr; |
| 85 |
| 86 WKNSURLConnectionDelegateProxyPtr WKCreateNSURLConnectionDelegateProxy(void); |
| 87 |
| 88 void WKDisableCGDeferredUpdates(void); |
| 89 |
| 90 Class WKNSURLProtocolClassForRequest(NSURLRequest *request); |
| 91 void WKSetNSURLRequestShouldContentSniff(NSMutableURLRequest *request, BOOL shou
ldContentSniff); |
| 92 |
| 93 void WKSetCookieStoragePrivateBrowsingEnabled(BOOL enabled); |
| 94 |
| 95 unsigned WKGetNSAutoreleasePoolCount(void); |
| 96 |
| 97 void WKAdvanceDefaultButtonPulseAnimation(NSButtonCell *button); |
| 98 |
| 99 NSString *WKMouseMovedNotification(void); |
| 100 NSString *WKWindowWillOrderOnScreenNotification(void); |
| 101 NSString *WKWindowWillOrderOffScreenNotification(void); |
| 102 void WKSetNSWindowShouldPostEventNotifications(NSWindow *window, BOOL post); |
| 103 |
| 104 CFTypeID WKGetAXTextMarkerTypeID(void); |
| 105 CFTypeID WKGetAXTextMarkerRangeTypeID(void); |
| 106 CFTypeRef WKCreateAXTextMarker(const void *bytes, size_t len); |
| 107 BOOL WKGetBytesFromAXTextMarker(CFTypeRef textMarker, void *bytes, size_t length
); |
| 108 CFTypeRef WKCreateAXTextMarkerRange(CFTypeRef start, CFTypeRef end); |
| 109 CFTypeRef WKCopyAXTextMarkerRangeStart(CFTypeRef range); |
| 110 CFTypeRef WKCopyAXTextMarkerRangeEnd(CFTypeRef range); |
| 111 void WKAccessibilityHandleFocusChanged(void); |
| 112 AXUIElementRef WKCreateAXUIElementRef(id element); |
| 113 void WKUnregisterUniqueIdForElement(id element); |
| 114 |
| 115 |
| 116 #if !defined(BUILDING_ON_LEOPARD) |
| 117 // Remote Accessibility API. |
| 118 void WKAXRegisterRemoteApp(void); |
| 119 void WKAXInitializeElementWithPresenterPid(id, pid_t); |
| 120 NSData *WKAXRemoteTokenForElement(id); |
| 121 id WKAXRemoteElementForToken(NSData *); |
| 122 void WKAXSetWindowForRemoteElement(id remoteWindow, id remoteElement); |
| 123 void WKAXRegisterRemoteProcess(bool registerProcess, pid_t); |
| 124 pid_t WKAXRemoteProcessIdentifier(id remoteElement); |
| 125 #endif |
| 126 |
| 127 void WKSetUpFontCache(void); |
| 128 |
| 129 void WKSignalCFReadStreamEnd(CFReadStreamRef stream); |
| 130 void WKSignalCFReadStreamHasBytes(CFReadStreamRef stream); |
| 131 void WKSignalCFReadStreamError(CFReadStreamRef stream, CFStreamError *error); |
| 132 |
| 133 CFReadStreamRef WKCreateCustomCFReadStream(void *(*formCreate)(CFReadStreamRef,
void *), |
| 134 void (*formFinalize)(CFReadStreamRef, void *), |
| 135 Boolean (*formOpen)(CFReadStreamRef, CFStreamError *, Boolean *, void *), |
| 136 CFIndex (*formRead)(CFReadStreamRef, UInt8 *, CFIndex, CFStreamError *, Bool
ean *, void *), |
| 137 Boolean (*formCanRead)(CFReadStreamRef, void *), |
| 138 void (*formClose)(CFReadStreamRef, void *), |
| 139 void (*formSchedule)(CFReadStreamRef, CFRunLoopRef, CFStringRef, void *), |
| 140 void (*formUnschedule)(CFReadStreamRef, CFRunLoopRef, CFStringRef, void *), |
| 141 void *context); |
| 142 |
| 143 void WKDrawCapsLockIndicator(CGContextRef, CGRect); |
| 144 |
| 145 void WKDrawFocusRing(CGContextRef context, CGColorRef color, int radius); |
| 146 // The CG context's current path is the focus ring's path. |
| 147 // A color of 0 means "use system focus ring color". |
| 148 // A radius of 0 means "use default focus ring radius". |
| 149 |
| 150 void WKSetDragImage(NSImage *image, NSPoint offset); |
| 151 |
| 152 void WKDrawBezeledTextFieldCell(NSRect, BOOL enabled); |
| 153 void WKDrawTextFieldCellFocusRing(NSTextFieldCell*, NSRect); |
| 154 void WKDrawBezeledTextArea(NSRect, BOOL enabled); |
| 155 void WKPopupMenu(NSMenu*, NSPoint location, float width, NSView*, int selectedIt
em, NSFont*); |
| 156 void WKPopupContextMenu(NSMenu *menu, NSPoint screenLocation); |
| 157 void WKSendUserChangeNotifications(void); |
| 158 #ifndef __LP64__ |
| 159 BOOL WKConvertNSEventToCarbonEvent(EventRecord *carbonEvent, NSEvent *cocoaEvent
); |
| 160 void WKSendKeyEventToTSM(NSEvent *theEvent); |
| 161 void WKCallDrawingNotification(CGrafPtr port, Rect *bounds); |
| 162 #endif |
| 163 |
| 164 BOOL WKGetGlyphTransformedAdvances(CGFontRef, NSFont*, CGAffineTransform *m, ATS
GlyphRef *glyph, CGSize *advance); |
| 165 NSFont *WKGetFontInLanguageForRange(NSFont *font, NSString *string, NSRange rang
e); |
| 166 NSFont *WKGetFontInLanguageForCharacter(NSFont *font, UniChar ch); |
| 167 void WKSetCGFontRenderingMode(CGContextRef cgContext, NSFont *font); |
| 168 BOOL WKCGContextGetShouldSmoothFonts(CGContextRef cgContext); |
| 169 |
| 170 |
| 171 void WKSetBaseCTM(CGContextRef, CGAffineTransform); |
| 172 void WKSetPatternPhaseInUserSpace(CGContextRef, CGPoint); |
| 173 CGAffineTransform WKGetUserToBaseCTM(CGContextRef); |
| 174 |
| 175 void WKGetGlyphsForCharacters(CGFontRef, const UniChar[], CGGlyph[], size_t); |
| 176 bool WKGetVerticalGlyphsForCharacters(CTFontRef, const UniChar[], CGGlyph[], siz
e_t); |
| 177 |
| 178 CTLineRef WKCreateCTLineWithUniCharProvider(const UniChar* (*provide)(CFIndex st
ringIndex, CFIndex* charCount, CFDictionaryRef* attributes, void*), void (*dispo
se)(const UniChar* chars, void*), void*); |
| 179 #if !defined(BUILDING_ON_LEOPARD) && !defined(BUILDING_ON_SNOW_LEOPARD) |
| 180 CTTypesetterRef WKCreateCTTypesetterWithUniCharProviderAndOptions(const UniChar*
(*provide)(CFIndex stringIndex, CFIndex* charCount, CFDictionaryRef* attributes
, void*), void (*dispose)(const UniChar* chars, void*), void*, CFDictionaryRef o
ptions); |
| 181 |
| 182 CGContextRef WKIOSurfaceContextCreate(IOSurfaceRef, unsigned width, unsigned hei
ght, CGColorSpaceRef); |
| 183 CGImageRef WKIOSurfaceContextCreateImage(CGContextRef context); |
| 184 #endif |
| 185 |
| 186 typedef enum { |
| 187 WKPatternTilingNoDistortion, |
| 188 WKPatternTilingConstantSpacingMinimalDistortion, |
| 189 WKPatternTilingConstantSpacing |
| 190 } WKPatternTiling; |
| 191 |
| 192 CGPatternRef WKCGPatternCreateWithImageAndTransform(CGImageRef image, CGAffineTr
ansform transform, int tiling); |
| 193 |
| 194 #ifndef __LP64__ |
| 195 NSEvent *WKCreateNSEventWithCarbonEvent(EventRef eventRef); |
| 196 NSEvent *WKCreateNSEventWithCarbonMouseMoveEvent(EventRef inEvent, NSWindow *win
dow); |
| 197 NSEvent *WKCreateNSEventWithCarbonClickEvent(EventRef inEvent, WindowRef windowR
ef); |
| 198 #endif |
| 199 |
| 200 CGContextRef WKNSWindowOverrideCGContext(NSWindow *, CGContextRef); |
| 201 void WKNSWindowRestoreCGContext(NSWindow *, CGContextRef); |
| 202 |
| 203 void WKNSWindowMakeBottomCornersSquare(NSWindow *); |
| 204 |
| 205 // These constants match the ones used by ThemeScrollbarArrowStyle (some of the
values are private, so we can't just |
| 206 // use that enum directly). |
| 207 typedef enum { |
| 208 WKThemeScrollBarArrowsSingle = 0, |
| 209 WKThemeScrollBarArrowsLowerRight = 1, |
| 210 WKThemeScrollBarArrowsDouble = 2, |
| 211 WKThemeScrollBarArrowsUpperLeft = 3, |
| 212 } WKThemeScrollBarArrowStyle; |
| 213 |
| 214 OSStatus WKThemeDrawTrack(const HIThemeTrackDrawInfo* inDrawInfo, CGContextRef i
nContext, int inArrowStyle); |
| 215 |
| 216 |
| 217 BOOL WKCGContextIsBitmapContext(CGContextRef context); |
| 218 |
| 219 void WKGetWheelEventDeltas(NSEvent *, float *deltaX, float *deltaY, BOOL *contin
uous); |
| 220 |
| 221 BOOL WKAppVersionCheckLessThan(NSString *, int, double); |
| 222 |
| 223 typedef enum { |
| 224 WKMovieTypeUnknown, |
| 225 WKMovieTypeDownload, |
| 226 WKMovieTypeStoredStream, |
| 227 WKMovieTypeLiveStream |
| 228 } WKMovieType; |
| 229 |
| 230 int WKQTMovieGetType(QTMovie* movie); |
| 231 |
| 232 BOOL WKQTMovieHasClosedCaptions(QTMovie* movie); |
| 233 void WKQTMovieSetShowClosedCaptions(QTMovie* movie, BOOL showClosedCaptions); |
| 234 void WKQTMovieSelectPreferredAlternates(QTMovie* movie); |
| 235 void WKQTMovieSelectPreferredAlternateTrackForMediaType(QTMovie* movie, NSString
* mediaType); |
| 236 |
| 237 unsigned WKQTIncludeOnlyModernMediaFileTypes(void); |
| 238 int WKQTMovieDataRate(QTMovie* movie); |
| 239 float WKQTMovieMaxTimeLoaded(QTMovie* movie); |
| 240 float WKQTMovieMaxTimeSeekable(QTMovie* movie); |
| 241 NSString *WKQTMovieMaxTimeLoadedChangeNotification(void); |
| 242 void WKQTMovieViewSetDrawSynchronously(QTMovieView* view, BOOL sync); |
| 243 void WKQTMovieDisableComponent(uint32_t[5]); |
| 244 NSURL *WKQTMovieResolvedURL(QTMovie* movie); |
| 245 |
| 246 CFStringRef WKCopyFoundationCacheDirectory(void); |
| 247 |
| 248 #if defined(BUILDING_ON_SNOW_LEOPARD) || defined(BUILDING_ON_LEOPARD) |
| 249 typedef struct __CFURLStorageSession* CFURLStorageSessionRef; |
| 250 #else |
| 251 typedef const struct __CFURLStorageSession* CFURLStorageSessionRef; |
| 252 #endif |
| 253 CFURLStorageSessionRef WKCreatePrivateStorageSession(CFStringRef); |
| 254 NSURLRequest *WKCopyRequestWithStorageSession(CFURLStorageSessionRef, NSURLReque
st*); |
| 255 NSCachedURLResponse *WKCachedResponseForRequest(CFURLStorageSessionRef, NSURLReq
uest*); |
| 256 void WKSetRequestStorageSession(CFURLStorageSessionRef, CFMutableURLRequestRef); |
| 257 |
| 258 typedef struct OpaqueCFHTTPCookieStorage* CFHTTPCookieStorageRef; |
| 259 CFHTTPCookieStorageRef WKCopyHTTPCookieStorage(CFURLStorageSessionRef); |
| 260 unsigned WKGetHTTPCookieAcceptPolicy(CFHTTPCookieStorageRef); |
| 261 void WKSetHTTPCookieAcceptPolicy(CFHTTPCookieStorageRef, unsigned policy); |
| 262 NSArray *WKHTTPCookiesForURL(CFHTTPCookieStorageRef, NSURL *); |
| 263 void WKSetHTTPCookiesForURL(CFHTTPCookieStorageRef, NSArray *, NSURL *, NSURL *)
; |
| 264 void WKDeleteHTTPCookie(CFHTTPCookieStorageRef, NSHTTPCookie *); |
| 265 |
| 266 CFHTTPCookieStorageRef WKGetDefaultHTTPCookieStorage(void); |
| 267 WKCFURLCredentialRef WKCopyCredentialFromCFPersistentStorage(CFURLProtectionSpac
eRef); |
| 268 void WKSetCFURLRequestShouldContentSniff(CFMutableURLRequestRef, bool flag); |
| 269 CFArrayRef WKCFURLRequestCopyHTTPRequestBodyParts(CFURLRequestRef); |
| 270 void WKCFURLRequestSetHTTPRequestBodyParts(CFMutableURLRequestRef, CFArrayRef bo
dyParts); |
| 271 |
| 272 void WKSetVisibleApplicationName(CFStringRef); |
| 273 |
| 274 typedef enum { |
| 275 WKMediaUIPartFullscreenButton = 0, |
| 276 WKMediaUIPartMuteButton, |
| 277 WKMediaUIPartPlayButton, |
| 278 WKMediaUIPartSeekBackButton, |
| 279 WKMediaUIPartSeekForwardButton, |
| 280 WKMediaUIPartTimelineSlider, |
| 281 WKMediaUIPartTimelineSliderThumb, |
| 282 WKMediaUIPartRewindButton, |
| 283 WKMediaUIPartSeekToRealtimeButton, |
| 284 WKMediaUIPartShowClosedCaptionsButton, |
| 285 WKMediaUIPartHideClosedCaptionsButton, |
| 286 WKMediaUIPartUnMuteButton, |
| 287 WKMediaUIPartPauseButton, |
| 288 WKMediaUIPartBackground, |
| 289 WKMediaUIPartCurrentTimeDisplay, |
| 290 WKMediaUIPartTimeRemainingDisplay, |
| 291 WKMediaUIPartStatusDisplay, |
| 292 WKMediaUIPartControlsPanel, |
| 293 WKMediaUIPartVolumeSliderContainer, |
| 294 WKMediaUIPartVolumeSlider, |
| 295 WKMediaUIPartVolumeSliderThumb |
| 296 } WKMediaUIPart; |
| 297 |
| 298 typedef enum { |
| 299 WKMediaControllerThemeClassic = 1, |
| 300 WKMediaControllerThemeQuickTime = 2 |
| 301 } WKMediaControllerThemeStyle; |
| 302 |
| 303 typedef enum { |
| 304 WKMediaControllerFlagDisabled = 1 << 0, |
| 305 WKMediaControllerFlagPressed = 1 << 1, |
| 306 WKMediaControllerFlagDrawEndCaps = 1 << 3, |
| 307 WKMediaControllerFlagFocused = 1 << 4 |
| 308 } WKMediaControllerThemeState; |
| 309 |
| 310 BOOL WKMediaControllerThemeAvailable(int themeStyle); |
| 311 BOOL WKHitTestMediaUIPart(int part, int themeStyle, CGRect bounds, CGPoint point
); |
| 312 void WKMeasureMediaUIPart(int part, int themeStyle, CGRect *bounds, CGSize *natu
ralSize); |
| 313 void WKDrawMediaUIPart(int part, int themeStyle, CGContextRef context, CGRect re
ct, unsigned state); |
| 314 void WKDrawMediaSliderTrack(int themeStyle, CGContextRef context, CGRect rect, f
loat timeLoaded, float currentTime, float duration, unsigned state); |
| 315 NSView *WKCreateMediaUIBackgroundView(void); |
| 316 |
| 317 typedef enum { |
| 318 WKMediaUIControlTimeline, |
| 319 WKMediaUIControlSlider, |
| 320 WKMediaUIControlPlayPauseButton, |
| 321 WKMediaUIControlExitFullscreenButton, |
| 322 WKMediaUIControlRewindButton, |
| 323 WKMediaUIControlFastForwardButton, |
| 324 WKMediaUIControlVolumeUpButton, |
| 325 WKMediaUIControlVolumeDownButton |
| 326 } WKMediaUIControlType; |
| 327 |
| 328 NSControl *WKCreateMediaUIControl(int controlType); |
| 329 |
| 330 NSArray *WKQTGetSitesInMediaDownloadCache(); |
| 331 void WKQTClearMediaDownloadCacheForSite(NSString *site); |
| 332 void WKQTClearMediaDownloadCache(); |
| 333 |
| 334 #ifndef BUILDING_ON_LEOPARD |
| 335 mach_port_t WKInitializeRenderServer(void); |
| 336 |
| 337 @class CALayer; |
| 338 |
| 339 CALayer *WKMakeRenderLayer(uint32_t contextID); |
| 340 |
| 341 typedef struct __WKSoftwareCARendererRef *WKSoftwareCARendererRef; |
| 342 |
| 343 WKSoftwareCARendererRef WKSoftwareCARendererCreate(uint32_t contextID); |
| 344 void WKSoftwareCARendererDestroy(WKSoftwareCARendererRef); |
| 345 void WKSoftwareCARendererRender(WKSoftwareCARendererRef, CGContextRef, CGRect); |
| 346 |
| 347 typedef struct __WKCARemoteLayerClientRef *WKCARemoteLayerClientRef; |
| 348 |
| 349 WKCARemoteLayerClientRef WKCARemoteLayerClientMakeWithServerPort(mach_port_t por
t); |
| 350 void WKCARemoteLayerClientInvalidate(WKCARemoteLayerClientRef); |
| 351 uint32_t WKCARemoteLayerClientGetClientId(WKCARemoteLayerClientRef); |
| 352 void WKCARemoteLayerClientSetLayer(WKCARemoteLayerClientRef, CALayer *); |
| 353 CALayer *WKCARemoteLayerClientGetLayer(WKCARemoteLayerClientRef); |
| 354 |
| 355 @class CARenderer; |
| 356 |
| 357 void WKCARendererAddChangeNotificationObserver(CARenderer *, void (*callback)(vo
id*), void* context); |
| 358 void WKCARendererRemoveChangeNotificationObserver(CARenderer *, void (*callback)
(void*), void* context); |
| 359 |
| 360 typedef struct __WKWindowBounceAnimationContext *WKWindowBounceAnimationContextR
ef; |
| 361 |
| 362 WKWindowBounceAnimationContextRef WKWindowBounceAnimationContextCreate(NSWindow
*window); |
| 363 void WKWindowBounceAnimationContextDestroy(WKWindowBounceAnimationContextRef con
text); |
| 364 void WKWindowBounceAnimationSetAnimationProgress(WKWindowBounceAnimationContextR
ef context, double animationProgress); |
| 365 |
| 366 #if defined(__x86_64__) |
| 367 #import <mach/mig.h> |
| 368 CFRunLoopSourceRef WKCreateMIGServerSource(mig_subsystem_t subsystem, mach_port_
t serverPort); |
| 369 #endif // defined(__x86_64__) |
| 370 |
| 371 NSUInteger WKGetInputPanelWindowStyle(void); |
| 372 UInt8 WKGetNSEventKeyChar(NSEvent *); |
| 373 #endif // !defined(BUILDING_ON_LEOPARD) |
| 374 |
| 375 @class CAPropertyAnimation; |
| 376 void WKSetCAAnimationValueFunction(CAPropertyAnimation*, NSString* function); |
| 377 |
| 378 unsigned WKInitializeMaximumHTTPConnectionCountPerHost(unsigned preferredConnect
ionCount); |
| 379 int WKGetHTTPPipeliningPriority(CFURLRequestRef); |
| 380 void WKSetHTTPPipeliningMaximumPriority(int maximumPriority); |
| 381 void WKSetHTTPPipeliningPriority(CFURLRequestRef, int priority); |
| 382 void WKSetHTTPPipeliningMinimumFastLanePriority(int priority); |
| 383 |
| 384 void WKSetCONNECTProxyForStream(CFReadStreamRef, CFStringRef proxyHost, CFNumber
Ref proxyPort); |
| 385 void WKSetCONNECTProxyAuthorizationForStream(CFReadStreamRef, CFStringRef proxyA
uthorizationString); |
| 386 CFHTTPMessageRef WKCopyCONNECTProxyResponse(CFReadStreamRef, CFURLRef responseUR
L); |
| 387 |
| 388 #if defined(BUILDING_ON_LEOPARD) || defined(BUILDING_ON_SNOW_LEOPARD) |
| 389 typedef enum { |
| 390 WKEventPhaseNone = 0, |
| 391 WKEventPhaseBegan = 1, |
| 392 WKEventPhaseChanged = 2, |
| 393 WKEventPhaseEnded = 3, |
| 394 } WKEventPhase; |
| 395 |
| 396 int WKGetNSEventMomentumPhase(NSEvent *); |
| 397 #endif |
| 398 |
| 399 void WKWindowSetAlpha(NSWindow *window, float alphaValue); |
| 400 void WKWindowSetScaledFrame(NSWindow *window, NSRect scaleFrame, NSRect nonScale
dFrame); |
| 401 |
| 402 #ifndef BUILDING_ON_LEOPARD |
| 403 void WKSyncSurfaceToView(NSView *view); |
| 404 |
| 405 void WKEnableSettingCursorWhenInBackground(void); |
| 406 |
| 407 CFDictionaryRef WKNSURLRequestCreateSerializableRepresentation(NSURLRequest *req
uest, CFTypeRef tokenNull); |
| 408 NSURLRequest *WKNSURLRequestFromSerializableRepresentation(CFDictionaryRef repre
sentation, CFTypeRef tokenNull); |
| 409 |
| 410 CFDictionaryRef WKNSURLResponseCreateSerializableRepresentation(NSURLResponse *r
esponse, CFTypeRef tokenNull); |
| 411 NSURLResponse *WKNSURLResponseFromSerializableRepresentation(CFDictionaryRef rep
resentation, CFTypeRef tokenNull); |
| 412 |
| 413 #ifndef __LP64__ |
| 414 ScriptCode WKGetScriptCodeFromCurrentKeyboardInputSource(void); |
| 415 #endif |
| 416 |
| 417 #endif |
| 418 |
| 419 #if defined(BUILDING_ON_LEOPARD) || defined(BUILDING_ON_SNOW_LEOPARD) |
| 420 CFIndex WKGetHyphenationLocationBeforeIndex(CFStringRef string, CFIndex index); |
| 421 #endif |
| 422 |
| 423 CFArrayRef WKCFURLCacheCopyAllHostNamesInPersistentStore(void); |
| 424 void WKCFURLCacheDeleteHostNamesInPersistentStore(CFArrayRef hostArray); |
| 425 |
| 426 CFStringRef WKGetCFURLResponseMIMEType(CFURLResponseRef); |
| 427 CFURLRef WKGetCFURLResponseURL(CFURLResponseRef); |
| 428 CFHTTPMessageRef WKGetCFURLResponseHTTPResponse(CFURLResponseRef); |
| 429 CFStringRef WKCopyCFURLResponseSuggestedFilename(CFURLResponseRef); |
| 430 void WKSetCFURLResponseMIMEType(CFURLResponseRef, CFStringRef mimeType); |
| 431 |
| 432 CIFormat WKCIGetRGBA8Format(void); |
| 433 |
| 434 #if !defined(BUILDING_ON_LEOPARD) && !defined(BUILDING_ON_SNOW_LEOPARD) |
| 435 |
| 436 typedef enum { |
| 437 WKSandboxExtensionTypeReadOnly, |
| 438 WKSandboxExtensionTypeWriteOnly, |
| 439 WKSandboxExtensionTypeReadWrite, |
| 440 } WKSandboxExtensionType; |
| 441 typedef struct __WKSandboxExtension *WKSandboxExtensionRef; |
| 442 |
| 443 WKSandboxExtensionRef WKSandboxExtensionCreate(const char* path, WKSandboxExtens
ionType type); |
| 444 void WKSandboxExtensionDestroy(WKSandboxExtensionRef sandboxExtension); |
| 445 |
| 446 bool WKSandboxExtensionConsume(WKSandboxExtensionRef sandboxExtension); |
| 447 bool WKSandboxExtensionInvalidate(WKSandboxExtensionRef sandboxExtension); |
| 448 |
| 449 const char* WKSandboxExtensionGetSerializedFormat(WKSandboxExtensionRef sandboxE
xtension, size_t* length); |
| 450 WKSandboxExtensionRef WKSandboxExtensionCreateFromSerializedFormat(const char* s
erializationFormat, size_t length); |
| 451 |
| 452 int WKRecommendedScrollerStyle(void); |
| 453 |
| 454 bool WKExecutableWasLinkedOnOrBeforeSnowLeopard(void); |
| 455 |
| 456 NSRange WKExtractWordDefinitionTokenRangeFromContextualString(NSString *contextS
tring, NSRange range, NSDictionary **options); |
| 457 void WKShowWordDefinitionWindow(NSAttributedString *term, NSPoint screenPoint, N
SDictionary *options); |
| 458 void WKHideWordDefinitionWindow(void); |
| 459 |
| 460 CFStringRef WKCopyDefaultSearchProviderDisplayName(void); |
| 461 |
| 462 NSURL* WKAVAssetResolvedURL(AVAsset*); |
| 463 |
| 464 NSCursor *WKCursor(const char *name); |
| 465 |
| 466 #endif |
| 467 |
| 468 #if !defined(BUILDING_ON_LEOPARD) && !defined(BUILDING_ON_SNOW_LEOPARD) |
| 469 |
| 470 #import <dispatch/dispatch.h> |
| 471 |
| 472 dispatch_source_t WKCreateVMPressureDispatchOnMainQueue(void); |
| 473 |
| 474 #endif |
| 475 |
| 476 #ifdef __cplusplus |
| 477 } |
| 478 #endif |
| OLD | NEW |