Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 336156 - user can DnD url from web browser into Eclipse to start MPC install sequence
Summary: user can DnD url from web browser into Eclipse to start MPC install sequence
Status: RESOLVED FIXED
Alias: None
Product: MPC
Classification: Technology
Component: wizard (show other bugs)
Version: unspecified   Edit
Hardware: PC Linux
: P3 enhancement (vote)
Target Milestone: 1.1   Edit
Assignee: Benjamin Muskalla CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-02-02 16:00 EST by Benjamin Muskalla CLA
Modified: 2011-03-16 15:45 EDT (History)
3 users (show)

See Also:


Attachments
draft patch (7.07 KB, patch)
2011-02-21 12:14 EST, Benjamin Muskalla CLA
no flags Details | Diff
final patch (24.53 KB, patch)
2011-02-24 11:41 EST, Benjamin Muskalla CLA
greensopinion: iplog+
Details | Diff
sample html page (338 bytes, text/html)
2011-02-24 11:42 EST, Benjamin Muskalla CLA
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Benjamin Muskalla CLA 2011-02-02 16:00:34 EST
It should be possible to DnD a URL from the webbrowser directly into MPC to start installing a solution.
Comment 1 Benjamin Muskalla CLA 2011-02-21 12:14:31 EST
Created attachment 189422 [details]
draft patch

David, can we have a quick look at this together? Open items:

* what to do if we don't know the marketplace? in my POV, I'd just fail for now. This could be improved once we have server-side catalog listings that could provide us with the right catalog.

* URL format: My idea is that it can be part of every url as part of the query. This would allow marketplaces to always use these links to point to some descriptive page if clicked (eg http://marketplace.eclipse.org/marketplace-client-intro) and use the same url for DnD into Eclipse. Is there any reason on the current marketplace to use Forms with GET instead of raw links? If we can agree on one form, we could easily merge this with MPBrowserIntegration.
Comment 2 Benjamin Muskalla CLA 2011-02-24 11:41:33 EST
Created attachment 189715 [details]
final patch

David, attached is the final patch for this. I iterated over our discussed items and merged the implementations of MPBrowserIntegration and the Drop Adapter. The idea to check for the URL early is not possible as SWT doesn't propagate the data until the drop event occurs.
Comment 3 Benjamin Muskalla CLA 2011-02-24 11:42:47 EST
Created attachment 189716 [details]
sample html page

Here is a small html page with different link types that can be dropped on Eclipse to start the installation process.
Comment 4 Benjamin Muskalla CLA 2011-02-24 11:44:42 EST
Please note that DnD from the Install button on the current marketplace is not possible due to the usage of the form tag. I recommend changing this to a raw link as shown in the html snippet, that solution is also backwards-compatible. Will talk to Nathan about this.
Comment 5 David Green CLA 2011-02-25 18:02:55 EST
Comment on attachment 189715 [details]
final patch

patch applied, with fixes to copyright header, and MPC drop adapter is registered with a UI job instead of using Display.asyncExec
Comment 6 David Green CLA 2011-02-25 18:04:09 EST
Tested, looks great.  Note that in my testing only certain areas of Eclipse were able to accept the drop.  Benjamin please resolve if there's nothing left to do here.
Comment 7 Benjamin Muskalla CLA 2011-02-25 18:14:00 EST
Thanks. Yes, that's a limitation of the operation system. For example on Linux, you cannot drop anything on the MenuBar of the Shell. Nothing we can do here with the "limitations" (SWT) we have.