Closed
Bug 341057
Opened 18 years ago
Closed 11 years ago
Drag&drop of text to Download button does nothing
Categories
(Firefox :: Toolbars and Customization, defect)
Firefox
Toolbars and Customization
Tracking
()
RESOLVED
WORKSFORME
People
(Reporter: thephilips, Unassigned)
Details
(Keywords: polish)
Attachments
(1 file)
1.58 KB,
patch
|
Details | Diff | Splinter Review |
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8.0.4) Gecko/20060508 Firefox/1.5.0.4 Build Identifier: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8.0.4) Gecko/20060508 Firefox/1.5.0.4 Tab bar when text is dropped onto it does perform check to see whehther the test looks like URL and if it is, it does open it in (new) tab. The same works for location bar. But that doesn't work, when DnD text onto Downloads button. DnDing URL opens Download manager and starts download of DnDed URL. But DnDing of text does nothing. Reproducible: Always Steps to Reproduce: 1. (Skip the step if Downloads button is already in toolbar) right click on toolbar and select customize. DnD "Downloads" button anywhere on toolbar. Close Customize sheet. 2. Open any page. DnD any link from it on "Downloads" button. Notice it works. 3. Open any page. DnD any link from it on Tab bar. Notice it works. 4. Open page with inlined URL. Select URL and DnD it on tab bar. Notice it works. 5. Open page with inlined URL. Select URL and DnD it into location bar. Notice it works. 6. Open page with inlined URL. Select URL and DnD it onto "Downloads" button. Notice it does NOT work. Actual Results: In step 6 nothing happens. Expected Results: Download manager starts downloading the URL. P.S. Ironicaly, since there is no workaround for the problem (impossible to download inlined link/plain text URL, see bug 62253, (dup) bug 326649, etc) i have to keep the problem at "normal" severity :-/
Comment 1•18 years ago
|
||
Looks like a valid request to me. It should be possible to modify the onDrop event of DownloadsButtonDNDObserver to do this.
Status: UNCONFIRMED → NEW
Ever confirmed: true
Comment 2•18 years ago
|
||
Attachment #225130 -
Flags: review?(mconnor)
Reporter | ||
Comment 3•18 years ago
|
||
What shall I do to try that change on 1.5.x? My understaning was: (1) unpack chrome/browser.jar/content/browser to chrome (2) patch browser/browser.js Is that sufficient?
Comment 4•18 years ago
|
||
The easiest way to test this patch without jumping through hoops would be to install the userChrome.js extension (see http://forums.mozillazine.org/viewtopic.php?t=397735 ) and then add the following code to the new userChrome.js file in your profile's chrome folder: DownloadsButtonDNDObserver.onDrop = function(aEvent, aXferData, aDragSession) { // same way to get a valid URL as used by tabbrowser::onDrop var url = transferUtils.retrieveURLFromData(aXferData.data, aXferData.flavour.contentType); if (!url || url.indexOf(" ", 0) != -1 || /^(javascript|data):/.test(url)) return; getBrowser().dragDropSecurityCheck(aEvent, aDragSession, url); var filename = aXferData.data.split("\n")[1] || null; saveURL(url, filename, null, true, true); }; Of course, unpacking browser.jar, applying the patch and repacking browser.jar would also work.
Reporter | ||
Comment 5•18 years ago
|
||
It works with the userChrome.js hack. So I expect it to work with attached patch.
Updated•18 years ago
|
Attachment #225130 -
Flags: review?(mconnor) → review?(gavin.sharp)
Updated•17 years ago
|
Updated•17 years ago
|
Assignee: nobody → zeniko
Status: ASSIGNED → NEW
Comment 6•17 years ago
|
||
Comment on attachment 225130 [details] [diff] [review] get the URL in the same way as the tabbrowser The Bookmarks, New Tab, New Window and Go buttons don't correctly get the URL from the dropped object, either. Canceling this request until a more general solution has been considered.
Attachment #225130 -
Flags: review?(gavin.sharp)
Updated•17 years ago
|
Assignee: zeniko → nobody
Component: Download Manager → Toolbars
QA Contact: download.manager → toolbars
Reporter | ||
Comment 7•17 years ago
|
||
> Canceling this request until a more general solution has been considered.
As it was highlighted in other bug, Download Manager button is more /critical/ than others.
I have found the defect when I was trying to find a way to download file from URL which was part of text on page. All you can do with such "text" is to copy it to clipboard or drag&drop.
One can easily fed an URL e.g. from clipboard to Boormarks or New Tab/Window. But there is no easy way for a Download Manager since it doesn't support any way for user to give it an URL - nor by drag&drop of text nor from clipboard.
Though I would agree that it is hardly an argument ;)
Comment 8•11 years ago
|
||
This appears to have been fixed - I believe it was taken care of as part of the Downloads Panel work in bug 564934.
Updated•11 years ago
|
Target Milestone: --- → Firefox 20
Comment 9•11 years ago
|
||
This works in Firefox 19 without the download panel activated.
No longer depends on: DownloadsPanel
Resolution: FIXED → WORKSFORME
Target Milestone: Firefox 20 → ---
You need to log in
before you can comment on or make changes to this bug.
Description
•