Re: Minimalistic JPA in GWT 2.1.0.M3
Hi Jin, Thank you for your response! I was able to make JPA work in Jetty, but only using resource-local entity manager in Java SE environement. This makes sence because for container-managed entity manager an EE environment is required, and Jetty by itslef does not provide it. My persistence unit uses JTA data source, but it probably does not make sence to have it in SE environment, so I'll move back to a regular data source. Initially I tried to place my persistence unit in an application client jar file. When I used that jar file from a console application, it worked fine. But as soon as I linked it to my GWT project, I ran into problems. I use GWT 2.1's EntityRecord that is annotated with @DataTransferObject(Entity.class), where the Entity class sits in the persistence unit. When I ran the application from Eclipse, it would intermitently fail to load saying that Entity class could not be found. When I debugged the application from Eclipse, it would always fail with the same error. GWT compilation would also fail similarly. So I ended up placing the perisistence unit directly into the GWT project, exactly as you did, and then the errors disappeared. My main question for you is can you debug your client and server code without doing GWT compilation? Debugging without GWT compilation is the main thing that keeps me from moving from a plain Jetty to an application server. Thanks again for your resonse. Yuri On Oct 4, 7:08 pm, Jin jintl...@gmail.com wrote: Hi Yuri, I went through similar issues trying to get GWT to work with JPA. I would imagine that Jetty does *not* support JPA - I'm using Glassfish Enterprise Server with my GWT app for JEE / JPA support. Glassfish is open source and commercial support can be purchased if that's needed. I've been able to use injection using annotations (@PersistenceContext etc). My GWT and JEE code are in the same project - when I had them in separate projects I had problems getting them to talk. Have lots of battle scars from this one, so let me know if you have any other questions =) Cheers, Jin On Oct 4, 6:14 pm, Y2i yur...@gmail.com wrote: I read through Java Persistence API spec and finally was able to make a resource-local entity manager work. persistence.xml went to WEB-INF/ classes/META-INF. I'd like to able to use a container-managed entity manager through injection, but I'm not sure if it is possible at all using a plain web container (Jetty). It looks as if I need to add some sort of an EE container on top of Jetty, but I'm not sure where to start from. My persistence unit already uses JTA-aware data source (com.atomikos.jdbc.AtomikosDataSourceBean + org.postgresql.xa.PGXADataSource), but when I try to use @PersistenceContext or @PersistenceUnit, injection does not happen. I would really appreciate it if someone could please help me understand where I should look next. Thanks in advance! Yuri On Sep 30, 11:52 pm, Y2i yur...@gmail.com wrote: persistence.xml has persistence-unit name=Domain. I tried @PersistenceContext, @PersistenceUnit and Persistence.createEntityManagerFactory() without any result. The problem is it does not matter what I type in persistence.xml, jetty does not see the file. I'm doing something fundamentally wrong, I'll try this again tomorrow with a fresh head. Thanks for sticking with me! On Sep 30, 11:33 pm, lineman78 linema...@gmail.com wrote: Does your persistence.xml have the following: persistence-unit name=Domain and using the following in your session bean: @PersistenceContext(unitName=Domain) EntityManager em; On Sep 30, 11:08 pm, Y2i yur...@gmail.com wrote: Thanks for the reply. I'm doing something wrong because I'm getting the same error even when I place persistence.xml to /war/META-INF. javax.persistence.PersistenceException: No Persistence provider for EntityManager named Domain The exception is thrown in both hosted and stand-alone mode. I'll try to configure JTA transactions first before doing anything else with the JPA. On Sep 30, 6:15 pm, lineman78 linema...@gmail.com wrote: persistence.xml should be located in /war/META-INF On Sep 30, 4:28 pm, Y2i yur...@gmail.com wrote: Client's requests go the server through RequestFactoryServlet. My service objects (those annotated with @Service(SomeDomainClass.class) on the client side are being called fine. When a service method explicitly creates an entity and returns it to the client, the request returns without problems. The problem occurs as soon as I start using JPA I use EclipseLink 2.1.0. The transaction type is Resource Local for now When I try to eject EntityManager using @PersistenceContext, it is always null. When I try to get the factory using
Re: New GWT 2.0 Book
I think it's fair enough for a developer of the framework to write a book. This gives a more comprehensive insight in the framework. Buying a book is a choice to be exercised by us . No one forces us. If it is well written and worth it why not buy it. As far as documentation goes, I do agree that with GWT that's a problem. Actually at time I think it's not the lack of documentation but the comprehensive coverage at some common location. Another problem with jet speed the framework is evolving. It's difficult to keep pace for the documentation (I am a developer and I know how hard it is) All said and done, I do not see a reason for why to get pissed off for a developer writing a book. And whenever we have some tutorial/example to share let's do it. On Oct 4, 10:06 pm, Paul Stockley pstockl...@gmail.com wrote: 2.1 Isn't even released yet so why are you pissed off about there being no documentation! On Oct 4, 11:36 am, Ashton Thomas ash...@acrinta.com wrote: At the end of the day, the GWT community will benefit from the book. For whatever reasons Chris is writing the book I am certain they are justified and reasonable and I am sure he will be able to provide the GWT community some valuable insight outside of buying the book. yes, books may be a little behind development especially at the rate GWT is coming along. So it is understandable that you would prefer to have some more agile and publicly available documentation going on. So your argument is understandable but this is probably not the worst thing ever. A more appropriate response may be to continue to highlight the contributions of people and make specific requests to be addressed. On Oct 4, 11:24 am, Isaac Truett itru...@gmail.com wrote: I think if this makes your list of things to get really pissed off about, then life must be pretty good. Someone who works on GWT gets a writing credit on a book about GWT; that's not something to get upset over. On Fri, Oct 1, 2010 at 1:38 PM, Tommy Lui tlui1...@gmail.com wrote: Hi, Please help me understand why Chris Ramsdale (Google's Developer Relations team to develop and advocate GWT best practices.) is writting a book about GWT 2.1 when he works at Google on the GWT team and there's no official documentation, except for a few waves available to the developer community. Is this some way for him to force developers to buy his book? http://www.manning.com/bambury/ The book is due to be release in 2011, so I'm sure it's GWT 2.1 not GWT 2.0 content. I'm hoping that I'm not the only person really pissed off about this. I'd really like other peoples opinions on this topic -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.comgoogle-web-toolkit%2Bunsubs cr...@googlegroups.com . For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en. -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
Re: Help: Development of large App with GWT
With ability to bid on multiple bidding at the same time I think what you are leveraging is the ability to do multiple AJAX calls to server simultaneously which is GWT strength but is not unique to GWT. There are many AJAX engines out there. I feel where GWT stands out is to able to push a lot of logic processing code on client side which would be hard to write in plain Java script. I would suggest to think of something where you are doing a lot of processing on client side and providing a fast response to the end user. On Oct 4, 10:38 pm, Noor baken...@gmail.com wrote: Thanks Mig, As I stated above, I am trying to implement a bidding system and above I described some its potential features such simultaneously bidding on the several items -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
Re: calling GWT Javascript compiler from ant
great, works now thanks nacho On Oct 4, 10:03 pm, nacho vela.igna...@gmail.com wrote: Try with this: ?xml version=1.0 encoding=utf-8 ? project name=ProjectName default=war basedir=. !-- Configure path to GWT SDK -- property name=gwt.sdk location=/path/to/gwt / !-- SWT on Mac requires the -XstartOFirstThreadFlag. -- condition property=XstartOnFirstThreadFlag value=- XstartOnFirstThread else=-Dgwt.dummy.arg1= os family=mac/ /condition !-- SWT on Mac requires the -d32 flag if the VM is 64-bit. -- condition property=d32Flag value=-d32 else=-Dgwt.dummy.arg2= and os family=mac/ equals arg1=${sun.arch.data.model} arg2=64/ /and /condition path id=project.class.path pathelement location=war/WEB-INF/classes/ pathelement location=${gwt.sdk}/gwt-user.jar/ fileset dir=${gwt.sdk} includes=gwt-dev*.jar/ !-- Add any additional non-server libs (such as JUnit) -- fileset dir=war/WEB-INF/lib includes=**/*.jar/ /path target name=libs description=Copy libs to WEB-INF/lib mkdir dir=war/WEB-INF/lib / copy todir=war/WEB-INF/lib file=${gwt.sdk}/gwt-servlet.jar / !-- Add any additional server libs that need to be copied -- /target target name=javac depends=libs description=Compile java source mkdir dir=war/WEB-INF/classes/ javac srcdir=src includes=** encoding=utf-8 destdir=war/WEB-INF/classes source=1.5 target=1.5 nowarn=true debug=true debuglevel=lines,vars,source classpath refid=project.class.path/ /javac copy todir=war/WEB-INF/classes fileset dir=src excludes=**/*.java/ /copy /target target name=gwtc depends=javac description=GWT compile to JavaScript java failonerror=true fork=true classname=com.google.gwt.dev.Compiler classpath pathelement location=src/ path refid=project.class.path/ /classpath !-- add jvmarg -Xss16M or similar if you see a StackOverflowError -- jvmarg value=-Xmx256M/ jvmarg value=${XstartOnFirstThreadFlag}/ jvmarg value=${d32Flag}/ !-- Additional arguments like -styzle PRETTY or -logLevel DEBUG -- arg line=-style PRETTY/ arg value=com.mycompany.myProject.MyEntryPoint/ /java /target target name=hosted depends=javac description=Run hosted mode java failonerror=true fork=true classname=com.google.gwt.dev.HostedMode classpath pathelement location=src/ path refid=project.class.path/ /classpath jvmarg value=-Xmx256M/ jvmarg value=${XstartOnFirstThreadFlag}/ jvmarg value=${d32Flag}/ arg value=-startupUrl/ arg value=MyEntryPoint.html/ !-- Additional arguments like -style PRETTY or -logLevel DEBUG -- arg value=com.mycompany.myProject.MyEntryPoint/ /java /target target name=build depends=gwtc description=Build this project / target name=war depends=build description=Create a war file zip destfile=/path/to/MyWar.war basedir=war/ /target target name=clean description=Cleans this project delete dir=war/WEB-INF/classes failonerror=false / /target /project Let me know if it works for you. On 4 oct, 11:45, 3p1...@googlemail.com 3p1...@googlemail.com wrote: Hi Sebastian and thank you for your help ant gives me Reference project.class.path not found. on this line: java failonerror=true fork=true classname=com.google.gwt.dev.Compiler and do i have to do anything in your lib requirement or can i omit it in my case? best regards On Oct 4, 4:02 pm, Sebastian Rothbucher sebastian.rothbuc...@clarities.de wrote: Hi, you can invoke it e.g. with the following script: target name=gwtc depends=libs description=GWT compile to JavaScript java failonerror=true fork=true classname=com.google.gwt.dev.Compiler classpath pathelement location=src/ !-- this is gwt-dev.jar gwt-user.jar all JARs you have yourself -- path refid=project.class.path/ /classpath !-- add jvmarg -Xss16M or similar if you see a StackOverflowError -- jvmarg value=-Xmx256M/ !-- Additional arguments like -style PRETTY or -logLevel DEBUG -- arg value=org.whatever.yourapphere/ /java /target Basically, the GWT compiler is just a java program you can invoke via the java command... Hope this helps - best regards Sebastian Rothbucher On 4 Okt., 12:13, 3p1...@googlemail.com 3p1...@googlemail.com wrote: Hi everyone How can i call the gwt Javascript compiler from an Ant build script? I am using eclipse 3.5 with GWT plugin 2.0 best regards -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to
Re: Help: Development of large App with GWT
Yes, I think that you r right lalit. That's the confusing part, which app can i develop, what where i am blocked?? -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
Re: part II - Large scale application development and MVP - No Eclipse supported!
SOLVED, THANKS!! I had to clear the cache files under the war folder. I have to look into these remaining warnings: ContactsViewImpl is a raw type. References to generic type ContactsViewImplT should be parameterized The import com.google.gwt.dom.client.NodeList is never used The import com.google.gwt.sample.contacts.client.common.SelectionModel is never used The import com.google.gwt.user.client.rpc.IsSerializable is never used The import com.google.gwt.user.client.ui.CheckBox is never used The import com.google.gwt.user.client.ui.HTMLTable is never used The import com.google.gwt.user.client.Window is never used The import java.util.ArrayList is never used The serializable class Address does not declare a static final serialVersionUID field of type long Address.java/Contacts2/src/com/ google/gwt/sample/contacts/shared line 5 Java But your file worked for me. Thanks!! Regards, Chris. On 4 okt, 19:15, Y2i yur...@gmail.com wrote: Sorry, somehow the link got messed up. This one should work.https://docs.google.com/leaf?id=0B6oje-sOVpn_NTFhNzg0OWUtYTE0OS00ZDI5... On Oct 4, 2:21 am, 100IT chris.devri...@gmail.com wrote: Hi Y2I, Could you check your link? Its dead to my knowledge. thanks for your help. Regards. Chris. On 4 okt, 08:01, Y2i yur...@gmail.com wrote: Strange, those steps work for me fine, here is the eclipse project that I got: https://docs.google.com/leaf?id=0B6oje-sOVpn_NTFhNzg0OWUtYTE0OS00ZDI5... 1) unzip the file 2) In eclipse: File-Import... 3) Select Existing Project into Workspace under General, click Next 3) Click Browse... 4) Select the directory where the file was unzipped in step 1), click Ok 5) Click Finish I tried this in Helios Java EE version, but I don't think it'll also work with the Java version On Oct 3, 2:09 pm, 100IT chris.devri...@gmail.com wrote: Thanks for your quick answer, I tried but no luck. I get tons of warnings and one error. I'm using: Eclipse IDE for Java Developers Version: Helios Release Build id: 20100617-1415 Which works ok with: Large scale application development and MVP version I. this should probably be simulated on your system using your experience. Pity the source isn't made like version I as this would help a lot of newbie volunteers. thanks for any help!! -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
CellTable and Paging question
Hi, I have a CellTable with a SimplePager. When I click forward on the SimplePager widget, it flicks through the pages as you'd expect. However, when I get to the last page and continue hitting forward, blank pages keep loading. Which parameters should I change to stop this behaviour? Thanks! Maurice -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
Re: AppEngine Users Service with GWT will always reload page/module upon login
Maybe instead try asking the person to login before enabling him the option to write a message? On Oct 3, 12:31 pm, Haris harishas...@gmail.com wrote: Using Users Service, after filling up login and password and press OK, onModuleLoad is executed. Basically the gwt module is reloaded. I am going to loose data entry stuff form the user. For instant if someone is typing a forum post and click submit only to discover that login already timeout. The person relogin using User API login page only to discover that the text typed is lost because of this. Any suggestion? Regards, Haris -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
Re: Programming issue with splitlayoutpanel
[RESOLVED] It's allright I've found a solution. here it's my source code for a widget that works as the Windows Explorer in detail mode: Within the splitlayoutpanel there are labels. - .ui.xml - ui:UiBinder xmlns:ui=urn:ui:com.google.gwt.uibinder xmlns:g=urn:import:com.google.gwt.user.client.ui xmlns:my=urn:import:org.mbt.client.ui g:DockLayoutPanel ui:field=dockpanel unit='PX' /g:DockLayoutPanel /ui:UiBinder - .java - public class SplitLabel extends ResizeComposite { interface SplitLabelUiBinder extends UiBinderDockLayoutPanel, SplitLabel{}; private static SplitLabelUiBinder uiBinder = GWT.create(SplitLabelUiBinder.class); @UiField DockLayoutPanel dockpanel; String width, height; double miniLabelWidth; SplitLayoutPanel splitLayoutPanel = new SplitLayoutPanel(); /** * Unique constructeur de la classe * * @param width largeur du widget, convention CSS. DOIT etre en pixels. strongEx: 120px/strong * @param height hauteur du widget, convention CSS. DOIT etre en pixels. strongEx: 200px/strong * @param labelContent chaine contenant les contenus par defaut des {...@link Label} du widget. * Le séparateur est un ':' strongEx: contenuLabel1:contenuLabel2:contenuLabel3/strong * @param miniLabelWidth largeur minimum des {...@link Label} du widget. * Bien entendu, selon la taille passée au widget et le nombre de Labels qu'il contient, ces derniers * pourront être plus larges. */ public @UiConstructor SplitLabel(String width, String height, String labelContent, double miniLabelWidth) { this.width = width; this.height = height; initWidget(uiBinder.createAndBindUi(this)); dockpanel.setSize(this.width, this.height); // on recupere les titres des Label dans un tableau String[] contentList = labelContent.split(:); int nbLabel = contentList.length; //width : largeur du splitLabel width = width.substring(0, (width.length())-2); // labelWidth: largeur initiale des Labels Double labelWidth = new Double(width)/nbLabel; // labelWidth est soumis à une taille minimale if(labelWidth miniLabelWidth) labelWidth = miniLabelWidth; for(int i=0; inbLabel; i++) { splitLayoutPanel.addWest(new Label(contentList[i]), labelWidth); } // the tail of the splitlabel HTML splitLabelTail = new HTML(); splitLabelTail.addStyleDependentName(splitLabelTail); // ex background-color = red; splitLayoutPanel.add(splitLabelTail); // global widget style splitLayoutPanel.addStyleDependentName(splitLabel); dockpanel.add(splitLayoutPanel); } } PS : sorry for french comments! -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
Re: AppEngine Users Service with GWT will always reload page/module upon login
Hi, can't you store this text in a cookie so that you get it back after reload ? (I would even say you that you can push this cookie back/down to the client browser via some rpc form of you choice in order to place it in the browser cache before reload happens) regards didier On Oct 5, 1:56 pm, Shedokan shedok...@gmail.com wrote: Maybe instead try asking the person to login before enabling him the option to write a message? On Oct 3, 12:31 pm, Haris harishas...@gmail.com wrote: Using Users Service, after filling up login and password and press OK, onModuleLoad is executed. Basically the gwt module is reloaded. I am going to loose data entry stuff form the user. For instant if someone is typing a forum post and click submit only to discover that login already timeout. The person relogin using User API login page only to discover that the text typed is lost because of this. Any suggestion? Regards, Haris -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
Re: GWT for client-only web-application
I had the same question, when I started using GWT I knew javascript very good and I was just starting with java. I found that when writing in java you can have classes and classes that inherit from other classes which is a must in all modern apps, this makes your life a whole lot easier. You do have to think differently but once you get the hang of it you'll find out that some apps are a lot easier to make in GWT.. But don't forget that there are somethings that are impossible to do in GWT like loading a class by it's name, and others. If you want to use it instead of JQuery then you'll find out that you can't traverse trough the DOM using queries, you'll have to keep elements in variables and in arrays, which makes it execute a lot faster. On Oct 2, 12:14 am, bog.imp bog@gmail.com wrote: Hello I know Javascript very well and Java(not good but i can learn because i know many languages, c++, python etc), so i think i can create application using GWT. Now i want create DHTML based application using Google Data Api(only client), and some other *cool* Google API, but this application i can create using any javascript framework(like jQuey). So problem that i can't choose why better use GWT, because i never use GWT, Can you help me get good decision. -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
Re: Who is the owner of gwtnews.blogspot.com?
Thanks for your help, I hope this gets resolved because these blogs are just unneeded and probably are used just to make money. If it is not against the Blogger TOS maybe at least they can ask them to hide our emails. Thanks On Sep 29, 4:43 pm, David Chandler (Google) drfibona...@google.com wrote: Thanks for bringing these blogs to our attention. They are (obviously) not official GWT blogs. I'll forward this to the Blogger team to verify compliance with the Blogger terms of service. Thank you, /dmc David Chandler Developer Programs Engineer, Google Web Toolkithttp://googlewebtoolkit.blogspot.com On Sep 29, 7:17 am, Shedokan shedok...@gmail.com wrote: Hello, I am getting tons of spam lately, and I found out spam bots can find me by a simple google search because these two blogs archive GWT conversaions and keep full emails intact: gwtnews.blogspot.com gwtletter.blogspot.com So whoever is the owners of these blogs, I would like to kindley ask you to remove my email addresses from these posts:http://gwtletter.blogspot.com/2010/06/digest-for-google-web_3092.html.. And please remove all other emails if you can or hide a part of them like in your most recent posts. Thank you. -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
Wrapping elements, preventing leaks, attach, detach
Hi, I'm trying to figure out onAttach() onDetatch() onDetachChildren() to ensure I'm not leaking, but I don't quite get it. Is there a reference somewhere? Am I best digging through the code to figure out the flow? I've read the javadocs, but am having a hard time putting it together. Got a gwt app, server sends me down a block of html (a table which is a calendar), gwt client takes the html, and calls setInnerHtml() on a widget. Perfect. The server's html has a div id=foo/div that I want to take over, and shove widgets into. It'd be nice if I could do: RootPanel().get(foo).add(...); // but this asserts What I've done instead is create a wrapper which subclasses Widget, implements HasClickHandlers, and makes onAttach() public. Then I create my wrapped Anchor, get the div in the server's html and append: Anchor link = new Anchor(click me); MyWrapper wrapper = new MyWrapper(link.getElement()); wrapper.addOnClickHandler(...); wrapper.onAttach(); // without this, I can't handle the clicks HorizontalPanel hp = new HorizontalPanel(); hp.add(link); // add more to hp DivElement serverElement = Document.get().getElementById(foo).cast(); serverElement.appendChild(hp.getElement()); --- This all works great. I've got my panel in the div, and the link works. I'm just wondering if I need to do more, as I don't really 'get' the attach, detach, detachChildren flow. Thanks. -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
Re: AppEngine Users Service with GWT will always reload page/module upon login
Hello Haris, Not sure if I understand your problem, so I'll rephrase it: You have a GWT page with a Form element and a submit button. When the submit button is clicked, the page is reloaded. Question: Do you programmatically construct the form or does it exist in the static html? The reason for the reload is likely that GWT does not consume the submit event. To get started, you must use a button element, since input type=submit will cause the form to be mercilessly submitted. Also, you need to register a clickHandler on that button, otherwise the form will be submitted again with Internet Explorer. On Oct 3, 12:31 pm, Haris harishas...@gmail.com wrote: Using Users Service, after filling up login and password and press OK, onModuleLoad is executed. Basically the gwt module is reloaded. I am going to loose data entry stuff form the user. For instant if someone is typing a forum post and click submit only to discover that login already timeout. The person relogin using User API login page only to discover that the text typed is lost because of this. Any suggestion? Regards, Haris -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
Re: AppEngine Users Service with GWT will always reload page/module upon login
On Oct 3, 12:31 pm, Haris harishas...@gmail.com wrote: Using Users Service, after filling up login and password and press OK, onModuleLoad is executed. Basically the gwt module is reloaded. I am going to loose data entry stuff form the user. For instant if someone is typing a forum post and click submit only to discover that login already timeout. The person relogin using User API login page only to discover that the text typed is lost because of this. Any suggestion? AFAICT it really depends how you're wiring GAE authentication within your app. I'm not very familiar with GAE auth but it seems to me you should be able to either: - signal to the user their session expired, without redirecting to the login page (GMail is doing this, at least when offline is enabled; if I was typing a message, then I just open a new tab/window, log in, and then continue in GMail: sessions are based on a cookie, so the next call to the server will contain the updated cookie generated in the other tab/window) - do the login in a popup window, with your redirect_to URL signaling the opening window (your app) that the user is successfully logged in (so you can retry the RPC call / form submission) before closing itself. And of course you could combine both for a great UX! -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
menu with stacklayout
Hi Guys, I'm new at gwt and I would like to ask some hint or advise how can do this. My idea that I want to use StackPanel (StackLayout) to group my menuitems like this: - administration -- user administration -- rules - practice -- hangman -- card etc. The 'administration' and 'practice' part are not links. If the user click on those they will be closed or opened. The 'user administration', 'rules', 'hangman' and 'card' are the links. To click on these different part of application is changing. So, thats the idea. I would like to know which panel is good for me inside StackPanel (StackLayout). Thanks for suggestion in advance! András -- - - -- Csanyi Andras (Sayusi Ando) -- http://sayusi.hu -- http://facebook.com/andras.csanyi -- Trust in God and keep your gunpowder dry! - Cromwell -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
Re: Wrapping elements, preventing leaks, attach, detach
On Oct 5, 2:30 pm, Brian hibr...@gmail.com wrote: Hi, I'm trying to figure out onAttach() onDetatch() onDetachChildren() to ensure I'm not leaking, but I don't quite get it. Is there a reference somewhere? Am I best digging through the code to figure out the flow? I've read the javadocs, but am having a hard time putting it together. Got a gwt app, server sends me down a block of html (a table which is a calendar), gwt client takes the html, and calls setInnerHtml() on a widget. Perfect. The server's html has a div id=foo/div that I want to take over, and shove widgets into. Have a look at HTMLPanel then. It'd be nice if I could do: RootPanel().get(foo).add(...); // but this asserts What I've done instead is create a wrapper which subclasses Widget, implements HasClickHandlers, and makes onAttach() public. Then I create my wrapped Anchor, get the div in the server's html and append: Anchor link = new Anchor(click me); MyWrapper wrapper = new MyWrapper(link.getElement()); wrapper.addOnClickHandler(...); wrapper.onAttach(); // without this, I can't handle the clicks HorizontalPanel hp = new HorizontalPanel(); hp.add(link); // add more to hp DivElement serverElement = Document.get().getElementById(foo).cast(); serverElement.appendChild(hp.getElement()); --- This all works great. I've got my panel in the div, and the link works. I'm just wondering if I need to do more, as I don't really 'get' the attach, detach, detachChildren flow. Not detaching your widgets when you remove them from the document (and/ or on window.unload) will lead to memory leaks in some browsers (mainly, or maybe even *only*, IE6/7/8). You'll note that RootPanel, and every widget that has a wrap() static method, will register itself to be detached on window close, which will detach all its children. But really, what you're trying to do is already there, in HTMLPanel. -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
Re: Wrapping elements, preventing leaks, attach, detach
Thanks. I still have to call onAttach() on my widget in order for the ClickHandler to fire. HTMLPanel hpanel = new HTMLPanel(); Wrapper w = new Wrapper(Test); w.addClickHandler(...); w.onAttach(); hpanel.add(w, foo); This does clean up the code a lot -- but I'm still left wondering when/ where to call onDetach on the wrapper. I'm guessing I'd need to subclass HTMLPanel, handle onDetach, and call it on my wrapper. On Oct 5, 9:20 am, Thomas Broyer t.bro...@gmail.com wrote: On Oct 5, 2:30 pm, Brian hibr...@gmail.com wrote: Hi, I'm trying to figure out onAttach() onDetatch() onDetachChildren() to ensure I'm not leaking, but I don't quite get it. Is there a reference somewhere? Am I best digging through the code to figure out the flow? I've read the javadocs, but am having a hard time putting it together. Got a gwt app, server sends me down a block of html (a table which is a calendar), gwt client takes the html, and calls setInnerHtml() on a widget. Perfect. The server's html has a div id=foo/div that I want to take over, and shove widgets into. Have a look at HTMLPanel then. It'd be nice if I could do: RootPanel().get(foo).add(...); // but this asserts What I've done instead is create a wrapper which subclasses Widget, implements HasClickHandlers, and makes onAttach() public. Then I create my wrapped Anchor, get the div in the server's html and append: Anchor link = new Anchor(click me); MyWrapper wrapper = new MyWrapper(link.getElement()); wrapper.addOnClickHandler(...); wrapper.onAttach(); // without this, I can't handle the clicks HorizontalPanel hp = new HorizontalPanel(); hp.add(link); // add more to hp DivElement serverElement = Document.get().getElementById(foo).cast(); serverElement.appendChild(hp.getElement()); --- This all works great. I've got my panel in the div, and the link works. I'm just wondering if I need to do more, as I don't really 'get' the attach, detach, detachChildren flow. Not detaching your widgets when you remove them from the document (and/ or on window.unload) will lead to memory leaks in some browsers (mainly, or maybe even *only*, IE6/7/8). You'll note that RootPanel, and every widget that has a wrap() static method, will register itself to be detached on window close, which will detach all its children. But really, what you're trying to do is already there, in HTMLPanel. -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
Re: GWT-Platform with GWT 2.1
Do you have to use Guice on the server side in order to use Dispatch or can you use Spring on the server side? On Wed, Sep 29, 2010 at 11:46 PM, Brendan Doherty bren...@propertysimplified.com wrote: Here are a few discussions on the differences. http://groups.google.com/group/gwt-platform/browse_frm/thread/862cab91ccb28d40/cfa2e17fa2a510cc http://groups.google.com/group/gwt-platform/browse_frm/thread/4c00e59dc139ccdf/759eb3a5a6fa67ff http://groups.google.com/group/gwt-platform/browse_frm/thread/7ae934e754089102/d885c122233faa32 There are so many features in gwt-platform, it would be hard to summarise here. You should check out the wiki http://code.google.com/p/gwt-platform/wiki/LibraryOverview On Sep 30, 12:25 pm, Travis Camechis camec...@gmail.com wrote: understand. We are mainly trying to figure out which MVP framework to start with but not sure which one would be the wise decision. Can you tell me some of the benefits of GWTP over 2.1 MVP are? On Wed, Sep 29, 2010 at 6:38 PM, Christian Goudreau goudreau.christ...@gmail.com wrote: There's no big plan for now, since features are moving a lot in trunk of Gwt, but I can assure you that we will include every Gwt core features that we can. Cheers, On Wed, Sep 29, 2010 at 6:26 PM, Travis Camechis camec...@gmail.com wrote: Does anyone know what the plan is for GWT-Platform with the upcoming 2.1 release? Will GWT-Platform integrate the new features or some of them? On Wed, Sep 29, 2010 at 4:04 PM, Bayard Randel k...@bestpractice.net.nzwrote: Yes, I'm currently working on a GWTP project using 2.1M3 without any issues. On Sep 30, 9:01 am, tc camec...@gmail.com wrote: We currently looking at starting a new project. I like what GWT 2.1 provides. Does anyone know if you can use GWT-PLATFORM with 2.1M3+? The main thing we would like to use if using GWT-Platform is the Cell widgets. -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com . To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.comgoogle-web-toolkit%2bunsubscr...@googlegroups.comgoogle-web-toolkit%2Bunsubs cr...@googlegroups.com . For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en. -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.comgoogle-web-toolkit%2bunsubscr...@googlegroups.comgoogle-web-toolkit%2Bunsubs cr...@googlegroups.com . For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en. -- Christian Goudreau www.arcbees.com -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.comgoogle-web-toolkit%2bunsubscr...@googlegroups.comgoogle-web-toolkit%2Bunsubs cr...@googlegroups.com . For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en. -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.comgoogle-web-toolkit%2bunsubscr...@googlegroups.com . For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en. -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
Re: GWT for client-only web-application
asier. You do have to think differentl2010/10/5 Shedokan shedok...@gmail.com I had the same question, when I started using GWT I knew javascript very good and I was just starting with java. I found that when writing in java you can have classes and classes that inherit from other classes which is a must in all modern apps, this makes your life a whole lot ey but once you get the hang of it you'll find out that some apps are a lot easier to make in GWT.. But don't forget that there are somethings that are impossible to do in GWT like loading a class by it's name, and others. If you want to use it instead of JQuery then you'll find out that you can't traverse trough the DOM using queries, you'll have to keep elements in variables and in arrays, which makes it execute a lot faster. On Oct 2, 12:14 am, bog.imp bog@gmail.com wrote: Hello I know Javascript very well and Java(not good but i can learn because i know many languages, c++, python etc), so i think i can create application using GWT. Now i want create DHTML based application using Google Data Api(only client), and some other *cool* Google API, but this application i can create using any javascript framework(like jQuey). So problem that i can't choose why better use GWT, because i never use GWT, Can you help me get good decision. -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.comgoogle-web-toolkit%2bunsubscr...@googlegroups.com . For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en. كثيرآما تصلني من هذة الرسائل وانما ليست مزعجة بلعكس انها محادثة بناءة في المعرفة ولاكن في الغات غير لغتي الام وانا اعاني من البرجمة لفظيآ لولا مساعدة ترجمة جوجل وكذالك اقول انها ليست موجه لي وانما موجه لكافة المستخدمين والنص في الاسفل هية عبارة عن نموذج ترجمة ارجو التوجية او ازالة مثل هذة الرسائل وتأخذ الوقت كثير كان لي نفس السؤال ، عندما بدأت باستخدام جافا سكريبت عرفت GWT جيدة جدا وكنت بدأت للتو مع جافا. التي وجدت في الكتابة عندما يمكن أن يكون جاوة الطبقات والطبقات فئات أخرى ترث من ما هو ويجب في جميع تطبيقات الحديثة وهذا يجعل حياتك الاسهل لوط. لديك لفكر إلى مختلف وبمجرد الحصول على تعليق منه ستجد أن بعض تطبيقات الكثير من الأسهل لجعل في GWT.. ولكن لا ننسى أن هناك شيء ما يستحيل القيام به GWT مثل التحميل في فئة به اسم ، وغيرها. إذا كنت تريد استخدامها بدلا من مسج بعد ذلك سوف تجد أن عليك دوم لا يستطيعون عبور الحوض باستخدام استعلامات ، سيكون لديك للحفاظ على في المتغيرات والعناصر في المصفوفات ، الأمر الذي يجعل من تنفيذ الكثير أسرع. في 2 أكتوبر ، 00:14 ، كتب bog.imp bog@gmail.com: مرحبا وأنا أعلم جيدا جافا سكريبت وجافا (ليست جيدة لتعلم لأنني لا أستطيع أنا أعرف الكثير من اللغات ، ج ، بيثون ، الخ.) لذا أعتقد أنني أستطيع إنشاء التطبيق باستخدام GWT. والآن أريد خلق دتمل تطبيق المستندة باستخدام جوجل بيانات معهد البترول (فقط العملاء) ، وبعض اخرى باردة * * جوجل واجهات برمجة التطبيقات مشاهدة هذا أنا يمكن تطبيق إنشاء باستخدام أي إطار جافا سكريبت (مثل JQuey). وهكذا مشكلة ويمكن أن يختار لماذا أنا لا أفضل استخدام GWT ، لأنني لم تستخدم GWT ، هل يمكنك مساعدتي للحصول على قرار جيد. -- www.abuawad@gmail.com -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
Re: CellTable and Paging question
On Oct 5, 12:28 pm, Maurice maurice.ocon...@gmail.com wrote: Hi, I have a CellTable with a SimplePager. When I click forward on the SimplePager widget, it flicks through the pages as you'd expect. However, when I get to the last page and continue hitting forward, blank pages keep loading. Which parameters should I change to stop this behaviour? It depends whether the rowCount of your data is exact (isRowCountExact of your CellTable) or not (inexact row count makes hasNextPage return true) and if your SimplePager isRangeLimited(). -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
Re: time selection widget?
hie thanks just for a single widget i dont want to use whole library so i was looking for a number selector widget and could not find that either. any advise plz.. Thankx and Regards Vik Founder www.sakshum.com www.sakshum.blogspot.com On Mon, Oct 4, 2010 at 7:33 PM, ctasada ctas...@gmail.com wrote: There's no default time selection widget in GWT. You can create your own (that's what I did) or use one of the multiple GWT frameworks if fits your development process (see GXT, SmartGWT, GWT-Mosaic, ...) Cheers. On Oct 3, 6:28 pm, Vik vik@gmail.com wrote: Hie I was checking at gwt widget gallery but could not find a time selection widget. Can someone please advise ? Thankx and Regards Vik Founderwww.sakshum.comwww.sakshum.blogspot.com -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.comgoogle-web-toolkit%2bunsubscr...@googlegroups.com . For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en. -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
Re: GWT- chat
There's a complete Chat implementation library using xmpp as protocol at: emite.googlecode.com You can use only the library or the complete UI implementation. Maybe it helps On Oct 4, 5:44 pm, Subhrajyoti Moitra subhrajyo...@gmail.com wrote: http://code.google.com/p/atmosphere-gwt-comet/ http://code.google.com/p/atmosphere-gwt-comet/Here one more for the same purpose. On Mon, Oct 4, 2010 at 9:00 PM, andy stevko andy.ste...@gmail.com wrote: Hello Yudji, I believe you are referring to the application model call Comet http://en.wikipedia.org/wiki/Comet_(programming)http://en.wikipedia.org/wiki/Comet_%28programming%29 There is a Comet implementation for the Google Web Toolkit http://code.google.com/p/gwt-comet/ On Sun, Oct 3, 2010 at 6:48 PM, Yudji guilhermeyu...@hotmail.com wrote: I have created a simple client/server app that does nothing but sends a string from client to server. Now I would like to expand it so the server can send messages to all clients. How can this be done? -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.comgoogle-web-toolkit%2Bunsubs cr...@googlegroups.com . For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en. -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.comgoogle-web-toolkit%2Bunsubs cr...@googlegroups.com . For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en. -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
Gzip'ing nocache file causes IE 6 to fail to load
I came across a weird situation yesterday where if I compressed my nocache.js file after deploying my app, IE 6 fails to start the GWT module unless I hit shift-refresh to reload the page. After doing that, the page loads fine on further page loads. This issue didn't exist in any other browser, including IE 7 and 8. After telling my server not to gzip nocache.js files everything works perfectly. Does anyone have any idea what's going on here with IE 6? My host page HTML is below, it's an extremely simple jsp. On startup, my module loads itself into the search div slot. In IE 6, nothing happens. The host page is loaded but no code from my module runs. !DOCTYPE HTML PUBLIC -//W3C//DTD HTML 4.01 Transitional//EN http://www.w3.org/TR/html4/loose.dtd; html head titleSearch/title style type=text/css #search { width: 100%; } /style script type=text/javascript src=module.nocache.js/script /head body div id=search/div /body /html -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
Re: GWT panel for HTML UL/LI lists
I took a similar approach but made it more generic and didn't add special Widget wrapping methods (I just add ElementPanel(LI) to an ElementPanel(UL) or ElementPanel(OL). I like your approach which enforces usage. /** * A generic element panel for Hx, UL, LI, etc. */ public class ElementPanel extends ComplexPanel implements HasText, HasHTML { public ElementPanel(String tagname) { setElement(DOM.createElement(tagname)); } // more stuff in here . } I'm not sure I understand the need for the special clear() method implementation in your code. -Andy On Sep 24, 5:51 pm, Markus Kramer tomaton...@googlemail.com wrote: Hi, for my current GWT project I wanted to make more use of HTML UL/LI elements than the table based layouts that you normally use in GWT applications. Biggest advantages for me is that other people can make changes to the layout/design of the page without having to touch the code itself. I couldn't find a class in GWT or anywhere else that helps with that, so I wrote my own. I can now create HTML like this: ul class=sampleList liWidget A/li liWidget B/li /ul with this code: UlListPanel ulList = new UlListPanel(); ulList.addStyleName(sampleList); ulList.add(widgetA); ulList.add(widgetB); For the code go here:http://markusbraindump.blogspot.com/2010/09/gwt-panel-for-html-ulli-l... Or did I reinvent the wheel? Markus -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
Upgrade to 2.1.0m3 failed.
I tried upgrading to version 2.1.0m3 to pick up some fixes related to blank/white pages. After the upgrade on our Solaris servers, all my RPC calls are failing when the first page is trying to load. Thoughts? -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
Re: Wrapping elements, preventing leaks, attach, detach
What's odd (ie, I don't get this stuff yet) is the HTMLPanel's onAttach doesn't get called when htmlpanel.add() is called. Soo.. instead of wrapping the widget, it seems better to wrap the HTMLPanel and call onAttach on the panel itself, and add it to RootPanel.detachOnWindowClose(). ie, Label myLabel = new Label(Hey now); myLabel.addClickHandler(..); MyPanel p = new MyPanel(); // subclassed HTMLPanel, onAttach is public p.add(myLabel, foo); p.onAttach(); // just does: super.onAttach(); RootPanel.detachOnChildClose(p); // ensures everyone's onDetach called Just guessing here... On Oct 5, 9:40 am, Brian hibr...@gmail.com wrote: Thanks. I still have to call onAttach() on my widget in order for the ClickHandler to fire. HTMLPanel hpanel = new HTMLPanel(); Wrapper w = new Wrapper(Test); w.addClickHandler(...); w.onAttach(); hpanel.add(w, foo); This does clean up the code a lot -- but I'm still left wondering when/ where to call onDetach on the wrapper. I'm guessing I'd need to subclass HTMLPanel, handle onDetach, and call it on my wrapper. On Oct 5, 9:20 am, Thomas Broyer t.bro...@gmail.com wrote: On Oct 5, 2:30 pm, Brian hibr...@gmail.com wrote: Hi, I'm trying to figure out onAttach() onDetatch() onDetachChildren() to ensure I'm not leaking, but I don't quite get it. Is there a reference somewhere? Am I best digging through the code to figure out the flow? I've read the javadocs, but am having a hard time putting it together. Got a gwt app, server sends me down a block of html (a table which is a calendar), gwt client takes the html, and calls setInnerHtml() on a widget. Perfect. The server's html has a div id=foo/div that I want to take over, and shove widgets into. Have a look at HTMLPanel then. It'd be nice if I could do: RootPanel().get(foo).add(...); // but this asserts What I've done instead is create a wrapper which subclasses Widget, implements HasClickHandlers, and makes onAttach() public. Then I create my wrapped Anchor, get the div in the server's html and append: Anchor link = new Anchor(click me); MyWrapper wrapper = new MyWrapper(link.getElement()); wrapper.addOnClickHandler(...); wrapper.onAttach(); // without this, I can't handle the clicks HorizontalPanel hp = new HorizontalPanel(); hp.add(link); // add more to hp DivElement serverElement = Document.get().getElementById(foo).cast(); serverElement.appendChild(hp.getElement()); --- This all works great. I've got my panel in the div, and the link works. I'm just wondering if I need to do more, as I don't really 'get' the attach, detach, detachChildren flow. Not detaching your widgets when you remove them from the document (and/ or on window.unload) will lead to memory leaks in some browsers (mainly, or maybe even *only*, IE6/7/8). You'll note that RootPanel, and every widget that has a wrap() static method, will register itself to be detached on window close, which will detach all its children. But really, what you're trying to do is already there, in HTMLPanel. -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
Re: Upgrade to 2.1.0m3 failed.
Be sure to delete all generated files (hosted.htmt *.js etc ...). On Tue, Oct 5, 2010 at 4:00 PM, skippy al.leh...@fisglobal.com wrote: I tried upgrading to version 2.1.0m3 to pick up some fixes related to blank/white pages. After the upgrade on our Solaris servers, all my RPC calls are failing when the first page is trying to load. Thoughts? -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.comgoogle-web-toolkit%2bunsubscr...@googlegroups.com . For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en. -- Computers are useless. They can only give you answers. - Pablo Picasso - -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
Re: Wrapping elements, preventing leaks, attach, detach
On Oct 5, 4:13 pm, Brian hibr...@gmail.com wrote: What's odd (ie, I don't get this stuff yet) is the HTMLPanel's onAttach doesn't get called when htmlpanel.add() is called. Of course. It'll be called when adding the HTMLPanel into a container widget. Soo.. instead of wrapping the widget, it seems better to wrap the HTMLPanel and call onAttach on the panel itself, and add it to RootPanel.detachOnWindowClose(). How are you showing/displaying your HTMLPanel ?!?! -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
Re: Gzip'ing nocache file causes IE 6 to fail to load
On Oct 5, 3:52 pm, Jeremy Hulford jer...@hulford.net wrote: I came across a weird situation yesterday where if I compressed my nocache.js file after deploying my app, IE 6 fails to start the GWT module unless I hit shift-refresh to reload the page. After doing that, the page loads fine on further page loads. This issue didn't exist in any other browser, including IE 7 and 8. After telling my server not to gzip nocache.js files everything works perfectly. Does anyone have any idea what's going on here with IE 6? Bug bug bug! Google for gzip js ie6 One of the results: http://sebduggan.com/posts/ie6-gzip-bug-solved-using-isapi-rewrite -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
Re: Upgrade to 2.1.0m3 failed.
OK, I do see the old version got checked into our source control environment. Let me clean that up and I will let you know. On Oct 5, 9:15 am, olivier nouguier olivier.nougu...@gmail.com wrote: Be sure to delete all generated files (hosted.htmt *.js etc ...). On Tue, Oct 5, 2010 at 4:00 PM, skippy al.leh...@fisglobal.com wrote: I tried upgrading to version 2.1.0m3 to pick up some fixes related to blank/white pages. After the upgrade on our Solaris servers, all my RPC calls are failing when the first page is trying to load. Thoughts? -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.comgoogle-web-toolkit%2bunsubscr...@googlegroups.com . For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en. -- Computers are useless. They can only give you answers. - Pablo Picasso -- Hide quoted text - - Show quoted text - -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
Re: Wrapping elements, preventing leaks, attach, detach
ok thank you. I had been doing : String s = getServerHTML(); DOM.getElementById(id).setInnerHTML(s); // woops id is an id to a Panel in the hierarchy. I didn't know how to set its innerHTML without using the DOM class. From there, I was using Dom methods to get the div I wanted to append a child to, and that's when the various attach and detach issues came up. Pain and suffering. Instead of using an HTMLPanel to replace the div inside the html, I used an HTMLPanel as content to the whole server html. From there, I just hooked up things as normal. HTMLPanel htmlpanel = new HTMLPanel( getServerHTML() ); simplePanel.add(htmlpanel); When I want to take over some part of the server's html: htmlpanel.add(someElement, someID); Now I've got -no- subclassed widgets nor panels, handlers fire, so I'm assuming everything is hooked up correctly. Thanks much. On Oct 5, 10:26 am, Thomas Broyer t.bro...@gmail.com wrote: On Oct 5, 4:13 pm, Brian hibr...@gmail.com wrote: What's odd (ie, I don't get this stuff yet) is the HTMLPanel's onAttach doesn't get called when htmlpanel.add() is called. Of course. It'll be called when adding the HTMLPanel into a container widget. Soo.. instead of wrapping the widget, it seems better to wrap the HTMLPanel and call onAttach on the panel itself, and add it to RootPanel.detachOnWindowClose(). How are you showing/displaying your HTMLPanel ?!?! -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
Re: New GWT 2.0 Book
Hi, if you look at the Table of Contents, you can see it is mostly basic stuff and 2.0 contents. regards Kristjan On Oct 1, 7:38 pm, Tommy Lui tlui1...@gmail.com wrote: Hi, Please help me understand why Chris Ramsdale (Google's Developer Relations team to develop and advocate GWT best practices.) is writting a book about GWT 2.1 when he works at Google on the GWT team and there's no official documentation, except for a few waves available to the developer community. Is this some way for him to force developers to buy his book? http://www.manning.com/bambury/ The book is due to be release in 2011, so I'm sure it's GWT 2.1 not GWT 2.0 content. I'm hoping that I'm not the only person really pissed off about this. I'd really like other peoples opinions on this topic -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
TextBox
I have created a puzzle app using resources from AWT/Swing and it prints TextFields in a window according to specific positions (x, y) I set with setBounds in order to form a main vertical word. This app works very well. Now, I have to pass this app into a GWT one, but I don't know how to create the same interface, once I used TextField in AWT/Swing to do that and now I have to use TextBox. Does anyone have a suggestion to help me? -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
Re: Help: Development of large App with GWT
I am also thinking about this. Google provide us with a toolkit. So, what type of application can we create with this one that we cannot or would be difficult with another framework. Because Now Noor must choose a proper application that clearly shows that yes, THIS APPLICATION WOULD HAVE BEEN DIFFICULT OR IMPOSSIBLE WITHOUT GWT. So guys, what type of application can we recommend Noor, this is a great question which lies in our experience? Can someone has good suggestion -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
GWT Module Dependency
I was read the article http://code.google.com/p/gwt-comet/wiki/GettingStarted and where in the project I put inherits name=net.zschech.gwt.comet.Comet / ? and add-linker name=xs/ anywhere in the xml? thanks -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
Re: Wrapping elements, preventing leaks, attach, detach
Hi GWT in Action has an excellent chapter about Event Handling. It's an old book, probably 2007 and GWT 1.6 but as far as I can tell from looking at the 2.1.M3 API (*com.google.gwt.user.client.ui.Widget) *alot of this hasn't changed much, if at all I read somewhere that in 2.0 Listeners became handlers,* *The Chapter has about 20+ pages of great content, hopefully that will help you out. Does any know how much the event handling has changed since 1.6?* * On Tue, Oct 5, 2010 at 7:13 AM, Brian hibr...@gmail.com wrote: What's odd (ie, I don't get this stuff yet) is the HTMLPanel's onAttach doesn't get called when htmlpanel.add() is called. Soo.. instead of wrapping the widget, it seems better to wrap the HTMLPanel and call onAttach on the panel itself, and add it to RootPanel.detachOnWindowClose(). ie, Label myLabel = new Label(Hey now); myLabel.addClickHandler(..); MyPanel p = new MyPanel(); // subclassed HTMLPanel, onAttach is public p.add(myLabel, foo); p.onAttach(); // just does: super.onAttach(); RootPanel.detachOnChildClose(p); // ensures everyone's onDetach called Just guessing here... On Oct 5, 9:40 am, Brian hibr...@gmail.com wrote: Thanks. I still have to call onAttach() on my widget in order for the ClickHandler to fire. HTMLPanel hpanel = new HTMLPanel(); Wrapper w = new Wrapper(Test); w.addClickHandler(...); w.onAttach(); hpanel.add(w, foo); This does clean up the code a lot -- but I'm still left wondering when/ where to call onDetach on the wrapper. I'm guessing I'd need to subclass HTMLPanel, handle onDetach, and call it on my wrapper. On Oct 5, 9:20 am, Thomas Broyer t.bro...@gmail.com wrote: On Oct 5, 2:30 pm, Brian hibr...@gmail.com wrote: Hi, I'm trying to figure out onAttach() onDetatch() onDetachChildren() to ensure I'm not leaking, but I don't quite get it. Is there a reference somewhere? Am I best digging through the code to figure out the flow? I've read the javadocs, but am having a hard time putting it together. Got a gwt app, server sends me down a block of html (a table which is a calendar), gwt client takes the html, and calls setInnerHtml() on a widget. Perfect. The server's html has a div id=foo/div that I want to take over, and shove widgets into. Have a look at HTMLPanel then. It'd be nice if I could do: RootPanel().get(foo).add(...); // but this asserts What I've done instead is create a wrapper which subclasses Widget, implements HasClickHandlers, and makes onAttach() public. Then I create my wrapped Anchor, get the div in the server's html and append: Anchor link = new Anchor(click me); MyWrapper wrapper = new MyWrapper(link.getElement()); wrapper.addOnClickHandler(...); wrapper.onAttach(); // without this, I can't handle the clicks HorizontalPanel hp = new HorizontalPanel(); hp.add(link); // add more to hp DivElement serverElement = Document.get().getElementById(foo).cast(); serverElement.appendChild(hp.getElement()); --- This all works great. I've got my panel in the div, and the link works. I'm just wondering if I need to do more, as I don't really 'get' the attach, detach, detachChildren flow. Not detaching your widgets when you remove them from the document (and/ or on window.unload) will lead to memory leaks in some browsers (mainly, or maybe even *only*, IE6/7/8). You'll note that RootPanel, and every widget that has a wrap() static method, will register itself to be detached on window close, which will detach all its children. But really, what you're trying to do is already there, in HTMLPanel. -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.comgoogle-web-toolkit%2bunsubscr...@googlegroups.com . For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en. -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
MVP JUnit test startup error
Hello there, I just implemented MVP into my project and wanted to do some GWTTestCase tests. I run the test by eclipse launcher with JUnit 3, also tried JUnit 4, but no success. I get the following stacktrace: Module com.nuon.cs.is.nuonxx.web.mijnnuon.gwt.movestatus.MoveStatusTest.JUnit has been loaded StandardContext[]shell: init [WARN] StandardContext[]Exception while dispatching incoming RPC call java.lang.NoSuchMethodError: javax.servlet.http.HttpServletResponse.setCharacterEncoding(Ljava/lang/ String;)V at com.google.gwt.rpc.server.RpcServlet.processPost(RpcServlet.java: 186) at com.google.gwt.user.server.rpc.AbstractRemoteServiceServlet.doPost(AbstractRemoteServiceServlet.java: 62) at javax.servlet.http.HttpServlet.service(HttpServlet.java:760) at com.google.gwt.junit.server.JUnitHostImpl.service(JUnitHostImpl.java: 151) at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) at com.google.gwt.dev.shell.GWTShellServlet.service(GWTShellServlet.java: 288) at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java: 237) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java: 157) at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java: 214) at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java: 104) at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java: 520) at org.apache.catalina.core.StandardContextValve.invokeInternal(StandardContextValve.java: 198) at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java: 152) at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java: 104) at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java: 520) at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java: 137) at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java: 104) at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java: 118) at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java: 102) at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java: 520) at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java: 109) at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java: 104) at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java: 520) at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java: 929) at org.apache.coyote.tomcat5.CoyoteAdapter.service(CoyoteAdapter.java: 160) at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java: 799) at org.apache.coyote.http11.Http11Protocol $Http11ConnectionHandler.processConnection(Http11Protocol.java:705) at org.apache.tomcat.util.net.TcpWorkerThread.runIt(PoolTcpEndpoint.java: 577) at org.apache.tomcat.util.threads.ThreadPool $ControlRunnable.run(ThreadPool.java:683) at java.lang.Thread.run(Thread.java:619) Anyone has experience with this kind of errors? -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
Re: Weird error on RPC calls
Are you intending for ActualModelData to extend MyModelData rather than ModelData? Yes - sorry my typo. I would have loved to step through the source for the serializer and try to work out why that field didn't get serialized, but I don't know where to find that code. Thanks, Quincy -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
NoClassDefFoundError
im getting this random error today i dont know why it was working better yesterday javax.servlet.ServletContext log: Exception while dispatching incoming RPC call com.google.gwt.user.server.rpc.UnexpectedException: Service method 'public abstract java.lang.Boolean com.dushyant.PO.client.PoService.SavePOrder(java.util.ArrayList)' threw an unexpected exception: java.lang.NoClassDefFoundError: Could not initialize class com.dushyant.PO.server.PMF at com.google.gwt.user.server.rpc.RPC.encodeResponseForFailure(RPC.java: 378) at com.google.gwt.user.server.rpc.RPC.invokeAndEncodeResponse(RPC.java: 581) at com.google.gwt.user.server.rpc.RemoteServiceServlet.processCall(RemoteServiceServlet.java: 188) at com.google.gwt.user.server.rpc.RemoteServiceServlet.processPost(RemoteServiceServlet.java: 224) at com.google.gwt.user.server.rpc.AbstractRemoteServiceServlet.doPost(AbstractRemoteServiceServlet.java: 62) at javax.servlet.http.HttpServlet.service(HttpServlet.java:713) at javax.servlet.http.HttpServlet.service(HttpServlet.java:806) at org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java: 511) at org.mortbay.jetty.servlet.ServletHandler $CachedChain.doFilter(ServletHandler.java:1166) at com.google.apphosting.utils.servlet.ParseBlobUploadFilter.doFilter(ParseBlobUploadFilter.java: 97) at org.mortbay.jetty.servlet.ServletHandler $CachedChain.doFilter(ServletHandler.java:1157) at com.google.apphosting.runtime.jetty.SaveSessionFilter.doFilter(SaveSessionFilter.java: 35) at org.mortbay.jetty.servlet.ServletHandler $CachedChain.doFilter(ServletHandler.java:1157) at com.google.apphosting.utils.servlet.TransactionCleanupFilter.doFilter(TransactionCleanupFilter.java: 43) at org.mortbay.jetty.servlet.ServletHandler $CachedChain.doFilter(ServletHandler.java:1157) at org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java: 388) at org.mortbay.jetty.security.SecurityHandler.handle(SecurityHandler.java: 216) . . -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
Re: Cannot create new web applications.
This was sent 3 days ago. I've since gone with Aptana which worked successfully. The 32 and 64 bit versions of Eclipse didn't work. Also, this moderation is lame for a group based around user support :-/ -justin On Mon, Oct 4, 2010 at 9:19 PM, Y2i yur...@gmail.com wrote: Strange, I didn't have such problem in Win 7 and Ubuntu 10.04 64-bit. Can you verify that the GWT plugin is installed? Help-Install New Software, then click What is already isntalled? link On Oct 1, 10:03 pm, Justin Lilly justinli...@gmail.com wrote: I just downloaded eclipse v3.6 (Helios), Java EE version. I then added the google repository athttp://dl.google.com/eclipse/plugin/3.6to my possible installation places, selected all downloads (which included the google plugin for eclipse as well as the appengine and gwt sdk). I'm attempting to follow through with the tutorial, but there is no Create new web application selection available in my new project dialog box. Yes, I already looked in the other section too. I'm on 64 bit windows 7, with 64 bit eclipse. Any help would be greatly appreciated. -justin -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en. -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
Re: GWT Complier OutOfMemory issue
This doesn't address code-splitting per-se, but r8921 and r8850 reduce both DevMode and compiler memory footprint. On Sat, Sep 18, 2010 at 11:34 PM, lin.liang birdandfis...@gmail.com wrote: Chris, I didn't see the OOME before using code splitting. In order to reduce the application's startup time, I adopt code splitting in the DynaClassGenerator.java (the implementation of GWT generator on data deferred binding in our project) 1) Before using code splitting, the code is: if (com.nantian.iwap3.frameworkdev.client.dataitem.DataItemMgr.equals(className)) { com.nantian.iwap3.frameworkdev.client.dataitem.DataItemMgr instance = new com.nantian.iwap3.frameworkdev.client.dataitem.DataItemMgr(); } 2) After using code splitting: if (com.nantian.iwap3.frameworkdev.client.dataitem.DataItemMgr.equals(className)) { GWT.runAsync(new RunAsyncCallbackAdapter() { public void onSuccess() { com.nantian.iwap3.frameworkdev.client.dataitem.DataItemMgr instance = new com.nantian.iwap3.frameworkdev.client.dataitem.DataItemMgr(); callback.onSuccess((T)instance); } }); } In the former one, the complier work fine. However, in the second one, the complie process was interrupted by the OOME. P.S. It about 1,000 instances created by this way (e.g. com.nantian.iwap3.frameworkdev.client.dataitem.DataItemMgr above). On 9月17日, 下午11时00分, Chris Conroy con...@google.com wrote: That should be more than enough memory to run your compile. Do you have a stack trace for the OOME? FWIW, I have a pending change that should decrease the amount of memory needed to run a compile or DevMode. On Fri, Sep 17, 2010 at 7:19 AM, lin.liang birdandfis...@gmail.com wrote: The OutOfMemory exception always happen when the gwt project was complied. The gwt project has 7 modules, and about 5,700 java files. I have a look at gwt docs. It said that when the project became bigger, the complier using the memory more too. However, I have set the memory to 1.7G, it still report the OutOfMemory exception. Is this the bug of gwt complier? How can I do to solve this issue? I have no clue about this so far. Look forward your response. Thanks! -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.comgoogle-web-toolkit%2bunsubscr...@googlegroups.com google-web-toolkit%2bunsubs-cr...@googlegroups.comgoogle-web-toolkit%252bunsubs-cr...@googlegroups.com . For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.- 隐藏被引用文字 - - 显示引用的文字 - -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
Best way to add click handler to Element?
What's the best practice to add a ClickHandler in GWT to an Element? For example, I have a ul with multiple li Elements inside, and I need to take an action based on which li is clicked. (It would also be best if other widgets could listen for those events, since I'm using this to make tabs but may also use it for other navigation structures in the future, and I'm not 100% clear on GWT's sink/source model) Putting the ClickHandler on the ul would probably be the most efficient, but I'm also fine with putting the ClickHandler directly on the li or making a li widget that implements HasClickHandlers if those don't cause too much of a performance hit. I'm just curious what the best way to do this is. Thanks! -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
Re: Cannot create new web applications.
Justin, we'd all love to not have to deal with the hassle of moderation, but sadly there are a lot of spammers out there. Only new members are automatically moderated, and once a member makes some legitimate posts, we flip the bit that allows them to post without being stuck in the moderation queue. Aptana doesn't support GWT directly AFAIK. The Eclipse UI for the new project dialog is a bit confusing. You'll probably need to select File-New Project-Google-Web Application Project. The plugin should also add a few buttons to your toolbar including one for just this action. On Mon, Oct 4, 2010 at 9:45 PM, Justin Lilly jus...@justinlilly.com wrote: This was sent 3 days ago. I've since gone with Aptana which worked successfully. The 32 and 64 bit versions of Eclipse didn't work. Also, this moderation is lame for a group based around user support :-/ -justin On Mon, Oct 4, 2010 at 9:19 PM, Y2i yur...@gmail.com wrote: Strange, I didn't have such problem in Win 7 and Ubuntu 10.04 64-bit. Can you verify that the GWT plugin is installed? Help-Install New Software, then click What is already isntalled? link On Oct 1, 10:03 pm, Justin Lilly justinli...@gmail.com wrote: I just downloaded eclipse v3.6 (Helios), Java EE version. I then added the google repository athttp://dl.google.com/eclipse/plugin/3.6to my possible installation places, selected all downloads (which included the google plugin for eclipse as well as the appengine and gwt sdk). I'm attempting to follow through with the tutorial, but there is no Create new web application selection available in my new project dialog box. Yes, I already looked in the other section too. I'm on 64 bit windows 7, with 64 bit eclipse. Any help would be greatly appreciated. -justin -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com . To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.comgoogle-web-toolkit%2bunsubscr...@googlegroups.com . For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en. -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.comgoogle-web-toolkit%2bunsubscr...@googlegroups.com . For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en. -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
Re: GWT panel for HTML UL/LI lists
You could do it with DOM.createElement(ul). But you would be using some lower level API directly. I believe it's good to have a clear encapsulation of a HTML construct that at least I use quite frequently now. @Andy: I no longer understand the purpose of that clear method as well. Have to check if it can be removed... Never used the H1, H2,... tags in GWT until now. Just Labels with CSS classes instead. /Markus On Oct 5, 3:56 pm, Andy pula...@gmail.com wrote: I took a similar approach but made it more generic and didn't add special Widget wrapping methods (I just add ElementPanel(LI) to an ElementPanel(UL) or ElementPanel(OL). I like your approach which enforces usage. /** * A generic element panel for Hx, UL, LI, etc. */ public class ElementPanel extends ComplexPanel implements HasText, HasHTML { public ElementPanel(String tagname) { setElement(DOM.createElement(tagname)); } // more stuff in here . } I'm not sure I understand the need for the special clear() method implementation in your code. -Andy On Sep 24, 5:51 pm, Markus Kramer tomaton...@googlemail.com wrote: Hi, for my current GWT project I wanted to make more use of HTML UL/LI elements than the table based layouts that you normally use in GWT applications. Biggest advantages for me is that other people can make changes to the layout/design of the page without having to touch the code itself. I couldn't find a class in GWT or anywhere else that helps with that, so I wrote my own. I can now create HTML like this: ul class=sampleList liWidget A/li liWidget B/li /ul with this code: UlListPanel ulList = new UlListPanel(); ulList.addStyleName(sampleList); ulList.add(widgetA); ulList.add(widgetB); For the code go here:http://markusbraindump.blogspot.com/2010/09/gwt-panel-for-html-ulli-l... Or did I reinvent the wheel? Markus -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
Re: Cannot create new web applications.
Aptana does work with GWT. I installed GWT and Eclipse Java EE version (4 times, twice with 64 bit, twice with 32 bit versions of eclipse). I installed the GWT plugin (install software, etc) but those menu options were not there, they did not appear after a restart (computer or eclipse itself), yet the plugin remained installed, just inaccessible through any method I tried (menu items, etc). I've since moved on to Aptana, which seems to work, but worth noting that it is an issue for at least some windows users. Contact me off list if you have specific questions about environment, etc. -justin On Tue, Oct 5, 2010 at 11:23 AM, Chris Conroy con...@google.com wrote: Justin, we'd all love to not have to deal with the hassle of moderation, but sadly there are a lot of spammers out there. Only new members are automatically moderated, and once a member makes some legitimate posts, we flip the bit that allows them to post without being stuck in the moderation queue. Aptana doesn't support GWT directly AFAIK. The Eclipse UI for the new project dialog is a bit confusing. You'll probably need to select File-New Project-Google-Web Application Project. The plugin should also add a few buttons to your toolbar including one for just this action. On Mon, Oct 4, 2010 at 9:45 PM, Justin Lilly jus...@justinlilly.com wrote: This was sent 3 days ago. I've since gone with Aptana which worked successfully. The 32 and 64 bit versions of Eclipse didn't work. Also, this moderation is lame for a group based around user support :-/ -justin On Mon, Oct 4, 2010 at 9:19 PM, Y2i yur...@gmail.com wrote: Strange, I didn't have such problem in Win 7 and Ubuntu 10.04 64-bit. Can you verify that the GWT plugin is installed? Help-Install New Software, then click What is already isntalled? link On Oct 1, 10:03 pm, Justin Lilly justinli...@gmail.com wrote: I just downloaded eclipse v3.6 (Helios), Java EE version. I then added the google repository athttp://dl.google.com/eclipse/plugin/3.6to my possible installation places, selected all downloads (which included the google plugin for eclipse as well as the appengine and gwt sdk). I'm attempting to follow through with the tutorial, but there is no Create new web application selection available in my new project dialog box. Yes, I already looked in the other section too. I'm on 64 bit windows 7, with 64 bit eclipse. Any help would be greatly appreciated. -justin -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en. -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en. -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en. -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
Nested Layout Issues
I'm creating an application with a view based upon the DockLayoutPanel. I initialize a DockLayoutPanel and add SimplePanels to the north, south, west, and center docks so I can pass them to the Presenters. The presenter then adds a custom widget to the to the SimplePanel. The custom widget contains a StackLayoutPanel (think left stackpanel navigation like gmail). The issue is the stack isn't displaying correctly, I'm only seeing the first stack in the panel. If I add the custom widget directly to the DockLayoutPanel without first adding a SimplePanel, it works fine. But this would mess up my MVP coupling. Any help is appreciated. -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
Re: Wrapping elements, preventing leaks, attach, detach
On Oct 5, 4:40 pm, Flan Brody flannanbr...@gmail.com wrote: Hi GWT in Action has an excellent chapter about Event Handling. It's an old book, probably 2007 and GWT 1.6 but as far as I can tell from looking at the 2.1.M3 API (*com.google.gwt.user.client.ui.Widget) *alot of this hasn't changed much, if at all I read somewhere that in 2.0 Listeners became handlers,* That was GWT 1.6 actually. Listeners are deprecated since then. The original plan was to remove them in 2.0 but they're finally still there, and will probably last a bit of time (there's also an history in GWT that nothing had ever been removed...) Does any know how much the event handling has changed since 1.6?* It hasn't. It might change a bit in a future release (was initially planned for 2.1 but won't do it) but onyl at a lower level. The com.google.gwt.event.* public API won't change any time soon I guess. (note that in 2.1, HandlerManager's internals have changed, but again, it's low-level, so it's probably only relevant to 0.1% GWT users) -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
Re: Help: Development of large App with GWT
On Oct 5, 3:02 pm, 007Prog camarad250...@gmail.com wrote: I am also thinking about this. Google provide us with a toolkit. So, what type of application can we create with this one that we cannot or would be difficult with another framework. Because Now Noor must choose a proper application that clearly shows that yes, THIS APPLICATION WOULD HAVE BEEN DIFFICULT OR IMPOSSIBLE WITHOUT GWT. There cannot be a single such app; because GWT is JavaScript in the end, so anything you can do in a browser you can do in GWT, and vice versa (GWT is, before all, a Java-to-JavaScript compiler, everything else is extensible and even replaceable; yes, even the Java Runtime Emulation!) Where GWT is good is in taking advantage of the static typing of Java, to do static analysis of the code at compile time and automatically generate code based on this. The best example is GWT-RPC, but even better are, in the upcoming 2.1 release, RequestFactory and Editor. This is something that you just cannot do in pure JS, but it doesn't make GWT able to create apps that would have been diffucult or impossible without it; you'd just have approached them differently (and of course have done much more work either upfront –by hand– or at runtime –using some kind of reflection–) -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
Re: Wrapping elements, preventing leaks, attach, detach
good to know that the excellent chapter in GWT in A on event handling is still more or less relevant with 2.1. Thanks Thomas On Tue, Oct 5, 2010 at 9:06 AM, Thomas Broyer t.bro...@gmail.com wrote: On Oct 5, 4:40 pm, Flan Brody flannanbr...@gmail.com wrote: Hi GWT in Action has an excellent chapter about Event Handling. It's an old book, probably 2007 and GWT 1.6 but as far as I can tell from looking at the 2.1.M3 API (*com.google.gwt.user.client.ui.Widget) *alot of this hasn't changed much, if at all I read somewhere that in 2.0 Listeners became handlers,* That was GWT 1.6 actually. Listeners are deprecated since then. The original plan was to remove them in 2.0 but they're finally still there, and will probably last a bit of time (there's also an history in GWT that nothing had ever been removed...) Does any know how much the event handling has changed since 1.6?* It hasn't. It might change a bit in a future release (was initially planned for 2.1 but won't do it) but onyl at a lower level. The com.google.gwt.event.* public API won't change any time soon I guess. (note that in 2.1, HandlerManager's internals have changed, but again, it's low-level, so it's probably only relevant to 0.1% GWT users) -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.comgoogle-web-toolkit%2bunsubscr...@googlegroups.com . For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en. -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
Re: MVP JUnit test startup error
On Oct 5, 10:00 am, Tom de Vroomen tomh...@gmail.com wrote: Hello there, I just implemented MVP into my project and wanted to do some GWTTestCase tests. I run the test by eclipse launcher with JUnit 3, also tried JUnit 4, but no success. I get the following stacktrace: Module com.nuon.cs.is.nuonxx.web.mijnnuon.gwt.movestatus.MoveStatusTest.JUnit has been loaded StandardContext[]shell: init [WARN] StandardContext[]Exception while dispatching incoming RPC call java.lang.NoSuchMethodError: javax.servlet.http.HttpServletResponse.setCharacterEncoding(Ljava/lang/ String;)V Do you have the servlet-api in your classpath? before gwt-user? in a version before servlets 2.4? gwt-user bundles the servlet api (2.4 or 2.5, cannot remember), so you don't have to put yours in the classpath. -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
Re: Need help with [ERROR] Annotation error: while doing GWT compile
On Oct 5, 5:31 am, Sanjeev sanjeev.x.ve...@gmail.com wrote: Hi: GWT newbie here, using gwt 2.04 with Guice 2.0, Gin 1.0 and mvp4g-1.2.0. I am getting the below error when trying to run “com.google.gwt.dev.Compiler” on my GWT project. Feeling very lost right now, so please help. Please ask for more information if needed – quick help will be very appreciated. Buildfile: C:\workspace\basel2-gwt\build.xml prepare: compile.gwt: [java] Oct 4, 2010 11:15:08 PM java.util.prefs.WindowsPreferences init [java] WARNING: Could not open/create prefs root node Software \JavaSoft\Prefs at root 0x8002. Windows RegCreateKeyEx(...) returned error code 5. [java] Compiling module com.boa.basel2.precalc.PreCalcAdjustment [java] Resolving com.boa.basel2.precalc.client.presenter.WorkflowPresenter [java] Found type 'com.boa.basel2.precalc.client.presenter.WorkflowPresenter' [java] [ERROR] Annotation error: cannot resolve com.boa.basel2.precalc.client.view.WorkflowView [java] java.lang.ClassNotFoundException: com.boa.basel2.precalc.client.view.WorkflowView Have you compiled you code with javac? Is the compiled *.class in the classpath? It's a necessary step, even if the *.class won't be run in the JVM because they're only client-side code to be compiled by GWT into JavaScript. -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
Re: GWT-Platform with GWT 2.1
Spring support is planned for release 0.5 (e.t.a. early November) Philippe On Tue, Oct 5, 2010 at 6:40 AM, Travis Camechis camec...@gmail.com wrote: Do you have to use Guice on the server side in order to use Dispatch or can you use Spring on the server side? On Wed, Sep 29, 2010 at 11:46 PM, Brendan Doherty bren...@propertysimplified.com wrote: Here are a few discussions on the differences. http://groups.google.com/group/gwt-platform/browse_frm/thread/862cab91ccb28d40/cfa2e17fa2a510cc http://groups.google.com/group/gwt-platform/browse_frm/thread/4c00e59dc139ccdf/759eb3a5a6fa67ff http://groups.google.com/group/gwt-platform/browse_frm/thread/7ae934e754089102/d885c122233faa32 There are so many features in gwt-platform, it would be hard to summarise here. You should check out the wiki http://code.google.com/p/gwt-platform/wiki/LibraryOverview On Sep 30, 12:25 pm, Travis Camechis camec...@gmail.com wrote: understand. We are mainly trying to figure out which MVP framework to start with but not sure which one would be the wise decision. Can you tell me some of the benefits of GWTP over 2.1 MVP are? On Wed, Sep 29, 2010 at 6:38 PM, Christian Goudreau goudreau.christ...@gmail.com wrote: There's no big plan for now, since features are moving a lot in trunk of Gwt, but I can assure you that we will include every Gwt core features that we can. Cheers, On Wed, Sep 29, 2010 at 6:26 PM, Travis Camechis camec...@gmail.comwrote: Does anyone know what the plan is for GWT-Platform with the upcoming 2.1 release? Will GWT-Platform integrate the new features or some of them? On Wed, Sep 29, 2010 at 4:04 PM, Bayard Randel k...@bestpractice.net.nzwrote: Yes, I'm currently working on a GWTP project using 2.1M3 without any issues. On Sep 30, 9:01 am, tc camec...@gmail.com wrote: We currently looking at starting a new project. I like what GWT 2.1 provides. Does anyone know if you can use GWT-PLATFORM with 2.1M3+? The main thing we would like to use if using GWT-Platform is the Cell widgets. -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com . To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.comgoogle-web-toolkit%2Bunsubs cr...@googlegroups.com . For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en. -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.comgoogle-web-toolkit%2Bunsubs cr...@googlegroups.com . For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en. -- Christian Goudreau www.arcbees.com -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.comgoogle-web-toolkit%2Bunsubs cr...@googlegroups.com . For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en. -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en. -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en. -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
Re: Nested Layout Issues
In general, the *LayoutPanels need one of the LayoutPanels as their parents because of the absolute positioning CSS magic GWT is doing to make the layouts work. You can switch to using one of the LayoutPanels as a parent; set a height value for the StackLayoutPanel in your code (which is obviously inflexible and doesn't change based on how many things you have in your panel, so that generally doesn't work); override the position: absolute on the element and make it position: relative so that it will expand fluidly (which is a bit hacky for my taste and might need to be touched with new versions of GWT); or you can extend the StackLayoutPanel and override the display/create your own widget. You might also be able to extend SimplePanel and add whatever size handling is needed for StackLayoutPanel. I haven't explored that avenue, but the best place to start would be to look at the code for GWT's built-in LayoutPanels and see what they're doing. On Oct 5, 10:33 am, Chris Boldon cbol...@gmail.com wrote: I'm creating an application with a view based upon the DockLayoutPanel. I initialize a DockLayoutPanel and add SimplePanels to the north, south, west, and center docks so I can pass them to the Presenters. The presenter then adds a custom widget to the to the SimplePanel. The custom widget contains a StackLayoutPanel (think left stackpanel navigation like gmail). The issue is the stack isn't displaying correctly, I'm only seeing the first stack in the panel. If I add the custom widget directly to the DockLayoutPanel without first adding a SimplePanel, it works fine. But this would mess up my MVP coupling. Any help is appreciated. -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
Re: GWT Module Dependency
These go to your module file. http://code.google.com/webtoolkit/doc/latest/DevGuideOrganizingProjects.html#DevGuideModuleXml On Oct 4, 3:34 pm, Yudji guilhermeyu...@hotmail.com wrote: I was read the articlehttp://code.google.com/p/gwt-comet/wiki/GettingStarted and where in the project I put inherits name=net.zschech.gwt.comet.Comet / ? and add-linker name=xs/ anywhere in the xml? thanks -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
GWT Designer for Eclipse 3.6 - Install Fails
I have tried w/ Eclipse 3.6; 3.6sr1; for J2EE RCP. With and without GWT Eclipse Plugin installed prior (GEP install succeeds). Problem Occurred message w/ 3.6sr1 for RCP is... - An error occurred while collecting items to be installed session context was:(profile=epp.package.rcp, phase=org.eclipse.equinox.internal.p2.engine.phases.Collect, operand=, action=). Problems downloading artifact: osgi.bundle,com.instantiations.designer.gwt.doc.user, 8.0.0.r36x201009160831. Downloaded stream not a valid archive. Check the server. Problems downloading artifact: osgi.bundle,com.instantiations.eclipse.ui,8.0.0.r36x201009131432. Downloaded stream not a valid archive. Check the server. Problems downloading artifact: osgi.bundle,com.instantiations.j2ee, 8.0.0.r36x201009140724. Downloaded stream not a valid archive. Check the server. --- Please advise, thanks. -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
Calling java from external javascript
Hi, I'm currently trying to call a java method from a javascript that lives outside of the generated javascript from GWT. What I want to do is the following : make the gwt component communicates with a javascript component (in both ways). I have to say that I don't know at all javascript.. The problem I encounter is the following : * call to javascript method (generated by GWT) from my handwritten javascript does not work : firebug says : $wnd does not exist. I thought this variable was always existing in javascript but this assumption is may be false. I think it is quite basic (probably a problem of understanding in javascript). I have read the following (this is where I found most of the code for doing the stuff) : http://www.gwtapps.com/doc/html/com.google.gwt.doc.DeveloperGuide.JavaScriptNativeInterface.JavaFromJavaScript.html plus others (like http://www.mail-archive.com/google-web-toolkit@googlegroups.com/msg38714.html) but I'm stuck there. Here the very basic code to test the feature : The GWT Component package test.app.client; import com.google.gwt.core.client.EntryPoint; import com.google.gwt.dom.client.DivElement; import com.google.gwt.dom.client.Document; import com.google.gwt.event.dom.client.ClickEvent; import com.google.gwt.event.dom.client.ClickHandler; import com.google.gwt.user.client.ui.Button; import com.google.gwt.user.client.ui.DialogBox; import com.google.gwt.user.client.ui.HTML; import com.google.gwt.user.client.ui.RootPanel; import com.google.gwt.user.client.ui.VerticalPanel; import com.google.gwt.user.client.ui.Widget; /** * Entry point classes define codeonModuleLoad()/code. */ public class GwtAndJavascript implements EntryPoint { JsButton jsButton; public void onModuleLoad() { final Button gwtButton = new Button(Add item to JS !); final VerticalPanel panel = new VerticalPanel(); panel.add(gwtButton); RootPanel.get(sendButtonContainer).add(panel); MyUtilityClass.exportStaticMethod(); final ClickHandler handler = new ClickHandler() { public void onClick(ClickEvent event) { jsButton.callSayHello(User); } }; gwtButton.addClickHandler(handler); // Now I want to add javascript button that lives in a js script... jsButton = new JsButton(); panel.add(jsButton); } private class JsButton extends Widget { public JsButton() { DivElement element = Document.get().createDivElement(); makeMyGraphicalObject(element); setElement(element); } private native void makeMyGraphicalObject(DivElement element) /*-{ $wnd.createButton(element); }-*/; public native void callSayHello(String name) /*-{ $wnd.javascriptSayHello(name); }-*/; } } === The class that should help to trigger the java method from javascript === package test.app.client; import com.google.gwt.user.client.Window; public class MyUtilityClass { public static void sayHello() { Window.alert(Say Hello !); } public static native void exportStaticMethod() /*-{ $wnd.sayHello = @test.app.client.MyUtilityClass::sayHello(); }-*/; } The HTML page html head meta http-equiv=content-type content=text/html; charset=UTF-8 !-- -- !-- Consider inlining CSS to reduce the number of requested files -- !-- -- link type=text/css rel=stylesheet href=GwtAndJavascript.css !-- -- !-- Any title is fine -- !-- -- titleWeb Application Starter Project/title !-- -- !-- This script loads your compiled module. -- !-- If you add any GWT meta tags, they must -- !-- be added before this line.-- !-- -- script type=text/javascript language=javascript src=gwtandjavascript/gwtandjavascript.nocache.js/script script type=text/javascript language=javascript src=button.js/script /head !-- -- !-- The body can have arbitrary html, or -- !-- you can leave the body empty if you want -- !-- to create a completely dynamic UI.-- !-- -- body !-- OPTIONAL: include this if you want history support -- iframe src=javascript:'' id=__gwt_historyFrame tabIndex='-1' style=position:absolute;width:0;height:0;border:0/iframe !-- RECOMMENDED if your web app will not function without JavaScript enabled -- noscript div style=width: 22em; position: absolute; left: 50%; margin-left: -11em; color: red; background-color: white; border: 1px solid
Re: Calling java from external javascript
Sorry for the javascript : there is a mistake : variable name is not buttonnode but button at return step of the method... Anyway the problem still stands ;-) Boris 2010/10/5 Boris Lenzinger boris.lenzin...@gmail.com Hi, I'm currently trying to call a java method from a javascript that lives outside of the generated javascript from GWT. What I want to do is the following : make the gwt component communicates with a javascript component (in both ways). I have to say that I don't know at all javascript.. The problem I encounter is the following : * call to javascript method (generated by GWT) from my handwritten javascript does not work : firebug says : $wnd does not exist. I thought this variable was always existing in javascript but this assumption is may be false. I think it is quite basic (probably a problem of understanding in javascript). I have read the following (this is where I found most of the code for doing the stuff) : http://www.gwtapps.com/doc/html/com.google.gwt.doc.DeveloperGuide.JavaScriptNativeInterface.JavaFromJavaScript.html plus others (like http://www.mail-archive.com/google-web-toolkit@googlegroups.com/msg38714.html) but I'm stuck there. Here the very basic code to test the feature : The GWT Component package test.app.client; import com.google.gwt.core.client.EntryPoint; import com.google.gwt.dom.client.DivElement; import com.google.gwt.dom.client.Document; import com.google.gwt.event.dom.client.ClickEvent; import com.google.gwt.event.dom.client.ClickHandler; import com.google.gwt.user.client.ui.Button; import com.google.gwt.user.client.ui.DialogBox; import com.google.gwt.user.client.ui.HTML; import com.google.gwt.user.client.ui.RootPanel; import com.google.gwt.user.client.ui.VerticalPanel; import com.google.gwt.user.client.ui.Widget; /** * Entry point classes define codeonModuleLoad()/code. */ public class GwtAndJavascript implements EntryPoint { JsButton jsButton; public void onModuleLoad() { final Button gwtButton = new Button(Add item to JS !); final VerticalPanel panel = new VerticalPanel(); panel.add(gwtButton); RootPanel.get(sendButtonContainer).add(panel); MyUtilityClass.exportStaticMethod(); final ClickHandler handler = new ClickHandler() { public void onClick(ClickEvent event) { jsButton.callSayHello(User); } }; gwtButton.addClickHandler(handler); // Now I want to add javascript button that lives in a js script... jsButton = new JsButton(); panel.add(jsButton); } private class JsButton extends Widget { public JsButton() { DivElement element = Document.get().createDivElement(); makeMyGraphicalObject(element); setElement(element); } private native void makeMyGraphicalObject(DivElement element) /*-{ $wnd.createButton(element); }-*/; public native void callSayHello(String name) /*-{ $wnd.javascriptSayHello(name); }-*/; } } === The class that should help to trigger the java method from javascript === package test.app.client; import com.google.gwt.user.client.Window; public class MyUtilityClass { public static void sayHello() { Window.alert(Say Hello !); } public static native void exportStaticMethod() /*-{ $wnd.sayHello = @test.app.client.MyUtilityClass::sayHello(); }-*/; } The HTML page html head meta http-equiv=content-type content=text/html; charset=UTF-8 !-- -- !-- Consider inlining CSS to reduce the number of requested files -- !-- -- link type=text/css rel=stylesheet href=GwtAndJavascript.css !-- -- !-- Any title is fine -- !-- -- titleWeb Application Starter Project/title !-- -- !-- This script loads your compiled module. -- !-- If you add any GWT meta tags, they must -- !-- be added before this line.-- !-- -- script type=text/javascript language=javascript src=gwtandjavascript/gwtandjavascript.nocache.js/script script type=text/javascript language=javascript src=button.js/script /head !-- -- !-- The body can have arbitrary html, or -- !-- you can leave the body empty if you want -- !-- to create a completely dynamic UI.-- !-- -- body !-- OPTIONAL: include this if you want history support -- iframe
Re: Wrapping elements, preventing leaks, attach, detach
Just got rid of all remaining wrapped elements where I was calling onAttach directly. It's a different case than before... Have a few pages of static html where I just come in to attach a ClickHandler to a few divs. I was doing the DOM traversal, then wrapping an element, adding my click hander, and calling attach. Now, I'm using the RootPanel.get, traversing the widgets for a particular id, casting to a FocusWidget, and adding my handler. Works great, and no more onAttach direct calls. Gotta think this helps memory leaks somewhere. On Oct 5, 12:13 pm, Flan Brody flannanbr...@gmail.com wrote: good to know that the excellent chapter in GWT in A on event handling is still more or less relevant with 2.1. Thanks Thomas On Tue, Oct 5, 2010 at 9:06 AM, Thomas Broyer t.bro...@gmail.com wrote: On Oct 5, 4:40 pm, Flan Brody flannanbr...@gmail.com wrote: Hi GWT in Action has an excellent chapter about Event Handling. It's an old book, probably 2007 and GWT 1.6 but as far as I can tell from looking at the 2.1.M3 API (*com.google.gwt.user.client.ui.Widget) *alot of this hasn't changed much, if at all I read somewhere that in 2.0 Listeners became handlers,* That was GWT 1.6 actually. Listeners are deprecated since then. The original plan was to remove them in 2.0 but they're finally still there, and will probably last a bit of time (there's also an history in GWT that nothing had ever been removed...) Does any know how much the event handling has changed since 1.6?* It hasn't. It might change a bit in a future release (was initially planned for 2.1 but won't do it) but onyl at a lower level. The com.google.gwt.event.* public API won't change any time soon I guess. (note that in 2.1, HandlerManager's internals have changed, but again, it's low-level, so it's probably only relevant to 0.1% GWT users) -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.comgoogle-web-toolkit%2Bunsubs cr...@googlegroups.com . For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en. -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
Implementing @OneToMany in a GWT Record subclass
An Entity class participates in one-to-many relationship: @OneToMany private SetSomeClass someClass = new HashSetSomeClass(); How would I implement an EntityRecord? PropertyXXX someClass = new PropertyXXX(someClass, SomeClass.class); abstract XXXSomeClassRecord getSomeClass(); What should go instead of XXX above? I tried looking at what Roo does but it fails to generate correct records for one-to-many relationships. Would really appreciate your help! Thanks, Yuri -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
Re: New GWT 2.0 Book
Just to clarify, I donated my time to submit a few chapters and to review some of the other content that is going into the book. And yes, you read that right...I donated my time. We don't accept royalties at Google. I can't comment on the amount of 2.1 content in the book, but I can say definitively that the GWT team is in the process of wrapping up documentation on: - Cell-based widgets - RequestFactory - Activities and Places -- Chris On Oct 1, 1:38 pm, Tommy Lui tlui1...@gmail.com wrote: Hi, Please help me understand why Chris Ramsdale (Google's Developer Relations team to develop and advocate GWT best practices.) is writting a book about GWT 2.1 when he works at Google on the GWT team and there's no official documentation, except for a few waves available to the developer community. Is this some way for him to force developers to buy his book? http://www.manning.com/bambury/ The book is due to be release in 2011, so I'm sure it's GWT 2.1 not GWT 2.0 content. I'm hoping that I'm not the only person really pissed off about this. I'd really like other peoples opinions on this topic -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
Re: New GWT 2.0 Book
Chris, Nice to hear from you. Really appreciate your articles on MVP. Please elaborate more on GWT 2.1 MVP support in your book. Thanks, Yuri On Oct 5, 10:19 am, Chris Ramsdale cramsd...@google.com wrote: Just to clarify, I donated my time to submit a few chapters and to review some of the other content that is going into the book. And yes, you read that right...I donated my time. We don't accept royalties at Google. I can't comment on the amount of 2.1 content in the book, but I can say definitively that the GWT team is in the process of wrapping up documentation on: - Cell-based widgets - RequestFactory - Activities and Places -- Chris On Oct 1, 1:38 pm, Tommy Lui tlui1...@gmail.com wrote: Hi, Please help me understand why Chris Ramsdale (Google's Developer Relations team to develop and advocate GWT best practices.) is writting a book about GWT 2.1 when he works at Google on the GWT team and there's no official documentation, except for a few waves available to the developer community. Is this some way for him to force developers to buy his book? http://www.manning.com/bambury/ The book is due to be release in 2011, so I'm sure it's GWT 2.1 not GWT 2.0 content. I'm hoping that I'm not the only person really pissed off about this. I'd really like other peoples opinions on this topic -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
Re: AppEngine Users Service with GWT will always reload page/module upon login
The way the users service work is. A login or logout url is generated by the User Service API. The link with this URL is presented to User. Let say to login, User will click the login url and it will redirect to login page. I did not create this login page. If using Google, it is google login page. If using Yahoo as the Open ID provider, then it is Yahoo page. Perhaps this the reason for the reload. Because, after a successful login. My page or app is reloaded by the login page from Google or the open ID provider? However it is still frustrating. On Oct 5, 8:43 pm, George Georgovassilis g.georgovassi...@gmail.com wrote: HelloHaris, Not sure if I understand your problem, so I'll rephrase it: You have a GWT page with a Form element and a submit button. When the submit button is clicked, the page is reloaded. Question: Do you programmatically construct the form or does it exist in the static html? The reason for the reload is likely that GWT does not consume the submit event. To get started, you must use a button element, since input type=submit will cause the form to be mercilessly submitted. Also, you need to register a clickHandler on that button, otherwise the form will be submitted again with Internet Explorer. On Oct 3, 12:31 pm,Harisharishas...@gmail.com wrote: Using Users Service, after filling up login and password and press OK, onModuleLoad is executed. Basically the gwt module is reloaded. I am going to loose data entry stuff form the user. For instant if someone is typing a forum post and click submit only to discover that login already timeout. The person relogin using User API login page only to discover that the text typed is lost because of this. Any suggestion? Regards, Haris -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
Re: AppEngine Users Service with GWT will always reload page/module upon login
As per your reply: - do the login in a popup window, with your redirect_to URL signaling the opening window (your app) that the user is successfully logged in This is what I want to do. Just that I do not know how to do it. Perhaps I will figure this out eventually. Will be great if you can show me in the right direction. Thanks Regards, Haris On Oct 5, 9:12 pm, Thomas Broyer t.bro...@gmail.com wrote: On Oct 3, 12:31 pm,Harisharishas...@gmail.com wrote: Using Users Service, after filling up login and password and press OK, onModuleLoad is executed. Basically the gwt module is reloaded. I am going to loose data entry stuff form the user. For instant if someone is typing a forum post and click submit only to discover that login already timeout. The person relogin using User API login page only to discover that the text typed is lost because of this. Any suggestion? AFAICT it really depends how you're wiring GAE authentication within your app. I'm not very familiar with GAE auth but it seems to me you should be able to either: - signal to the user their session expired, without redirecting to the login page (GMail is doing this, at least when offline is enabled; if I was typing a message, then I just open a new tab/window, log in, and then continue in GMail: sessions are based on a cookie, so the next call to the server will contain the updated cookie generated in the other tab/window) - do the login in a popup window, with your redirect_to URL signaling the opening window (your app) that the user is successfully logged in (so you can retry the RPC call / form submission) before closing itself. And of course you could combine both for a great UX! -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
Re: AppEngine Users Service with GWT will always reload page/module upon login
A good idea. However there bound to be user who type very long message and time out. On Oct 5, 7:56 pm, Shedokan shedok...@gmail.com wrote: Maybe instead try asking the person to login before enabling him the option to write a message? On Oct 3, 12:31 pm,Harisharishas...@gmail.com wrote: Using Users Service, after filling up login and password and press OK, onModuleLoad is executed. Basically the gwt module is reloaded. I am going to loose data entry stuff form the user. For instant if someone is typing a forum post and click submit only to discover that login already timeout. The person relogin using User API login page only to discover that the text typed is lost because of this. Any suggestion? Regards, Haris -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
Re: New GWT 2.0 Book
Thanks, it's not my book though. The vast majority of the book is being written by Robert Hanson and Adam Tracy (the original authors of GWT In Action). On Oct 5, 2:06 pm, Y2i yur...@gmail.com wrote: Chris, Nice to hear from you. Really appreciate your articles on MVP. Please elaborate more on GWT 2.1 MVP support in your book. Thanks, Yuri On Oct 5, 10:19 am, Chris Ramsdale cramsd...@google.com wrote: Just to clarify, I donated my time to submit a few chapters and to review some of the other content that is going into the book. And yes, you read that right...I donated my time. We don't accept royalties at Google. I can't comment on the amount of 2.1 content in the book, but I can say definitively that the GWT team is in the process of wrapping up documentation on: - Cell-based widgets - RequestFactory - Activities and Places -- Chris On Oct 1, 1:38 pm, Tommy Lui tlui1...@gmail.com wrote: Hi, Please help me understand why Chris Ramsdale (Google's Developer Relations team to develop and advocate GWT best practices.) is writting a book about GWT 2.1 when he works at Google on the GWT team and there's no official documentation, except for a few waves available to the developer community. Is this some way for him to force developers to buy his book? http://www.manning.com/bambury/ The book is due to be release in 2011, so I'm sure it's GWT 2.1 not GWT 2.0 content. I'm hoping that I'm not the only person really pissed off about this. I'd really like other peoples opinions on this topic -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
GWT + GAE StockWatcher tutorial still has issues
I've been following the GWT Tutorial - Google App Engine and following the Eclipse instructions. I downloaded and imported the StockWatcher project from http://code.google.com/webtoolkit/doc/latest/tutorial/projects/GettingStartedAppEngine.zip. Once I got to the point of testing the UserService features I ran into problems with the build path. There were warnings about gwt- servlet.jar not being the right size, as well as warnings about the wrong version of a few GAE libraries. The error in the log was quite confusing, I've lost it now that its fixed, but it was an RPC issue with the wrong version of String class. Googling this pointed out that the gwt-servlet.jar might be the issue, and upon further research I found the following link that had the solution: http://code.google.com/p/google-web-toolkit/issues/detail?id=3626 I had to Remove and re-add the GWT and GAE Libraries in the build path, as well as clicking on the 'Configure SDK' link. That appeared to put the correct jars and versions in WEB-INF/lib, and it worked. Just FYI in case anyone else has this problem. I'm using Eclipse 3.4, GWT 2.0.4, and GAE 1.3.5 on Windows 7. -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
Re: New GWT 2.0 Book
While we've got your ear Chris, are we also likely to see documentation on scaffolding with Roo as well, or is that remaining within the purview of the Springsource team? On Oct 6, 7:38 am, Chris Ramsdale cramsd...@google.com wrote: Thanks, it's not my book though. The vast majority of the book is being written by Robert Hanson and Adam Tracy (the original authors of GWT In Action). On Oct 5, 2:06 pm, Y2i yur...@gmail.com wrote: Chris, Nice to hear from you. Really appreciate your articles on MVP. Please elaborate more on GWT 2.1 MVP support in your book. Thanks, Yuri On Oct 5, 10:19 am, Chris Ramsdale cramsd...@google.com wrote: Just to clarify, I donated my time to submit a few chapters and to review some of the other content that is going into the book. And yes, you read that right...I donated my time. We don't accept royalties at Google. I can't comment on the amount of 2.1 content in the book, but I can say definitively that the GWT team is in the process of wrapping up documentation on: - Cell-based widgets - RequestFactory - Activities and Places -- Chris On Oct 1, 1:38 pm, Tommy Lui tlui1...@gmail.com wrote: Hi, Please help me understand why Chris Ramsdale (Google's Developer Relations team to develop and advocate GWT best practices.) is writting a book about GWT 2.1 when he works at Google on the GWT team and there's no official documentation, except for a few waves available to the developer community. Is this some way for him to force developers to buy his book? http://www.manning.com/bambury/ The book is due to be release in 2011, so I'm sure it's GWT 2.1 not GWT 2.0 content. I'm hoping that I'm not the only person really pissed off about this. I'd really like other peoples opinions on this topic -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
Trouble in using jboss with GWT in dev mode ([ERROR] Unable to find 'xxxx.gwt.xml' on your classpath; could be a typo, or maybe you forgot to include a classpath entry for source?)
Gurus: GWT newbie here, need help. I have a J2EE app (has web and MDB components) that I am developing using JBoss as the app server. We decided to use GWT as a piece in our frontend technology. I am having trouble setting up the project such that I can run the app in dev mode. I have a GWT module inside a file named PreCalcAdjustment.gwt.xml, and inside the module, I am doing something like this: module rename-to='' Now, the application is deployed on JBoss as a ear file (NOT expanded), and the results of gwtcompile lie inside BaseProjectDirInEclipse/gwtcompile folder. Just FYI, the root folder name inside is the same as module name, which is . I have setup the eclipse run config to use the -noserver option, and I have included BaseProjectDirInEclipse/gwtcompile in the classpath of the run configuration. But when I try to run the app in Dev mode, I get an error on the dev console saying 00:28:46.862 [ERROR] Unable to find '.gwt.xml' on your classpath; could be a typo, or maybe you forgot to include a classpath entry for source? 00:28:46.862 [ERROR] Failed to load module 'basel2ui' from user agent 'Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9.2.10) Gecko/ 20100914 Firefox/3.6.10' at localhost:3830 What baffles me is why is it complaining about .gwt.xml, when that file does not even exist. the name of the file that contains my module is PreCalcAdjustment.gwt.xml, and inside it I havbe renamed the module to ''. Like I said, I am making sure that the gwt compiled source is in the classpath. Please help!!! Thanks in advance! -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
Re: Need help with [ERROR] Annotation error: while doing GWT compile
You are right sir, absolutely! I had not compiled the code (^%$), I know :-). Thank you for helping out! Regards Sanjeev -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
Resolution specific size of panels / widgets
Hi All, I have one complex UI binder file. The xml file is attached here. The problem is that it appears as fixed size layout on all system resolution / all sizes of monitors. So it does not look good on high resolution. I want that the panels and widgets inside it should automaticall be adjusted/resize according to the screen/monitor size so that it should look good on all kinds of monitor size/resolution. Kindly someone pl guide me how to acheive this. -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en. !DOCTYPE ui:UiBinder SYSTEM http://dl.google.com/gwt/DTD/xhtml.ent; ui:UiBinder xmlns:ui=urn:ui:com.google.gwt.uibinder xmlns:g=urn:import:com.google.gwt.user.client.ui ui:style /* Add CSS here. See the GWT docs on UI Binder for more details */ body{ background:url(images/index.png) repeat-x scroll 0 0 #D8DCE0; bottom:0; left:0; margin:0; overflow:hidden; position:absolute; right:0; top:0; } .important { font-weight: bold; } .verticalLabel { overflow:scroll; } .headerLabel{ box-shadow: 5px 5px 5px #ccc; -moz-box-shadow: 5px 5px 5px #ccc; -webkit-box-shadow: 5px 5px 5px #ccc; -moz-border-radius-topleft:10px; -moz-border-radius-topright:10px; border-top-left-radius: 10px 10px; border-top-right-radius: 10px 10px; background-color:#5590D2; background-image:-moz-linear-gradient(center top , #61A7F2, #5590D2); border-left:1px solid #86B7ED; left:50px; position:absolute; padding-top: 8px; font-weight: bold; font-size: 13px; overflow: hidden; padding-left: 8px; color:white; cursor:default; margin:6px 0px 0 7px; } .headerLabel1{ box-shadow: 8px 8px 8px #ccc; -moz-box-shadow: 5px 5px 5px #ccc; -webkit-box-shadow: 5px 5px 5px #ccc; -moz-border-radius-topleft:10px; -moz-border-radius-topright:10px; background-color:#5590D2; background-image:-moz-linear-gradient(center top , #61A7F2, #5590D2); border-left:1px solid #86B7ED; left:332px; position:absolute; padding-top: 8px; font-weight: bold; font-size: 13px; overflow: hidden; padding-left: 8px; color:white; cursor:default; margin:6px 0px 0 9px; } .headerLabel2{ box-shadow: 8px 8px 8px #ccc; -moz-box-shadow: 5px 5px 5px #ccc; -webkit-box-shadow: 5px 5px 5px #ccc; -moz-border-radius-topleft:10px; -moz-border-radius-topright:10px; border-top-left-radius: 10px 10px; border-top-right-radius: 10px 10px; background-color:#5590D2; background-image:-moz-linear-gradient(center top , #61A7F2, #5590D2); border-left:1px solid #86B7ED; left:248px; position:absolute; padding-top: 8px; font-weight: bold; font-size: 13px; overflow: hidden; padding-left: 5px; color:white; cursor:default; margin:6px 0px 0 9px; } .simplePane{ box-shadow: 5px 5px 5px #ccc; -moz-box-shadow: 5px 5px 5px #ccc; -webkit-box-shadow: 5px 5px 5px #ccc; background-color: white; left:50px; overflow:auto;height:500px; position:absolute; top:27px; margin:6px 0px 0 7px; border-bottom:2px solid #C9E2FC; } .simplePane2{ box-shadow: 5px 5px 5px #ccc; -moz-box-shadow: 5px 5px 5px #ccc; -webkit-box-shadow: 5px 5px 5px #ccc; background-color: white; left:-150px; overflow:visible;height:500px; position:absolute; top:27px; margin:6px 0px 0 7px; } .resize-bar{} .buttonPanel{ background-color:#C9E2FC; background-image:none; border-left:1px solid #E4F1FE; padding:12px 5px 12px 5px; } .bottomPanel{ background-color:#C9E2FC; background-image:none; margin-top:168px;position:absolute; -moz-border-radius-topleft:10px; -moz-border-radius-topright:10px; border-top-left-radius: 10px 10px; border-top-right-radius: 10px 10px; } .bottomPanel2{ background-color:#C9E2FC; background-image:none; margin-top:416px;position:absolute; -moz-border-radius-topleft:10px; -moz-border-radius-topright:10px; border-top-left-radius: 10px 10px; border-top-right-radius: 10px 10px; } .slider{ margin-left: 50px; } .label{ margin-top: 25px; text-align: center; font-size: small; font-weight: bold; } .lblBus{ margin-top: 20px; margin-right: 10px; text-align: center; font-size: small; font-weight: bold; } .image{ margin-top: 2px; } .busType{ padding: 20px; } .searchBox{ width: 425px; } /ui:style g:AbsolutePanel g:VerticalPanel g:HorizontalPanel width=800px g:HTMLPanel table tr td img src=images/logo2.png
Re: Calling java from external javascript
if you are in javascript its not $wnd its just window :) 2010/10/5 Boris Lenzinger boris.lenzin...@gmail.com Sorry for the javascript : there is a mistake : variable name is not buttonnode but button at return step of the method... Anyway the problem still stands ;-) Boris 2010/10/5 Boris Lenzinger boris.lenzin...@gmail.com Hi, I'm currently trying to call a java method from a javascript that lives outside of the generated javascript from GWT. What I want to do is the following : make the gwt component communicates with a javascript component (in both ways). I have to say that I don't know at all javascript.. The problem I encounter is the following : * call to javascript method (generated by GWT) from my handwritten javascript does not work : firebug says : $wnd does not exist. I thought this variable was always existing in javascript but this assumption is may be false. I think it is quite basic (probably a problem of understanding in javascript). I have read the following (this is where I found most of the code for doing the stuff) : http://www.gwtapps.com/doc/html/com.google.gwt.doc.DeveloperGuide.JavaScriptNativeInterface.JavaFromJavaScript.html plus others (like http://www.mail-archive.com/google-web-toolkit@googlegroups.com/msg38714.html) but I'm stuck there. Here the very basic code to test the feature : The GWT Component package test.app.client; import com.google.gwt.core.client.EntryPoint; import com.google.gwt.dom.client.DivElement; import com.google.gwt.dom.client.Document; import com.google.gwt.event.dom.client.ClickEvent; import com.google.gwt.event.dom.client.ClickHandler; import com.google.gwt.user.client.ui.Button; import com.google.gwt.user.client.ui.DialogBox; import com.google.gwt.user.client.ui.HTML; import com.google.gwt.user.client.ui.RootPanel; import com.google.gwt.user.client.ui.VerticalPanel; import com.google.gwt.user.client.ui.Widget; /** * Entry point classes define codeonModuleLoad()/code. */ public class GwtAndJavascript implements EntryPoint { JsButton jsButton; public void onModuleLoad() { final Button gwtButton = new Button(Add item to JS !); final VerticalPanel panel = new VerticalPanel(); panel.add(gwtButton); RootPanel.get(sendButtonContainer).add(panel); MyUtilityClass.exportStaticMethod(); final ClickHandler handler = new ClickHandler() { public void onClick(ClickEvent event) { jsButton.callSayHello(User); } }; gwtButton.addClickHandler(handler); // Now I want to add javascript button that lives in a js script... jsButton = new JsButton(); panel.add(jsButton); } private class JsButton extends Widget { public JsButton() { DivElement element = Document.get().createDivElement(); makeMyGraphicalObject(element); setElement(element); } private native void makeMyGraphicalObject(DivElement element) /*-{ $wnd.createButton(element); }-*/; public native void callSayHello(String name) /*-{ $wnd.javascriptSayHello(name); }-*/; } } === The class that should help to trigger the java method from javascript === package test.app.client; import com.google.gwt.user.client.Window; public class MyUtilityClass { public static void sayHello() { Window.alert(Say Hello !); } public static native void exportStaticMethod() /*-{ $wnd.sayHello = @test.app.client.MyUtilityClass::sayHello(); }-*/; } The HTML page html head meta http-equiv=content-type content=text/html; charset=UTF-8 !-- -- !-- Consider inlining CSS to reduce the number of requested files -- !-- -- link type=text/css rel=stylesheet href=GwtAndJavascript.css !-- -- !-- Any title is fine -- !-- -- titleWeb Application Starter Project/title !-- -- !-- This script loads your compiled module. -- !-- If you add any GWT meta tags, they must -- !-- be added before this line.-- !-- -- script type=text/javascript language=javascript src=gwtandjavascript/gwtandjavascript.nocache.js/script script type=text/javascript language=javascript src=button.js/script /head !-- -- !-- The body can have arbitrary html, or -- !-- you can leave the body empty if you want -- !-- to create a completely dynamic UI.-- !--
Re: Calling java from external javascript
I think Boris is correct by using $wnd. I also call my javascript library functions from a native method through $wnd, as described here: http://googlewebtoolkit.blogspot.com/2008/07/getting-to-really-know-gwt-part-1-jsni.html Boris' example seems complicated. At the beginning I would simply create a javascript function that calls alert: function sayHello(name) { alert(Hello from JavaScript, + name); } and a native method in my Entry Point class: native void sayHelloInJava(String name) /*-{ $wnd.sayHello(name); }-*/; (this is exactly as shown in the reference above) I use exactly the same approach, except instead of using HTML file I place my JS library into a public folder and use script src='lib.js'/ in my module. This technique is described here: http://code.google.com/webtoolkit/doc/latest/DevGuideOrganizingProjects.html#DevGuideModules Once this worked I would move further. On Oct 5, 2:33 pm, Daniel Kurka kurka.dan...@googlemail.com wrote: if you are in javascript its not $wnd its just window :) 2010/10/5 Boris Lenzinger boris.lenzin...@gmail.com Sorry for the javascript : there is a mistake : variable name is not buttonnode but button at return step of the method... Anyway the problem still stands ;-) Boris 2010/10/5 Boris Lenzinger boris.lenzin...@gmail.com Hi, I'm currently trying to call a java method from a javascript that lives outside of the generated javascript from GWT. What I want to do is the following : make the gwt component communicates with a javascript component (in both ways). I have to say that I don't know at all javascript.. The problem I encounter is the following : * call to javascript method (generated by GWT) from my handwritten javascript does not work : firebug says : $wnd does not exist. I thought this variable was always existing in javascript but this assumption is may be false. I think it is quite basic (probably a problem of understanding in javascript). I have read the following (this is where I found most of the code for doing the stuff) : http://www.gwtapps.com/doc/html/com.google.gwt.doc.DeveloperGuide.Jav... plus others (like http://www.mail-archive.com/google-web-toolkit@googlegroups.com/msg38...) but I'm stuck there. Here the very basic code to test the feature : The GWT Component package test.app.client; import com.google.gwt.core.client.EntryPoint; import com.google.gwt.dom.client.DivElement; import com.google.gwt.dom.client.Document; import com.google.gwt.event.dom.client.ClickEvent; import com.google.gwt.event.dom.client.ClickHandler; import com.google.gwt.user.client.ui.Button; import com.google.gwt.user.client.ui.DialogBox; import com.google.gwt.user.client.ui.HTML; import com.google.gwt.user.client.ui.RootPanel; import com.google.gwt.user.client.ui.VerticalPanel; import com.google.gwt.user.client.ui.Widget; /** * Entry point classes define codeonModuleLoad()/code. */ public class GwtAndJavascript implements EntryPoint { JsButton jsButton; public void onModuleLoad() { final Button gwtButton = new Button(Add item to JS !); final VerticalPanel panel = new VerticalPanel(); panel.add(gwtButton); RootPanel.get(sendButtonContainer).add(panel); MyUtilityClass.exportStaticMethod(); final ClickHandler handler = new ClickHandler() { public void onClick(ClickEvent event) { jsButton.callSayHello(User); } }; gwtButton.addClickHandler(handler); // Now I want to add javascript button that lives in a js script... jsButton = new JsButton(); panel.add(jsButton); } private class JsButton extends Widget { public JsButton() { DivElement element = Document.get().createDivElement(); makeMyGraphicalObject(element); setElement(element); } private native void makeMyGraphicalObject(DivElement element) /*-{ $wnd.createButton(element); }-*/; public native void callSayHello(String name) /*-{ $wnd.javascriptSayHello(name); }-*/; } } === The class that should help to trigger the java method from javascript === package test.app.client; import com.google.gwt.user.client.Window; public class MyUtilityClass { public static void sayHello() { Window.alert(Say Hello !); } public static native void exportStaticMethod() /*-{ $wnd.sayHello = @test.app.client.MyUtilityClass::sayHello(); }-*/; } The HTML page html head meta http-equiv=content-type content=text/html; charset=UTF-8 !-- -- !-- Consider inlining CSS to reduce the number of requested files -- !--
Re: Resolution specific size of panels / widgets
On 5 oct, 23:02, Deepak Singh deepaksingh...@gmail.com wrote: Hi All, I have one complex UI binder file. The xml file is attached here. The problem is that it appears as fixed size layout on all system resolution / all sizes of monitors. So it does not look good on high resolution. I want that the panels and widgets inside it should automaticall be adjusted/resize according to the screen/monitor size so that it should look good on all kinds of monitor size/resolution. OMG, tables all the way down! Kindly someone pl guide me how to acheive this. Really? I think you should try LayoutPanel and/or DockLayoutPanel (will be much more readable and maintainable!), and try using % or em/ ex units (for fluid/elastic layout). -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
Re: Implementing @OneToMany in a GWT Record subclass
On 5 oct, 18:54, Y2i yur...@gmail.com wrote: An Entity class participates in one-to-many relationship: @OneToMany private SetSomeClass someClass = new HashSetSomeClass(); How would I implement an EntityRecord? PropertyXXX someClass = new PropertyXXX(someClass, SomeClass.class); Hmm, M2? FYI, properties are gone in M3. abstract XXXSomeClassRecord getSomeClass(); What should go instead of XXX above? I tried looking at what Roo does but it fails to generate correct records for one-to-many relationships. Even M3 does not support lists and sets, but trunk does support both java.util.List and java.util.Set; it'll be in the upcoming RC1. -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
Re: Implementing @OneToMany in a GWT Record subclass
Thanks for the reply Thomas. Properties are still there in M3, and Roo still generates them. May be they are gone in M4? Or simply they are not necessary in M3. I'll try to get rid of them. Regarding one-to-many: for now I use many-to-one and service methods to retrieve collections. Will be looking forward to RC1's support of one-to-many. Yuri On Oct 5, 3:23 pm, Thomas Broyer t.bro...@gmail.com wrote: On 5 oct, 18:54, Y2i yur...@gmail.com wrote: An Entity class participates in one-to-many relationship: @OneToMany private SetSomeClass someClass = new HashSetSomeClass(); How would I implement an EntityRecord? PropertyXXX someClass = new PropertyXXX(someClass, SomeClass.class); Hmm, M2? FYI, properties are gone in M3. abstract XXXSomeClassRecord getSomeClass(); What should go instead of XXX above? I tried looking at what Roo does but it fails to generate correct records for one-to-many relationships. Even M3 does not support lists and sets, but trunk does support both java.util.List and java.util.Set; it'll be in the upcoming RC1. -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
GWT 1.6.4 question
I am working on an app that uses GWT 1.6.4 - I need to override the RemoteServiceProxy stub that gets dynamically created when I call GWT.create(Service) to set a custom header before it fires off the request to the server. I have found a way to do this using BindUI, however, upgrading GWT to 2.0 is not an option in this case. Can anyone think of a *clean* way to do this across a large number of services, without manually making changes to each service or how the services are called? -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
Advice for site design
I'm creating a site which will have a sign up screen, a login system, and then interaction with the site once you login. My question is, can I mix GWT with PHP in a healthy manner? I don't know how well GWT handles client-server interactions. But should I stick to pure GWT for ease and cross browser compatibility, a mix with PHP, or just pure PHP ? Thanks. -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
JSON requests with authorization and cross-site
Hi there, im quite new to GWT and i can not figure this one out... I want to do a JSON request to a server which would normally show me a popup to fill in my username and password. How can i access this with GWT? i tried the request builder and using setPassword and setUser but it doesnt work for me. The statuscode I receive after I make my request is '0' which i think is weird... can anybody help me out with this? -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
Re: Wrapping elements, preventing leaks, attach, detach
Sorry for bothering you with this -- but I just put it on net -- and it's a very very cool tool -- Check it out:http://cool-movie-browser.blogspot.com/ Cheers! PS: if you want more GWT tricks you can find it here: http://ui-programming.blogspot.com/ -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
Re: Advice for site design
I decided to use end-to-end Java solution (GWT, Jetty, and even considering replacing PostgreSQL with Derby), but GWT is also compatible with PHP on the server. http://code.google.com/webtoolkit/doc/latest/tutorial/JSONphp.html I think you can also embed PHP client code for authentication. For example, you can configure JAAS through web.xml's login-config/ and auth-methodFORM/auth-method, and redirect login requests to PHP login pages. I personally re-direct login requests to a GWT module, but it does not matter. On Oct 5, 2:45 pm, nick kov nickko...@gmail.com wrote: I'm creating a site which will have a sign up screen, a login system, and then interaction with the site once you login. My question is, can I mix GWT with PHP in a healthy manner? I don't know how well GWT handles client-server interactions. But should I stick to pure GWT for ease and cross browser compatibility, a mix with PHP, or just pure PHP ? Thanks. -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
Re: JSON requests with authorization and cross-site
If it is basic auth then you should just be able to use JSONP, since it is cross site, if form auth you will need to have them auth before making the request. Remember you can't make cross site requests directly, but JSONP allows you to work around that. Since it is an authenticated request a server-side proxy is not really an option, so you are pretty much stuck with JSONP. On Oct 5, 2:18 pm, Wouter wouterwillem...@gmail.com wrote: Hi there, im quite new to GWT and i can not figure this one out... I want to do a JSON request to a server which would normally show me a popup to fill in my username and password. How can i access this with GWT? i tried the request builder and using setPassword and setUser but it doesnt work for me. The statuscode I receive after I make my request is '0' which i think is weird... can anybody help me out with this? -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
Re: Advice for site design
interesting...thanks! , anybody else have any input? On Oct 5, 7:03 pm, Y2i yur...@gmail.com wrote: I decided to use end-to-end Java solution (GWT, Jetty, and even considering replacing PostgreSQL with Derby), but GWT is also compatible with PHP on the server.http://code.google.com/webtoolkit/doc/latest/tutorial/JSONphp.html I think you can also embed PHP client code for authentication. For example, you can configure JAAS through web.xml's login-config/ and auth-methodFORM/auth-method, and redirect login requests to PHP login pages. I personally re-direct login requests to a GWT module, but it does not matter. On Oct 5, 2:45 pm, nick kov nickko...@gmail.com wrote: I'm creating a site which will have a sign up screen, a login system, and then interaction with the site once you login. My question is, can I mix GWT with PHP in a healthy manner? I don't know how well GWT handles client-server interactions. But should I stick to pure GWT for ease and cross browser compatibility, a mix with PHP, or just pure PHP ? Thanks. -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
how to create PushButton using UiBinder
hi, I tried to create a PushButton(with an image) in UiBinder but could not get it work, here is my code g:PushButton ui:field=myPushButton image=myImage.gif/ anyone know how? thanks. -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
Re: how to create PushButton using UiBinder
May be this will help? http://google-web-toolkit.googlecode.com/svn/javadoc/2.1/com/google/gwt/user/client/ui/CustomButton.html On Oct 5, 5:54 pm, mars marsg...@gmail.com wrote: hi, I tried to create a PushButton(with an image) in UiBinder but could not get it work, here is my code g:PushButton ui:field=myPushButton image=myImage.gif/ anyone know how? thanks. -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
hbm2ddl not working with POJO that implement IsSerializable
I've used GWT on about 10 projects now and it's been great. This project I tried doing things a little differently. Using JPA (Hibernate) and hbm2ddl. Now I'm have a bunch of problems. I think I solved all the problem except for hbm2ddl. When I run it on the POJOs I get a ClassNotFoundException. If I remove IsSerializable then hbm2ddl finds the POJOs. Does anyone know a fix for this or do I have to drop hbm2ddl? Thanks -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
Re: hbm2ddl not working with POJO that implement IsSerializable
I figured it out. I'm using Maven and my GWT dependency looked like this dependency groupIdcom.google.gwt/groupId artifactIdgwt-user/artifactId version${gwt.version}/version scoperuntime/scope /dependency The org.codehaus.mojo.hibernate3-maven-plugin requires the dependency scope to be in test. So I removed the runtime scope and it worked. On Oct 5, 10:14 pm, Ted Malaska ted.mala...@gmail.com wrote: I've used GWT on about 10 projects now and it's been great. This project I tried doing things a little differently. Using JPA (Hibernate) and hbm2ddl. Now I'm have a bunch of problems. I think I solved all the problem except for hbm2ddl. When I run it on the POJOs I get a ClassNotFoundException. If I remove IsSerializable then hbm2ddl finds the POJOs. Does anyone know a fix for this or do I have to drop hbm2ddl? Thanks -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
Comet help about code
I read the comet in http://code.google.com/p/gwt-comet/source/browse/trunk/src/net/zschech/gwt/chat/server/ChatServiceImpl.java?r=98 Can explain to me about the code, because i dont undestand: public void send(String message) throws ChatException { . . . for (Map.EntryString, CometSession entry : users.entrySet()) { entry.getValue().enqueue(chatMessage); } } thaks -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
Comet help about code
I read the comet in http://code.google.com/p/gwt-comet/source/browse/trunk/src/net/zschech/gwt/chat/server/ChatServiceImpl.java?r=98 Can explain to me about the code, because i dont undestand: public void send(String message) throws ChatException { . . . for (Map.EntryString, CometSession entry : users.entrySet()) { entry.getValue().enqueue(chatMessage); } } thaks -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
Re: Help: Development of large App with GWT
Thus, if we resume, GWT helps more in the development phase of software development. The end result is similar to the client as development with any other framework. Is it that? -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
2 Questions: getOffsetHeight ignores margin CssRe source doesn´t include css property
Hi guys, i´ve got 2 questions. I´m using getOffsetHeight to get the height of an Widget. This works fine, but when i adding a css margin to the widget, the css-property seems to be ignored. The doc says: This is the total width of the object, including decorations such as border, margin, and padding. Is this an bug? The next thing i would like to know is, if its possible to use none WC3 valid css-properties like: background: -moz-linear-gradient(top, white 0%, skyblue 75%); inside a ClientBundle, CssResource CssFile. Is there an config property to allow such css? Im using this for an private Project and it would be annoying if this was not possible. Greets from Austria, Six Michael -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
Disable Widgets till File Upload is complete
HI! I am developing a web application in which the user selects several files and submits for file upload in a form. My problem is, I want to disable all the widgets on the form panel till the file Upload is complete. Currently, in my application, when the file upload begins, the user can still click on the widgets and change the field values even after the form is complete. I am using GWT for my application. Can anybody suggest me on how i can achieve disabling widgets and still make the widget accessible on the server side. Please help me Thanking you. Regards, Nitin -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
Re: Disable Widgets till File Upload is complete
disable them in a submit handler and you can re-enable them in a submit complete handler. On Oct 5, 10:57 pm, Nitin nkam...@gmail.com wrote: HI! I am developing a web application in which the user selects several files and submits for file upload in a form. My problem is, I want to disable all the widgets on the form panel till the file Upload is complete. Currently, in my application, when the file upload begins, the user can still click on the widgets and change the field values even after the form is complete. I am using GWT for my application. Can anybody suggest me on how i can achieve disabling widgets and still make the widget accessible on the server side. Please help me Thanking you. Regards, Nitin -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
Re: Advice for site design
I see no reason you would want PHP if you can use GWT. For security use Spring. -Original Message- From: nick kov nickko...@gmail.com Sender: google-web-toolkit@googlegroups.com Date: Tue, 5 Oct 2010 14:45:29 To: Google Web Toolkitgoogle-web-toolkit@googlegroups.com Reply-To: google-web-toolkit@googlegroups.com Subject: Advice for site design I'm creating a site which will have a sign up screen, a login system, and then interaction with the site once you login. My question is, can I mix GWT with PHP in a healthy manner? I don't know how well GWT handles client-server interactions. But should I stick to pure GWT for ease and cross browser compatibility, a mix with PHP, or just pure PHP ? Thanks. -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en. -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
[gwt-contrib] Re: Test timeout in JUnitShell ? (GWT 2.0.0)
Yesterday my test was run with success and last night it failed again, without anything changing in the meantime :( I was digging a bit more in the GWT Junit test code and I think the test fails because I don't use a servlet that is hosted by the Tomcat container started by GWT. Like Freeland mentions above, I have to contact the backend within 60 sec to overcome the timeout exception. I think I have to contact a servlet run in the GWT Tomcat instance as otherwise it's not seen as a backend contact. Is this the true ? In my case, because I run in noserver mode, I run my own tomcat standalone server and use a proxy servlet that extends from GWTShellServlet to forward any business/servlet calls to my standalone server. So I never use any servlet in the GWT tomcat instance and as such receive a timeout exception when my tests don't run fast enough, which is what sometimes happens Please feedback on this and how I can solve this ? The only option I see now is: disable my GWT test cases as the current sometimes-failures is unacceptable on the build machine :( I have no idea how to solve it otherwise... On Oct 3, 8:10 pm, Ed post2edb...@gmail.com wrote: Just played with the -runStyle Manual option I am afraid that is not a correct option for me as I will run the tests during the nightly build and with -runStyle option Manual will stop when running the test and I have to manually copy/past the displayed url, like explained in:http://code.google.com/webtoolkit/doc/latest/DevGuideTesting.html#Man Of course this isn't possible during a nightly build. I will try the option -prod, this might bypass the HtmlUnit code that might give problems as you explain above. I tried this option in Eclipse and the test do run fine with this option. I hope this will solve the problem, as I have no idea what else it could be :( In Eclipse, the GWT tests always run fine (through launch files, I don't use the plugin), and never give me the timeout problem. If you have any more ideas, giving my posts above, please let me know? -- http://groups.google.com/group/Google-Web-Toolkit-Contributors
[gwt-contrib] Re: Test timeout in JUnitShell ? (GWT 2.0.0)
Hi John, Thanks for your reply. There are really two apps running in this case. First, there is the one created by JUnitShell, which contacts an RPC servlet to manage running the test. The timeout you see is because that servlet didn't get contacted. Could you please give me some more info and pointers here? I find the GWT Junit code difficult to follow, especially debugging is a bit hard. Where and how does this required servlet get contacted to overcome the timeout? If I follow the service method in GWTShellServlet, I don't understand where the required contact is made. And I can't find the relation with the messageQueue in the method JUnitShell.notdone() that must contain the required info to overcome the timeout exception :( The GWT Tomcat instance that contains my proxy servlet and my standalone Tomcat instance, run on the same server (the Cargo maven plugin starts the stanalone tomcat instance on port 8090) When you say noserver mode, what exactly do you mean? JUnitShell doesn't Maybe it's better not to use the word noserver in this case it might be misleading. I use the noserver mode during development mode with own launch files. In this case it doesn't make sense as GWT Junit always uses his own Tomcat instance like you explain. If you need a real browser to run the test in an automated way, the recommendation would be to use -runStyle Selenium:uri and run a Selenium-RC I also use Selenium, have about 2500 tests that run through Selenium, that take about 50 hours to complete ;)... Some background info: I don't use runstyle for this. I run the tests against production ready code produced during the nigtly build. I run my tests through testNG with Maven surefire plugin. I have build a little testing framework around Selenium RC in which case Selenium RC is just an implementation detail. I could also use other Ajax testing framework by creating a class that implements my Browser interface and connects to the testing framework. I model all elements on the screen that I want to test as objects and inject a Browser instance (link to Selenium). I then ask the element object something like isPresent(), isPresentWait(), typeText(String), etc... or in case of a DatePickerElement, something like: setDate(Date). The Date picker implementation will then open the date picker and choose the specified date and close it again. So you end up having a class hierarchy of Elements like TextElement, DateElement, etc I use it now for about two years and it works well and the tester that uses it, which isn't a experienced developers, likes it and can make his test scenarios well in eclipse... On Oct 5, 2:07 pm, John Tamplin j...@google.com wrote: On Tue, Oct 5, 2010 at 5:50 AM, Ed post2edb...@gmail.com wrote: Yesterday my test was run with success and last night it failed again, without anything changing in the meantime :( I was digging a bit more in the GWT Junit test code and I think the test fails because I don't use a servlet that is hosted by the Tomcat container started by GWT. Like Freeland mentions above, I have to contact the backend within 60 sec to overcome the timeout exception. I think I have to contact a servlet run in the GWT Tomcat instance as otherwise it's not seen as a backend contact. Is this the true ? There are really two apps running in this case. First, there is the one created by JUnitShell, which contacts an RPC servlet to manage running the test. The timeout you see is because that servlet didn't get contacted. Second, there is your actual test code, which may contact your own servlets that you create. Due to SOP, these must be on the same server that the code was loaded from, but your proxy servlet can run there and redirect the request to another server since it isn't bound by that restriction. In my case, because I run in noserver mode, I run my own tomcat standalone server and use a proxy servlet that extends from GWTShellServlet to forward any business/servlet calls to my standalone server. So I never use any servlet in the GWT tomcat instance and as such receive a timeout exception when my tests don't run fast enough, which is what sometimes happens When you say noserver mode, what exactly do you mean? JUnitShell doesn't support -noserver, since as mentioned above it's own servlet has to run to operate the test infrastructure. Please feedback on this and how I can solve this ? The only option I see now is: disable my GWT test cases as the current sometimes-failures is unacceptable on the build machine :( I have no idea how to solve it otherwise... -runStyle Manual was the suggestion for how to debug what is going on. There you should be able to see what is going wrong. If you need a real browser to run the test in an automated way, the recommendation would be to use -runStyle Selenium:uri and run a Selenium-RC server with the browser you want to test with. If you are on Linux, you can, for
Re: [gwt-contrib] Re: Test timeout in JUnitShell ? (GWT 2.0.0)
On Tue, Oct 5, 2010 at 8:47 AM, Ed post2edb...@gmail.com wrote: There are really two apps running in this case. First, there is the one created by JUnitShell, which contacts an RPC servlet to manage running the test. The timeout you see is because that servlet didn't get contacted. Could you please give me some more info and pointers here? I find the GWT Junit code difficult to follow, especially debugging is a bit hard. Where and how does this required servlet get contacted to overcome the timeout? If I follow the service method in GWTShellServlet, I don't understand where the required contact is made. And I can't find the relation with the messageQueue in the method JUnitShell.notdone() that must contain the required info to overcome the timeout exception :( Look at the comment at the top of JUnitShell -- it explains the connections. If you need a real browser to run the test in an automated way, the recommendation would be to use -runStyle Selenium:uri and run a Selenium-RC I also use Selenium, have about 2500 tests that run through Selenium, that take about 50 hours to complete ;)... Some background info: I don't use runstyle for this. I run the tests against production ready code produced during the nigtly build. I run my tests through testNG with Maven surefire plugin. Right, but there your Selenium tests are exercising the running app. I am suggesting it can also be used for running GWTTestCases in a real browser automatically. -- John A. Tamplin Software Engineer (GWT), Google -- http://groups.google.com/group/Google-Web-Toolkit-Contributors
[gwt-contrib] Re: Test timeout in JUnitShell ? (GWT 2.0.0)
On Oct 5, 2:51 pm, John Tamplin j...@google.com wrote: I also use Selenium, have about 2500 tests that run through Selenium, that take about 50 hours to complete ;)... Some background info: I don't use runstyle for this. I run the tests against production ready code produced during the nigtly build. I run my tests through testNG with Maven surefire plugin. Right, but there your Selenium tests are exercising the running app. I am suggesting it can also be used for running GWTTestCases in a real browser automatically. Or in other words: http://code.google.com/p/google-web-toolkit/wiki/RemoteTesting#Selenium ;-) -- http://groups.google.com/group/Google-Web-Toolkit-Contributors
[gwt-contrib] Re: Test timeout in JUnitShell ? (GWT 2.0.0)
Thanks, I found the servlet you meant: JUnitHostImpl I see that the url that touches this servlet is correctly forwarded by the proxy and received by this servlet when debugging in Eclipse: The url that touches it: / com.bv.gwt.profile.intern.ProfileGwtTest.JUnit/junithost (also appears in the logging below) However, when it's running during the nightly build and fails, I's hard to find out what went wrong as the this servlet doesn't contain debug/trace logging. It would be nice to see the path of execution in the logging such that I can see why the servlet isn't touched. Any idea's how to solve this? Or any idea about what would be going wrong ? Below the proxy part code that is very straightforward and some logging that might be of interest. In the logging I noticed that just after receiving the /junit url that should touch the JUnitHostImpl, a retry is attempted. Does that give you any ideas? protected void service(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException { final String uri = createUriRequest(request); LOG.debug(Receiving url request, url: {}, uri); if (uriContainsRequestParts(uri)) { LOG.debug(Forwarding url to external system.\nUrl: {}\nTarget host: {}\nTarget port: {}\nTarget protocol: {}, new Object[] { uri, this.host, this.port, this.protocol }); proxy(request, response, uri); } else { LOG.debug(No forward. Calling parent method. Url: {}, uri); super.service(request, response); } } - The output snippet looks like: [INFO] 14:27:07.709 [http-0-Processor4] DEBUG com.ited.gwt.dev.server.ProxyServlet - Receiving url request, url: / com.bv.gwt.profile.intern.ProfileGwtTest.JUnit/junithost [INFO] 14:27:07.709 [http-0-Processor4] DEBUG com.ited.gwt.dev.server.ProxyServlet - No forward. Calling parent method. Url: /com.bv.gwt.profile.intern.ProfileGwtTest.JUnit/junithost [INFO] 14:27:10.891 [http-0-Processor4] DEBUG com.ited.gwt.dev.server.ProxyServlet - Receiving url request, url: /bv- web/intern/rpc-gwt/srv-general [INFO] 14:27:10.892 [http-0-Processor4] DEBUG com.ited.gwt.dev.server.ProxyServlet - Forwarding url to external system. ... ... [INFO] 14:27:12.909 [http-0-Processor4] DEBUG com.ited.gwt.dev.server.ProxyServlet - Receiving url request, url: / com.bv.gwt.profile.intern.ProfileGwtTest.JUnit/junithost [INFO] 14:27:12.909 [http-0-Processor4] DEBUG com.ited.gwt.dev.server.ProxyServlet - No forward. Calling parent method. Url: /com.bv.gwt.profile.intern.ProfileGwtTest.JUnit/junithost [INFO] [WARN] com.bv.gwt.profile.intern.ProfileGwtTest.JUnit:com.bv.gwt.profile.XGwtBackendTestUpdateLoggedInMemberOk.testUpdateLoggedInTaxer is being retried, retry attempt = 1 [INFO] [WARN] com.bv.gwt.profile.intern.ProfileGwtTest.JUnit:com.bv.gwt.profile.XGwtBackendTestUpdateLoggedInMemberOk.testUpdateLoggedInTaxer is being retried, retry attempt = 2 [INFO] Tests run: 2, Failures: 0, Errors: 2, Skipped: 0, Time elapsed: 385.986 sec FAILURE! [INFO] testUpdateLoggedInTaxer(com.bv.gwt.profile.XGwtBackendTestUpdateLoggedInMemberOk) Time elapsed: 385.952 sec ERROR! [INFO] com.google.gwt.junit.client.TimeoutException: The browser did not contact the server within 6ms. [INFO] - NO RESPONSE: 192.168.1.45 / Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9.0.1) Gecko/2008070208 Firefox/3.0.1 [INFO] - 1 client(s) haven't responded back to JUnitShell since the start of the test. --- On Oct 5, 2:51 pm, John Tamplin j...@google.com wrote: On Tue, Oct 5, 2010 at 8:47 AM, Ed post2edb...@gmail.com wrote: There are really two apps running in this case. First, there is the one created by JUnitShell, which contacts an RPC servlet to manage running the test. The timeout you see is because that servlet didn't get contacted. Could you please give me some more info and pointers here? I find the GWT Junit code difficult to follow, especially debugging is a bit hard. Where and how does this required servlet get contacted to overcome the timeout? If I follow the service method in GWTShellServlet, I don't understand where the required contact is made. And I can't find the relation with the messageQueue in the method JUnitShell.notdone() that must contain the required info to overcome the timeout exception :( Look at the comment at the top of JUnitShell -- it explains the connections. If you need a real browser to run the test in an automated way, the recommendation would be to use -runStyle Selenium:uri and run a Selenium-RC I also use Selenium, have about 2500 tests that run through Selenium, that take about 50 hours to complete ;)... Some background info: I don't use runstyle for this. I run the tests against production ready code produced during the
Re: [gwt-contrib] Re: Test timeout in JUnitShell ? (GWT 2.0.0)
On Tue, Oct 5, 2010 at 10:12 AM, Ed post2edb...@gmail.com wrote: I found the servlet you meant: JUnitHostImpl I see that the url that touches this servlet is correctly forwarded by the proxy and received by this servlet when debugging in Eclipse: The url that touches it: / com.bv.gwt.profile.intern.ProfileGwtTest.JUnit/junithost (also appears in the logging below) However, when it's running during the nightly build and fails, I's hard to find out what went wrong as the this servlet doesn't contain debug/trace logging. It would be nice to see the path of execution in the logging such that I can see why the servlet isn't touched. Any idea's how to solve this? Or any idea about what would be going wrong ? If it works when you run it directly, yet fails in the continuous build, then something is different between the two that matters. I would suggest running the test in your continuous build environment with remote debugging enabled and attaching to it with a debugger to see what is going on. -- John A. Tamplin Software Engineer (GWT), Google -- http://groups.google.com/group/Google-Web-Toolkit-Contributors