Hi,
and what is, if I want to use an instance field or something else from
that instance in that method?
Regards, Max
On 25 Jan., 21:42, Alfredo Quiroga-Villamil laww...@gmail.com wrote:
public void setName(String value) {
Window.alert(setName);
}
Needs to be static. Remove the
Then your JS code needs an instance of the object: either the JSNI method
has to *not* be static (so that there's a 'this' value, just like in Java),
or you have to somehow pass it an instance of your MyClass to replace the
'this' in your code.
--
You received this message because you are
Hi,
i'm trying to call an instance java method from a JSNI method like
decriped in GWT JSNI documentation.
But somehow I'm still getting exceptions:
My code:
public void bla() {
jsni_method(JavaScriptObject event);// event is an dropEvent,
but that doesn't matter
}
public static native
public void setName(String value) {
Window.alert(setName);
}
Needs to be static. Remove the this. reference from the JSNI to call it.
Regards,
Alfredo
On Wed, Jan 25, 2012 at 12:25 PM, Maxim Schäfner maxim.schaef...@ewetel.net
wrote:
Hi,
i'm trying to call an instance java method