[webkit-reviews] review granted: [Bug 176038] Add initial support for dataTransferItem.webkitGetAsEntry() : [Attachment 319239] Patch

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Tue Aug 29 09:09:41 PDT 2017


Wenson Hsieh <wenson_hsieh at apple.com> has granted Chris Dumez
<cdumez at apple.com>'s request for review:
Bug 176038: Add initial support for dataTransferItem.webkitGetAsEntry()
https://bugs.webkit.org/show_bug.cgi?id=176038

Attachment 319239: Patch

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




--- Comment #5 from Wenson Hsieh <wenson_hsieh at apple.com> ---
Comment on attachment 319239
  --> https://bugs.webkit.org/attachment.cgi?id=319239
Patch

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

> Source/WebCore/ChangeLog:100
> +	   Construct a DataTransferItem is the file is a directory now that we

s/is the file/if the file/

> Source/WebCore/dom/DataTransferItem.cpp:111
> +    if (!m_list || !m_list->dataTransfer().canReadData() || !m_file)

Could we just use ::getAsFile() here and bail if it's null? (this would avoid
duplicated checks for !m_list or !m_list->dataTransfer().canReadData())

> Source/WebCore/dom/DataTransferItemList.cpp:31
> +#include "FileSystem.h"

Do we need this import? Looks like we've only added a call to File::isDirectory
here.


More information about the webkit-reviews mailing list