diff options
Diffstat (limited to 'Source/WebKit2/UIProcess/API/C')
-rw-r--r-- | Source/WebKit2/UIProcess/API/C/WKAPICast.h | 4 | ||||
-rw-r--r-- | Source/WebKit2/UIProcess/API/C/WKInspector.cpp | 5 | ||||
-rw-r--r-- | Source/WebKit2/UIProcess/API/C/WKInspector.h | 1 | ||||
-rw-r--r-- | Source/WebKit2/UIProcess/API/C/WKNotification.cpp | 5 | ||||
-rw-r--r-- | Source/WebKit2/UIProcess/API/C/WKNotification.h | 1 | ||||
-rw-r--r-- | Source/WebKit2/UIProcess/API/C/WKPage.cpp | 5 | ||||
-rw-r--r-- | Source/WebKit2/UIProcess/API/C/WKPage.h | 23 | ||||
-rw-r--r-- | Source/WebKit2/UIProcess/API/C/WKPagePrivate.h | 1 | ||||
-rw-r--r-- | Source/WebKit2/UIProcess/API/C/WKPreferences.cpp | 10 | ||||
-rw-r--r-- | Source/WebKit2/UIProcess/API/C/WKPreferences.h | 5 | ||||
-rw-r--r-- | Source/WebKit2/UIProcess/API/C/mac/WKInspectorPrivateMac.h (renamed from Source/WebKit2/UIProcess/API/C/mac/WKInspectorMac.h) | 16 |
11 files changed, 64 insertions, 12 deletions
diff --git a/Source/WebKit2/UIProcess/API/C/WKAPICast.h b/Source/WebKit2/UIProcess/API/C/WKAPICast.h index 0e7175a42..bd3fa2d74 100644 --- a/Source/WebKit2/UIProcess/API/C/WKAPICast.h +++ b/Source/WebKit2/UIProcess/API/C/WKAPICast.h @@ -83,6 +83,8 @@ class WebPageProxy; class WebPluginSiteDataManager; class WebPreferences; class WebProtectionSpace; +class WebRenderLayer; +class WebRenderObject; class WebTextChecker; WK_ADD_API_MAPPING(WKApplicationCacheManagerRef, WebApplicationCacheManagerProxy) @@ -119,6 +121,8 @@ WK_ADD_API_MAPPING(WKPageRef, WebPageProxy) WK_ADD_API_MAPPING(WKPluginSiteDataManagerRef, WebPluginSiteDataManager) WK_ADD_API_MAPPING(WKPreferencesRef, WebPreferences) WK_ADD_API_MAPPING(WKProtectionSpaceRef, WebProtectionSpace) +WK_ADD_API_MAPPING(WKRenderLayerRef, WebRenderLayer) +WK_ADD_API_MAPPING(WKRenderObjectRef, WebRenderObject) WK_ADD_API_MAPPING(WKTextCheckerRef, WebTextChecker) #if ENABLE(INSPECTOR) diff --git a/Source/WebKit2/UIProcess/API/C/WKInspector.cpp b/Source/WebKit2/UIProcess/API/C/WKInspector.cpp index 1a4ecc7c9..7e2187dda 100644 --- a/Source/WebKit2/UIProcess/API/C/WKInspector.cpp +++ b/Source/WebKit2/UIProcess/API/C/WKInspector.cpp @@ -48,6 +48,11 @@ bool WKInspectorIsVisible(WKInspectorRef inspectorRef) return toImpl(inspectorRef)->isVisible(); } +bool WKInspectorIsFront(WKInspectorRef inspectorRef) +{ + return toImpl(inspectorRef)->isFront(); +} + void WKInspectorShow(WKInspectorRef inspectorRef) { toImpl(inspectorRef)->show(); diff --git a/Source/WebKit2/UIProcess/API/C/WKInspector.h b/Source/WebKit2/UIProcess/API/C/WKInspector.h index 2e85688d0..a00d103de 100644 --- a/Source/WebKit2/UIProcess/API/C/WKInspector.h +++ b/Source/WebKit2/UIProcess/API/C/WKInspector.h @@ -43,6 +43,7 @@ WK_EXPORT WKTypeID WKInspectorGetTypeID(); WK_EXPORT WKPageRef WKInspectorGetPage(WKInspectorRef inspector); WK_EXPORT bool WKInspectorIsVisible(WKInspectorRef inspector); +WK_EXPORT bool WKInspectorIsFront(WKInspectorRef inspector); WK_EXPORT void WKInspectorShow(WKInspectorRef inspector); WK_EXPORT void WKInspectorClose(WKInspectorRef inspector); diff --git a/Source/WebKit2/UIProcess/API/C/WKNotification.cpp b/Source/WebKit2/UIProcess/API/C/WKNotification.cpp index 634aa9824..5dfcbba29 100644 --- a/Source/WebKit2/UIProcess/API/C/WKNotification.cpp +++ b/Source/WebKit2/UIProcess/API/C/WKNotification.cpp @@ -52,6 +52,11 @@ WKStringRef WKNotificationCopyIconURL(WKNotificationRef notification) return toCopiedAPI(toImpl(notification)->iconURL()); } +WKStringRef WKNotificationCopyReplaceID(WKNotificationRef notification) +{ + return toCopiedAPI(toImpl(notification)->replaceID()); +} + WKSecurityOriginRef WKNotificationGetSecurityOrigin(WKNotificationRef notification) { return toAPI(toImpl(notification)->origin()); diff --git a/Source/WebKit2/UIProcess/API/C/WKNotification.h b/Source/WebKit2/UIProcess/API/C/WKNotification.h index 7c2723896..11ea97275 100644 --- a/Source/WebKit2/UIProcess/API/C/WKNotification.h +++ b/Source/WebKit2/UIProcess/API/C/WKNotification.h @@ -37,6 +37,7 @@ WK_EXPORT WKTypeID WKNotificationGetTypeID(); WK_EXPORT WKStringRef WKNotificationCopyTitle(WKNotificationRef notification); WK_EXPORT WKStringRef WKNotificationCopyBody(WKNotificationRef notification); WK_EXPORT WKStringRef WKNotificationCopyIconURL(WKNotificationRef notification); +WK_EXPORT WKStringRef WKNotificationCopyReplaceID(WKNotificationRef notification); WK_EXPORT WKSecurityOriginRef WKNotificationGetSecurityOrigin(WKNotificationRef notification); WK_EXPORT uint64_t WKNotificationGetID(WKNotificationRef notification); diff --git a/Source/WebKit2/UIProcess/API/C/WKPage.cpp b/Source/WebKit2/UIProcess/API/C/WKPage.cpp index 3010016c3..130dd0e45 100644 --- a/Source/WebKit2/UIProcess/API/C/WKPage.cpp +++ b/Source/WebKit2/UIProcess/API/C/WKPage.cpp @@ -660,6 +660,11 @@ void WKPageDrawPagesToPDF(WKPageRef page, WKFrameRef frame, WKPrintInfo printInf { toImpl(page)->drawPagesToPDF(toImpl(frame), printInfoFromWKPrintInfo(printInfo), first, count, DataCallback::create(context, callback)); } + +void WKPageEndPrinting(WKPageRef page) +{ + toImpl(page)->endPrinting(); +} #endif WKImageRef WKPageCreateSnapshotOfVisibleContent(WKPageRef) diff --git a/Source/WebKit2/UIProcess/API/C/WKPage.h b/Source/WebKit2/UIProcess/API/C/WKPage.h index 96d097c60..05b7aff0c 100644 --- a/Source/WebKit2/UIProcess/API/C/WKPage.h +++ b/Source/WebKit2/UIProcess/API/C/WKPage.h @@ -285,24 +285,29 @@ enum { }; // ContextMenu client -typedef void (*WKPageGetContextMenuFromProposedContextMenuCallback)(WKPageRef page, WKArrayRef proposedMenu, WKArrayRef* newMenu, WKTypeRef userData, const void* clientInfo); +typedef void (*WKPageGetContextMenuFromProposedContextMenuCallback)(WKPageRef page, WKArrayRef proposedMenu, WKArrayRef* newMenu, WKHitTestResultRef hitTestResult, WKTypeRef userData, const void* clientInfo); typedef void (*WKPageCustomContextMenuItemSelectedCallback)(WKPageRef page, WKContextMenuItemRef contextMenuItem, const void* clientInfo); typedef void (*WKPageContextMenuDismissedCallback)(WKPageRef page, const void* clientInfo); +// Deprecated +typedef void (*WKPageGetContextMenuFromProposedContextMenuCallback_deprecatedForUseWithV0)(WKPageRef page, WKArrayRef proposedMenu, WKArrayRef* newMenu, WKTypeRef userData, const void* clientInfo); struct WKPageContextMenuClient { - int version; - const void * clientInfo; - + int version; + const void * clientInfo; + // Version 0 - WKPageGetContextMenuFromProposedContextMenuCallback getContextMenuFromProposedMenu; - WKPageCustomContextMenuItemSelectedCallback customContextMenuItemSelected; - + WKPageGetContextMenuFromProposedContextMenuCallback_deprecatedForUseWithV0 getContextMenuFromProposedMenu_deprecatedForUseWithV0; + WKPageCustomContextMenuItemSelectedCallback customContextMenuItemSelected; + // Version 1 - WKPageContextMenuDismissedCallback contextMenuDismissed; + WKPageContextMenuDismissedCallback contextMenuDismissed; + + // Version 2 + WKPageGetContextMenuFromProposedContextMenuCallback getContextMenuFromProposedMenu; }; typedef struct WKPageContextMenuClient WKPageContextMenuClient; -enum { kWKPageContextMenuClientCurrentVersion = 1 }; +enum { kWKPageContextMenuClientCurrentVersion = 2 }; WK_EXPORT WKTypeID WKPageGetTypeID(); diff --git a/Source/WebKit2/UIProcess/API/C/WKPagePrivate.h b/Source/WebKit2/UIProcess/API/C/WKPagePrivate.h index 097aabfe1..18860fd74 100644 --- a/Source/WebKit2/UIProcess/API/C/WKPagePrivate.h +++ b/Source/WebKit2/UIProcess/API/C/WKPagePrivate.h @@ -83,6 +83,7 @@ WK_EXPORT void WKPageComputePagesForPrinting(WKPageRef page, WKFrameRef frame, W typedef void (*WKPageDrawToPDFFunction)(WKDataRef data, WKErrorRef error, void* functionContext); WK_EXPORT void WKPageBeginPrinting(WKPageRef page, WKFrameRef frame, WKPrintInfo printInfo); WK_EXPORT void WKPageDrawPagesToPDF(WKPageRef page, WKFrameRef frame, WKPrintInfo printInfo, uint32_t first, uint32_t count, WKPageDrawToPDFFunction callback, void* context); +WK_EXPORT void WKPageEndPrinting(WKPageRef page); // FIXME https://bugs.webkit.org/show_bug.cgi?id=66979: Remove this sync call. WK_EXPORT WKImageRef WKPageCreateSnapshotOfVisibleContent(WKPageRef page); diff --git a/Source/WebKit2/UIProcess/API/C/WKPreferences.cpp b/Source/WebKit2/UIProcess/API/C/WKPreferences.cpp index 87d32ed2f..39903bcb5 100644 --- a/Source/WebKit2/UIProcess/API/C/WKPreferences.cpp +++ b/Source/WebKit2/UIProcess/API/C/WKPreferences.cpp @@ -688,6 +688,16 @@ bool WKPreferencesGetSuppressesIncrementalRendering(WKPreferencesRef preferences return toImpl(preferencesRef)->suppressesIncrementalRendering(); } +void WKPreferencesSetSuppressIncrementalRendering(WKPreferencesRef preferencesRef, bool enabled) +{ + WKPreferencesSetSuppressesIncrementalRendering(preferencesRef, enabled); +} + +bool WKPreferencesGetSuppressIncrementalRendering(WKPreferencesRef preferencesRef) +{ + return WKPreferencesGetSuppressesIncrementalRendering(preferencesRef); +} + void WKPreferencesSetBackspaceKeyNavigationEnabled(WKPreferencesRef preferencesRef, bool enabled) { toImpl(preferencesRef)->setBackspaceKeyNavigationEnabled(enabled); diff --git a/Source/WebKit2/UIProcess/API/C/WKPreferences.h b/Source/WebKit2/UIProcess/API/C/WKPreferences.h index 8054e00f3..501c5a5d6 100644 --- a/Source/WebKit2/UIProcess/API/C/WKPreferences.h +++ b/Source/WebKit2/UIProcess/API/C/WKPreferences.h @@ -172,6 +172,11 @@ WK_EXPORT bool WKPreferencesGetWebAudioEnabled(WKPreferencesRef preferencesRef); // Defaults to false WK_EXPORT void WKPreferencesSetSuppressesIncrementalRendering(WKPreferencesRef preferencesRef, bool enabled); WK_EXPORT bool WKPreferencesGetSuppressesIncrementalRendering(WKPreferencesRef preferencesRef); + +// Defaults to false +// These functions are deprecated. See <rdar://problem/10929617> Remove WKPreferences[Get|Set]SuppressIncrementalRendering from WKPreferences.h. +WK_EXPORT void WKPreferencesSetSuppressIncrementalRendering(WKPreferencesRef preferencesRef, bool enabled); +WK_EXPORT bool WKPreferencesGetSuppressIncrementalRendering(WKPreferencesRef preferencesRef); // Defaults to true WK_EXPORT void WKPreferencesSetBackspaceKeyNavigationEnabled(WKPreferencesRef preferencesRef, bool enabled); diff --git a/Source/WebKit2/UIProcess/API/C/mac/WKInspectorMac.h b/Source/WebKit2/UIProcess/API/C/mac/WKInspectorPrivateMac.h index ec5a35afb..aef86a5d9 100644 --- a/Source/WebKit2/UIProcess/API/C/mac/WKInspectorMac.h +++ b/Source/WebKit2/UIProcess/API/C/mac/WKInspectorPrivateMac.h @@ -23,8 +23,8 @@ * THE POSSIBILITY OF SUCH DAMAGE. */ -#ifndef WKInspectorMac_h -#define WKInspectorMac_h +#ifndef WKInspectorPrivateMac_h +#define WKInspectorPrivateMac_h #ifdef __cplusplus extern "C" { @@ -32,8 +32,18 @@ extern "C" { const NSInteger WKInspectorViewTag = 1000; +// This class is the Web Inspector window delegate. It can be used to add interface +// actions that need to work when the Web Inspector window is key. +WK_EXPORT @interface WKWebInspectorProxyObjCAdapter : NSObject <NSWindowDelegate> { + void* _inspectorProxy; +} + +@property (readonly) WKInspectorRef inspectorRef; + +@end + #ifdef __cplusplus } #endif -#endif // WKInspectorMac_h +#endif // WKInspectorPrivateMac_h |