Bug 38227

Summary: [Chromium] Filter out URLs with a file scheme from text/uri-list when dragging.
Product: WebKit Reporter: Daniel Cheng <dcheng>
Component: New BugsAssignee: Nobody <webkit-unassigned>
Status: RESOLVED FIXED    
Severity: Normal CC: commit-queue, jianli
Priority: P2    
Version: 528+ (Nightly build)   
Hardware: PC   
OS: Windows 7   
Attachments:
Description Flags
Filter file:// URLs from event.dataTransfer.getData
none
Filter file:// URLs from event.dataTransfer.getData
jianli: review-
Filter file URLs from event.dataTransfer.getData none

Description Daniel Cheng 2010-04-27 16:08:19 PDT
Original issue at https://bugs.webkit.org/show_bug.cgi?id=25882, which fixed duplicate file paths appearing in text/uri-list on a file drop.

This issue covers removing the remaining file:// URL from event.dataTransfer on a drop.
Comment 1 Daniel Cheng 2010-04-27 16:09:23 PDT
Created attachment 54468 [details]
Filter file:// URLs from event.dataTransfer.getData
Comment 2 Daniel Cheng 2010-04-27 16:21:00 PDT
Created attachment 54470 [details]
Filter file:// URLs from event.dataTransfer.getData

Fix incorrect permissions on WebCore/ChangeLog
Comment 3 Jian Li 2010-04-27 16:25:00 PDT
Comment on attachment 54470 [details]
Filter file:// URLs from event.dataTransfer.getData

WebCore/ChangeLog:5
 +          [Chromium] Filter out URLs with file:// scheme from text/uri-list when dragging.
Can you update the bug title in order to be consistent with the line above. Also, I think you could simply say "file scheme".

WebCore/platform/chromium/ClipboardChromium.cpp:170
 +                  if (protocolIs(uri, "file"))
Could you please add a comment for doing this?

WebCore/platform/chromium/ClipboardChromium.cpp:185
 +          if (!m_dataObject->url.isEmpty() && !m_dataObject->url.isLocalFile()) {
ditto.

WebCore/platform/chromium/ClipboardChromium.cpp:321
 +      if (m_dataObject->url.isValid() && !m_dataObject->url.isLocalFile()) {
ditto.
Comment 4 Daniel Cheng 2010-04-27 17:50:18 PDT
Created attachment 54486 [details]
Filter file URLs from event.dataTransfer.getData
Comment 5 Jian Li 2010-04-27 18:05:37 PDT
Comment on attachment 54486 [details]
Filter file URLs from event.dataTransfer.getData

r=me
Comment 6 WebKit Commit Bot 2010-04-27 22:21:41 PDT
Comment on attachment 54486 [details]
Filter file URLs from event.dataTransfer.getData

Clearing flags on attachment: 54486

Committed r58378: <http://trac.webkit.org/changeset/58378>
Comment 7 WebKit Commit Bot 2010-04-27 22:21:47 PDT
All reviewed patches have been landed.  Closing bug.