GWT clickable link (anchor) without href

I'm trying to create a link (anchor) in GWT that can be clicked and it's ClickEvent can be processed, while at the same time this anchor wouldn't reload the page. This basically means that a href must not be set.

In javascript this is done like this:

<a href="javascript:handleAnchorClick();">Link</a> 

or with

<a href="#" onclick="return handleAnchorClick()">Link</a>  

where handleAnchorClick() returns false.

What would be the best way to achieve this in GWT?

9
задан Peter Knego 4 December 2010 в 23:58
поделиться