Hi Rolf,

this is a quite new feature that was introduces in platform 4.10 see: 
https://www.eclipse.org/eclipse/news/4.10/platform.php#link-handlers
I would assume that once a link handler is registered on OS level that this 
also works in the internal web browser and that such specific code is not 
necessary.

Regards,
Matthias

From: <platform-dev-boun...@eclipse.org> on behalf of Rolf Theunissen 
<rolf.theunis...@gmail.com>
Reply to: "Eclipse platform general developers list." <platform-dev@eclipse.org>
Date: Tuesday, 7. April 2020 at 18:51
To: "Eclipse platform general developers list." <platform-dev@eclipse.org>
Subject: Re: [platform-dev] How can usiSchemaHandlers be used in internal web 
browser?

Hi,

I did not know about the link handlers defined there. For a custom widget we 
made an extension to process custom links in the browser. We extended 
WebBrowserEditor to add a location listener, see below. I don't think that the 
default WebBrowser processes the Link Handlers as defined in the preferences.

Rolf

@Override
public void createPartControl(org.eclipse.swt.widgets.Composite parent) {
   super.createPartControl(parent);
   webBrowser.getBrowser().addLocationListener(new LocationAdapter() {
     @Override
     public void changing(LocationEvent event) {
        // Do something like opening an editor (in case of platform:/resource/ 
uri)
     }
   });
}

Op di 7 apr. 2020 om 18:29 schreef Mickael Istria 
<mist...@redhat.com<mailto:mist...@redhat.com>>:
On Tue, Apr 7, 2020 at 6:18 PM Ed Merks 
<ed.me...@gmail.com<mailto:ed.me...@gmail.com>> wrote:

Did you enable Window -> Preferences -> General -> Link Handlers for the 
eclipse+mpc scheme?  Certainly that's needed for clicks of eclipse-mpc scheme 
links a browser to work.

I tried that and that didn't work for me, both in internal and external browser.
_______________________________________________
platform-dev mailing list
platform-dev@eclipse.org<mailto:platform-dev@eclipse.org>
To unsubscribe from this list, visit 
https://www.eclipse.org/mailman/listinfo/platform-dev
_______________________________________________
platform-dev mailing list
platform-dev@eclipse.org
To unsubscribe from this list, visit 
https://www.eclipse.org/mailman/listinfo/platform-dev

Reply via email to