WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED WONTFIX
41476
Dragging URL with linebreak truncates URL
https://bugs.webkit.org/show_bug.cgi?id=41476
Summary
Dragging URL with linebreak truncates URL
Daniel Cheng
Reported
2010-07-01 11:55:48 PDT
Some web sites attempt to automatically wrap long lines, which can occasionally cause an embedded URL to be wrapped incorrectly. If you select the URL (including the part that got wrapped around and is unlinked), and drag it, you can have two different behaviors depending on where you started your drag: 1. If you start the drag from the text, there will be no URL in the drag data. Safari and Chromium will still navigate to the proper URL (they strip out all whitespace from a URL-like string prior to navigating). 2. If you start the drag from the hyperlinked portion, then Safari and Chromium will only use the URL data in the drag. Since the hyperlinked URL was mistakenly truncated, Safari and Chromium will fail this navigation. As far as I can tell, Firefox is able to handle this case correctly, so we should try too.
Attachments
Patch
(7.78 KB, patch)
2010-07-01 15:01 PDT
,
Daniel Cheng
dcheng
: review-
dcheng
: commit-queue-
Details
Formatted Diff
Diff
View All
Add attachment
proposed patch, testcase, etc.
Daniel Cheng
Comment 1
2010-07-01 15:01:42 PDT
Created
attachment 60292
[details]
Patch
Dave Hyatt
Comment 2
2010-07-01 15:11:47 PDT
Comment on
attachment 60292
[details]
Patch This patch makes zero sense to me. The source is clearly broken.
Daniel Cheng
Comment 3
2010-07-01 15:37:48 PDT
Comment on
attachment 60292
[details]
Patch (In reply to
comment #2
)
> (From update of
attachment 60292
[details]
) > This patch makes zero sense to me. The source is clearly broken.
See
comment #4
on
http://code.google.com/p/support/issues/detail?id=2363
. If you select the entire URL, including the section that was badly wrapped, then you get two different behaviors depending on how you start the drag: 1) If you start the drag by clicking on the link and drop it in a WebKit view to navigate, you will navigate to a broken URL. 2) If you start the drag by clicking on the non-linked portion of the URL, you will navigate to the complete URL. Obviously the link itself is broken, but it seems strange to have two different behaviors for dragging around the same bit of data. I'll be moving the ClipboardChromium change into a separate patch.
Stuart Morgan
Comment 4
2010-07-01 15:45:30 PDT
(In reply to
comment #2
)
> The source is clearly broken.
Nobody is arguing that it's not; the point is that it's a case that does happen in the wild (I'm sure I've seen this on sites other than code.google.com), and the behavior is strange and hard to understand--I was being bitten by this and it took me a while to figure out that the place I clicked in the selection to start the drag mattered; before that I thought it was random. If we can do what users expect in the face of mildly broken sites, that seems like a win; c.f. quirks mode.
Ryosuke Niwa
Comment 5
2012-04-30 22:24:40 PDT
I'd say we won't fix this bug. I don't think we want to be too clever about these things given how many editing and drag&drop bugs we already have. If websites have a bug to auto-truncate URLs, then it's their authors' responsibility to fix that.
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug