Glad to hear that this is also working for you, as that increases my confidence in the correctness of the fix.
Regarding GWTx being included in GWT, well, I don't see a problem with the general model of satellite projects addressing specific needs, and then GWT grabbing and incorporating what turns out to be most successful and popular into its core classes. That is the specific intent of the GWT incubator for widgets and I think the same approach applies informally to other projects like GWTx. But I do agree with you that in this particular case the time may have come for GWT to pick up GWTx, as it is a very useful set of classes. And certainly it would help with ensuring that testing and fixing occurs with each new GWT release, especially when there is stuff that is connected at a low level, like these JSNI references, that needs to be tightly integrated. Carl On Jan 9, 5:17 am, francescoNemesi <[email protected]> wrote: > Hi Carl, > > thank you very much for your reply. As a matter of fact I had already > seen and applied the patch (i.e. new Pattern class) in my code and now > everything seems to be well. I meant to follow up on my post with the > solution, but never got the time to do it. > > I wish GWT implemented natively all the classes implemented for it inGWTxin > order to have official support and not be dependent on an > external project. I guess for example PropertyChangeSupport is > something that in a way or another every complex application needs. > > Thanks again, I hope the GWT developers are reading this and that will > seeGWTxincluded in future releases of GWT. > > Kind Regards, > Francesco > > On Jan 9, 12:43 pm, Carl <[email protected]> wrote: > > > > > Hi, Francesco, > > > I have just upgraded to GWT 2.0 and encountered the same problem as > > you did. > > > I believe that I have now surmounted this problem, thanks largely to a > > developer who posted a fix to theGWTxissues list, issue 18, which is > > referenced from the mainGWTxpage (with a line through it indicating > > that it had been fixed, although that fix does not seem to have held > > through the latest GWT release): > > >http://code.google.com/p/gwtx/issues/detail?id=18 > > > The issue seems to be that the problematic class (Pattern) is making a > > number of references > > via JSNI to Javascript elements that are generated by the GWT > > compiler, but the compiler seems > > to have changed the way in which it generates the names of these > > elements (perhaps due to > > the new 2.0 features that provide more rigorous obfuscation through > > renaming - that is just a guess), > > and as a result these references to native elements are incorrect. > > > The developer who addressed this issue in the abovementioned post > > fixed the problematic references and posted his fixed version of the > > entire Pattern.java source file to the above-referenced message on > >GWTx. > > > Note that his message was posted on November 6, 2009, before the > > official release of GWT 2.0, and so apparently the earlier 1.7.1 > > release of GWT that I was using prior to this version update did not > > flag this as an issue and indeed it may not have been an issue for > > that release. It is possible that this developer was working with an > > intermediate or advance release. > > > The details of GWT's mappings to Javascript are beyond my present > > level of experience, and so I cannot claim to understand this fix at a > > detailed level, but it is clear that the exact lines that are flagged > > by the compiler in the error messages that you cite are the lines that > > were fixed by this patch. > > > Anyway, I downloaded the Pattern.java file so nicely attached by the > > developer (one darek.kobylarz), looked it over, > > and then unzipped the gwt-1.5.2.jar file, replaced Pattern.java with > > the new Pattern.java, and then zipped it back up using the jar tool, > > creating a new archive called gwt-1.5.2-patched.jar. I then replaced > > my project's reference to the old archive with a reference to the new > > archive, and, voila! no more compiler complaints. And, presumably > > (hopefully) working code, too. > > > I did some basic testing of my site and all seems to be well, but that > > is not a guarantee! Remember that my understanding of this problem > > and of the fix posted is rudimentary, and so you must take steps to > > satisfy yourself that this solution is a good one. But, so far it is > > looking like a fix to me. Good luck! > > > One more thought is that if you look at the message thread, this looks > > like a recurring problem, and a wild guess would be that each time GWT > > changes its naming conventions, it breaks this code. But maybe > > Derek's fix is more secure than the others, > > since he is no longer using hard-coded names. Anyway, if you do use > > this fix, then in future releases, you might want to keep an eye on > > this code to see if it breaks again. > > > It does seems a little strange thatGWTxhas not provided a new > > release for this and it may be because the issue thread to which > > the developer posted his file was closed in February of 2009, and so > > maybe nobody realizes that there is this issue with 2.0, although it > > seems strange that they would not have noticed. I'll probably open an > > issue for it there. > > > Carl > > > On Dec 30 2009, 6:05 am, francescoNemesi <[email protected]> wrote:> Hi All, > > > > my (rather huge) GWT application relies heavily on theGWTx > > > implementation of propertyChangeSupport. This doesn't seem to work > > > anymore with GWT 2.0. In development mode, I get this error: > > > > 14:40:55.873 [WARN] [kbit] Warnings in 'jar:file:/D:/GWT/gwt-keinavo- > > > external-library/gwtx-1.5.2.jar!/com/googlecode/gwtx/java/util/emul/ > > > java/util/regex/Pattern.java' > > > 14:40:55.904 [WARN] [kbit] Line 140: Referencing class > > > 'com.googlecode.gwtx.java.util.emul.java.util.regex.Pattern':unableto > > > resolve class, expect subsequent failures > > > 14:40:55.935 [WARN] [kbit] Line 149: Referencing class > > > 'com.googlecode.gwtx.java.util.emul.java.util.regex.Pattern':unableto > > > resolve class, expect subsequent failures > > > 14:40:55.966 [WARN] [kbit] Line 183: Referencing class > > > 'com.googlecode.gwtx.java.util.emul.java.util.regex.Pattern':unableto > > > resolve class, expect subsequent failures > > > 14:40:55.982 [WARN] [kbit] Line 194: Referencing class > > > 'com.googlecode.gwtx.java.util.emul.java.util.regex.Pattern':unableto > > > resolve class, expect subsequent failures > > > > Has anyone else experience this? Are there any workarounds or > > > alternatives toGWTx? I am badly stumped on this. > > > > Thanks, Francesco
-- You received this message because you are subscribed to the Google Groups "Google Web Toolkit" group. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
