[Webkit-unassigned] [Bug 161450] [Cocoa] No reliable way to get a snapshot of WKWebView

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Fri Feb 17 13:53:12 PST 2017


https://bugs.webkit.org/show_bug.cgi?id=161450

--- Comment #59 from mitz at webkit.org <mitz at webkit.org> ---
Comment on attachment 301971
  --> https://bugs.webkit.org/attachment.cgi?id=301971
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=301971&action=review

> Source/WebKit2/UIProcess/API/Cocoa/WKSnapshotConfiguration.h:39
> + @discussion This rect should be contained within WKWebView's bounds. If the rect is not set, 
> + the WKWebView's bounds will be used.

I think the comment can be more explicit (and also make it clear how to reset the property). Namely, it can say that if set to the null rect, the view’s bounds will be used, and that the initial value is the null rect.

> Source/WebKit2/UIProcess/API/Cocoa/WKWebView.h:232
> +- (void)takeSnapshotWithConfiguration:(nullable WKSnapshotConfiguration *)snapshotConfiguration completionHandler:(void(^)(UIImage * _Nullable snapshotImage, NSError * _Nullable error))completionHandler WK_API_AVAILABLE(macosx(WK_MAC_TBA), ios(WK_IOS_TBA));

Omit the macosx entry here.

> Source/WebKit2/UIProcess/API/Cocoa/WKWebView.h:234
> +- (void)takeSnapshotWithConfiguration:(nullable WKSnapshotConfiguration *)snapshotConfiguration completionHandler:(void(^)(NSImage * _Nullable snapshotImage, NSError * _Nullable error))completionHandler WK_API_AVAILABLE(macosx(WK_MAC_TBA), ios(WK_IOS_TBA));

Omit the ios entry here!

-- 
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.webkit.org/pipermail/webkit-unassigned/attachments/20170217/1991fd66/attachment-0001.html>


More information about the webkit-unassigned mailing list