[webkit-reviews] review granted: [Bug 212339] [Clipboard API] Support reading "image/png" on ClipboardItem : [Attachment 400216] For EWS

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Wed May 27 11:38:52 PDT 2020


Tim Horton <thorton at apple.com> has granted Wenson Hsieh
<wenson_hsieh at apple.com>'s request for review:
Bug 212339: [Clipboard API] Support reading "image/png" on ClipboardItem
https://bugs.webkit.org/show_bug.cgi?id=212339

Attachment 400216: For EWS

https://bugs.webkit.org/attachment.cgi?id=400216&action=review




--- Comment #5 from Tim Horton <thorton at apple.com> ---
Comment on attachment 400216
  --> https://bugs.webkit.org/attachment.cgi?id=400216
For EWS

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

> Source/WebCore/Modules/async-clipboard/mac/ClipboardImageReaderMac.mm:41
> +	   if (auto bitmapData = retainPtr([image TIFFRepresentation])) {
> +	       auto bitmapRepresentation = adoptNS([[NSBitmapImageRep alloc]
initWithData:bitmapData.get()]);
> +	       m_result =
Blob::create(SharedBuffer::create([bitmapRepresentation
representationUsingType:NSBitmapImageFileTypePNG properties:@{ }]),
m_mimeType);

I provided a potential alternative to this double-encode offline.


More information about the webkit-reviews mailing list