Disable links in Browser [message #449721] |
Fri, 28 January 2005 08:49 |
Eclipse User |
|
|
|
Originally posted by: dorus.savatech.ro
Hello everybody,
I have the following problem: I need to display a html file using
browser component, but with following behavior: when the user clicks on
a link, I want that the browser should not change its location, the
original location should be preserved.
I tried to do this via LocationListener, inside changing() method, but
if there I set the browser url to the original one, the JVM crash.
Any suggestion?
Thank you very much.
Doru
|
|
|
Re: Disable links in Browser [message #449723 is a reply to message #449721] |
Fri, 28 January 2005 10:27 |
Eclipse User |
|
|
|
Originally posted by: kostask.vector.gr
Doru Sular wrote:
> Hello everybody,
> I have the following problem: I need to display a html file using
> browser component, but with following behavior: when the user clicks on
> a link, I want that the browser should not change its location, the
> original location should be preserved.
>
> I tried to do this via LocationListener, inside changing() method, but
> if there I set the browser url to the original one, the JVM crash.
>
> Any suggestion?
> Thank you very much.
> Doru
I did that just yesterday, so consider yourself lucky ;-)
browser.addLocationListener(new LocationAdapter() {
public void changing(LocationEvent event) {
event.doit = false;
}
});
|
|
|
Re: Disable links in Browser [message #449750 is a reply to message #449723] |
Fri, 28 January 2005 14:31 |
Eclipse User |
|
|
|
Originally posted by: dorus.savatech.ro
Thank you very much :)
Doru
Kostas Kokkoros wrote:
> Doru Sular wrote:
>
>> Hello everybody,
>> I have the following problem: I need to display a html file using
>> browser component, but with following behavior: when the user clicks
>> on a link, I want that the browser should not change its location, the
>> original location should be preserved.
>>
>> I tried to do this via LocationListener, inside changing() method, but
>> if there I set the browser url to the original one, the JVM crash.
>>
>> Any suggestion?
>> Thank you very much.
>> Doru
>
>
> I did that just yesterday, so consider yourself lucky ;-)
>
> browser.addLocationListener(new LocationAdapter() {
> public void changing(LocationEvent event) {
> event.doit = false;
> }
> });
|
|
|
Powered by
FUDForum. Page generated in 0.02752 seconds