Re: how to avoid instanceof checks in ActivityMapper ? is DoubleDispatch used in Expenses sample ?
I'm sorry but, what's the problem actually? theoretical purity? (AFAICT, Roo generated apps use those processors for ease of maintainance: the processor is maintained by Roo while the activity mapper is generated once) -- 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: HTMLPanel - Why doesn't it work with setTag(button)
Having the stream of obscure exceptions might help understanding the issue. -- 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: Adding event handler to UiBinder
Don't use an Image widget, but an element that you'll apply the ImageResource to (or, even better, use a @sprite in a CssResource if you can): create an AbstractImagePrototype from your ImageResource, then use either one of getHTML or createElement (if you don't plan on supporting IE6 –and I really mean IE6, not the whole ie6 permutation, i.e. this will work OK in IE7 and IE8 in compatibility view–, then you can even use applyTo, by cast()ing your element to ImagePrototypeElement) -- 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: Question regarding Activites, Places, Dependeny Injection and complex layouts.
Noone has anything to add on this subject? This should really be a basic structure of most apps.. so I really done buy the fact that noone else is trying to wrap their heads around this subject? :) On 31 Des 2010, 15:27, Frank Bølviken frank.bolvi...@gmail.com wrote: Hi, Here you will find a simple sample project. COuld someone please help me/explain to me how you go abaout and implement this layout in the sample project? WestNavigationPlace should be at the left always. And based on the buttons you click there, the main center region should be populated with either HelloPlace or GoodbyePlace :) http://www.easy-share.com/1913435325/web.zip Thanks in advance, Frank B On Dec 30, 9:51 pm, Frank Bølviken frank.bolvi...@gmail.com wrote: Hi, I've been looking for examples which show how to build up complex GUI's which use West region for navigation for example, and a Main region for content. I've found some posts about it, but none of which is really good and easy to follow. None of them use Guice and Gin as dependency injection. So i'm curious... is there any good examples out there showing this? As i understood it, there is supposed to be a way of doing this, but it's not out of the box in the current GWT release. Right now I'm just using 1 activitymapper which map the places. I've understood that I may need two mappers to accomplish this, is this right? Thanks in advance, Frank -- 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 MVP Activities and Places
Is there any existing sample-projects which use this structure, with DI(gin/guice) ? On 3 Des 2010, 14:08, Brian Reilly brian.irei...@gmail.com wrote: That's the exact use case for FilteredActivityMapper and CachingActivityMapper (and how they're used AFAICT in scaffold applications generated by String Roo for the master activities). Thanks for the confirmation, Thomas. I felt like it was a bit cumbersome to use, but it makes more sense as a consistent way to get that behavior in generated code (which is unfortunate, but it is what it is). what about situations where a display region is master in some cases (requiring to be cached), and detail in other cases ? for example, when we have West, Center, and East Regions, Center region can act as Detail for West Region in some use cases, but in other use cases, be used as Master for East Region. I can think of two approaches, depending on the specificity of the places. 1. Use an activity mapper for the center region but not the east region. This would be appropriate if the center region shows the item of interest and the east region contains some contextual detail that isn't worthy of being encoded into a place. 2. Have both the center and east regions react to the same place where, unlike option 1, the place contains enough context for both regions. The east region would use that extra detail to display something specific about the item of interest while the center region can ignore it if it doesn't affect what's displayed. I'm sure there are more ways to approach it. Just keep in mind that activity mappers are for mapping places to activities. Once you decide how granular you want your places to be, that will help determine the best use of activity mappers. what happens if we use CachingActivityMapper for ALL of our ActivityMappers ? would there be a performance problem, what are the implications, benefits or drawbacks ? CachingActivityMapper caches the last activity it returned, to be re-used if we see the same place twice (http://google-web-toolkit.googlecode.com/svn/javadoc/2.1/com/google/g...). If your concern is memory, there should be little to no overhead when using a CachingActivityMapper. As for performance, the goal of CachingActivityMapper is to avoid initializing a new activity (and potentially fetching data from the server, doing client-side processing, etc.) when the current activity already represents the requested place. I can't think of any downside to using CachingActivityMapper... as long as the wrapped activity mapper and the places it uses are implemented as advised (be sure to properly implement equals() and hashCode() for your places). -Brian -- 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.
Assign handler to UiHandler
Hi, sorry I could not find this anywhere. I know I can add handler like this: @UiHandler(submit) void onClickCreate(final ClickEvent e) { if (check()) create(); else Window.alert(messages.wrongConditions()); } but how would I mimic this using UiBinder (UpperCaser class implements BlurHandler): lastName.addBlurHandler(new UpperCaser()); 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.
File choose
I am using only GWT code for file choosing, but posting code are in javascript and HTML 5. I know only the java and not other. So i need app for GWT for read, write and access file. Please send me some sample app in GWT and not in other like HTML, or javascript. Because, here GWT will convert to javascript as already know. -- 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 set size of the DecoratedTabPanel constant?
Hi, I would like to make the width and height of the DecoratedTabPanel constant. I have tried setsize, but the DecoratedTabPanel seems ignoring it. It just wraps the widget as tight as possible. Is there any way to fix the height and width of the panel? Scrollbar is expected if the widget contains too much data. 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: Assign handler to UiHandler
BTW right now I just call lastName.addBlurHandler... in constructor but would prefer using @UiHandler if possible. -- 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: DockLayoutPanel MVP and events
Hi, Does it exist any sample-project app which demonstrate this, with dependency-injection like GIN? I've successfully implemented this in a simple app where the activity takes the whole screen. But what I would like is a navigationmenu left, header, footer and main content in the center of the screen. Any help would be greatly appriciated. Sincerly, Frank B -- 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: File choose
Take a look to the gwtupload project source http://code.google.com/p/gwtupload/ On 3 ene, 08:44, jc jc.chan...@gmail.com wrote: I am using only GWT code for file choosing, but posting code are in javascript and HTML 5. I know only the java and not other. So i need app for GWT for read, write and access file. Please send me some sample app in GWT and not in other like HTML, or javascript. Because, here GWT will convert to javascript as already know. -- 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 get a widget from another panel
Just add the widget to the panel that you want. panel.add(widget); On 3 ene, 00:29, Néstor Boscán nesto...@gmail.com wrote: Hi I have a GWT application with two panels. How to I get a Widget from one panel from the other panel?. Regards, Néstor Boscán -- 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: Tutorial 1: Getting started with guit framework. 2:30 minutes video
This is the first that I have heard of this. Looking forward to checking this out. Hopefully it simplifies development and makes things a little bit easier. I have been trying to learn how to use MVP but have been having some trouble getting it setup. On Jan 2, 3:37 pm, Gal Dolber gal.dol...@gmail.com wrote: http://www.youtube.com/watch?v=S_u7CkU_NnI -- Guit: Elegant, beautiful, modular and *production ready* gwt applications. http://code.google.com/p/guit/ -- 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: First column in CellBrowser - width not working
This appears to be exactly my issue. I have starred the issue - fingers crossed it gets fixed soon. I wonder if I could do a workaround/hack involving creating a dummy first column, then hiding it in CSS or something. Do you know of any way of assigning CSS classes/IDs to only the first column? -- 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 write file with GWT?
Hello to all ... I have to write an XML doc with GWT. I discovered that you can not do client-side but it can be done with server-side. So I setup the synchronous and asynchronous client-side: package com.example.foobar.client ; import com.google.gwt.user.client.rpc.RemoteService; public interface extends RPCInterface RemoteService { testRPC public String (String message); } -- - package com.example.foobar.client ; import com.google.gwt.user.client.rpc.AsyncCallback; public interface RPCInterfaceAsync { testRPC void (String message, AsyncCallback callback String); } -- --- while on the server-side I did: import java.io.BufferedWriter; import java.io.DataOutputStream; import java.io.FileOutputStream; import java.io.FileWriter; import java.io.IOException; import java.text.DateFormat; import java.util.Date; import com.google.gwt.user.server.rpc.RemoteServiceServlet; import com.example.foobar.client.RPCInterface; public class extends RPCImpl RemoteServiceServlet implements RPCInterface { private static final long serialVersionUID = 1L; testRPC public String (String message) { Date now = new Date (); Dtm DateFormat.getTimeInstance String = (DateFormat.MEDIUM.) Format (now); try { BufferedWriter out = new BufferedWriter (new FileWriter (test.txt)); out.write (message); out.close (); } Catch (IOException e) { } return This is my message + message; } } -- -- - I have not forgotten anything in the matter, because before you use the class FileWriter and BufferedWriter the program run smoothly. I have these errors: ERROR] javax.servlet.ServletContext log: Exception while dispatching incoming RPC call com.google.gwt.user.server.rpc.UnexpectedException: Service method 'public abstract java.lang.String com.example.foobar.client.RPCInterface.testRPC (java.lang.String)' Threw an unexpected exception: java. lang.NoClassDefFoundError: java.io.FileWriter is a restricted class. Please see the Google App Engine developer's guide for more details. 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: 207) at com.google.gwt.user.server.rpc.RemoteServiceServlet.processPost (RemoteServiceServlet.java: 243) 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.appengine.api.blobstore.dev.ServeBlobFilter.doFilter (ServeBlobFilter.java: 58) 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 com.google.appengine.tools.development.StaticFileFilter.doFilter (StaticFileFilter.java: 122) 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) at org.mortbay.jetty.servlet.SessionHandler.handle (SessionHandler.java: 182) at org.mortbay.jetty.handler.ContextHandler.handle (ContextHandler.java: 765) at org.mortbay.jetty.webapp.WebAppContext.handle (WebAppContext.java: 418) at com.google.apphosting.utils.jetty.DevAppEngineWebAppContext.handle (DevAppEngineWebAppContext.java: 70) at org.mortbay.jetty.handler.HandlerWrapper.handle (HandlerWrapper.java: 152) com.google.appengine.tools.development.JettyContainerService at $ ApiProxyHandler.handle (JettyContainerService.java: 349) at org.mortbay.jetty.handler.HandlerWrapper.handle (HandlerWrapper.java: 152) at org.mortbay.jetty.Server.handle (server.jar: 326) at org.mortbay.jetty.HttpConnection.handleRequest (HttpConnection.java: 542) org.mortbay.jetty.HttpConnection at $ RequestHandler.content (HttpConnection.java: 938) at org.mortbay.jetty.HttpParser.parseNext (HttpParser.java: 755) at org.mortbay.jetty.HttpParser.parseAvailable (HttpParser.java: 218) at org.mortbay.jetty.HttpConnection.handle (HttpConnection.java: 404) at org.mortbay.io.nio.SelectChannelEndPoint.run (SelectChannelEndPoint.java: 409) org.mortbay.thread.QueuedThreadPool at $ PoolThread.run (QueuedThreadPool.java:
Re: Adding event handler to UiBinder
AbstractImagePrototype is interesting. How does the overhead compare to using an Image widget and Image.setResource(..) ? -- 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: Adding event handler to UiBinder
From looking at the source code it doesn't look like there'd be a great deal of difference. -- 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 get a widget from another panel
Hi Thanks for the quick reply. I don't want to add the widget I want to get the value of a widget that is in another panel On 1/3/11, nacho vela.igna...@gmail.com wrote: Just add the widget to the panel that you want. panel.add(widget); On 3 ene, 00:29, Néstor Boscán nesto...@gmail.com wrote: Hi I have a GWT application with two panels. How to I get a Widget from one panel from the other panel?. Regards, Néstor Boscán -- 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.
EnterButton
I have a couple of places where I want the user to be able to hit enter, and have a button clicked. So I created the class EnterButton, which has all the default constructors, and the following bit of code: public void onKeyPress (KeyPressEvent event) { int keyCode = event.getNativeEvent ().getKeyCode (); if (keyCode == KeyCodes.KEY_ENTER) click (); } Is there a reason why some such class isn't part of GWT already? Is there something in this code that will turn around and bite me in the tush? -- 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.
Where do KeyPress Events go?
So, now that I have an EnterButton class, I'd like to use it. :-) I have a form panel with a FileUpload. I'd like to let the user select a file, then hit enter to fire the form submit button (which is an EnterButton, not a SubmitButton). Unfortunately, FileUpload does not have an addKeyPressHandler routine. So, who gets any key events I generate while in the text field part of a FileUpload? What is the call chain for events that aren't captured by the Widget where the event happens? Sorry if this is an FAQ, and in the docs. I took a (quick) look, and couldn't find anything. Please point me to the correct docs if it is in there. Thanks! Greg -- 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: Tutorial 1: Getting started with guit framework. 2:30 minutes video
Thanks! more video tutorials to come On Mon, Jan 3, 2011 at 10:01 AM, B Woods bradleydeanwo...@gmail.com wrote: This is the first that I have heard of this. Looking forward to checking this out. Hopefully it simplifies development and makes things a little bit easier. I have been trying to learn how to use MVP but have been having some trouble getting it setup. On Jan 2, 3:37 pm, Gal Dolber gal.dol...@gmail.com wrote: http://www.youtube.com/watch?v=S_u7CkU_NnI -- Guit: Elegant, beautiful, modular and *production ready* gwt applications. http://code.google.com/p/guit/ -- 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. -- Guit: Elegant, beautiful, modular and *production ready* gwt applications. http://code.google.com/p/guit/ -- 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 get a widget from another panel
Well, assuming both panels are in the same web application, save the widget in a global variable, and access that when you want information. Greg On Jan 3, 8:49 am, Néstor Boscán nesto...@gmail.com wrote: Hi Thanks for the quick reply. I don't want to add the widget I want to get the value of a widget that is in another panel On 1/3/11, nacho vela.igna...@gmail.com wrote: Just add the widget to the panel that you want. panel.add(widget); On 3 ene, 00:29, Néstor Boscán nesto...@gmail.com wrote: Hi I have a GWT application with two panels. How to I get a Widget from one panel from the other panel?. Regards, Néstor Boscán -- 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: How to get a widget from another panel
Some code will help On Mon, Jan 3, 2011 at 11:07 AM, Greg Dougherty dougherty.greg...@mayo.eduwrote: Well, assuming both panels are in the same web application, save the widget in a global variable, and access that when you want information. Greg On Jan 3, 8:49 am, Néstor Boscán nesto...@gmail.com wrote: Hi Thanks for the quick reply. I don't want to add the widget I want to get the value of a widget that is in another panel On 1/3/11, nacho vela.igna...@gmail.com wrote: Just add the widget to the panel that you want. panel.add(widget); On 3 ene, 00:29, Néstor Boscán nesto...@gmail.com wrote: Hi I have a GWT application with two panels. How to I get a Widget from one panel from the other panel?. Regards, Néstor Boscán -- 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.comgoogle-web-toolkit%2bunsubscr...@googlegroups.com . For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en. -- Guit: Elegant, beautiful, modular and *production ready* gwt applications. http://code.google.com/p/guit/ -- 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 get a widget from another panel
Greg thanks a lot. Using rootpanel.get won't help? On 1/3/11, Greg Dougherty dougherty.greg...@mayo.edu wrote: Well, assuming both panels are in the same web application, save the widget in a global variable, and access that when you want information. Greg On Jan 3, 8:49 am, Néstor Boscán nesto...@gmail.com wrote: Hi Thanks for the quick reply. I don't want to add the widget I want to get the value of a widget that is in another panel On 1/3/11, nacho vela.igna...@gmail.com wrote: Just add the widget to the panel that you want. panel.add(widget); On 3 ene, 00:29, Néstor Boscán nesto...@gmail.com wrote: Hi I have a GWT application with two panels. How to I get a Widget from one panel from the other panel?. Regards, Néstor Boscán -- 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: Assign handler to UiHandler
This should work: @UiHandler(lastName) void onLastNameBlur(BlurEvent event) { // code from UpperCase goes here } On Jan 3, 5:33 am, Peter Ondruska peter.ondru...@gmail.com wrote: BTW right now I just call lastName.addBlurHandler... in constructor but would prefer using @UiHandler if possible. -- 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: Tutorial 1: Getting started with guit framework. 2:30 minutes video
Out of curiosity, is there supposed to be audio? On Jan 2, 2:37 pm, Gal Dolber gal.dol...@gmail.com wrote: http://www.youtube.com/watch?v=S_u7CkU_NnI -- Guit: Elegant, beautiful, modular and *production ready* gwt applications. http://code.google.com/p/guit/ -- 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 write file with GWT?
The stack trace says it all... com.example.foobar.client.RPCInterface.testRPC (java.lang.String)' Threw an unexpected exception: java. lang.NoClassDefFoundError: java.io.FileWriter is a restricted class. Please see the Google App Engine developer's guide for more details. You appear to have your test module in the com.example.foobar.client package. ^ This means that the GWT compiler will compile that module and it looks to me like that contains a reference to java.io.FileWriter - as the stack trace message says, the developer's guide will explain to you exactly what the problem is but the 'executive summary' is that java.io.FileWriter can't be used in GWT 'client' code because it can't be compiled to Javascript. The rule in GWT is: 1. things that will only be run as javascript on the client should be in the your.module.client.* packages 2. things that will only be run on the server should be in the your.module.server.* packages 3. things that will be shared by the client code should be in the your.module.shared.* packages - IMHO these should be kept to a minimum. You must make sure that you have both client and shared in the your.module.Module.gwt.xml file Java classes used in 1. and 3. above must be restricted to those classes supported by the GWT compiler - see http://code.google.com/webtoolkit/doc/latest/RefJreEmulation.html for more details. Its all in the docs or has already been covered on this list HTH Alan On 1/3/2011 6:19 AM, Sebe wrote: Hello to all ... I have to write an XML doc with GWT. I discovered that you can not do client-side but it can be done with server-side. So I setup the synchronous and asynchronous client-side: package com.example.foobar.client ; import com.google.gwt.user.client.rpc.RemoteService; public interface extends RPCInterface RemoteService { testRPC public String (String message); } -- - package com.example.foobar.client ; import com.google.gwt.user.client.rpc.AsyncCallback; public interface RPCInterfaceAsync { testRPC void (String message, AsyncCallback callbackString); } -- --- while on the server-side I did: import java.io.BufferedWriter; import java.io.DataOutputStream; import java.io.FileOutputStream; import java.io.FileWriter; import java.io.IOException; import java.text.DateFormat; import java.util.Date; import com.google.gwt.user.server.rpc.RemoteServiceServlet; import com.example.foobar.client.RPCInterface; public class extends RPCImpl RemoteServiceServlet implements RPCInterface { private static final long serialVersionUID = 1L; testRPC public String (String message) { Date now = new Date (); Dtm DateFormat.getTimeInstance String = (DateFormat.MEDIUM.) Format (now); try { BufferedWriter out = new BufferedWriter (new FileWriter (test.txt)); out.write (message); out.close (); } Catch (IOException e) { } return This is my message + message; } } -- -- - I have not forgotten anything in the matter, because before you use the class FileWriter and BufferedWriter the program run smoothly. I have these errors: ERROR] javax.servlet.ServletContext log: Exception while dispatching incoming RPC call com.google.gwt.user.server.rpc.UnexpectedException: Service method 'public abstract java.lang.String com.example.foobar.client.RPCInterface.testRPC (java.lang.String)' Threw an unexpected exception: java. lang.NoClassDefFoundError: java.io.FileWriter is a restricted class. Please see the Google App Engine developer's guide for more details. 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: 207) at com.google.gwt.user.server.rpc.RemoteServiceServlet.processPost (RemoteServiceServlet.java: 243) 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.appengine.api.blobstore.dev.ServeBlobFilter.doFilter (ServeBlobFilter.java: 58) at org.mortbay.jetty.servlet.ServletHandler $ CachedChain.doFilter (ServletHandler.java: 1157) at com.google.apphosting.utils.servlet.TransactionCleanupFilter.doFilter (TransactionCleanupFilter.java: 43) at
Re: How to write file with GWT?
Hi Alan, thanks for the response I can not figure out is how to save content from client-side textbox as a parameter via an XML file. The work to be done into server's package right? I'm working with Eclipse and I use Google Apple Engine.. You know give me a hand? Or know of a tutorial that explains how it works? I'm desperate .. Thanks very much Regards On Jan 3, 4:46 pm, a...@mechnicality.com a...@mechnicality.com wrote: The stack trace says it all... com.example.foobar.client.RPCInterface.testRPC (java.lang.String)' Threw an unexpected exception: java. lang.NoClassDefFoundError: java.io.FileWriter is a restricted class. Please see the Google App Engine developer's guide for more details. You appear to have your test module in the com.example.foobar.client package. ^ This means that the GWT compiler will compile that module and it looks to me like that contains a reference to java.io.FileWriter - as the stack trace message says, the developer's guide will explain to you exactly what the problem is but the 'executive summary' is that java.io.FileWriter can't be used in GWT 'client' code because it can't be compiled to Javascript. The rule in GWT is: 1. things that will only be run as javascript on the client should be in the your.module.client.* packages 2. things that will only be run on the server should be in the your.module.server.* packages 3. things that will be shared by the client code should be in the your.module.shared.* packages - IMHO these should be kept to a minimum. You must make sure that you have both client and shared in the your.module.Module.gwt.xml file Java classes used in 1. and 3. above must be restricted to those classes supported by the GWT compiler - see http://code.google.com/webtoolkit/doc/latest/RefJreEmulation.html for more details. Its all in the docs or has already been covered on this list HTH Alan On 1/3/2011 6:19 AM, Sebe wrote: Hello to all ... I have to write an XML doc with GWT. I discovered that you can not do client-side but it can be done with server-side. So I setup the synchronous and asynchronous client-side: package com.example.foobar.client ; import com.google.gwt.user.client.rpc.RemoteService; public interface extends RPCInterface RemoteService { testRPC public String (String message); } -- - package com.example.foobar.client ; import com.google.gwt.user.client.rpc.AsyncCallback; public interface RPCInterfaceAsync { testRPC void (String message, AsyncCallback callbackString); } -- --- while on the server-side I did: import java.io.BufferedWriter; import java.io.DataOutputStream; import java.io.FileOutputStream; import java.io.FileWriter; import java.io.IOException; import java.text.DateFormat; import java.util.Date; import com.google.gwt.user.server.rpc.RemoteServiceServlet; import com.example.foobar.client.RPCInterface; public class extends RPCImpl RemoteServiceServlet implements RPCInterface { private static final long serialVersionUID = 1L; testRPC public String (String message) { Date now = new Date (); Dtm DateFormat.getTimeInstance String = (DateFormat.MEDIUM.) Format (now); try { BufferedWriter out = new BufferedWriter (new FileWriter (test.txt)); out.write (message); out.close (); } Catch (IOException e) { } return This is my message + message; } } -- -- - I have not forgotten anything in the matter, because before you use the class FileWriter and BufferedWriter the program run smoothly. I have these errors: ERROR] javax.servlet.ServletContext log: Exception while dispatching incoming RPC call com.google.gwt.user.server.rpc.UnexpectedException: Service method 'public abstract java.lang.String com.example.foobar.client.RPCInterface.testRPC (java.lang.String)' Threw an unexpected exception: java. lang.NoClassDefFoundError: java.io.FileWriter is a restricted class. Please see the Google App Engine developer's guide for more details. 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: 207) at com.google.gwt.user.server.rpc.RemoteServiceServlet.processPost (RemoteServiceServlet.java: 243) at com.google.gwt.user.server.rpc.AbstractRemoteServiceServlet.doPost (AbstractRemoteServiceServlet.java: 62) at
Re: Real-time app: best approach
Which grid/table would you recommend? I used GXT grid and the new CellTable, but they are too slow or not able of rendering its content dynamically while scrolling. How would you send that data to the client, what is the fastest way? I make a String for each row, send it to the client over RPC and parse it back, but that's not the fastest way I assume. @Jeff: The 400MB I mentioned are for the client side only. @Brian: paging is not in the requirement and therefore not an option. Cheers Tim -- 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: Assign handler to UiHandler
Oh 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 write file with GWT?
All of the writing needs to be done on the server, so within your sever package. The only thing which the client should do with this is make an RPC call. -- 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.
event plumbing
Hi, please help me to debug (or even better - to tap) events to PopupPanel/ MenuBar. I'm trying to create context menu over OpenLayers map. Composite which contains map sinks mouse events and I can see that those events are processed. When I'm creating PopupPanel containing MenuBar, PopupPanel shows in place I expect after Event.ONCONTEXTMENU event and it correctly responses to mouse clicks and closes properly. So far everything is ok. My problem is - it seems that my MenuBar somehow interferes with map sitting beneath it - it doesn't respond to mouse move events (doesn't highlight mouse over MenuItem) and clicking on it works as it was click outside PopupPanel - MenuItem command is not executed. Overriding PopupPanel, MenuBar and adding explicit sinkEvent of required mouse events doesn't help. During context menu handling I'm not interested in map. How could I take over mouse control and direct necessary events to my MenuBar? Thanks, Grazvydas -- 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: CellTree and RPC
i am also stuck in the same confusion please share your solution. Regards, Saket -- 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.
Generated Maven pom.xml does not add GWT project natures
Hi GWT gurus, I'm generating an Eclipse project using webAppCreator. The project is created but the pom.xml does not contain the appropriate GWT project nature, meaning the application can't be launched as Web Application because the Project does not use GWT or GAE. The usual sequence to launch the app by right clicking the project root - Run As - Web Application is not available since it's not a GWT project. Found in GWT Release (e.g. 1.5.3, 1.6 RC): 2.1.0 Encountered on OS / Browser (e.g. WinXP, IE6-7, FF3): Win7 Shortest code snippet which demonstrates issue (please indicate where actual result differs from expected result): Run webAppCreator -maven -noant -out test com.googlecode.easygwt.Test. Then check the generated pom.xml and .project file. The former lacks: plugin groupIdorg.apache.maven.plugins/groupId artifactIdmaven-eclipse-plugin/artifactId version2.8/version configuration additionalProjectnatures projectnaturecom.google.gwt.eclipse.core.gwtprojectnature/ projectnature projectnatureorg.eclipse.jdt.core.javaprojectnature/ projectnature projectnatureorg.eclipse.jem.workbench.JavaEMFprojectnature/ projectnature projectnatureorg.eclipse.wst.common.modulecore.ModuleCoreprojectnature/ projectnature projectnatureorg.eclipse.wst.common.project.facet.core.projectnature/ projectnature projectnatureorg.eclipse.wst.jsdt.core.jsprojectnature/ projectnature /additionalProjectnatures additionalBuildcommands buildCommandcom.google.gdt.eclipse.core.webAppProjectValidator/ buildCommand buildCommandcom.google.gwt.eclipse.core.gwtProjectValidator/ buildCommand buildCommandorg.eclipse.wst.jsdt.core.javascriptValidator/ buildCommand buildCommandorg.eclipse.wst.common.project.facet.core.builder/ buildCommand buildCommandorg.eclipse.wst.validation.validationbuilder/ buildCommand /additionalBuildcommands /configuration /plugin while the latter should have: buildSpec buildCommand nameorg.eclipse.wst.jsdt.core.javascriptValidator/name arguments /arguments /buildCommand buildCommand nameorg.eclipse.wst.common.project.facet.core.builder/name arguments /arguments /buildCommand buildCommand nameorg.eclipse.jdt.core.javabuilder/name arguments /arguments /buildCommand buildCommand nameorg.eclipse.wst.validation.validationbuilder/name arguments /arguments /buildCommand /buildSpec natures natureorg.eclipse.jem.workbench.JavaEMFNature/nature natureorg.eclipse.wst.common.modulecore.ModuleCoreNature/nature natureorg.eclipse.jdt.core.javanature/nature natureorg.eclipse.wst.common.project.facet.core.nature/nature natureorg.eclipse.wst.jsdt.core.jsNature/nature /natures Workaround if you have one: Right click on the project - Google - Web Toolkit Settings. Then check Use Google Web Toolkit Can this be fixed? Many thanks! Regards, Cheng -- 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.
Handling clicks on CellWidgets
Hi, Happy new year to all! I have some questions regarding cellwidgets. In the showcase http://gwt.google.com/samples/Showcase/Showcase.html#!CwCellSampler when clicking the cell which contains the button, it reacts not only when pressing the button but also when clicking inside the cell but outside the button. First Question, can i avoid this behavior and only reacting to the button press in a cell? Inspecting the code for this example and the sample from CellList i see the following: From the CellList example, each cell is a div with a single onclick. div onclick= __idx=0 class=GEGGSC0BI style=outline:none;tabletbodytr ... /tr/tbody/table/ div From the CellSampler (which uses a cellTable) the onclick is not in each cell but in each row. tr onclick= class=GEGGSC0BEDtd class=GEGGSC0BDC GEGGSC0BFD GEGGSC0BGCdiv style=outline:none;/div/td/tr I tried to use a composite cell with two buttons in a celllist but as there is only one handler per cell, clicking on any of the two buttons (and also outside the buttons but inside the cell) reacts with the same handler. I can't distinguish them. Question 2. How can I distinguish clicks inside a cell when using a cell list. Question 3 Am I forced to use celltable with different cells for each column. Question 4 How do you managed to distinguish cellclicks if there is only one handler per row in a celltable? I know the questions are not very concise, sorry. Ramon Salla Rovira -- 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.
please Help me GWT Listbox
hi, please Help Me in Listbox widget i want to add option Group like Select tag's Option group in List box How it is Possible. i don't Know. Please Help me on it thanks in advance Regards, Vijay Gohel -- 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.
JRE Emulation Reference - not updated
Hello! I believe that new JRE emulation classes was implemented in GWT 2.1.0, e.g. java.math.BigDecimal. At least this class is still missing from JRE Emulation Reference page. http://code.google.com/intl/fi-FI/webtoolkit/doc/latest/RefJreEmulation.html Regards, Matti -- 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 write file with GWT?
Hi Sebe As I understand it, you want to be able to upload a file from the client and save it on the server. One important point - You CANNOT read and write files in the local (that is, client) computer's general filing system using javascript in the browser. You can only upload a file to the server, save it on the server's filing system and then download it to the client again. If you want to do anything else you simply can't, it would be a huge security loophole and there's enough anarchy in the web already! I'm not very familiar with GAE but a quick scan of the docs seems to indicate that you will have to use the BlobstoreService and upload your files to the BlobStore. One thing you *can't* seem to do is modify the contents of the BlobStore from within the server application. It is a restriction of GAE that you can't save files to the local filing system - if you host your own server (*not* GAE) you can do this. If all you want to do is to upload the file and then serve it back to your user that seems easy. You can also read the blob data, with the 'fetchData' method, so you if it is XML you can read it and return (parsed if necessary) to your client maybe using some kind of XHR request like in the code you posted. To upload the files in your GWT app you will need to use a FileUpload widget - the example in the javadocs is pretty comprehensive. As I've never used GAE I can't be of any more help at this point, but others on the list may have more relevant experience. Regards Alan On 1/3/2011 7:53 AM, Sebe wrote: Hi Alan, thanks for the response I can not figure out is how to save content from client-side textbox as a parameter via an XML file. The work to be done into server's package right? I'm working with Eclipse and I use Google Apple Engine.. You know give me a hand? Or know of a tutorial that explains how it works? I'm desperate .. Thanks very much Regards On Jan 3, 4:46 pm, a...@mechnicality.coma...@mechnicality.com wrote: The stack trace says it all... com.example.foobar.client.RPCInterface.testRPC (java.lang.String)' Threw an unexpected exception: java. lang.NoClassDefFoundError: java.io.FileWriter is a restricted class. Please see the Google App Engine developer's guide for more details. You appear to have your test module in the com.example.foobar.client package. ^ This means that the GWT compiler will compile that module and it looks to me like that contains a reference to java.io.FileWriter - as the stack trace message says, the developer's guide will explain to you exactly what the problem is but the 'executive summary' is that java.io.FileWriter can't be used in GWT 'client' code because it can't be compiled to Javascript. The rule in GWT is: 1. things that will only be run as javascript on the client should be in the your.module.client.* packages 2. things that will only be run on the server should be in the your.module.server.* packages 3. things that will be shared by the client code should be in the your.module.shared.* packages - IMHO these should be kept to a minimum. You must make sure that you have both client and shared in the your.module.Module.gwt.xml file Java classes used in 1. and 3. above must be restricted to those classes supported by the GWT compiler - see http://code.google.com/webtoolkit/doc/latest/RefJreEmulation.html for more details. Its all in the docs or has already been covered on this list HTH Alan On 1/3/2011 6:19 AM, Sebe wrote: Hello to all ... I have to write an XML doc with GWT. I discovered that you can not do client-side but it can be done with server-side. So I setup the synchronous and asynchronous client-side: package com.example.foobar.client ; import com.google.gwt.user.client.rpc.RemoteService; public interface extends RPCInterface RemoteService { testRPC public String (String message); } -- - package com.example.foobar.client ; import com.google.gwt.user.client.rpc.AsyncCallback; public interface RPCInterfaceAsync { testRPC void (String message, AsyncCallback callbackString); } -- --- while on the server-side I did: import java.io.BufferedWriter; import java.io.DataOutputStream; import java.io.FileOutputStream; import java.io.FileWriter; import java.io.IOException; import java.text.DateFormat; import java.util.Date; import com.google.gwt.user.server.rpc.RemoteServiceServlet; import com.example.foobar.client.RPCInterface; public class extends RPCImpl RemoteServiceServlet implements RPCInterface { private static final long serialVersionUID = 1L; testRPC public String (String message) { Date now = new Date (); Dtm DateFormat.getTimeInstance String = (DateFormat.MEDIUM.) Format
Re: How to write file with GWT?
Vi posto il mio caso cosi vedete dove sbaglio (grazie in anticipo): CLIENT SIDE: final String nickname=textNickReg.getText(); final String pass=textPassReg.getText(); final String email2=textMail.getText(); final String gio=valueListBoxGG.getValue().toString(); final String mes=valueListBoxMM.getValue().toString(); final String ann=valueListBoxAA.getValue().toString(); RequestBuilder builder = new RequestBuilder(RequestBuilder.POST, url); try{ Request response = builder.sendRequest(url, new RequestCallback() { public void onError(Request request, Throwable exception) { Window.alert(errore nel sistema); } public void onResponseReceived(Request request, Response response) { Document xmlDoc = XMLParser.parse(response.getText()); Element root = xmlDoc.getDocumentElement(); // root=utenti Element utente = xmlDoc.createElement(utente); root.appendChild(utente); Element nick = xmlDoc.createElement(nick); Text nickTest = xmlDoc.createTextNode(nickname); Element password = xmlDoc.createElement(psw); Text pswTest = xmlDoc.createTextNode(pass); Element email = xmlDoc.createElement(mail); Text mailTest = xmlDoc.createTextNode(email2); Element datan = xmlDoc.createElement(datan); utente.appendChild(datan); String rooto = root.toString(); RPCService rpc = new RPCService(); rpc.testRPC(rooto, callback); ... AsyncCallback callback = new AsyncCallback() { public void onFailure(Throwable caught) { Window.alert(Failure!); } public void onSuccess(Object result) { Window.alert(Success); // System.out.println((String)result); } }; --- package de.vogella.gwt.helloworld.client; import com.google.gwt.user.client.rpc.RemoteService; public interface MyService extends RemoteService { public String testRPC(String message); } --- package de.vogella.gwt.helloworld.client; import com.google.gwt.user.client.rpc.AsyncCallback; public interface MyServiceAsync { void testRPC(String message, AsyncCallbackString callback); } --- package de.vogella.gwt.helloworld.client; import com.google.gwt.core.client.GWT; import com.google.gwt.user.client.rpc.AsyncCallback; import com.google.gwt.user.client.rpc.ServiceDefTarget; public class RPCService implements MyServiceAsync { MyServiceAsync service = (MyServiceAsync) GWT.create(MyService.class); ServiceDefTarget endpoint = (ServiceDefTarget) service; public RPCService() { endpoint.setServiceEntryPoint(GWT.getModuleBaseURL() + rpc); } public void testRPC(String message, AsyncCallback callback) { service.testRPC(message, callback); } } - SERVER SIDE: package de.vogella.gwt.helloworld.server; import java.text.DateFormat; import java.util.Date; import java.io.*; import de.vogella.gwt.helloworld.client.MyService; import com.google.gwt.user.server.rpc.RemoteServiceServlet; public class MyServiceImpl extends RemoteServiceServlet implements MyService { //implementazione del metodo public String testRPC(String message) { Date now = new Date(); String dtm = DateFormat.getTimeInstance(DateFormat.MEDIUM).format(now); FileOutputStream fos; DataOutputStream dos; //ERROR!!! try { BufferedWriter out = new BufferedWriter (new FileWriter
Re: JRE Emulation Reference - not updated
Good catch, Matti. We'll update the JRE doc. Thanks! /dmc On Mon, Jan 3, 2011 at 2:05 AM, MrMasa matti.simp...@swp.fi wrote: Hello! I believe that new JRE emulation classes was implemented in GWT 2.1.0, e.g. java.math.BigDecimal. At least this class is still missing from JRE Emulation Reference page. http://code.google.com/intl/fi-FI/webtoolkit/doc/latest/RefJreEmulation.html Regards, Matti -- 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. -- David Chandler Developer Programs Engineer, Google Web Toolkit w: http://code.google.com/ b: http://googlewebtoolkit.blogspot.com/ t: @googledevtools -- 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: JRE Emulation Reference - not updated
David, FWIW, someone also entered this issue report (although the spelling sets my teeth on edge) http://code.google.com/p/google-web-toolkit/issues/detail?id=5828 On Jan 3, 8:40 am, David Chandler drfibona...@google.com wrote: Good catch, Matti. We'll update the JRE doc. Thanks! /dmc On Mon, Jan 3, 2011 at 2:05 AM, MrMasa matti.simp...@swp.fi wrote: Hello! I believe that new JRE emulation classes was implemented in GWT 2.1.0, e.g. java.math.BigDecimal. At least this class is still missing from JRE Emulation Reference page. http://code.google.com/intl/fi-FI/webtoolkit/doc/latest/RefJreEmulati... Regards, Matti -- 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 athttp://groups.google.com/group/google-web-toolkit?hl=en. -- David Chandler Developer Programs Engineer, Google Web Toolkit w:http://code.google.com/ b:http://googlewebtoolkit.blogspot.com/ t: @googledevtools -- 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: Having multiple semi-autonomous .html pages vs single page with multiple Places ?
One implication that you'll have is the possible increase of compilation units in your applications. Since each of the host pages would show something different, you'd have one entry point for each. Since you don't want to download and start all of the entry points when you're only using one, you'll want them in separate modules. This will slow down GWT compilation because any code shared among the modules (including GWT itself and the JRE emulation layer) will be recompiled for each module. For a new project, I'm not sure what you would gain be keeping these separate, other than having separate .html locations for each feature (which is a purely aesthetic decision as you can achieve persistent locations for each feature using GWT's history support, especially places in GWT 2.1). I faced a similar problem when trying to integrate GWT into a legacy application. I didn't want to replace the entire application frame (yet) but wanted to be able to implement certain pages using GWT. After manually implementing a solution involving a single dispatching entry point and a javascript variable token, I came across gwt-multipage (http://gwtmultipage.org/) which did something similar using a URL pattern. I contributed the javascript token switching logic to that project and am using it now. If you really need separate pages, that might be helpful for you. -Brian On Sat, Jan 1, 2011 at 8:29 PM, zixzigma zixzi...@gmail.com wrote: Hello Everyone, normally GWT apps are consisted of only one HTML page. this html page loads one or more scripts. User navigation is through manipulating the history tokens/Places. what if someone decided to implement the approach below: instead of having only one HTML page for entire application, have one HTML page per functional area (workspace/section). for example, if an application has Employee Management section , Document Management section, AccountSettings section, Message/Notification section, what if, these four different part of the application, were in fact in four separate HTML files. and navigating from one section to other, was done in traditional sense. each section, in its own page, showing widgets/interacting with user, loading data/ etc basically an independent application on its own and once user decides to navigate away to different part of an application, it is basically a different gwt .html page. to summarize, partitioning our big application into semi-autonomous sections, with their own .html file. and linking these sections through a href= after all, these gwt main html files, are basically empty, just loading a script, so it is not like we are loading a heavyweight html page. what is wrong with this design ? what are the implications ? -- 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.
Request Builder and cross domain requests
I am trying to use RequestBuilder to access an xml document that is available on the same server as my GWT 2.1 application but in a different servlet container. Thus my GWT application is accessed via http://localhost:8084/sdv and the xml document is accessed via localhost:8086:/geoserver/rest/... The code I am using is shown below. RequestBuilder builder = new RequestBuilder( RequestBuilder.GET, getRestUrl(layer)); try { Request request = builder.sendRequest(null, new RequestCallback() { public void onError(Request request, Throwable exception) { } public void onResponseReceived(Request request, Response response) { } }); } catch (RequestException e) { } Is it that the domain is bboth the server and port, not just the server. John -- 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: Tutorial 1: Getting started with guit framework. 2:30 minutes video
No, sorry, my spoken english sucks... no that I write very good :) .. I am from Argentina On Mon, Jan 3, 2011 at 11:41 AM, Falcon msu.fal...@gmail.com wrote: Out of curiosity, is there supposed to be audio? On Jan 2, 2:37 pm, Gal Dolber gal.dol...@gmail.com wrote: http://www.youtube.com/watch?v=S_u7CkU_NnI -- Guit: Elegant, beautiful, modular and *production ready* gwt applications. http://code.google.com/p/guit/ -- 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. -- Guit: Elegant, beautiful, modular and *production ready* gwt applications. http://code.google.com/p/guit/ -- 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.
Label Click Handler Problem
Hi, I am getting an error when clicking on a label, the label has a click handler attached to it, i am using GWT 2.1 and the problem is only on IE stack trace: 09:27:45.777 [ERROR] [biddingsystem] Uncaught exception escaped com.google.gwt.event.shared.UmbrellaException: One or more exceptions caught, see full set in UmbrellaException#getCauses at com.google.gwt.event.shared.SimpleEventBus.doFire(SimpleEventBus.java: 214) at com.google.gwt.event.shared.SimpleEventBus.fireEvent(SimpleEventBus.java: 103) at com.google.gwt.event.shared.HandlerManager.fireEvent(HandlerManager.java: 96) at com.google.gwt.user.client.ui.Widget.fireEvent(Widget.java:107) at com.google.gwt.event.dom.client.DomEvent.fireNativeEvent(DomEvent.java: 116) at com.google.gwt.user.client.ui.Widget.onBrowserEvent(Widget.java: 155) at com.google.gwt.user.client.DOM.dispatchEventImpl(DOM.java:1308) at com.google.gwt.user.client.DOM.dispatchEvent(DOM.java:1264) at sun.reflect.GeneratedMethodAccessor206.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java: 25) at java.lang.reflect.Method.invoke(Method.java:597) at com.google.gwt.dev.shell.MethodAdaptor.invoke(MethodAdaptor.java:103) at com.google.gwt.dev.shell.MethodDispatch.invoke(MethodDispatch.java:71) at com.google.gwt.dev.shell.OophmSessionHandler.invoke(OophmSessionHandler.java: 157) at com.google.gwt.dev.shell.BrowserChannelServer.reactToMessagesWhileWaitingForReturn(BrowserChannelServer.java: 326) at com.google.gwt.dev.shell.BrowserChannelServer.invokeJavascript(BrowserChannelServer.java: 207) at com.google.gwt.dev.shell.ModuleSpaceOOPHM.doInvoke(ModuleSpaceOOPHM.java: 126) at com.google.gwt.dev.shell.ModuleSpace.invokeNative(ModuleSpace.java: 561) at com.google.gwt.dev.shell.ModuleSpace.invokeNativeObject(ModuleSpace.java: 269) at com.google.gwt.dev.shell.JavaScriptHost.invokeNativeObject(JavaScriptHost.java: 91) at com.google.gwt.core.client.impl.Impl.apply(Impl.java) at com.google.gwt.core.client.impl.Impl.entry0(Impl.java:214) at sun.reflect.GeneratedMethodAccessor202.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java: 25) at java.lang.reflect.Method.invoke(Method.java:597) at com.google.gwt.dev.shell.MethodAdaptor.invoke(MethodAdaptor.java:103) at com.google.gwt.dev.shell.MethodDispatch.invoke(MethodDispatch.java:71) at com.google.gwt.dev.shell.OophmSessionHandler.invoke(OophmSessionHandler.java: 157) at com.google.gwt.dev.shell.BrowserChannelServer.reactToMessages(BrowserChannelServer.java: 281) at com.google.gwt.dev.shell.BrowserChannelServer.processConnection(BrowserChannelServer.java: 531) at com.google.gwt.dev.shell.BrowserChannelServer.run(BrowserChannelServer.java: 352) at java.lang.Thread.run(Thread.java:662) Caused by: com.google.gwt.event.shared.UmbrellaException: One or more exceptions caught, see full set in UmbrellaException#getCauses at com.google.gwt.event.shared.SimpleEventBus.doFire(SimpleEventBus.java: 214) at com.google.gwt.event.shared.SimpleEventBus.fireEvent(SimpleEventBus.java: 103) at com.google.gwt.event.shared.HandlerManager.fireEvent(HandlerManager.java: 96) at com.BiddingSystem.client.Presenter.SigninRegisterPresenter $1.onClick(SigninRegisterPresenter.java:50) at com.google.gwt.event.dom.client.ClickEvent.dispatch(ClickEvent.java: 54) at com.google.gwt.event.dom.client.ClickEvent.dispatch(ClickEvent.java:1) at com.google.gwt.event.shared.SimpleEventBus.doFire(SimpleEventBus.java: 204) at com.google.gwt.event.shared.SimpleEventBus.fireEvent(SimpleEventBus.java: 103) at com.google.gwt.event.shared.HandlerManager.fireEvent(HandlerManager.java: 96) at com.google.gwt.user.client.ui.Widget.fireEvent(Widget.java:107) at com.google.gwt.event.dom.client.DomEvent.fireNativeEvent(DomEvent.java: 116) at com.google.gwt.user.client.ui.Widget.onBrowserEvent(Widget.java: 155) at com.google.gwt.user.client.DOM.dispatchEventImpl(DOM.java:1308) at com.google.gwt.user.client.DOM.dispatchEvent(DOM.java:1264) at sun.reflect.GeneratedMethodAccessor206.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java: 25) at java.lang.reflect.Method.invoke(Method.java:597) at com.google.gwt.dev.shell.MethodAdaptor.invoke(MethodAdaptor.java:103) at com.google.gwt.dev.shell.MethodDispatch.invoke(MethodDispatch.java:71) at com.google.gwt.dev.shell.OophmSessionHandler.invoke(OophmSessionHandler.java: 157) at com.google.gwt.dev.shell.BrowserChannelServer.reactToMessagesWhileWaitingForReturn(BrowserChannelServer.java: 326) at com.google.gwt.dev.shell.BrowserChannelServer.invokeJavascript(BrowserChannelServer.java: 207) at com.google.gwt.dev.shell.ModuleSpaceOOPHM.doInvoke(ModuleSpaceOOPHM.java: 126) at
SelectionCell is displaying empty combo box
Hi, I have a cellTable and am displaying combox in one of the columns. I use SelectionCell for the same but my problem is that the combobox is displayed in all rows but all are empty, they dont show any values there. Code is as follows: final ListString picUps = new ArrayListString(); // Adding values to picUps list SelectionCell picUpPointCell = new SelectionCell(picUps); ColumnIBusObjectRpc, String pickUpCol = new ColumnIBusObjectRpc, String(picUpPointCell) { @Override public String getValue(IBusObjectRpc object) { if(object instanceof TktvalaTripDTO) { return ((TktvalaTripDTO)object).getPickupPoint().get(0).getName(); }else if(object instanceof TktgooseBusDTO) { return ((TktgooseBusDTO)object).getPickupPoints().get(0).getDesc(); } return null; } }; table.addColumn(pickUpCol, Pic ups); I make sure that the proper values are returned from getValue(). Can somebody find out what i am doing wrong. Thanlks Deepak -- 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.
Asyncronous calls in RCP behaves wierd.
Hello, I'm doing a project where in the interface shows a listBox that includes the names of some books, the thing is that you must choose one and you will look wether in pdf or txt. My problem is that when changing the listbox, itll show the just last book you chose, rather the current one. heres the program so far. http://kido180020783.appspot.com/ Here's the part of the code that presents the problem. setCurrentBook(bookList.getItemText(bookList.getSelectedIndex())); if (pdfFlag) { if (!txtFlag) { pdfBook.setSize(booksPanelWidth, booksPanelHeight); } else { booksPanelWidth = String.valueOf(BOOKS_PANEL_WIDTH / 2); pdfBook.setSize(booksPanelWidth, booksPanelHeight); txtBook.setSize(booksPanelWidth, booksPanelHeight); } pdfBook.setUrl(pdf/ + currentBook.getUriPath() + .pdf); } else { .. //This method is being called AFTER the line pdfBook.setUrl(pdf/ + currentBook.getUriPath() + .pdf); wich is weird!!. public void setCurrentBook(String bookName) { AsyncCallbackBook callback = new AsyncCallbackBook() { public void onFailure(Throwable caught) { throw new UnsupportedOperationException(Not supported yet.); } public void onSuccess(Book result) { currentBook = result; } }; bookServicesHolder.loadBookByName(bookName, callback); } I dont want the method to be Asyncronous, please I really need some 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.
empty ghost place token getting created
Hi In my application, I'm using the MVP pattern with activities and places. I have a situation where: (1) I explicitely call: placeController.goto(new SomePlace()); (2) The appropriate SomePlaceActivity's start() gets called via event management as expected. (3) This method creates gets a SomePlaceView, and swaps it into the UI (4) An appropriate history event happens and http://mylocalenvironment#SomePlace:someplace appears briefly on my browser's nav bar. Then it gets weird. (5) A new empty String token gets created somehow. (6) It goes through the history management process, causing the defaultPlace to be created (7) The start() method on DefaultPlaceActivity() gets called (8) The app navigates away from SomePlace to DefaultPlace which makes me sad and very confused. I cannot figure out how that empty token gets created and the event handling mechanism gets invoked the second time. The code for this is, of course, spread over many files so its difficult to provide all the relevant code, but I've included much of what I think could be useful here. I'm hoping that people have seen this happen before and can point me to a typical cause. // from my ActivityMapper public Activity getActivity(Place place) { if (place instanceof LoginPlace) return new LoginPresenter((LoginPlace) place, factory); else if (place instanceof SomePlace ) return new SomePlaceActivity((SomePlace) place, factory); else if (place instanceof ForgotPasswordPlace ) return new ForgotPasswordPresenter((ForgotPasswordPlace) place, factory); return null; } // from SomePlace public class SomePlace extends Place { private final String name = somePlace; public SomePlace() { } public String getName() { return name;} public static class Tokenizer implements PlaceTokenizerSomePlace { public String getToken(SomePlace place) { return place.getName(); } public SomePlace getPlace(String token) { return new SomePlace(); } } } // from SomePlaceActivity public class SomePlaceActivity extends AbstractActivity implements Activity { private ClientFactory clientFactory; private SomePlace place; public SomePlaceActivity(SomePlace place, ClientFactory clientFactory){ this.clientFactory=clientFactory; this.place = place; } public void start(AcceptsOneWidget panel, EventBus eventBus) { clientFactory.getMainPanel().replaceCenter(clientFactory.getSomePlaceView().asWidget()); } } // from my entrypoint class's onModuleLoad() method ActivityMapper activityMapper = new ClientFactoryImpl.Controller(clientFactory); ActivityManager activityManager = new ActivityManager(activityMapper, clientFactory.getEventBus()); activityManager.setDisplay(clientFactory.getMainPanel().getCenter()); AppPlaceHistoryMapper historyMapper= GWT.create(AppPlaceHistoryMapper.class); PlaceHistoryHandler historyHandler = new PlaceHistoryHandler(historyMapper); historyHandler.register(placeController, clientFactory.getEventBus(), defaultPlace); // Goes to place represented on URL or default place historyHandler.handleCurrentHistory(); // from my AppPlaceHistoryMapper interface @WithTokenizers( { LoginPlace.Tokenizer.class, SomePlace.Tokenizer.class, ForgotPasswordPlace.Tokenizer.class }) public interface AppPlaceHistoryMapper extends PlaceHistoryMapper { } -- 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: Layout three GWT panels Horizontally
thank you ,i'll give that a try. On Dec 30 2010, 8:37 pm, Owen Powell opow...@gmail.com wrote: I'd try DockLayoutPanel with a HorizontalPanel in the West that holds most of your Widgets, and the final Widget in the Center. As for how to write it up, I'd do it with UiBinderhttp://code.google.com/intl/es/webtoolkit/doc/latest/DevGuideUiBinder...and CSS. ~Owen -- 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 avoid instanceof checks in ActivityMapper ? is DoubleDispatch used in Expenses sample ?
are you suggesting this is nothing to worry about ? in the case of Expenses app, there are only three entities: Expenses, Reports, Employees (and number of places and fine-grained activities mapper, is relative to the number of entities) however, in a larger app , there might be 50 entities. and when using 4-5 ActivityMappers (for different display regions), it will get difficult to manage. #1 - One approach is checking all our 50 entities(or places) in one giant if/else block. (50 if/else statement) #2- However, I believe we can group together our fine-grained activities-mapper, by using a base class for each group, and delegating the instance of checks, to a more specific activities mapper. this is better than using one giant if/else in ActivityMapper, but somehow these selections gets scattered. My Concern is this: I have read that frequent usage of instance of is a sign of code smell.[*] and also have read that if we have to resort to conditional instanceof checks, it is better to keep it in one place for the smell not getting spread ! the approach #2, delegating the instanceof checks to a more specific mapper, will result in the code smell to spread. and code inspection tools also flag these instanceof, it gives the impression of poor application design. this is what I'm very worried about : ( [*]Java quality assurance by detecting code smells http://citeseerx.ist.psu.edu/viewdoc/download?doi=10.1.1.80.2066rep=rep1type=pdf -- 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: Layout three GWT panels Horizontally
Just a question before trying this method: you don't think using DockLayoutPanel (which uses absolute positioning) will not allow my Editor Panel to resize automatically to the height of its children widgets? I was encountering this problem with first code using DockLayoutPanel ; so you suggest only use DockLayoutPanel as the top higher Panel to hold all other children widgets and that the children widgets should not use DockLayoutPanel ; is that correct? On Dec 30 2010, 8:37 pm, Owen Powell opow...@gmail.com wrote: I'd try DockLayoutPanel with a HorizontalPanel in the West that holds most of your Widgets, and the final Widget in the Center. As for how to write it up, I'd do it with UiBinderhttp://code.google.com/intl/es/webtoolkit/doc/latest/DevGuideUiBinder...and CSS. ~Owen -- 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 GWT 2.1.1
Aldo, If this is a Roo-generated app, you'll need to wait to until Roo 1.1.1 is released to upgrade to GWT 2.1.1. For now Roo-generated apps are only compatible with GWT 2.1. -- Chris On Fri, Dec 31, 2010 at 11:28 AM, Aldo Neto tumo...@gmail.com wrote: Hi All, I'm using STS 2.5.1 (i.e. Eclipse 3.6) and tried to upgrade to GWT 2.1.1, but I'm not able to do so. I updated the plugin and the SDK, updated the project reference to use them and compile the project. It all worked fine, but when I tried to run the project I got the errors below. Does anybody has any idea of what I'm doing wrong here? Thanks [ERROR] [applicationScaffold] - Errors in 'jar:file:/D:/springsource/sts-2.5.1.RELEASE/plugins/com.google.gwt.eclipse.sdkbundle.2.1.1_2.1.1.v201012170127/gwt-2.1.1/gwt-user.jar!/com/google/gwt/requestfactory/client/impl/AbstractClientRequestFactory.java' [ERROR] [applicationScaffold] - Line 29: The constructor DefaultRequestTransport() is undefined [ERROR] [applicationScaffold] - Errors in 'jar:file:/D:/springsource/sts-2.5.1.RELEASE/plugins/com.google.gwt.eclipse.sdkbundle.2.1.1_2.1.1.v201012170127/gwt-2.1.1/gwt-user.jar!/com/google/gwt/requestfactory/shared/DefaultProxyStore.java' [ERROR] [applicationScaffold] - Line 37: No source code is available for type com.google.gwt.autobean.shared.AutoBeanT; did you forget to inherit a required module? [ERROR] [applicationScaffold] - Line 38: No source code is available for type com.google.gwt.autobean.shared.Splittable; did you forget to inherit a required module? [ERROR] [applicationScaffold] - Line 60: No source code is available for type com.google.gwt.autobean.shared.AutoBeanCodex; did you forget to inherit a required module? [ERROR] [applicationScaffold] - Errors in 'jar:file:/D:/springsource/sts-2.5.1.RELEASE/plugins/com.google.gwt.eclipse.sdkbundle.2.1.1_2.1.1.v201012170127/gwt-2.1.1/gwt-user.jar!/com/google/gwt/requestfactory/shared/ProxyStore.java' [ERROR] [applicationScaffold] - Line 36: No source code is available for type com.google.gwt.autobean.shared.Splittable; did you forget to inherit a required module? [ERROR] [applicationScaffold] - Errors in 'jar:file:/D:/springsource/sts-2.5.1.RELEASE/plugins/com.google.gwt.eclipse.sdkbundle.2.1.1_2.1.1.v201012170127/gwt-2.1.1/gwt-user.jar!/com/google/gwt/requestfactory/shared/impl/AbstractRequest.java' [ERROR] [applicationScaffold] - Line 39: Bound mismatch: The type BaseProxy is not a valid substitute for the bounded parameter P extends EntityProxy of the type InstanceRequestP,T [ERROR] [applicationScaffold] - Line 113: No source code is available for type com.google.gwt.autobean.shared.Splittable; did you forget to inherit a required module? [ERROR] [applicationScaffold] - Errors in 'jar:file:/D:/springsource/sts-2.5.1.RELEASE/plugins/com.google.gwt.eclipse.sdkbundle.2.1.1_2.1.1.v201012170127/gwt-2.1.1/gwt-user.jar!/com/google/gwt/requestfactory/shared/impl/AbstractRequestContext.java' [ERROR] [applicationScaffold] - Line 19: The import com.google.gwt.requestfactory.shared.impl.Constants.REQUEST_CONTEXT cannot be resolved [ERROR] [applicationScaffold] - Line 63: The type AbstractRequestContext must implement the inherited abstract method RequestContext.create(ClassT) [ERROR] [applicationScaffold] - Line 63: The type AbstractRequestContext must implement the inherited abstract method RequestContext.edit(T) [ERROR] [applicationScaffold] - Line 374: Constants.VERSION_PROPERTY_B64 cannot be resolved [ERROR] [applicationScaffold] - Line 411: Constants.VERSION_PROPERTY_B64 cannot be resolved [ERROR] [applicationScaffold] - Line 511: REQUEST_CONTEXT cannot be resolved [ERROR] [applicationScaffold] - Line 606: The type new RequestTransport.TransportReceiver(){} must implement the inherited abstract method RequestTransport.TransportReceiver.onTransportFailure(String) [ERROR] [applicationScaffold] - Line 616: The constructor ServerFailure(String, String, String, boolean) is undefined [ERROR] [applicationScaffold] - Line 654: The constructor ServerFailure(String, String, String, boolean) is undefined [ERROR] [applicationScaffold] - Line 698: REQUEST_CONTEXT cannot be resolved [ERROR] [applicationScaffold] - Line 845: REQUEST_CONTEXT cannot be resolved [ERROR] [applicationScaffold] - Errors in 'jar:file:/D:/springsource/sts-2.5.1.RELEASE/plugins/com.google.gwt.eclipse.sdkbundle.2.1.1_2.1.1.v201012170127/gwt-2.1.1/gwt-user.jar!/com/google/gwt/requestfactory/shared/impl/AbstractRequestFactory.java' [ERROR] [applicationScaffold] - Line 18: The import com.google.gwt.requestfactory.shared.impl.Constants.STABLE_ID cannot be resolved [ERROR] [applicationScaffold] - Line 65: STABLE_ID cannot be resolved [ERROR] [applicationScaffold] - Line 95: The method getTypeToken(Class? extends BaseProxy) in the type IdFactory is not applicable for the arguments (Classcapture#1-of ? extends EntityProxy) [ERROR] [applicationScaffold] - Line 105:
Re: Asyncronous calls in RCP behaves wierd.
It is also saving more books when reloading the page (but I dont care much about it as that wont be too painful to fix). But please I need some help on the RCP asyncronous calls. What workaround can I do?. Kido. On 3 January 2011 19:23, Kidowell crui...@gmail.com wrote: Hello, I'm doing a project where in the interface shows a listBox that includes the names of some books, the thing is that you must choose one and you will look wether in pdf or txt. My problem is that when changing the listbox, itll show the just last book you chose, rather the current one. heres the program so far. http://kido180020783.appspot.com/ Here's the part of the code that presents the problem. setCurrentBook(bookList.getItemText(bookList.getSelectedIndex())); if (pdfFlag) { if (!txtFlag) { pdfBook.setSize(booksPanelWidth, booksPanelHeight); } else { booksPanelWidth = String.valueOf(BOOKS_PANEL_WIDTH / 2); pdfBook.setSize(booksPanelWidth, booksPanelHeight); txtBook.setSize(booksPanelWidth, booksPanelHeight); } pdfBook.setUrl(pdf/ + currentBook.getUriPath() + .pdf); } else { .. //This method is being called AFTER the line pdfBook.setUrl(pdf/ + currentBook.getUriPath() + .pdf); wich is weird!!. public void setCurrentBook(String bookName) { AsyncCallbackBook callback = new AsyncCallbackBook() { public void onFailure(Throwable caught) { throw new UnsupportedOperationException(Not supported yet.); } public void onSuccess(Book result) { currentBook = result; } }; bookServicesHolder.loadBookByName(bookName, callback); } I dont want the method to be Asyncronous, please I really need some 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.comgoogle-web-toolkit%2bunsubscr...@googlegroups.com . For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en. -- Cesar Ruiz. -- 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: Layout three GWT panels Horizontally
No Sorry this doesn't work! as i explained the DockLayoutPanel is not automatically resized to fit its children height.it uses absolute positioning (i explained this issue in my post). this gives me a weired Panel displaying nothing! as i guess its children height should be set. but i need the Editor to resize automatically into its children height. any other Idea? On Dec 30 2010, 8:37 pm, Owen Powell opow...@gmail.com wrote: I'd try DockLayoutPanel with a HorizontalPanel in the West that holds most of your Widgets, and the final Widget in the Center. As for how to write it up, I'd do it with UiBinderhttp://code.google.com/intl/es/webtoolkit/doc/latest/DevGuideUiBinder...and CSS. ~Owen -- 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: Asyncronous calls in RCP behaves wierd.
If I understand your code correctly, its actually doing exactly what you've asked it to do. You are calling a method called 'setCurrentBook(..))' which doesn't seem to do anything very much. You are then defining a callback 'public void setCurrentBook(String bookname)' blah... You are then *invoking* the call back bookServicesHolder.loadBookByName(bookName, callback); Your call back sets a variable called 'currentBook' and I cannot see what you intend this to do from the code provided, but, as written, its not going to do anything very much. If if is a global variable then you will never get the result you require. You need to carefully re-read the section in the GWT docs about Asynchronous calls. If you are using GWT you *MUST* use and fully understand asynchronous RPC - that's what Ajax is all about. It *should* go something like this. * Define an RPC callback for a particular service typically by using an anonymous inner class. * Invoke the call back specifying the data object (book) you want to read * On the successful asynchronous return, update the UI, by calling the update method from within the callback onSuccess method. There are many, many examples out there. In short, don't update the UI until the callback returns. If you don't want to make these calls asynchronous, then convert your program to a more servlet-centric approach. There are a (large) number of other web frameworks which will do this for you. GWT is all about Ajax and RPC. HTH Alan On 1/3/2011 12:17 PM, Cesar Ruiz wrote: It is also saving more books when reloading the page (but I dont care much about it as that wont be too painful to fix). But please I need some help on the RCP asyncronous calls. What workaround can I do?. Kido. On 3 January 2011 19:23, Kidowell crui...@gmail.com mailto:crui...@gmail.com wrote: Hello, I'm doing a project where in the interface shows a listBox that includes the names of some books, the thing is that you must choose one and you will look wether in pdf or txt. My problem is that when changing the listbox, itll show the just last book you chose, rather the current one. heres the program so far. http://kido180020783.appspot.com/ Here's the part of the code that presents the problem. setCurrentBook(bookList.getItemText(bookList.getSelectedIndex())); if (pdfFlag) { if (!txtFlag) { pdfBook.setSize(booksPanelWidth, booksPanelHeight); } else { booksPanelWidth = String.valueOf(BOOKS_PANEL_WIDTH / 2); pdfBook.setSize(booksPanelWidth, booksPanelHeight); txtBook.setSize(booksPanelWidth, booksPanelHeight); } pdfBook.setUrl(pdf/ + currentBook.getUriPath() + .pdf); } else { .. //This method is being called AFTER the line pdfBook.setUrl(pdf/ + currentBook.getUriPath() + .pdf); wich is weird!!. public void setCurrentBook(String bookName) { AsyncCallbackBook callback = new AsyncCallbackBook() { public void onFailure(Throwable caught) { throw new UnsupportedOperationException(Not supported yet.); } public void onSuccess(Book result) { currentBook = result; } }; bookServicesHolder.loadBookByName(bookName, callback); } I dont want the method to be Asyncronous, please I really need some 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-toolkit@googlegroups.com mailto:google-web-toolkit@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com mailto:google-web-toolkit%2bunsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en. -- Cesar Ruiz. -- 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: Multiple leftover fragments with a tree of code split points?
Anybody of the Dev team has a bit of advice on this ? Or might it be better to drop this in the contributor list? -- 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 avoid instanceof checks in ActivityMapper ? is DoubleDispatch used in Expenses sample ?
My app has a Place for every EntityProxy type. BasePlace has getProxyType() method that is called in MyActivityMapper.getActivity(place). Based on the proxy type returned, getActivity() method looks up an activity factory and calls factory.createActivity(place, config) All I have to do is to create an factory for every activity and configure the lookup table. If I forget to create a factory for a new activity, an assert will warn me about that. This might not be the best approach (may be there is a way to replace my factories with Gin, but I haven't investigated this yet), but I don't have any instaceof's in the ActivityMapper. If someone uses other approaches, please share, it would be very informative. On Jan 3, 11:40 am, zixzigma zixzi...@gmail.com wrote: are you suggesting this is nothing to worry about ? in the case of Expenses app, there are only three entities: Expenses, Reports, Employees (and number of places and fine-grained activities mapper, is relative to the number of entities) however, in a larger app , there might be 50 entities. and when using 4-5 ActivityMappers (for different display regions), it will get difficult to manage. #1 - One approach is checking all our 50 entities(or places) in one giant if/else block. (50 if/else statement) #2- However, I believe we can group together our fine-grained activities-mapper, by using a base class for each group, and delegating the instance of checks, to a more specific activities mapper. this is better than using one giant if/else in ActivityMapper, but somehow these selections gets scattered. My Concern is this: I have read that frequent usage of instance of is a sign of code smell.[*] and also have read that if we have to resort to conditional instanceof checks, it is better to keep it in one place for the smell not getting spread ! the approach #2, delegating the instanceof checks to a more specific mapper, will result in the code smell to spread. and code inspection tools also flag these instanceof, it gives the impression of poor application design. this is what I'm very worried about : ( [*]Java quality assurance by detecting code smellshttp://citeseerx.ist.psu.edu/viewdoc/download?doi=10.1.1.80.2066rep=... -- 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: Problem with java.util.Date
Hi, I'm usign java.util.Date!!! So the dafult constructor is present. My IDE import java.util and not java.sql package. Any ideas? Thanks! On 30 Dic 2010, 22:49, Y2i yur...@gmail.com wrote: java.sql.Date does not have a default constructor, so the example won't compile; it must be something different. BTW, I copied the three lines above to my client code: there is no problem with compiling and running it using java.util.Date and GWT 2.1.1. On Dec 30, 1:31 pm, Slava Lovkiy slava.lov...@gmail.com wrote: Is this error happing in old code or newly created? Check the package name in the import of the file, there is a chance your IDE auto-imported class Date not from java.util but from java.sql package. On Dec 31, 2:17 am, bond daniele.re...@gmail.com wrote: Hi, with the last version of GWT (2.1.1); in the client when I'm using this code: Date date = new Date(); date.setHours(13); date.setMinutes(00); throw this exception: java.lang.IllegalArgumentException: null at java.sql.Date.setHours(Unknown Source) I think that the problem is linked to the fact that now java.sql.Date is implemented in Gwt. How I can resolve the problem? Thanks very much 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 google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
Re: Layout three GWT panels Horizontally
What exactly do you want? A parent panel with width=100%, 3 children panels each of their own width, and then something like this? |-- Parent ---| | (space ) | A | B | C | |-| I'm confused as to whether you want the parent to resize or not - in other words, whether the (space) area should exist or not. ~Owen -- 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: Handling clicks on CellWidgets
On Monday, January 3, 2011 3:33:37 PM UTC+1, Ramon Salla wrote: Hi, Happy new year to all! I have some questions regarding cellwidgets. In the showcase http://gwt.google.com/samples/Showcase/Showcase.html#!CwCellSampler when clicking the cell which contains the button, it reacts not only when pressing the button but also when clicking inside the cell but outside the button. First Question, can i avoid this behavior and only reacting to the button press in a cell? See http://code.google.com/p/google-web-toolkit/issues/detail?id=5641 (for now, you'd have to use your own ButtonCell if you want the fixed behavior) Inspecting the code for this example and the sample from CellList i see the following: From the CellList example, each cell is a div with a single onclick. div onclick= __idx=0 class=GEGGSC0BI style=outline:none;tabletbodytr ... /tr/tbody/table/ div From the CellSampler (which uses a cellTable) the onclick is not in each cell but in each row. tr onclick= class=GEGGSC0BEDtd class=GEGGSC0BDC GEGGSC0BFD GEGGSC0BGCdiv style=outline:none;/div/td/tr I tried to use a composite cell with two buttons in a celllist but as there is only one handler per cell, clicking on any of the two buttons (and also outside the buttons but inside the cell) reacts with the same handler. I can't distinguish them. Question 2. How can I distinguish clicks inside a cell when using a cell list. Try using ActionCell instead of ButtonCell Question 3 Am I forced to use celltable with different cells for each column. You can use the same Cell for several columns. If you want columns though, you have to use CellTable, of make your own Cell widget (not trivial) Question 4 How do you managed to distinguish cellclicks if there is only one handler per row in a celltable? Cell widgets use event delegation, they register a single event listener but then dispatch accordingly, depending on the exact element targetted by the event (i.e. FieldUpdater for a given Column, onBrowserEvent and ValueUpdater for a given Cell) -- 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: Problem with java.util.Date
You are using java.util.Date because if you used java.sql.Date your example would not compile. does your example work if you comment out the line below? // date.setHours(13); On Jan 3, 1:16 pm, bond daniele.re...@gmail.com wrote: Hi, I'm usign java.util.Date!!! So the dafult constructor is present. My IDE import java.util and not java.sql package. Any ideas? Thanks! On 30 Dic 2010, 22:49, Y2i yur...@gmail.com wrote: java.sql.Date does not have a default constructor, so the example won't compile; it must be something different. BTW, I copied the three lines above to my client code: there is no problem with compiling and running it using java.util.Date and GWT 2.1.1. On Dec 30, 1:31 pm, Slava Lovkiy slava.lov...@gmail.com wrote: Is this error happing in old code or newly created? Check the package name in the import of the file, there is a chance your IDE auto-imported class Date not from java.util but from java.sql package. On Dec 31, 2:17 am, bond daniele.re...@gmail.com wrote: Hi, with the last version of GWT (2.1.1); in the client when I'm using this code: Date date = new Date(); date.setHours(13); date.setMinutes(00); throw this exception: java.lang.IllegalArgumentException: null at java.sql.Date.setHours(Unknown Source) I think that the problem is linked to the fact that now java.sql.Date is implemented in Gwt. How I can resolve the problem? Thanks very much 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 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 write file with GWT?
On Monday, January 3, 2011 4:46:38 PM UTC+1, alanmechy wrote: The stack trace says it all... com.example.foobar.client.RPCInterface.testRPC (java.lang.String)' Threw an unexpected exception: java. lang.NoClassDefFoundError: java.io.FileWriter is a restricted class. Please see the Google App Engine developer's guide for more details. You're right that the stack trace says it all, but you actually didn't read it correctly: the issue is that java.io.FileWriter cannot be used in AppEngine; this has nothing to do with GWT and/or client vs. server packages. See http://code.google.com/appengine/docs/java/jrewhitelist.html and http://code.google.com/appengine/docs/java/runtime.html#The_Sandbox -- 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: Request Builder and cross domain requests
Yes: http://en.wikipedia.org/wiki/Same_origin_policy and http://tools.ietf.org/html/draft-abarth-origin -- 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 write file with GWT?
I've learned to use ByteArrayOutputStream rather than FileOutputStream when needing to write files using server side logic. What happens after you've created one is another story. On Mon, Jan 3, 2011 at 1:41 PM, Thomas Broyer t.bro...@gmail.com wrote: On Monday, January 3, 2011 4:46:38 PM UTC+1, alanmechy wrote: The stack trace says it all... com.example.foobar.client.RPCInterface.testRPC (java.lang.String)' Threw an unexpected exception: java. lang.NoClassDefFoundError: java.io.FileWriter is a restricted class. Please see the Google App Engine developer's guide for more details. You're right that the stack trace says it all, but you actually didn't read it correctly: the issue is that java.io.FileWriter cannot be used in AppEngine; this has nothing to do with GWT and/or client vs. server packages. See http://code.google.com/appengine/docs/java/jrewhitelist.html and http://code.google.com/appengine/docs/java/runtime.html#The_Sandbox -- 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. -- -- A. Stevko === If everything seems under control, you're just not going fast enough. M. Andretti -- 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 write file with GWT?
Hi Thomas On 1/3/2011 1:41 PM, Thomas Broyer wrote: On Monday, January 3, 2011 4:46:38 PM UTC+1, alanmechy wrote: The stack trace says it all... com.example.foobar.client.RPCInterface.testRPC (java.lang.String)' Threw an unexpected exception: java. lang.NoClassDefFoundError: java.io.FileWriter is a restricted class. Please see the Google App Engine developer's guide for more details. You're right that the stack trace says it all, but you actually didn't read it correctly: the issue is that java.io.FileWriter cannot be used in AppEngine; this has nothing to do with GWT and/or client vs. server packages. See http://code.google.com/appengine/docs/java/jrewhitelist.html and http://code.google.com/appengine/docs/java/runtime.html#The_Sandbox Thanks for pointing this out, yes, I noticed that when I replied to the OP the 2nd time. I overlooked the GAE part. As I also said in my 2nd email I don't have any experience with GAE! I do believe, however, that my 2nd reply to him was correct - to achieve his aim, he will have to use the BlobStore because exactly as indicated FileWriter is not permitted - or stop using GAE! This is a bit OT, but I actually have a large project which takes uploaded files and processes them into a form which could be served by the GAE Blobstore, but I could see no mechanism to save binary data *from* the server *to* the BlobStore. Am I missing something? I discounted using GAE simply for this reason. Regards Alan -- 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: Layout three GWT panels Horizontally
The parent panel souhld fit the children Panels *height*. with DockLayoutPanel it is impossible to do that b/c DockLayoutPanel uses *absolute positioning*. So the solution should never use DockLayoutPanel. the parent should have three Panels Layed out in the most let and then the last one (C) should resize automatically to fit all remaining horizontal space left from parent after positioning A and B in the most left. does this makes sense? I'm surprised how it is so hard to achieve this simple Layout with GWT. there is no Layout Widget that is flexible enough to allow automatic resizing etc..is this Layout impossible to do with standard GWT? |-- Parent ---| || A | B | C | |-| On Mon, Jan 3, 2011 at 9:21 PM, Owen Powell opow...@gmail.com wrote: What exactly do you want? A parent panel with width=100%, 3 children panels each of their own width, and then something like this? |-- Parent ---| | (space ) | A | B | C | |-| I'm confused as to whether you want the parent to resize or not - in other words, whether the (space) area should exist or not. ~Owen -- 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: How to write file with GWT?
Can't you store it in the DB? -- 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 write file with GWT?
On 1/3/2011 2:05 PM, Matthew Hill wrote: Can't you store it in the DB? -- According to the GAE docs: maximum entity size 1 megabyte Most of my entities *start* at 1 MB and go up to maybe 500+ (its 3D data) So, I assumed that, no, I couldn't store it in the DB :-) Alan 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: empty ghost place token getting created
another clue? It seems to have something to do with the Tokenizers. If I comment out these places from the @WithTokenizers{} section of my PlaceHistoryMapper definition as shown at the bottom below, the navigation works correctly (in the sense that the correct page is loaded and navigation stops) but there are no bookmarkable urls and the back button does not work. What I'm looking for here is pretty simple: For the places defined so far, I want a url that looks like: http://myDomainEtc#SomePlace with no more specific data needed. I saw in the documentation: Many places in the app might not save any state to the URL, so they could just extend a BasicPlace that declares a PlaceTokenizer that returns a null token. I tried that, with the same result as the original implementation. The URL now looks like http://myDomainEtc#SomePlace:null, but as long as @WithTokenizers{} includes my SomePlace class, the URL is replaced immediately with a plain one and the browser loads the defaultPlace. On Jan 3, 1:48 pm, jones34 ljw1...@gmail.com wrote: Hi In my application, I'm using the MVP pattern with activities and places. I have a situation where: (1) I explicitely call: placeController.goto(new SomePlace()); (2) The appropriate SomePlaceActivity's start() gets called via event management as expected. (3) This method creates gets a SomePlaceView, and swaps it into the UI (4) An appropriate history event happens andhttp://mylocalenvironment#SomePlace:someplace appears briefly on my browser's nav bar. Then it gets weird. (5) A new empty String token gets created somehow. (6) It goes through the history management process, causing the defaultPlace to be created (7) The start() method on DefaultPlaceActivity() gets called (8) The app navigates away from SomePlace to DefaultPlace which makes me sad and very confused. I cannot figure out how that empty token gets created and the event handling mechanism gets invoked the second time. The code for this is, of course, spread over many files so its difficult to provide all the relevant code, but I've included much of what I think could be useful here. I'm hoping that people have seen this happen before and can point me to a typical cause. // from my ActivityMapper public Activity getActivity(Place place) { if (place instanceof LoginPlace) return new LoginPresenter((LoginPlace) place, factory); else if (place instanceof SomePlace ) return new SomePlaceActivity((SomePlace) place, factory); else if (place instanceof ForgotPasswordPlace ) return new ForgotPasswordPresenter((ForgotPasswordPlace) place, factory); return null; } // from SomePlace public class SomePlace extends Place { private final String name = somePlace; public SomePlace() { } public String getName() { return name;} public static class Tokenizer implements PlaceTokenizerSomePlace { public String getToken(SomePlace place) { return place.getName(); } public SomePlace getPlace(String token) { return new SomePlace(); } } } // from SomePlaceActivity public class SomePlaceActivity extends AbstractActivity implements Activity { private ClientFactory clientFactory; private SomePlace place; public SomePlaceActivity(SomePlace place, ClientFactory clientFactory){ this.clientFactory=clientFactory; this.place = place; } public void start(AcceptsOneWidget panel, EventBus eventBus) { clientFactory.getMainPanel().replaceCenter(clientFactory.getSomePlaceView() .asWidget()); } } // from my entrypoint class's onModuleLoad() method ActivityMapper activityMapper = new ClientFactoryImpl.Controller(clientFactory); ActivityManager activityManager = new ActivityManager(activityMapper, clientFactory.getEventBus()); activityManager.setDisplay(clientFactory.getMainPanel().getCenter()); AppPlaceHistoryMapper historyMapper= GWT.create(AppPlaceHistoryMapper.class); PlaceHistoryHandler historyHandler = new PlaceHistoryHandler(historyMapper); historyHandler.register(placeController, clientFactory.getEventBus(), defaultPlace); // Goes to place represented on URL or default place historyHandler.handleCurrentHistory(); // from my AppPlaceHistoryMapper interface @WithTokenizers( { LoginPlace.Tokenizer.class, SomePlace.Tokenizer.class, ForgotPasswordPlace.Tokenizer.class }) public interface AppPlaceHistoryMapper extends PlaceHistoryMapper { } -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to
Re: Layout three GWT panels Horizontally
suppose Panel A has 3 TextBox one over each others Panel B has 5 TextBoxes Panel C has 8 TextBoxes then parent should be smart enough to make its height fit 8 TextBox. with DockLayoutPanel this does'nt work. or am i doing smth wrong. the Panels are dynamically built and added to parent ,so parent should resize accordinly to fit the height and width of its children. as i said i used H/V panels to achieve automatic vertical resize. but horizontal resize of last pa On Jan 3, 10:02 pm, othman El Moulat othmanelmou...@gmail.com wrote: The parent panel souhld fit the children Panels *height*. with DockLayoutPanel it is impossible to do that b/c DockLayoutPanel uses *absolute positioning*. So the solution should never use DockLayoutPanel. the parent should have three Panels Layed out in the most let and then the last one (C) should resize automatically to fit all remaining horizontal space left from parent after positioning A and B in the most left. does this makes sense? I'm surprised how it is so hard to achieve this simple Layout with GWT. there is no Layout Widget that is flexible enough to allow automatic resizing etc..is this Layout impossible to do with standard GWT? |-- Parent ---| || A | B | C | |-| On Mon, Jan 3, 2011 at 9:21 PM, Owen Powell opow...@gmail.com wrote: What exactly do you want? A parent panel with width=100%, 3 children panels each of their own width, and then something like this? |-- Parent ---| | (space ) | A | B | C | |-| I'm confused as to whether you want the parent to resize or not - in other words, whether the (space) area should exist or not. ~Owen -- 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: Layout three GWT panels Horizontally
suppose Panel A has 3 TextBox one over each others Panel B has 5 TextBoxes Panel C has 8 TextBoxes then parent should be smart enough to make its height fit 8 TextBox. with DockLayoutPanel this does'nt work. or am i doing smth wrong. the Panels are dynamically built and added to parent ,so parent should resize accordinly to fit the height and width of its children. as i said i used H/V panels to achieve automatic vertical resize. but horizontal resize of last pa On Jan 3, 10:02 pm, othman El Moulat othmanelmou...@gmail.com wrote: The parent panel souhld fit the children Panels *height*. with DockLayoutPanel it is impossible to do that b/c DockLayoutPanel uses *absolute positioning*. So the solution should never use DockLayoutPanel. the parent should have three Panels Layed out in the most let and then the last one (C) should resize automatically to fit all remaining horizontal space left from parent after positioning A and B in the most left. does this makes sense? I'm surprised how it is so hard to achieve this simple Layout with GWT. there is no Layout Widget that is flexible enough to allow automatic resizing etc..is this Layout impossible to do with standard GWT? |-- Parent ---| || A | B | C | |-| On Mon, Jan 3, 2011 at 9:21 PM, Owen Powell opow...@gmail.com wrote: What exactly do you want? A parent panel with width=100%, 3 children panels each of their own width, and then something like this? |-- Parent ---| | (space ) | A | B | C | |-| I'm confused as to whether you want the parent to resize or not - in other words, whether the (space) area should exist or not. ~Owen -- 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: Layout three GWT panels Horizontally
suppose Panel A has 3 TextBox one over each others Panel B has 5 TextBoxes Panel C has 8 TextBoxes then parent should be smart enough to make its height fit 8 TextBox. with DockLayoutPanel this does'nt work. or am i doing smth wrong. the Panels are dynamically built and added to parent ,so parent should resize accordinly to fit the height and width of its children. as i said i used H/V panels to achieve automatic vertical resize. but horizontal resize of last pa On Jan 3, 10:02 pm, othman El Moulat othmanelmou...@gmail.com wrote: The parent panel souhld fit the children Panels *height*. with DockLayoutPanel it is impossible to do that b/c DockLayoutPanel uses *absolute positioning*. So the solution should never use DockLayoutPanel. the parent should have three Panels Layed out in the most let and then the last one (C) should resize automatically to fit all remaining horizontal space left from parent after positioning A and B in the most left. does this makes sense? I'm surprised how it is so hard to achieve this simple Layout with GWT. there is no Layout Widget that is flexible enough to allow automatic resizing etc..is this Layout impossible to do with standard GWT? |-- Parent ---| || A | B | C | |-| On Mon, Jan 3, 2011 at 9:21 PM, Owen Powell opow...@gmail.com wrote: What exactly do you want? A parent panel with width=100%, 3 children panels each of their own width, and then something like this? |-- Parent ---| | (space ) | A | B | C | |-| I'm confused as to whether you want the parent to resize or not - in other words, whether the (space) area should exist or not. ~Owen -- 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: How to write file with GWT?
Can you use com.google.appengine.api.datastore.Text ? Text wraps around a string of unlimited size. http://code.google.com/appengine/docs/java/javadoc/com/google/appengine/api/datastore/Text.html On Mon, Jan 3, 2011 at 2:12 PM, a...@mechnicality.com a...@mechnicality.com wrote: On 1/3/2011 2:05 PM, Matthew Hill wrote: Can't you store it in the DB? -- According to the GAE docs: maximum entity size 1 megabyte Most of my entities *start* at 1 MB and go up to maybe 500+ (its 3D data) So, I assumed that, no, I couldn't store it in the DB :-) Alan 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.comgoogle-web-toolkit%2bunsubscr...@googlegroups.com . For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en. -- -- A. Stevko === If everything seems under control, you're just not going fast enough. M. Andretti -- 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 write file with GWT?
I bookmarked this blog entry a while ago which has a recipe for posting into the blobstore from app engine. http://jeremyblythe.blogspot.com/2010/10/manipulating-images-in-blobstore.html One other note - I suspect using the ByteArrayOutputStream for hundreds of megabytes is going to run into the java runtime memory limit. I'm not sure what the limit is. The error logs show Exceeded soft memory limit with... On Mon, Jan 3, 2011 at 2:29 PM, A. Stevko andy.ste...@gmail.com wrote: Can you use com.google.appengine.api.datastore.Text ? Text wraps around a string of unlimited size. http://code.google.com/appengine/docs/java/javadoc/com/google/appengine/api/datastore/Text.html On Mon, Jan 3, 2011 at 2:12 PM, a...@mechnicality.com a...@mechnicality.com wrote: On 1/3/2011 2:05 PM, Matthew Hill wrote: Can't you store it in the DB? -- According to the GAE docs: maximum entity size 1 megabyte Most of my entities *start* at 1 MB and go up to maybe 500+ (its 3D data) So, I assumed that, no, I couldn't store it in the DB :-) Alan 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.comgoogle-web-toolkit%2bunsubscr...@googlegroups.com . For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en. -- -- A. Stevko === If everything seems under control, you're just not going fast enough. M. Andretti -- -- A. Stevko === If everything seems under control, you're just not going fast enough. M. Andretti -- 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 write file with GWT?
On 1/3/2011 2:29 PM, A. Stevko wrote: Can you use com.google.appengine.api.datastore.Text ? |Text| wraps around a string of unlimited size. http://code.google.com/appengine/docs/java/javadoc/com/google/appengine/api/datastore/Text.html Nope - its 3D vertex and animation data - basically integer and floating point binary values. The whole point of putting it in a blobstore is to avoid having lots of complicated code on the client to parse and process the data. The server processes it, caches it, and makes it available via a URN-based keying system. One possible option is to binhex it, I suppose, but that isn't very attractive, requiring an extra processing step on the client. I think I'll just stick to using Amazon EC2 for my web services! Thanks for the suggestions, however. Regards Alan On Mon, Jan 3, 2011 at 2:12 PM, a...@mechnicality.com mailto:a...@mechnicality.com a...@mechnicality.com mailto:a...@mechnicality.com wrote: On 1/3/2011 2:05 PM, Matthew Hill wrote: Can't you store it in the DB? -- According to the GAE docs: maximum entity size 1 megabyte Most of my entities *start* at 1 MB and go up to maybe 500+ (its 3D data) So, I assumed that, no, I couldn't store it in the DB :-) Alan 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 mailto:google-web-toolkit@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com mailto: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-toolkit@googlegroups.com mailto:google-web-toolkit@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com mailto:google-web-toolkit%2bunsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en. -- -- A. Stevko === If everything seems under control, you're just not going fast enough. M. Andretti -- 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. -- Alan Chaney CTO and Founder, Mechnicality, Inc. www.mechnicality.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: Label Click Handler Problem
The error is at com.BiddingSystem.client.View.LoginView.java: line 61 The relevant portion of your stack is: Caused by: com.google.gwt.core.client.JavaScriptException: (Error): Invalid argument. number: -2147024809 description: Invalid argument. at com.google.gwt.dev.shell.BrowserChannelServer.invokeJavascript(BrowserChannelServer.java: 237) at com.google.gwt.dev.shell.ModuleSpaceOOPHM.doInvoke(ModuleSpaceOOPHM.java: 126) at com.google.gwt.dev.shell.ModuleSpace.invokeNative(ModuleSpace.java: 561) at com.google.gwt.dev.shell.ModuleSpace.invokeNativeVoid(ModuleSpace.java: 289) at com.google.gwt.dev.shell.JavaScriptHost.invokeNativeVoid(JavaScriptHost.java: 107) at com.google.gwt.dom.client.Element$.setPropertyInt$ (Element.java) at com.google.gwt.user.client.DOM.setElementPropertyInt(DOM.java: 1118) at com.google.gwt.user.client.ui.FlexTable $FlexCellFormatter.setColSpan(FlexTable.java:78) at com.BiddingSystem.client.View.LoginView.init(LoginView.java: 61) at com.BiddingSystem.client.ApplicationController $1.onSignIn(ApplicationController.java:110) at ) -- -- A. Stevko === If everything seems under control, you're just not going fast enough. M. Andretti -- 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 avoid instanceof checks in ActivityMapper ? is DoubleDispatch used in Expenses sample ?
thank you for your suggestion. I was thinking of a similar approach, but couldn't come up with a way to populate the lookup table (initialize it for the first time with data). could you please explain how you register activities/places in the lookup table, so that they are available at run-time ? and your comment: My app has a Place for every EntityProxy type. how do you deal with composite entities ? for example, lets say part of our app deals with Projects/Tasks/Issues we have a number of projects, each with a list of tasks and their own list of issues. we would use ProjectProxy and TaskProxy and IssueProxy respectively. and apart from these related places/proxies/activities, lets say another section of our app deals with Account, Payment, BillingHistory, therefore we would need corresponding places/proxies/activities given the scenario above: #1 do you treat each of the entities in isolation, to model their Places/Activities or #2 you group them in a hierarchy for example, ProjectPlace/TaskPlace/IssuePlace can have AbstractProjectPlace base class, or an interface ProjectActivities, TaskActivities, IssueActivities can have an AbstractProjectActivities base class. therefore we are forming a hierarchy, that is different than that of Account, Payment, Billing History, for these three, we use AbstractAccountAcitivites and AbstractAccountPlace base class for Places and Activities. this is one approach, another approach is treating all of them in isolation, act as if Task/Place/Issue have no relationship with eachother, and treat them no differently than Account/Payment/Billing History despite the fact they can be grouped together in their workspace dealing with usecases specific to their hierarchy. what is the best way to deal with scenario above in GWT MVP ? should Activities/Places mimic structure of entity they are related to ? (forming parallel object hierarchies ? for place/activity/proxy ) 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.
Re: EnterButton
I've used this pattern throughout my code base with no problem. On Mon, Jan 3, 2011 at 6:57 AM, Greg Dougherty dougherty.greg...@mayo.eduwrote: I have a couple of places where I want the user to be able to hit enter, and have a button clicked. So I created the class EnterButton, which has all the default constructors, and the following bit of code: public void onKeyPress (KeyPressEvent event) { int keyCode = event.getNativeEvent ().getKeyCode (); if (keyCode == KeyCodes.KEY_ENTER) click (); } Is there a reason why some such class isn't part of GWT already? Is there something in this code that will turn around and bite me in the tush? -- 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. -- -- A. Stevko === If everything seems under control, you're just not going fast enough. M. Andretti -- 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: EnterButton
I haven't tried it but I think if you wrap your input widgets in a gwt form widget your button would respond appropriately. On Mon, Jan 3, 2011 at 9:57 AM, Greg Dougherty dougherty.greg...@mayo.eduwrote: I have a couple of places where I want the user to be able to hit enter, and have a button clicked. So I created the class EnterButton, which has all the default constructors, and the following bit of code: public void onKeyPress (KeyPressEvent event) { int keyCode = event.getNativeEvent ().getKeyCode (); if (keyCode == KeyCodes.KEY_ENTER) click (); } Is there a reason why some such class isn't part of GWT already? Is there something in this code that will turn around and bite me in the tush? -- 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. -- *Jeff Schwartz* -- 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 2.1 compiler option : -noserver
I want to run the appln in Websphere server and trying to explore the -noserver option. However I get the following error: gwtc: [java] Unknown argument: -noserver [java] Google Web Toolkit 2.1.0 has anybody tried this successfully? 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: Any clues on why my gwt project's compilation is so slow?
Thank Thomas. Without GPE, our productivity will be impacted. Do we have other ways to workaround this except to uninstall GPE? On Jan 2, 3:54 am, Thomas Broyer t.bro...@gmail.com wrote: It might be this:http://code.google.com/p/google-web-toolkit/issues/detail?id=5773 -- 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: Any clues on why my gwt project's compilation is so slow?
By the way, I find there is no such problem in Eclipse For Java Developer edition. But there are such problems in Eclipse for JavaEE edition. On Jan 2, 3:54 am, Thomas Broyer t.bro...@gmail.com wrote: It might be this:http://code.google.com/p/google-web-toolkit/issues/detail?id=5773 -- 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: Label Click Handler Problem
if the error is in my application, how is it that everything is fine in chrome and firefox -- 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.
about Listbox
hi all, please help me in listbox widget i would like to add option group in Listbox widget like optiongroup in select tag in html how we make ? please reply me thanks in advance -- Regards, Vijay Gohel -- 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: Read, write, access a file using GWT
Please tell me how or if you have sample app please send me code, idon't know because i am new to GWT. On Dec 30 2010, 8:51 pm, Jeff Larsen larse...@gmail.com wrote: Browsers specifically disallow local file editing. You'd have to serve the file from some kind of container to allow local editing, then post the changes back up to the server. -- 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: Choosing a file in local directory
you i don't know how to access file, so please send sample code if you have. Or can we access using server if it so, please send me code. On Dec 30 2010, 3:38 pm, Didier Durand durand.did...@gmail.com wrote: Hi, GWT Java code gets converted to Javascript. Javascript then runs in the sandbox of your browser: you can't access the local file system because of this sandbox architecture. regards didier On Dec 30, 8:27 am, Rubini rubinikuttyomku...@gmail.com wrote: jc jc.chan...@... writes: I check the fileupload widget, but it show only the filename correctly not full path. it show c:/fakepath/filename. I need to read and wirte a file in a local directory. Send me a sample code if you have. On Dec 28, 8:43 pm, Ben Imp benlee...@... wrote: You would be looking for the FileUpload widget, which just wraps a html file input element. -Ben On Dec 28, 2:15 am, jc jc.chan...@... wrote: Hi, i am new to GWT, but i know java. I am using GWT in Eclipse. for selecting a file in local directory in java, we use JFileChooser. but i don't know to select a file in a local directory in GWT. can any one help please. Hi, can anyone help me to read and write a file in a local directory . The file Upload widget is by default having a text box. how to disable the text box? . In chrome the text box is not editable while in IE i am able to edit it. how to disable the editing feature of file Upload-TxtBox in various browsers -Ruby -- 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: Label Click Handler Problem
Hi, you are setting an integer value that IE interprets it as -2147024809, so the exception. * $FlexCellFormatter.setColSpan(FlexTable.java:78) at com.BiddingSystem.client.View.LoginView.init(LoginView.java:* Thanks, -- * Vagner Araujo O PLANETA É O MEU PAÍS, E A CIÊNCIA É A MINHA RELIGIÃO ! INDO AO INFINITO E ALÉM... !! * [image: logo.gif] -- 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. logo.gif
Re: Is it possible to consturct CellTree form database via rpc
Thank you Y2i, Your messages are greatly help to me But there is an another problem stuck in... updataRowCount() and updataRowData should work with hasData, but cellTree doesnt implement it, so my requestion is, as to cellTree, how do both functions above work? On 2010年12月30日, 下午12时39分, Y2i yur...@gmail.com wrote: It can be populated dynamically. Please take a look at this post: http://groups.google.com/group/google-web-toolkit/msg/6a8f18668f046cc6 When the data provider receives results back it needs to populate itself by calling updateRowCount() updateRowData() On Dec 29, 7:12 pm, yeti superi...@gmail.com wrote: Hi , I wonder if celltree can be built dynamically... getNodeInfo is synchronous, so how to work with a asynchronous, that is , get node info via a request? Someone said, pass a ListDataProvider or AsyncDataProvider into DefaultNodeInfo. Then you can return the NodeInfo synchronously, but populate the data provider asynchronously. Is it right when I return defaultNodeinfo , it will wait me to populate the dataprovider? if not, could anyone show me more details? 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: [gwt-contrib] Stack overflow problem in HashMap.hashCode() and possible fix
mP, This is not a bug in the client, because this is exactly what the client in my case is trying to represent (a recursive graph of maps). It's not a bug to represent that structure. However since regular Java does not support this (i just checked), I agree that GWT should emulate Java's behavior. In my case I'll use the wrapper type I described above, and you're right - I'll have to override equals too. -- http://groups.google.com/group/Google-Web-Toolkit-Contributors
Re: [gwt-contrib] Stack overflow problem in HashMap.hashCode() and possible fix
Have you seen this note in the javadoc for java.lang.Map: Note: great care must be exercised if mutable objects are used as map keys. The behavior of a map is not specified if the value of an object is changed in a manner that affects equals comparisons while the object is a key in the map. A special case of this prohibition is that it is not permissible for a map to contain itself as a key. While it is permissible for a map to contain itself as a value, extreme caution is advised: the equals and hashCode methods are no longer well defined on such a map. – http://download.oracle.com/javase/6/docs/api/java/util/Map.html Instead of using a Map directly, maybe you should use an wrapper object that implements equals() and hashCode() independently of the content of the Map. Or, instead of using the Map itself as the key, use a sentinel object (e.g. public static final Object THIS_MAP = new Object(); ) (that being said, I'm having a hard time figuring out what could represent a Map that contains itself as a *key*) -- http://groups.google.com/group/Google-Web-Toolkit-Contributors
[gwt-contrib] Re: Stack overflow problem in HashMap.hashCode() and possible fix
Thanks for the link, Notice however that I'm not using the map as a key in itself, but as a value in itself, and as a key in another unrelated map. On Jan 3, 11:36 am, Thomas Broyer t.bro...@gmail.com wrote: Have you seen this note in the javadoc for java.lang.Map: Note: great care must be exercised if mutable objects are used as map keys. The behavior of a map is not specified if the value of an object is changed in a manner that affects equals comparisons while the object is a key in the map. A special case of this prohibition is that it is not permissible for a map to contain itself as a key. While it is permissible for a map to contain itself as a value, extreme caution is advised: the equals and hashCode methods are no longer well defined on such a map. –http://download.oracle.com/javase/6/docs/api/java/util/Map.html Instead of using a Map directly, maybe you should use an wrapper object that implements equals() and hashCode() independently of the content of the Map. Or, instead of using the Map itself as the key, use a sentinel object (e.g. public static final Object THIS_MAP = new Object(); ) (that being said, I'm having a hard time figuring out what could represent a Map that contains itself as a *key*) -- http://groups.google.com/group/Google-Web-Toolkit-Contributors
[gwt-contrib] Re: Stack overflow problem in HashMap.hashCode() and possible fix
Thomas - Also, regarding your suggestions the wrapper object is in fact what I'm using for now (my second post mentioned that). But I don't see how a sentinel would help me in my real use case of a complex graph of circular references between maps, since it will be hard to keep track of which sentinel represents which map. On Jan 3, 11:36 am, Thomas Broyer t.bro...@gmail.com wrote: Have you seen this note in the javadoc for java.lang.Map: Note: great care must be exercised if mutable objects are used as map keys. The behavior of a map is not specified if the value of an object is changed in a manner that affects equals comparisons while the object is a key in the map. A special case of this prohibition is that it is not permissible for a map to contain itself as a key. While it is permissible for a map to contain itself as a value, extreme caution is advised: the equals and hashCode methods are no longer well defined on such a map. –http://download.oracle.com/javase/6/docs/api/java/util/Map.html Instead of using a Map directly, maybe you should use an wrapper object that implements equals() and hashCode() independently of the content of the Map. Or, instead of using the Map itself as the key, use a sentinel object (e.g. public static final Object THIS_MAP = new Object(); ) (that being said, I'm having a hard time figuring out what could represent a Map that contains itself as a *key*) -- http://groups.google.com/group/Google-Web-Toolkit-Contributors
[gwt-contrib] Re: Stack overflow problem in HashMap.hashCode() and possible fix
Here's my complete wrapper. It's rather simplistic and could probably use some optimization in .equals, but I didn't try an awful lot. Comments welcome. /** * A wrapper of HashMap that support recursion in values (can contain itself as a value) and still calculate * hashCode and equals correctly. */ public class FixedHashMapK,V extends HashMapK,V { protected boolean _inHashCode = false; protected HashSetFixedHashMap?,? _inEqualsWith = new HashSetFixedHashMap?,?(); @Override public int hashCode() { int result = 0; if (_inHashCode ) { return result; } _inHashCode = true; result = super.hashCode(); _inHashCode = false; return result; } /** * Equals needs to fix the case of comparing two recursive maps. The rest is handled by the default implementation. */ @Override public boolean equals(Object other) { if (this == other) { return true; } if (null == other) { return false; } if (!(other instanceof HashMap)) { return false; } if (!(other instanceof FixedHashMap)) { // We assume other is a non-recursive map, // and the default .equals doesn't recurse infinitely return super.equals(other); } // It may be a recursive map. FixedHashMap?, ? savedOther = (FixedHashMap?, ?) other; if (this._inEqualsWith.contains(savedOther)) { // We are already comparing ourselves with this object! // Return 'true' because the final result will be the conjunction ('and') // of this result and all the other entries. If all the other entries are equal, // we can say the maps are equal. return true; } this._inEqualsWith.add(savedOther); boolean res = super.equals(other); this._inEqualsWith.remove(savedOther); return res; } } -- http://groups.google.com/group/Google-Web-Toolkit-Contributors
[gwt-contrib] Re: Stack overflow problem in HashMap.hashCode() and possible fix
For completeness here's a tester. (it passes on the above code) public static void main(String[] args) { System.out.println(Run this with vm arg: -ea); System.out.println(Running test...); FixedHashMapString,Object recMap1 = new FixedHashMapString, Object(); recMap1.put(me, recMap1); FixedHashMapString,Object recMap2 = new FixedHashMapString, Object(); recMap2.put(me, recMap2); HashMapObject,Object containerMap = new HashMapObject, Object(); containerMap.put(recMap1, null); // causes a stack overflow if recMap1 is a regular HashMap with recursion containerMap.put(recMap2, null); System.out.println(assertions...); assert recMap1.equals(recMap1); assert false == containerMap.equals(recMap1); assert false == recMap1.equals(containerMap); assert containerMap.equals(containerMap); assert recMap1.equals(recMap2); assert containerMap.size() == 1; System.out.println(containerMap.toString()); System.out.println(Done); } -- http://groups.google.com/group/Google-Web-Toolkit-Contributors
[gwt-contrib] Re: Stack overflow problem in HashMap.hashCode() and possible fix
On Monday, January 3, 2011 10:42:28 AM UTC+1, sinelaw wrote: Thomas - Also, regarding your suggestions the wrapper object is in fact what I'm using for now (my second post mentioned that). You're subclassing HashMap, not wrapping a Map. But I don't see how a sentinel would help me in my real use case of a complex graph of circular references between maps, since it will be hard to keep track of which sentinel represents which map. yes, sorry I misread your initial 4-lines repro case. So , I think you'd to use a wrapper object that implements equals and hashCode independently of the content of the wrapped map; something like: // do not implement Map, as it would break the contract for Map.hashCode and Map.equals class WrapperK, V { private final MapK, V map; public Wrapper(MapK,V map) { this.map = map; } public final MapK, V get() { return map; } @Overrides public boolean equals(Object obj) { if (obj == this) { return true; } if (obj instanceof Wrapper) { // use identity comparison: 2 wrappers are equal if they wrap the very same map, independently of its content return map == ((Wrapper) obj).map; } return false; } @Overrides public int hashCode() { // not the best for performances, but at least does not violates the Object.hashCode/equals contract return 31; } } Best would probably be to use a subclass of Map that keeps a reference to the key object so as to maintain a 1:1 bidirectional relationship between maps and their keys (and that way, you don't even have to implement the hashCode and equals methods, the default implementations are sufficient): class MapWithKeyK, V extends HashMapK, V { public final class KeyK, V { public MapWithKeyK, V getMap() { return MapWithKey.this; } } private final KeyK, V key = new KeyK, V(); public final KeyK, V getKey() { return key; } } Then, instead of testMap2.put(testMap, null), you'd use testMap2.put(testMap.getKey(), null); -- http://groups.google.com/group/Google-Web-Toolkit-Contributors
[gwt-contrib] [google-web-toolkit] r9486 committed - Edited wiki page BeanValidation through web user interface.
Revision: 9486 Author: ncha...@google.com Date: Mon Jan 3 14:41:18 2011 Log: Edited wiki page BeanValidation through web user interface. http://code.google.com/p/google-web-toolkit/source/detail?r=9486 Modified: /wiki/BeanValidation.wiki === --- /wiki/BeanValidation.wiki Wed Dec 22 10:25:25 2010 +++ /wiki/BeanValidation.wiki Mon Jan 3 14:41:18 2011 @@ -7,7 +7,7 @@ = Introduction = GWT supports a subset of JSR 303 Bean Validation. -At compile time GWT validation uses the same Validation Provider you use on the server to create Validator for all your objects +At compile time GWT validation uses the same Validation Provider you use on the server to create a Validator for all your objects = Quick Start = -- http://groups.google.com/group/Google-Web-Toolkit-Contributors
[gwt-contrib] [google-web-toolkit] r9487 committed - Added critical bugs.
Revision: 9487 Author: ncha...@google.com Date: Mon Jan 3 14:43:03 2011 Log: Added critical bugs. http://code.google.com/p/google-web-toolkit/source/detail?r=9487 Modified: /wiki/BeanValidation.wiki === --- /wiki/BeanValidation.wiki Mon Jan 3 14:41:18 2011 +++ /wiki/BeanValidation.wiki Mon Jan 3 14:43:03 2011 @@ -74,7 +74,8 @@ [http://code.google.com/p/google-web-toolkit/issues/list?can=2q=label%3Ajsr303 Open issues labeled jsr303] == Critical Bugs == - * None + * Message Interpolation can recurse forever. + * Object Graph Validation can recurse forever == Other Issues == * Calling the correct !ConstraintValidotor based on bean type (class) per the spec. -- http://groups.google.com/group/Google-Web-Toolkit-Contributors