I didn't see it was an interface, as you pointed they implicitly static and final hence requires initialization.
As you suggested, you can use abstract class as well. Actually in this particular case (EventTarget,Node etc) as there are actual corresponding JavaScript types available, it is more appropriate to abstract it via an abstract class. Doing that will make cast/instanceof work properly. On Sun, Dec 6, 2015 at 6:36 PM, Thomas Broyer <[email protected]> wrote: > > > On Monday, December 7, 2015 at 2:47:03 AM UTC+1, Goktug Gokdogan wrote: >> >> You need to remove initialization as well because the field by Java; the >> point is to link to the underlying javascript. >> > > Actually, this isn't possible here as a field in an *interface* is > necessarily a constant and as such requires an initializer. > I haven't follow JsInterop very closely so not sure but maybe the > interface could be changed into an abstract class then? > > -- > You received this message because you are subscribed to the Google Groups > "GWT Users" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to [email protected]. > To post to this group, send email to [email protected]. > Visit this group at http://groups.google.com/group/google-web-toolkit. > For more options, visit https://groups.google.com/d/optout. > -- You received this message because you are subscribed to the Google Groups "GWT Users" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. Visit this group at http://groups.google.com/group/google-web-toolkit. For more options, visit https://groups.google.com/d/optout.
