Maybe the same issue as: https://groups.google.com/forum/#!topic/Google-Web-Toolkit-Contributors/nx9mBU5kwEo
BTW, how do you use gwt-maven-plugin to pass the compile option "-XjsInteropMode JS"? On Tue, Jul 22, 2014 at 5:26 AM, Henrik <[email protected]> wrote: > On Wednesday, July 16, 2014 1:55:52 PM UTC+2, Eder Ignatowicz wrote: >> >> Yep! Thanks for your help! :) >> >> What does the trick is the flag -XjsInteropMode JS . >> >> If anyone want to use my GWT JS interop demo is on >> https://github.com/ederign/gwt-playground. >> > > Thanks for that; it helped me out a bit experimenting with jsinterop. > > I had the hardest time getting the jsni functions (those simply returning > $doc and $doc.body) to actually return anything other than null! After > playing with a bunch of options, I finally hit upon the problem. I was > using the maven gwt plugin (locally updated to use 2.7.0-SNAPSHOT of GWT) > and one of the arguments it sends to the compiler is "-localWorkers" with a > default of "8" (which comes from Runtime.getRuntime().availableProcessors() > ). The generated javascript functions contained "null.something" which > clearly would not work. But when I explicitly used "-localWorkers 1" > instead, hurray, it worked perfectly! Seems like some compiler bug to me. > > -- > You received this message because you are subscribed to a topic in the > Google Groups "Google Web Toolkit" group. > To unsubscribe from this topic, visit > https://groups.google.com/d/topic/google-web-toolkit/fGIr4sRkz7s/unsubscribe > . > To unsubscribe from this group and all its topics, 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 "Google Web Toolkit" 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.
