Re: How to Authenticate Uploaded file format, size at the GWT client side?

2010-05-11 Thread Manuel Carrasco Moñino
It is NOT possible to do anything with files using javascript, so Gwt
has nothing to do with files in client side.
So, I recommend you to do this:
- Use gwtupload library http://code.google.com/p/gwtupload/
- At server side extend UploadAction, and write your own file
validations (you can do it when the upload finishes or during the
transmission) using everything available in the java world.
- If the file doesn't match your requirements  throw an
UploadActionException, so that the client side will mark the upload as
unsuccessful and will alert the user.

Cheers
-Manolo

On Tue, May 11, 2010 at 8:58 AM, GWT Groups  wrote:
> Hello Friends
>
>                  My Problem is that I want to Authenticate Uploaded
> file format, size at the GWT client side, But I not having no Idea,
> I did my first attempt to do so in this way.
>
> 1) By creating a method at the client side
>
> public long getFileSize(String filename) {
>
>            File file = new File(filename);
>
>            if (!file.exists() || !file.isFile()) {
>              System.out.println("File doesn\'t exist");
>              return -1;
>            }
>
>            //Here we get the actual size
>            return file.length();
>          }
>
>
> 2)  Call to the method...
>
>
>                                           long size =
> getFileSize(textField.getName());
>                                            if(size>5242880)
>                                            {
>                                                MessageBox.alert("File Size 
> exceed Upload Limits");
>                                                System.out.println("Filesize 
> in bytes: " + size);
>                                            }
>                                            else
>                                            {
>                                        
> formPanel.getForm().submit(GWT.getModuleBaseURL()
> +"FileUploadServlet",     null, Connection.POST, "Saving Data...",
> false);
>                                            }
>
>
> *
>
> But this is not working, I find the reason of this is that "GWT only
> support Java.lang, java.lang package at client side."
>
> Then Please tell me what i should do to authenticate the file size and
> format at the client side before upload start.
>
> I am waiting for response from my Respected group members .
>
>
> Your Friend
>  Ankit
>
> --
> 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.



RichTextArea initialization

2010-05-11 Thread David Pinn
Why does RichTextArea implement HasInitializeHandlers? What can I do
with my RichTextArea before the onInitialize method has been called,
and what must wait until afterwards?

-- 
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.



Green IT

2010-05-11 Thread Stefan Bachert
In common Green IT will seen as a hardware issue.

However, when you are comparing GWT / AJAX - application with
classical web technologies like JSP, JSF, PHP you will detect that
these technologie heavily differs in power consumptions, too.

- GWT reduces the load of the servers.
- GWT reduces the load of the clients
- GWT reduces the load of the network

All this will save power and thatfore GWT is also a big contribution
to green IT.

My personell expectations is that switching from classical web
technologies to GWT could save 90% of power consumption.

Does someone know of a concrete investigation of this topic?  Or any
kind of study?


Stefan Bachert
http://gwtworld.de

-- 
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: ant hosted not working on my machine ...debugging is very tedious

2010-05-11 Thread Sid
Thanks for your reply. For some reson cutpasting the url in Opera does
not work. In fact my Opera version just shows a blank page. I am
having problems upgrading my fedora 9 version of Firefox to ff 3.6 as
its missing some packages. I guess I may have to install fedora 12 and
hopefully all the problems will go. Till then I guess its deploying
the war file route for me..but thanks for the suggestions from both my
repliers.

On May 9, 7:30 pm, kozura  wrote:
> Why not install a later version of firefox? ff 1.5 is pretty old..
>
> You can also just take the same URL and paste it into your Opera (or
> any other browser)
>
> On May 9, 5:21 am, Sid  wrote:
>
>
>
> > Hello,
> >   I am unable to develop in hosted mode because of which I am
> > unable to
> > debug the code in Java running the code in eclipse. Its becoming very
> > tedious
> > to create a war file everytime and deploy on tomcat server ..and in
> > war mode
> > one cannot see the system.out.println outputs.
> > On my machine which is runing on RHEL 5.0 has a Mozilla firefox
> > version of
> > 5.0.
>
> > Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.8.0.9) Gecko/20070118 Red
> > Hat/1.5.0.9-10.el5 Firefox/1.5.0.9 pango-text
>
> >  When I tried to install the plugins for running in hosted mode I got
> > the
> > error
>
> > Development Mode requires the Google Web Toolkit Developer Plugin
> > By downloading, you agree to the Terms & Conditions and Privacy
> > Policy.
> > Sorry, the GWT Developer Plugin only supports Firefox 3.0 and 3.5 at
> > present
> > plugins for other systems
> > Download the GWT Developer Plugin
> > For Firefox
> > Win x86, Linux x86/x86_64, Mac x86/PPC
> > Download the GWT Developer Plugin
> > For Internet Explorer
> > Win x86
> > Download the GWT Developer Plugin
> > For Chrome
> > Win x86
> > Download the GWT Developer Plugin
> > For Safari
> > Mac x86/x86_64/PPC
> > suggested download only
> > For help or troubleshooting, ask questions in the discussion group.
>
> > I have Opera installed on my system (was unable to install Chrome
> > because of
> > some package dependencies).
> > How do I resolve my issue? Is there a way to change the default
> > browser from
> > the hosted mode UI so that it does not load Mozilla but Opera?
> > Any suggestions will be most helpful.
>
> --
> 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.

-- 
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.



Generators

2010-05-11 Thread Stefan Bachert
Hi,

GWT generators are used to generate GWT-RPC, I18N a.s.o.
But the generator capability could be used as a general programming
concept, too.

Do you do such things too?
- What are you doing with generators?

- Do you find limits?

- When to use GWT generator, when to use other generator concepts
(e.g. XText)


Stefan Bachert
http://gwtworld.de

-- 
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: Green IT

2010-05-11 Thread Subhrajyoti Moitra
Very interesting observation. I would also be interested to know more on
this.

Thanks,
Subhro.

On Tue, May 11, 2010 at 1:03 PM, Stefan Bachert wrote:

> In common Green IT will seen as a hardware issue.
>
> However, when you are comparing GWT / AJAX - application with
> classical web technologies like JSP, JSF, PHP you will detect that
> these technologie heavily differs in power consumptions, too.
>
> - GWT reduces the load of the servers.
> - GWT reduces the load of the clients
> - GWT reduces the load of the network
>
> All this will save power and thatfore GWT is also a big contribution
> to green IT.
>
> My personell expectations is that switching from classical web
> technologies to GWT could save 90% of power consumption.
>
> Does someone know of a concrete investigation of this topic?  Or any
> kind of study?
>
>
> Stefan Bachert
> http://gwtworld.de
>
> --
> 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.



log4j:WARN No appenders could be found for logger

2010-05-11 Thread fomba collins
Hi,  
    I believe this error means that the log4j.properties is not seen in the 
class path. Please can someone help me with how to insert it into the classpath?


  

-- 
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To post to this group, send email to google-web-tool...@googlegroups.com.
To unsubscribe from this group, send email to 
google-web-toolkit+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/google-web-toolkit?hl=en.



Re: How to Use SplitPanel in UIBinder ??

2010-05-11 Thread Gourab Panda
No Answer Guyd ?

On Tue, Apr 20, 2010 at 5:23 PM, Gourab Panda  wrote:

> Hi.
>
> How can I set the BottomWidge and TopWidget in UIBInder XML File.
>
>
>   
>  //Top Panel
> 
> 
>   //Button Panel
> 
> 
>
>   
>
>

-- 
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: 1.7 to 2.0, GWT doesn't work any more

2010-05-11 Thread Navigateur
I found the solution. It was that the AbsolutePanel in 1.7 didn't need
to be sized, in 2.0 it does (I think it defaults at 0,0 when using GWT
2.0).

There are other differences in appearance from my 1.7 app too, which
I'm working through.

On May 8, 1:35 pm, Navigateur  wrote:
> I was wondering if anyone's had the issue of nothing displaying on
> their application when migrating from GWT 1.7 to 2.0? (The static html
> shows, none of the GWT widgets show). I can get an alert box to
> display onModuleLoad(), but nothing else.
>
> If so, how were you able to fix it? Or does anybody have any
> suggestions? I'm using GWTCanvas along with standard GWT widgets.
> Could that be the problem? If so, how would I use GWTCanvas for 2.0?
>
> I get no error messages, just a warning "Referencing deprecated class
> 'com.google.gwt.user.client.impl.DocumentRootImpl' "
>
> Many thanks,
> 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 
> athttp://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.



GWTCanvas doesn't draw lines in my app in GWT 2.0.3, was fine in GWT 1.7

2010-05-11 Thread Navigateur
Anybody have any idea about why lines drawn using GWTCanvas wouldn't
appear in GWT 2.0, but was ok in 1.7? Has anyone successfully drawn
lines in 2.0 and can show me a code snippet?

Cheers, 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: GWT with GAE Blobstore

2010-05-11 Thread compuroad
Anyone?

On May 9, 11:47 am, compuroad  wrote:
> I am trying to use GAEBlobstorewith GWT. I have changed the sample
> they have 
> online:http://code.google.com/appengine/docs/java/blobstore/overview.html
> I replaced the jsp page with a GWT page (below). I replaced the call
> to "<%= blobstoreService.createUploadUrl("/upload") %>" with a RPC
> call which is initiated by "controller.getUploadURL("/index").
> However I am getting the following error:
>
> SEVERE: [127300268044] javax.servlet.ServletContext log:
> Exception
> while dispatching incoming RPC call
> com.google.gwt.user.server.rpc.UnexpectedException: Service method
> 'public abstract java.lang.String
> net.compuroad.cerrado.client.data.DataAccessService.getUploadURL(java.lang.
> String)'
> threw an unexpected exception: java.lang.NoClassDefFoundError: com/
> google/appengine/api/blobstore/BlobstoreServiceFactory
>         at
> com.google.gwt.user.server.rpc.RPC.encodeResponseForFailure(RPC.java:
> 360)
>         at
> com.google.gwt.user.server.rpc.RPC.invokeAndEncodeResponse(RPC.java:
> 546)
>         at
> com.google.gwt.user.server.rpc.RemoteServiceServlet.processCall(RemoteServi
> ceServlet.java:
> 166)
>
> I have installed GAE SDK 1.3.3.1. What I don't understand is why GWT
> is looking for a  GAE class "BlobstoreServiceFactory" that is only
> called in the server side via RPC. Any ideas will be appreciated.
>
> Thanks,
>
> Wilson
>
> //GWT page to upload the images:
> public class ImagePage2 extends Page {
>         private String[] mediaList = {"Select
> media","picture","video"};
>         private FileUpload upload = null;
>         private Controller controller = null;
>         private static CerradoConstants constants = null;
>         private  final FormPanel form = new FormPanel();
>         private VerticalPanel panel = new VerticalPanel();
>     private FlexTable table = new FlexTable();
>     private Button btnAddImage = new Button("Add Image");
>     private Button btnUpload = new Button("Upload");
>     private TextBox txtPropertyID = new TextBox();
>     private TextBox txtPropertyName = new TextBox();
>     /**
>          * Constructor
>          */
>         public ImagePage2(final Controller controller, final
> CerradoConstants constants) {
>                 this.constants = constants;
>                 this.controller = controller;
>                 // Create a FormPanel and point it at a service.
>                 //form.setAction(GWT.getModuleBaseURL() +"Image");
>             // Because we're going to add a FileUpload widget, we'll
> need to set the
>             // form to use the POST method, and multipart MIME
> encoding.
>             form.setEncoding(FormPanel.ENCODING_MULTIPART);
>             form.setMethod(FormPanel.METHOD_POST);
>             form.setWidget(panel);
>             btnAddImage.addClickHandler( new ClickHandler(){
>                         @Override
>                         public void onClick(ClickEvent event) {
>                                       upload = new FileUpload();
>                                   upload.setName("uploadForm");
>                                     upload.setSize("450px", "25px");
>                                     panel.add(upload);
>                         }
>                 });
>             btnUpload.addClickHandler( new ClickHandler(){
>                         @Override
>                         public void onClick(ClickEvent event) {
>                        /***This call initiates the RPC and generates
> the error **/
>                                  controller.getUploadURL("/index");
>                         }
>                 });
>            //the upload URL should come back from the RPC call
> controller.getUploadURL("/index") using this listener
> controller.getData().addPropertyChangeListener("uploadURL", new
> PropertyChangeListener(){
>                         @Override
>                         public void
> propertyChange(PropertyChangeEvent
> event) {
>                                         String path = null;
>                                 if (event.getNewValue()!= null){
>                                         path = (String )
> event.getNewValue();
>                                         Window.alert("Upload URL:
> "+path);
>                                         form.setAction(path);
>                                         form.submit();
>                                 }
>                         }
>             });
>             panel.add(btnAddImage);
>             panel.add(btnUpload);
>             // Add an event handler to the form.
>            form.addFormHandler(new FormHandler() {
>               @Override
>               public void onSubmit(FormSubmitEvent event) {
>               }
>               public void onSubmitComplete(SubmitCompleteEvent event)
> {
>                 Window.alert(event.getResults());
>               }
>                 @Override
>                 public void onSubmitComplete(FormS

Re: GWT with GAE Blobstore

2010-05-11 Thread rudolf michael
you cannot use RPC to upload files as i may know.
when uploading you need to submit a HTML form.

best regards,
Rudolf Michael

On Tue, May 11, 2010 at 1:16 PM, compuroad wrote:

> Anyone?
>
> On May 9, 11:47 am, compuroad  wrote:
> > I am trying to use GAEBlobstorewith GWT. I have changed the sample
> > they have online:
> http://code.google.com/appengine/docs/java/blobstore/overview.html
> > I replaced the jsp page with a GWT page (below). I replaced the call
> > to "<%= blobstoreService.createUploadUrl("/upload") %>" with a RPC
> > call which is initiated by "controller.getUploadURL("/index").
> > However I am getting the following error:
> >
> > SEVERE: [127300268044] javax.servlet.ServletContext log:
> > Exception
> > while dispatching incoming RPC call
> > com.google.gwt.user.server.rpc.UnexpectedException: Service method
> > 'public abstract java.lang.String
> >
> net.compuroad.cerrado.client.data.DataAccessService.getUploadURL(java.lang.
> > String)'
> > threw an unexpected exception: java.lang.NoClassDefFoundError: com/
> > google/appengine/api/blobstore/BlobstoreServiceFactory
> > at
> > com.google.gwt.user.server.rpc.RPC.encodeResponseForFailure(RPC.java:
> > 360)
> > at
> > com.google.gwt.user.server.rpc.RPC.invokeAndEncodeResponse(RPC.java:
> > 546)
> > at
> >
> com.google.gwt.user.server.rpc.RemoteServiceServlet.processCall(RemoteServi
> > ceServlet.java:
> > 166)
> >
> > I have installed GAE SDK 1.3.3.1. What I don't understand is why GWT
> > is looking for a  GAE class "BlobstoreServiceFactory" that is only
> > called in the server side via RPC. Any ideas will be appreciated.
> >
> > Thanks,
> >
> > Wilson
> >
> > //GWT page to upload the images:
> > public class ImagePage2 extends Page {
> > private String[] mediaList = {"Select
> > media","picture","video"};
> > private FileUpload upload = null;
> > private Controller controller = null;
> > private static CerradoConstants constants = null;
> > private  final FormPanel form = new FormPanel();
> > private VerticalPanel panel = new VerticalPanel();
> > private FlexTable table = new FlexTable();
> > private Button btnAddImage = new Button("Add Image");
> > private Button btnUpload = new Button("Upload");
> > private TextBox txtPropertyID = new TextBox();
> > private TextBox txtPropertyName = new TextBox();
> > /**
> >  * Constructor
> >  */
> > public ImagePage2(final Controller controller, final
> > CerradoConstants constants) {
> > this.constants = constants;
> > this.controller = controller;
> > // Create a FormPanel and point it at a service.
> > //form.setAction(GWT.getModuleBaseURL() +"Image");
> > // Because we're going to add a FileUpload widget, we'll
> > need to set the
> > // form to use the POST method, and multipart MIME
> > encoding.
> > form.setEncoding(FormPanel.ENCODING_MULTIPART);
> > form.setMethod(FormPanel.METHOD_POST);
> > form.setWidget(panel);
> > btnAddImage.addClickHandler( new ClickHandler(){
> > @Override
> > public void onClick(ClickEvent event) {
> >   upload = new FileUpload();
> >   upload.setName("uploadForm");
> > upload.setSize("450px", "25px");
> > panel.add(upload);
> > }
> > });
> > btnUpload.addClickHandler( new ClickHandler(){
> > @Override
> > public void onClick(ClickEvent event) {
> >/***This call initiates the RPC and generates
> > the error **/
> >  controller.getUploadURL("/index");
> > }
> > });
> >//the upload URL should come back from the RPC call
> > controller.getUploadURL("/index") using this listener
> > controller.getData().addPropertyChangeListener("uploadURL", new
> > PropertyChangeListener(){
> > @Override
> > public void
> > propertyChange(PropertyChangeEvent
> > event) {
> > String path = null;
> > if (event.getNewValue()!= null){
> > path = (String )
> > event.getNewValue();
> > Window.alert("Upload URL:
> > "+path);
> > form.setAction(path);
> > form.submit();
> > }
> > }
> > });
> > panel.add(btnAddImage);
> > panel.add(btnUpload);
> > // Add an event handler to

Re: Another [com.google.gwt.user.client.rpc.StatusCodeException: The call failed on the server;] Exception

2010-05-11 Thread kirtcathey
I figured this one out with a bit of Google search and a lot of forum
reading
a couple of answers are available in this discussion thread:
http://forums.sun.com/thread.jspa?threadID=5141780

On May 11, 4:50 am, kirtcathey  wrote:
> Hi All.
> I get this error when I deploy the application to the Tomcat server,
> but not when I am testing locally. I think it may be because I have
> not registered something properly in one of the server side XML files
> or the server is not seeing the JDBC driver. I have installed the JDBC
> drive in [Catalina HOME]/common/lib as directed
>
> Thanks in advance for the help.
>
> Kirt
>
> --
> 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.

-- 
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.



Can we check uploaded file Size at client side in GWT by Reading the "header info" of the file

2010-05-11 Thread GWT Groups

Hello Friends

I required your views..

" Can we check uploaded file Size at client side in GWT by Reading the
"header info" of the file? "

Please if this is possible than please tell me how to do this. I have
done lot of search on this but not get any thing till now.

Please Help me.
I am waiting for you response


your Friend
Ankit

-- 
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.



Positioning Widgets Within Existing HTML

2010-05-11 Thread kirtcathey
Hi All.

I'm trying to figure out how to layout a widget within an existing
HTML page. I have a static web site that I use as the portal entrance,
but when a user clicks on registration, I send them to another static
HTML (registration) page that will have the registration form. This
registration form is a GWT application that I want to embed into an
existing web site. Any insights, links, or examples would be a big
help.

Thank you.
Kirt

-- 
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+EJB+JPA Integration without DTO's

2010-05-11 Thread hezjing
Thanks for sharing this sample!

What do you mean when you said the GWT 2.0 added the support for JPA
annotations?


On Wed, Feb 17, 2010 at 10:13 AM, Morswin  wrote:

> Maybe someone will find that useful:
> http://code.google.com/p/gwt-ejb-sample/
> Cheers,
> Morswin
>
> --
> 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.
>
>


-- 

Hez

-- 
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: Can we check uploaded file Size at client side in GWT by Reading the "header info" of the file

2010-05-11 Thread Sripathi Krishnan
You can't, and you don't want to.

You can't, because javascript doesn't provide any way to read the contents
of a file that is stored locally. You can't read the http header info when
the browser submits a multi-part post request. There just isn't a way to do
it (unless you are willing to write some Flex code to compile a SWF file for
Flash Player 10)..

You don't want to, because client side validation is no validation. It can
easily be bypassed. You'd have to perform the check on the server anyways,
so why bother with client side validation at all?

--Sri


On 11 May 2010 16:48, GWT Groups  wrote:

>
> Hello Friends
>
> I required your views..
>
> " Can we check uploaded file Size at client side in GWT by Reading the
> "header info" of the file? "
>
> Please if this is possible than please tell me how to do this. I have
> done lot of search on this but not get any thing till now.
>
> Please Help me.
> I am waiting for you response
>
>
> your Friend
> Ankit
>
> --
> 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: Positioning Widgets Within Existing HTML

2010-05-11 Thread mariyan nenchev
Hi, you can access the div (where you want to place the widget) via
RootPanel.get("div_id").add(yourWidget);

-- 
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To post to this group, send email to google-web-tool...@googlegroups.com.
To unsubscribe from this group, send email to 
google-web-toolkit+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/google-web-toolkit?hl=en.



GWT 1.7 to 2.0 upgrading problem: no longer working: GWTCanvas, gwt-diagrams2

2010-05-11 Thread Navigateur
Is there a way to get these things working in GWT 2.0?

I've found that gwt-diagrams2 works when deleting  from
the html file, but other things don't work then!

Would anybody recommend me going back to GWT 1.7?

Many thanks, 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: Unnormal behavior while using native redirect-Methode?

2010-05-11 Thread Thomas Broyer

On 10 mai, 16:42, malibubu  wrote:
> Hi @all...
>
> I'm calling my EntryPoint using the URLhttp://localhost:8080/testdesk/.
>
> I've implemented the following native Method to redirect to another
> page:
>
>         static native void redirect(String url)
>         /*-{
>                 $wnd.location.replace(url);
>         }-*/;

Note that you can write Window.Location.replace(url) to the same
effect.

> If an Exception occurs within my Methods, I call the native Method
> with the Parameter "./login.jsp" but he tries to open this 
> URL:http://localhost:8080/testdesk/testdesk/login.jsp
>
> What is wrong with the method?

The browser is just resolving the URL reference relative to the URL of
the *calling* browser context (in this case, the .cache.html,
which is loaded in a hidden iframe).
To fix this you just have to use an "absolute path", which you can
easily construct using GWT.getHostPageBaseURL(). For instance:

   Window.Location.replace(GWT.getHostPageBaseURL() + "login.jsp");

-- 
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: RPC Serialization Issue may be?

2010-05-11 Thread petko
figured it out - was missing the no argument constructor. an
exception / error would have made it easier to identify.

-- 
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: RPC Serialization Issue may be?

2010-05-11 Thread petko
figured it out - was missing the no argument constructor. an
exception / error would have made it easier to identify.

-- 
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: Can we check uploaded file Size at client side in GWT by Reading the "header info" of the file

2010-05-11 Thread Frank Harper
Because it is a much better user experience to show an error message right
away rather than letting the user wait for a long time and then telling him
the upload has failed.

On Tue, May 11, 2010 at 13:52, Sripathi Krishnan <
sripathi.krish...@gmail.com> wrote:

> You can't, and you don't want to.
>
> You can't, because javascript doesn't provide any way to read the contents
> of a file that is stored locally. You can't read the http header info when
> the browser submits a multi-part post request. There just isn't a way to do
> it (unless you are willing to write some Flex code to compile a SWF file for
> Flash Player 10)..
>
> You don't want to, because client side validation is no validation. It can
> easily be bypassed. You'd have to perform the check on the server anyways,
> so why bother with client side validation at all?
>
> --Sri
>
>
>
> On 11 May 2010 16:48, GWT Groups  wrote:
>
>>
>> Hello Friends
>>
>> I required your views..
>>
>> " Can we check uploaded file Size at client side in GWT by Reading the
>> "header info" of the file? "
>>
>> Please if this is possible than please tell me how to do this. I have
>> done lot of search on this but not get any thing till now.
>>
>> Please Help me.
>> I am waiting for you response
>>
>>
>> your Friend
>> Ankit
>>
>> --
>> 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: Can we check uploaded file Size at client side in GWT by Reading the "header info" of the file

2010-05-11 Thread Sripathi Krishnan
>
> Because it is a much better user experience to show an error message right
> away rather than letting the user wait for a long time and then telling him
> the upload has failed.

Agree, its a valid and reasonable use case, just a bit difficult to solve.

--Sri


On 11 May 2010 18:34, Frank Harper  wrote:

> Because it is a much better user experience to show an error message right
> away rather than letting the user wait for a long time and then telling him
> the upload has failed.
>
> On Tue, May 11, 2010 at 13:52, Sripathi Krishnan <
> sripathi.krish...@gmail.com> wrote:
>
>> You can't, and you don't want to.
>>
>> You can't, because javascript doesn't provide any way to read the contents
>> of a file that is stored locally. You can't read the http header info when
>> the browser submits a multi-part post request. There just isn't a way to do
>> it (unless you are willing to write some Flex code to compile a SWF file for
>> Flash Player 10)..
>>
>> You don't want to, because client side validation is no validation. It can
>> easily be bypassed. You'd have to perform the check on the server anyways,
>> so why bother with client side validation at all?
>>
>> --Sri
>>
>>
>>
>> On 11 May 2010 16:48, GWT Groups  wrote:
>>
>>>
>>> Hello Friends
>>>
>>> I required your views..
>>>
>>> " Can we check uploaded file Size at client side in GWT by Reading the
>>> "header info" of the file? "
>>>
>>> Please if this is possible than please tell me how to do this. I have
>>> done lot of search on this but not get any thing till now.
>>>
>>> Please Help me.
>>> I am waiting for you response
>>>
>>>
>>> your Friend
>>> Ankit
>>>
>>> --
>>> You received this message because you are subscribed to the Google Groups
>>> "Google Web Toolkit" group.
>>> To post to this group, send email to google-web-toolkit@googlegroups.com
>>> .
>>> To unsubscribe from this group, send email to
>>> google-web-toolkit+unsubscr...@googlegroups.com
>>> .
>>> For more options, visit this group at
>>> http://groups.google.com/group/google-web-toolkit?hl=en.
>>>
>>>
>>  --
>> You received this message because you are subscribed to the Google Groups
>> "Google Web Toolkit" group.
>> To post to this group, send email to google-web-tool...@googlegroups.com.
>> To unsubscribe from this group, send email to
>> google-web-toolkit+unsubscr...@googlegroups.com
>> .
>> For more options, visit this group at
>> http://groups.google.com/group/google-web-toolkit?hl=en.
>>
>
>  --
> You received this message because you are subscribed to the Google Groups
> "Google Web Toolkit" group.
> To post to this group, send email to google-web-tool...@googlegroups.com.
> To unsubscribe from this group, send email to
> google-web-toolkit+unsubscr...@googlegroups.com
> .
> For more options, visit this group at
> http://groups.google.com/group/google-web-toolkit?hl=en.
>

-- 
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To post to this group, send email to google-web-tool...@googlegroups.com.
To unsubscribe from this group, send email to 
google-web-toolkit+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/google-web-toolkit?hl=en.



Re: help for sending e-mail using rpc / gwt

2010-05-11 Thread Felipe Guarda
but what about the implementation of the RPC, you could help me?
thanks

On May 10, 2:06 am, abhiram wuntakal  wrote:
> Hi Felipe,
>
>   This block of code would help you send an email from the application. The
> trick basically is to get the textual data from the client side and pass it
> to the server side and then use this piece of code to send the email. This
> is actually with the file attachment feature even.
>
>   Initially, you need to have a few variables declared for the username,
> password, SMTP etc...
>
> private static String SMTP_HOST_NAME = "abc-abc.abc.com";
>     private static String SMTP_AUTH_USER = "a...@abc.com";
>     private static String SMTP_AUTH_PWD = "abcpassword";
>     private static final String emailMsgTxt = "Sample Message - Testing the
> email application";
>     private static final String emailSubjectTxt = "Sample Mail";
>     private static String emailFromAddress = "ab...@abcde.com";
>     private static final String[] emailList = new String[100];
>     String fileAttachment = SRCFOLDER + "sample.pdf";
>
>   public void sendEmail(EmailDetailsVo emailVo) {
>         emailList[0] = emailVo.getEmailRecipient();
>         Writer output = null;
>         String text = "sample Text";
>         OutputStream file;
>         System.out.println("Inside send email2");
>
>         fileAttachment = SRCFOLDER + "sample.pdf";
>
>         try {
>             file = new FileOutputStream(
>                     new File(
>                             SRCFOLDER + "sample.pdf"));
>
>             Document document = new Document();
>             try {
>                 PdfWriter.getInstance(document, file);
>                 document.open();
>                 document.add(new Paragraph(String_Body_Of_The_Email));
>
>             } catch (DocumentException e) {
>                 // TODO Auto-generated catch block
>                 e.printStackTrace();
>             }
>
>             document.close();
>             try {
>                 file.close();
>             } catch (IOException e) {
>                 // TODO Auto-generated catch block
>                 e.printStackTrace();
>             }
>
>         } catch (FileNotFoundException e1) {
>             // TODO Auto-generated catch block
>             e1.printStackTrace();
>         }
>
>         Properties props = new Properties();
>         props.put("mail.transport.protocol", "smtp");
>         props.put("mail.smtp.starttls.enable", "true");
>         props.put("mail.smtp.host", SMTP_HOST_NAME);
>         props.put("mail.smtp.auth", "true");
>
>         Authenticator auth = new SMTPAuthenticator();
>         Session session = Session.getDefaultInstance(props, auth);
>         MimeMessage message1 = new MimeMessage(session);
>         try {
>             message1.setFrom(new InternetAddress(emailFromAddress));
>             message1.addRecipient(Message.RecipientType.TO,
>                     new InternetAddress(emailList[0]));
>             message1.setSubject(emailVo.getEmailSubject());
>             message1.addRecipient(Message.RecipientType.CC,
>                     new InternetAddress(emailVo.getCcEmailAddress()));
>             // create the message part
>             MimeBodyPart messageBodyPart = new MimeBodyPart();
>
>             // fill message
>             messageBodyPart.setText(emailVo.getEmailBody());
>
>             Multipart multipart = new MimeMultipart();
>             multipart.addBodyPart(messageBodyPart);
>             messageBodyPart = new MimeBodyPart();
>
>             DataSource source = new FileDataSource(fileAttachment);
>             messageBodyPart.setDataHandler(new DataHandler(source));
>             messageBodyPart.setFileName("MainPdf.pdf");
>             multipart.addBodyPart(messageBodyPart);
>             // Put parts in message
>
>             message1.setContent(multipart);
>             // Send the message
>             Transport.send(message1);
>
>         } catch (AddressException e) {
>             // TODO Auto-generated catch block
>             e.printStackTrace();
>         } catch (MessagingException e) {
>             // TODO Auto-generated catch block
>             e.printStackTrace();
>         }
>
>         // return null;
>
>     }
>
>     public class SMTPAuthenticator extends javax.mail.Authenticator {
>
>         public PasswordAuthentication getPasswordAuthentication() {
>             String username = SMTP_AUTH_USER;
>             String password = SMTP_AUTH_PWD;
>             return new PasswordAuthentication(username, password);
>         }
>     }
>
> HTH,
>
> Thanks and Regards,
> Abhiram
>
>
>
>
>
> On Mon, May 10, 2010 at 3:59 AM, Felipe Guarda  wrote:
> > I'm trying to learn how to send emails using gwt/rpc but I have
> > difficulties.
> > Someone could send me a simple example that shows the implementation
> > of the code on the client and server?
>
> > tks
>
> > --
> > You received this message because you are subscribed to the Google Groups
> > "Google Web Toolkit" g

Re: GWT issue when browser offline

2010-05-11 Thread Abdullah Shaikh
Hey I know that in offline mode the browser doesn't access server, what I
was asking is how will the user know about this, by user I mean the end user
and not the developer.

Anyways I think I will go as per Sripathi explained by having a centralized
error handling.

- Abdullah

On Tue, May 11, 2010 at 12:19 AM, Sorinel C wrote:

> There is no solution here ...in offline mode the browser doesn't
> access server  and obviously the client RPC calls fail. t
> So, enable the browser "online" and your application will be alive and
> kicking.
>
> More GWT hints you can find here: http://ui-programming.blogspot.com/
>
> Cheers!
>
> --
> 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: Can we check uploaded file Size at client side in GWT by Reading the "header info" of the file

2010-05-11 Thread AndreAgosto
Hi Frank, can you help me about upload file?
i saw FileUpload Widget, i put it in a formpanel, but i can't do it
works.. Maybe i did some mistake in servlet side, but i don't know..
Can you send me an example?
 Thank you very much

On 11 Mag, 15:04, Frank Harper  wrote:
> Because it is a much better user experience to show an error message right
> away rather than letting the user wait for a long time and then telling him
> the upload has failed.
>
> On Tue, May 11, 2010 at 13:52, Sripathi Krishnan <
>
>
>
> sripathi.krish...@gmail.com> wrote:
> > You can't, and you don't want to.
>
> > You can't, because javascript doesn't provide any way to read the contents
> > of a file that is stored locally. You can't read the http header info when
> > the browser submits a multi-part post request. There just isn't a way to do
> > it (unless you are willing to write some Flex code to compile a SWF file for
> > Flash Player 10)..
>
> > You don't want to, because client side validation is no validation. It can
> > easily be bypassed. You'd have to perform the check on the server anyways,
> > so why bother with client side validation at all?
>
> > --Sri
>
> > On 11 May 2010 16:48, GWT Groups  wrote:
>
> >> Hello Friends
>
> >> I required your views..
>
> >> " Can we check uploaded file Size at client side in GWT by Reading the
> >> "header info" of the file? "
>
> >> Please if this is possible than please tell me how to do this. I have
> >> done lot of search on this but not get any thing till now.
>
> >> Please Help me.
> >> I am waiting for you response
>
> >> your Friend
> >> Ankit
>
> >> --
> >> 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 
> athttp://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.



RadioButton detect value change when deselection is automatic

2010-05-11 Thread Ice13ill
I'm trying to customize some radio buttons in GWT, but i cannot
execute operation when value is change by selecting other buttons in
the same group. It seams that onValueChange is not triggered for those
radio buttons that loose their value (automatic deselection) when a
certain radio button in the same group is pressed.

So is there a way of detecting that ? or make the method trigger for
the widget that looses value ? (i need that to set an image). I also
tried checking the value when at focus or blur, but if the "input" tag
is not displayed (i need to hide that to display my own selection
images), the onBlur, onFocus methods are not called.
I'm i doing smth wrong ?

-- 
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: Can we check uploaded file Size at client side in GWT by Reading the "header info" of the file

2010-05-11 Thread Frank Harper
Sorry, I can't add anything to what Sripathi already said. I haven't
implement this myself.

On Tue, May 11, 2010 at 15:22, AndreAgosto  wrote:

> Hi Frank, can you help me about upload file?
> i saw FileUpload Widget, i put it in a formpanel, but i can't do it
> works.. Maybe i did some mistake in servlet side, but i don't know..
> Can you send me an example?
>  Thank you very much
>
> On 11 Mag, 15:04, Frank Harper  wrote:
> > Because it is a much better user experience to show an error message
> right
> > away rather than letting the user wait for a long time and then telling
> him
> > the upload has failed.
> >
> > On Tue, May 11, 2010 at 13:52, Sripathi Krishnan <
> >
> >
> >
> > sripathi.krish...@gmail.com> wrote:
> > > You can't, and you don't want to.
> >
> > > You can't, because javascript doesn't provide any way to read the
> contents
> > > of a file that is stored locally. You can't read the http header info
> when
> > > the browser submits a multi-part post request. There just isn't a way
> to do
> > > it (unless you are willing to write some Flex code to compile a SWF
> file for
> > > Flash Player 10)..
> >
> > > You don't want to, because client side validation is no validation. It
> can
> > > easily be bypassed. You'd have to perform the check on the server
> anyways,
> > > so why bother with client side validation at all?
> >
> > > --Sri
> >
> > > On 11 May 2010 16:48, GWT Groups  wrote:
> >
> > >> Hello Friends
> >
> > >> I required your views..
> >
> > >> " Can we check uploaded file Size at client side in GWT by Reading the
> > >> "header info" of the file? "
> >
> > >> Please if this is possible than please tell me how to do this. I have
> > >> done lot of search on this but not get any thing till now.
> >
> > >> Please Help me.
> > >> I am waiting for you response
> >
> > >> your Friend
> > >> Ankit
> >
> > >> --
> > >> 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-toolkit@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.
>
> --
> 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: help for sending e-mail using rpc / gwt

2010-05-11 Thread abhiram wuntakal
Hi Felipe,

RPC implementation would be simple. Just write an ordinary
RemoteServiceServlet and write a function to pass a String parameter (or a
Vo) with the emailBody to the ServiceImpl code. From ServiceImpl, you can
use the code below to send the email.

Let me know if this answers your question.

Regards,
Abhi

On Tue, May 11, 2010 at 6:48 PM, Felipe Guarda  wrote:

> but what about the implementation of the RPC, you could help me?
> thanks
>
> On May 10, 2:06 am, abhiram wuntakal  wrote:
> > Hi Felipe,
> >
> >   This block of code would help you send an email from the application.
> The
> > trick basically is to get the textual data from the client side and pass
> it
> > to the server side and then use this piece of code to send the email.
> This
> > is actually with the file attachment feature even.
> >
> >   Initially, you need to have a few variables declared for the username,
> > password, SMTP etc...
> >
> > private static String SMTP_HOST_NAME = "abc-abc.abc.com";
> > private static String SMTP_AUTH_USER = "a...@abc.com";
> > private static String SMTP_AUTH_PWD = "abcpassword";
> > private static final String emailMsgTxt = "Sample Message - Testing
> the
> > email application";
> > private static final String emailSubjectTxt = "Sample Mail";
> > private static String emailFromAddress = "ab...@abcde.com";
> > private static final String[] emailList = new String[100];
> > String fileAttachment = SRCFOLDER + "sample.pdf";
> >
> >   public void sendEmail(EmailDetailsVo emailVo) {
> > emailList[0] = emailVo.getEmailRecipient();
> > Writer output = null;
> > String text = "sample Text";
> > OutputStream file;
> > System.out.println("Inside send email2");
> >
> > fileAttachment = SRCFOLDER + "sample.pdf";
> >
> > try {
> > file = new FileOutputStream(
> > new File(
> > SRCFOLDER + "sample.pdf"));
> >
> > Document document = new Document();
> > try {
> > PdfWriter.getInstance(document, file);
> > document.open();
> > document.add(new Paragraph(String_Body_Of_The_Email));
> >
> > } catch (DocumentException e) {
> > // TODO Auto-generated catch block
> > e.printStackTrace();
> > }
> >
> > document.close();
> > try {
> > file.close();
> > } catch (IOException e) {
> > // TODO Auto-generated catch block
> > e.printStackTrace();
> > }
> >
> > } catch (FileNotFoundException e1) {
> > // TODO Auto-generated catch block
> > e1.printStackTrace();
> > }
> >
> > Properties props = new Properties();
> > props.put("mail.transport.protocol", "smtp");
> > props.put("mail.smtp.starttls.enable", "true");
> > props.put("mail.smtp.host", SMTP_HOST_NAME);
> > props.put("mail.smtp.auth", "true");
> >
> > Authenticator auth = new SMTPAuthenticator();
> > Session session = Session.getDefaultInstance(props, auth);
> > MimeMessage message1 = new MimeMessage(session);
> > try {
> > message1.setFrom(new InternetAddress(emailFromAddress));
> > message1.addRecipient(Message.RecipientType.TO,
> > new InternetAddress(emailList[0]));
> > message1.setSubject(emailVo.getEmailSubject());
> > message1.addRecipient(Message.RecipientType.CC,
> > new InternetAddress(emailVo.getCcEmailAddress()));
> > // create the message part
> > MimeBodyPart messageBodyPart = new MimeBodyPart();
> >
> > // fill message
> > messageBodyPart.setText(emailVo.getEmailBody());
> >
> > Multipart multipart = new MimeMultipart();
> > multipart.addBodyPart(messageBodyPart);
> > messageBodyPart = new MimeBodyPart();
> >
> > DataSource source = new FileDataSource(fileAttachment);
> > messageBodyPart.setDataHandler(new DataHandler(source));
> > messageBodyPart.setFileName("MainPdf.pdf");
> > multipart.addBodyPart(messageBodyPart);
> > // Put parts in message
> >
> > message1.setContent(multipart);
> > // Send the message
> > Transport.send(message1);
> >
> > } catch (AddressException e) {
> > // TODO Auto-generated catch block
> > e.printStackTrace();
> > } catch (MessagingException e) {
> > // TODO Auto-generated catch block
> > e.printStackTrace();
> > }
> >
> > // return null;
> >
> > }
> >
> > public class SMTPAuthenticator extends javax.mail.Authenticator {
> >
> > public PasswordAuthentication getPasswordAuthentication() {
> >

Re: Client side file I/O

2010-05-11 Thread ben fenster
you can use php to create a server side script that will create a file
from data you will send via post request and  alink to the file
this way u will create save  button that will be a download link to a
file in the server side
loading shold be even easier since it just a file upload

On 10 מאי, 21:45, David Given  wrote:
> -BEGIN PGP SIGNED MESSAGE-
> Hash: SHA1
>
> I have a rich app client that wants to be able to construct data
> algorithmically and save the result; it also wants to be able to read a
> local file, and process it locally.
>
> [No, I do *not* want unrestricted access to the filesystem from the
> client! I want to do all this via standard file load/save dialogues
> mediated by the user, like a sane app does.]
>
> I can save data by constructing a data: URL, invoking it, and the web
> browser will pop up a save dialogue to the user; this is ideal.
>
> Unfortunately the only way I've found in classic HTML of loading data is
> to use a file upload field, but that doesn't let the client see the data
> - --- it sends it straight to the server. Apart from being a waste of time
> and bandwidth, my app may not *have* a server (instead running entirely
> locally).
>
> Are there any new techniques I'm not aware of that will allow me to
> prompt the user for a file and then be able to get the contents of the
> file into a client-side structure so I can process it?
>
> I'm willing to use Gears or HTML5 if necessary, but I'd prefer to use
> stock HTML/JS if possible.
>
> - --
> ┌─── dg@cowlark.com ─http://www.cowlark.com─
> │
> │ "There is no Fermi Paradox. Any time space faring aliens make it to
> │ Earth, the cows get them." --- Sam Starfall
> -BEGIN PGP SIGNATURE-
> Version: GnuPG v1.4.10 (GNU/Linux)
> Comment: Using GnuPG with Mozilla -http://enigmail.mozdev.org/
>
> iD8DBQFL6HBNf9E0noFvlzgRAthtAJ9z9Ctqgch4o+GoEals2Is5UCkBpgCcCzXJ
> DzHZtGbGNaLs777RQLe22dc=
> =UHjb
> -END PGP SIGNATURE-
>
> --
> 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.

-- 
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: RadioButton detect value change when deselection is automatic

2010-05-11 Thread Jim Douglas
You need to track ValueChangeEvents for all radio buttons in the
group, and remember which radio button is currently selected at all
times.  If you do that, then every time you see one radio button in
the group becoming selected, you know that the radio button that was
previously selected just became unselected.

http://google-web-toolkit.googlecode.com/svn/javadoc/2.0/com/google/gwt/user/client/ui/RadioButton.html
"Note, however, that browser limitations prevent ValueChangeEvents
from being sent when the radio button is cleared as a side effect of
another in the group being clicked."

On May 11, 6:56 am, Ice13ill  wrote:
> I'm trying to customize some radio buttons in GWT, but i cannot
> execute operation when value is change by selecting other buttons in
> the same group. It seams that onValueChange is not triggered for those
> radio buttons that loose their value (automatic deselection) when a
> certain radio button in the same group is pressed.
>
> So is there a way of detecting that ? or make the method trigger for
> the widget that looses value ? (i need that to set an image). I also
> tried checking the value when at focus or blur, but if the "input" tag
> is not displayed (i need to hide that to display my own selection
> images), the onBlur, onFocus methods are not called.
> I'm i doing smth wrong ?
>
> --
> 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.

-- 
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.



ImageSpriting now working in mobile Safari? gwt + phonegap

2010-05-11 Thread Daniel
Im building a phonegap Application with GWT and started switching my
css files to ClientBundles and ImageSpriting with GWT 2.0

the css file looked something like:

@sprite #someId {
gwt-image: "headerMiddle";
position: relative;
height: 40px;
border-bottom: 1px solid rgb(45, 54, 66);
}

And the BundleInterface looks like:
public interface HeaderPanelResourceBundle extends ClientBundle{

public static final HeaderPanelResourceBundle INSTANCE =
GWT.create(HeaderPanelResourceBundle.class);

@ImageResource.ImageOptions(repeatStyle =
ImageResource.RepeatStyle.Horizontal)
@ClientBundle.Source("org/dvelop/phonegap/iphone/public/img/
header_middle.png")
ImageResource headerMiddle();

@ClientBundle.Source("org/dvelop/phonegap/iphone/public/css/
headerPanel.css")
HeaderPanelCss css();

}

Everything works fine in Desktop Safari 4.0.5. If I remove the
spriting and replace it with a simple background-image everythings
fine again. Not only the sprinting style is broken all other styles in
the css file as well.

Anyone experienced something like that before?

-- 
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To post to this group, send email to google-web-tool...@googlegroups.com.
To unsubscribe from this group, send email to 
google-web-toolkit+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/google-web-toolkit?hl=en.



Re: new GWT MVP article (part 2)

2010-05-11 Thread Brian Reilly
The increased complexity is definitely an issue. I don't like the idea
of yet more interfaces to have to worry about. It's a shame that part
2 of the MVP article doesn't address testing beyond simply mentioning
that these practices improve testability. It would be much clearer to
see before-and-after code highlighting the code that we want to be
testable in both cases. Without that, it's hard to convince someone
that the extra complexity is worthwhile.

I'm currently working on a small application using UiBinder (and
hopefully GIN) without MVP. It's giving me a refreshing perspective on
how fluent GWT can be, and I think the people I work with will
appreciate that. However, it's not going to be any more testable than
any other web technology we've used.

>From there, I'm going to go about refactoring the code to make it more
testable. This will probably involve applying MVP-like patterns, but
I'm going to try to apply patterns that make sense and not be too
biased by existing examples. I may end up with something much like
what the GWT team is suggesting, or I may find some middle ground, but
I should at least have a good feel for what I'm getting in return for
the increased complexity.

-Brian

On May 11, 1:24 am, dayre  wrote:
> I could comprehend part I after watching Ray's presentation and
> reading it a few times... it gave me a much better idea on how to
> structure my application, but part II things started to fall apart for
> me.   It was very difficult to keep track of the additional layers of
> abstraction introduced and the reasons for them + introducing UIBinder
> and it's details, and shifting interfaces around from where they were
> in part 1 made me dizzy.   The author says it was a lot to cover at
> one point and it was definitely "lost in translation" for me.
>
> On Apr 25, 6:25 am, dmen  wrote:
>
> > I've read it and IMHO it suffers from extreme over-compexity. Problem
> > is people will take this article as a reference for their designs.
>
> > --
> > 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.
>
> --
> 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.

-- 
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.



Placing xxx.ui.xml files in different packages than counterpart Java files

2010-05-11 Thread Yaakov
Hi,

Does anyone know if there is a way to place the ui.xml files in a
separate from its Java counterpart file package?

What I have to have is essentially the following package structure:
view - All Java uibinder classes
view.uibinder - All .ui.xml files
view.uibinder.resources - All .css files.

I found the @UiTemplate annotation that allowed me to successfully
move the ui.xml files into the view.uibinder package and just refer to
those in the Java file with @UiTemplate("uibinder/someView.ui.xml").

Unfortunately, all the references to the resources, although showing
no errors in Eclipse, start breaking on GWT compile. So, for example,
if I have the following in my ui.xml:


When compiled, the error says that it can't find the style when lookin
in view/resources/styles.css. Note the lack of "uibinder" directory in
the error message!

Upon further testing, it seems clear that when the ui.xml files gets
ingested into its Java counter part, it copies that 'src' path
verbatum, without adjusting it first. I know this because if I put "../
resources/style.css", the error message will come with that it can't
find the path and show that it's looking in "view/../resources/
style.css"

Is there some annotation or some flag I am supposed to provide to get
this to work or is the location of the .ui.xml file forever stuck with
the location of its counterpart Java file?

Thanks,
Yaakov.

-- 
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.



UiBinder + CSS layouting

2010-05-11 Thread Oliver Uvman
Hello!

I'm wondering if anybody has a good way of handling the very time
consuming job of fixing the CSS when using UiBinder. Since we started
using UiBinder (which I really like, by the way) we've had to start re-
running the app whenever we want to make a change to the CSS.
Resulting in extremely bothersome change-rerun-check cycles whenever
layout is to be changed.

I can't really just check the HTML file in the browser without running
the application either, because for some reason images don't load when
doing that. Any way to make images load before the GWT app?

Regards,
Oliver Uvman

-- 
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To post to this group, send email to google-web-tool...@googlegroups.com.
To unsubscribe from this group, send email to 
google-web-toolkit+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/google-web-toolkit?hl=en.



Re: help for sending e-mail using rpc / gwt

2010-05-11 Thread Felipe Guarda
Abhi, you could best describe what must be put on every piece of code?
You sent me a piece of code that must remain in the Class
EmailServiceImpl server.side. My doubts are now, I need to create some
kind of interface EmailService and EmailServiceAsync?
In cliente.side.code how do I send the e-mail? Should I instantiate
that class?
Sorry for the stupid questions, I am now getting this world java /
gwt.

thanks,

Felipe

On May 11, 11:48 am, abhiram wuntakal  wrote:
> Hi Felipe,
>
> RPC implementation would be simple. Just write an ordinary
> RemoteServiceServlet and write a function to pass a String parameter (or a
> Vo) with the emailBody to the ServiceImpl code. From ServiceImpl, you can
> use the code below to send the email.
>
> Let me know if this answers your question.
>
> Regards,
> Abhi
>
>
>
>
>
> On Tue, May 11, 2010 at 6:48 PM, Felipe Guarda  wrote:
> > but what about the implementation of the RPC, you could help me?
> > thanks
>
> > On May 10, 2:06 am, abhiram wuntakal  wrote:
> > > Hi Felipe,
>
> > >   This block of code would help you send an email from the application.
> > The
> > > trick basically is to get the textual data from the client side and pass
> > it
> > > to the server side and then use this piece of code to send the email.
> > This
> > > is actually with the file attachment feature even.
>
> > >   Initially, you need to have a few variables declared for the username,
> > > password, SMTP etc...
>
> > > private static String SMTP_HOST_NAME = "abc-abc.abc.com";
> > >     private static String SMTP_AUTH_USER = "a...@abc.com";
> > >     private static String SMTP_AUTH_PWD = "abcpassword";
> > >     private static final String emailMsgTxt = "Sample Message - Testing
> > the
> > > email application";
> > >     private static final String emailSubjectTxt = "Sample Mail";
> > >     private static String emailFromAddress = "ab...@abcde.com";
> > >     private static final String[] emailList = new String[100];
> > >     String fileAttachment = SRCFOLDER + "sample.pdf";
>
> > >   public void sendEmail(EmailDetailsVo emailVo) {
> > >         emailList[0] = emailVo.getEmailRecipient();
> > >         Writer output = null;
> > >         String text = "sample Text";
> > >         OutputStream file;
> > >         System.out.println("Inside send email2");
>
> > >         fileAttachment = SRCFOLDER + "sample.pdf";
>
> > >         try {
> > >             file = new FileOutputStream(
> > >                     new File(
> > >                             SRCFOLDER + "sample.pdf"));
>
> > >             Document document = new Document();
> > >             try {
> > >                 PdfWriter.getInstance(document, file);
> > >                 document.open();
> > >                 document.add(new Paragraph(String_Body_Of_The_Email));
>
> > >             } catch (DocumentException e) {
> > >                 // TODO Auto-generated catch block
> > >                 e.printStackTrace();
> > >             }
>
> > >             document.close();
> > >             try {
> > >                 file.close();
> > >             } catch (IOException e) {
> > >                 // TODO Auto-generated catch block
> > >                 e.printStackTrace();
> > >             }
>
> > >         } catch (FileNotFoundException e1) {
> > >             // TODO Auto-generated catch block
> > >             e1.printStackTrace();
> > >         }
>
> > >         Properties props = new Properties();
> > >         props.put("mail.transport.protocol", "smtp");
> > >         props.put("mail.smtp.starttls.enable", "true");
> > >         props.put("mail.smtp.host", SMTP_HOST_NAME);
> > >         props.put("mail.smtp.auth", "true");
>
> > >         Authenticator auth = new SMTPAuthenticator();
> > >         Session session = Session.getDefaultInstance(props, auth);
> > >         MimeMessage message1 = new MimeMessage(session);
> > >         try {
> > >             message1.setFrom(new InternetAddress(emailFromAddress));
> > >             message1.addRecipient(Message.RecipientType.TO,
> > >                     new InternetAddress(emailList[0]));
> > >             message1.setSubject(emailVo.getEmailSubject());
> > >             message1.addRecipient(Message.RecipientType.CC,
> > >                     new InternetAddress(emailVo.getCcEmailAddress()));
> > >             // create the message part
> > >             MimeBodyPart messageBodyPart = new MimeBodyPart();
>
> > >             // fill message
> > >             messageBodyPart.setText(emailVo.getEmailBody());
>
> > >             Multipart multipart = new MimeMultipart();
> > >             multipart.addBodyPart(messageBodyPart);
> > >             messageBodyPart = new MimeBodyPart();
>
> > >             DataSource source = new FileDataSource(fileAttachment);
> > >             messageBodyPart.setDataHandler(new DataHandler(source));
> > >             messageBodyPart.setFileName("MainPdf.pdf");
> > >             multipart.addBodyPart(messageBodyPart);
> > >             // Put parts in 

java.lang.NoClassDefFoundError, it probably well known but I cannot found the solution....

2010-05-11 Thread Carfield Yim
HI, I just use the class in another JAR, eclipse show no compilation
error, and GWT compilation is success, why I still get following
error? BTW, I start the application using eclipse GWT plugin.

May 11, 2010 5:17:36 PM com.google.apphosting.utils.jetty.JettyLogger
warn
WARNING: Nested in javax.servlet.ServletException: init:
java.lang.NoClassDefFoundError: hk/com/carfield/core/Context
at
hk.com.carfield.server.InternetfolderServiceImpl.(InternetfolderServiceImpl.java:
27)
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native
Method)
at
sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:
57)
at
sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:
45)
at java.lang.reflect.Constructor.newInstance(Constructor.java:532)
at java.lang.Class.newInstance0(Class.java:372)
at java.lang.Class.newInstance(Class.java:325)
at org.mortbay.jetty.servlet.Holder.newInstance(Holder.java:153)
at
org.mortbay.jetty.servlet.ServletHolder.getServlet(ServletHolder.java:
339)
at org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java:
463)
at org.mortbay.jetty.servlet.ServletHandler
$CachedChain.doFilter(ServletHandler.java:1093)
at
com.google.appengine.api.blobstore.dev.ServeBlobFilter.doFilter(ServeBlobFilter.java:
51)
at org.mortbay.jetty.servlet.ServletHandler
$CachedChain.doFilter(ServletHandler.java:1084)
at
com.google.apphosting.utils.servlet.TransactionCleanupFilter.doFilter(TransactionCleanupFilter.java:
43)
at org.mortbay.jetty.servlet.ServletHandler
$CachedChain.doFilter(ServletHandler.java:1084)
at
com.google.appengine.tools.development.StaticFileFilter.doFilter(StaticFileFilter.java:
121)
at org.mortbay.jetty.servlet.ServletHandler
$CachedChain.doFilter(ServletHandler.java:1084)
at
org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:
360)
at
org.mortbay.jetty.security.SecurityHandler.handle(SecurityHandler.java:
216)
at
org.mortbay.jetty.servlet.SessionHandler.handle(SessionHandler.java:
181)
at
org.mortbay.jetty.handler.ContextHandler.handle(ContextHandler.java:
712)
at org.mortbay.jetty.webapp.WebAppContext.handle(WebAppContext.java:
405)
at
com.google.apphosting.utils.jetty.DevAppEngineWebAppContext.handle(DevAppEngineWebAppContext.java:
70)
at
org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:
139)
at com.google.appengine.tools.development.JettyContainerService
$ApiProxyHandler.handle(JettyContainerService.java:352)
at
org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:
139)
at org.mortbay.jetty.Server.handle(Server.java:313)
at org.mortbay.jetty.HttpConnection.handleRequest(HttpConnection.java:
506)
at org.mortbay.jetty.HttpConnection
$RequestHandler.content(HttpConnection.java:844)
at org.mortbay.jetty.HttpParser.parseNext(HttpParser.java:644)
at org.mortbay.jetty.HttpParser.parseAvailable(HttpParser.java:211)
at org.mortbay.jetty.HttpConnection.handle(HttpConnection.java:381)
at
org.mortbay.io.nio.SelectChannelEndPoint.run(SelectChannelEndPoint.java:
396)
at org.mortbay.thread.BoundedThreadPool
$PoolThread.run(BoundedThreadPool.java:442)
Caused by: java.lang.ClassNotFoundException:
hk.com.carfield.core.Context
at java.net.URLClassLoader$1.run(URLClassLoader.java:217)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:205)
at java.lang.ClassLoader.loadClass(ClassLoader.java:319)
at
com.google.appengine.tools.development.IsolatedAppClassLoader.loadClass(IsolatedAppClassLoader.java:
151)
at java.lang.ClassLoader.loadClass(ClassLoader.java:264)
at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:332)
... 34 more
May 11, 2010 5:17:36 PM com.google.apphosting.utils.jetty.JettyLogger
warn
WARNING: Nested in javax.servlet.ServletException: init:
java.lang.NoClassDefFoundError: hk/com/carfield/core/Context
at
hk.com.carfield.server.InternetfolderServiceImpl.(InternetfolderServiceImpl.java:
27)
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native
Method)
at
sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:
57)
at
sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:
45)
at java.lang.reflect.Constructor.newInstance(Constructor.java:532)
at java.lang.Class.newInstance0(Class.java:372)
at java.lang.Class.newInstance(Class.java:325)
at org.mortbay.jetty.servlet.Holder.newInstance(Holder.java:153)
at
org.mortbay.jetty.servlet.ServletHolder.getServlet(ServletHolder.java:
339)
at org.mortbay.jetty.s

Re: java.lang.NoClassDefFoundError, it probably well known but I cannot found the solution....

2010-05-11 Thread Sripathi Krishnan
I am guessing the class hk/com/carfield/core/Context is performing a
restricted operation - like creating a thread or opening a file/socket
connection. GAE does not allow you to perform such operations, and when you
do - it fails with a stack trace similar to what you have pasted.

Disable GAE in your eclipse settings, and completely remove all GAE jar
 files from your classpath. That should solve the problem.

--Sri


On 11 May 2010 22:48, Carfield Yim  wrote:

> HI, I just use the class in another JAR, eclipse show no compilation
> error, and GWT compilation is success, why I still get following
> error? BTW, I start the application using eclipse GWT plugin.
>
> May 11, 2010 5:17:36 PM com.google.apphosting.utils.jetty.JettyLogger
> warn
> WARNING: Nested in javax.servlet.ServletException: init:
> java.lang.NoClassDefFoundError: hk/com/carfield/core/Context
>at
>
> hk.com.carfield.server.InternetfolderServiceImpl.(InternetfolderServiceImpl.java:
> 27)
>at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native
> Method)
>at
>
> sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:
> 57)
>at
>
> sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:
> 45)
>at java.lang.reflect.Constructor.newInstance(Constructor.java:532)
>at java.lang.Class.newInstance0(Class.java:372)
>at java.lang.Class.newInstance(Class.java:325)
>at org.mortbay.jetty.servlet.Holder.newInstance(Holder.java:153)
>at
> org.mortbay.jetty.servlet.ServletHolder.getServlet(ServletHolder.java:
> 339)
>at
> org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java:
> 463)
>at org.mortbay.jetty.servlet.ServletHandler
> $CachedChain.doFilter(ServletHandler.java:1093)
>at
>
> com.google.appengine.api.blobstore.dev.ServeBlobFilter.doFilter(ServeBlobFilter.java:
> 51)
>at org.mortbay.jetty.servlet.ServletHandler
> $CachedChain.doFilter(ServletHandler.java:1084)
>at
>
> com.google.apphosting.utils.servlet.TransactionCleanupFilter.doFilter(TransactionCleanupFilter.java:
> 43)
>at org.mortbay.jetty.servlet.ServletHandler
> $CachedChain.doFilter(ServletHandler.java:1084)
>at
>
> com.google.appengine.tools.development.StaticFileFilter.doFilter(StaticFileFilter.java:
> 121)
>at org.mortbay.jetty.servlet.ServletHandler
> $CachedChain.doFilter(ServletHandler.java:1084)
>at
> org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:
> 360)
>at
> org.mortbay.jetty.security.SecurityHandler.handle(SecurityHandler.java:
> 216)
>at
> org.mortbay.jetty.servlet.SessionHandler.handle(SessionHandler.java:
> 181)
>at
> org.mortbay.jetty.handler.ContextHandler.handle(ContextHandler.java:
> 712)
>at org.mortbay.jetty.webapp.WebAppContext.handle(WebAppContext.java:
> 405)
>at
>
> com.google.apphosting.utils.jetty.DevAppEngineWebAppContext.handle(DevAppEngineWebAppContext.java:
> 70)
>at
> org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:
> 139)
>at com.google.appengine.tools.development.JettyContainerService
> $ApiProxyHandler.handle(JettyContainerService.java:352)
>at
> org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:
> 139)
>at org.mortbay.jetty.Server.handle(Server.java:313)
>at
> org.mortbay.jetty.HttpConnection.handleRequest(HttpConnection.java:
> 506)
>at org.mortbay.jetty.HttpConnection
> $RequestHandler.content(HttpConnection.java:844)
>at org.mortbay.jetty.HttpParser.parseNext(HttpParser.java:644)
>at org.mortbay.jetty.HttpParser.parseAvailable(HttpParser.java:211)
>at org.mortbay.jetty.HttpConnection.handle(HttpConnection.java:381)
>at
> org.mortbay.io.nio.SelectChannelEndPoint.run(SelectChannelEndPoint.java:
> 396)
>at org.mortbay.thread.BoundedThreadPool
> $PoolThread.run(BoundedThreadPool.java:442)
> Caused by: java.lang.ClassNotFoundException:
> hk.com.carfield.core.Context
>at java.net.URLClassLoader$1.run(URLClassLoader.java:217)
>at java.security.AccessController.doPrivileged(Native Method)
>at java.net.URLClassLoader.findClass(URLClassLoader.java:205)
>at java.lang.ClassLoader.loadClass(ClassLoader.java:319)
>at
>
> com.google.appengine.tools.development.IsolatedAppClassLoader.loadClass(IsolatedAppClassLoader.java:
> 151)
>at java.lang.ClassLoader.loadClass(ClassLoader.java:264)
>at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:332)
>... 34 more
> May 11, 2010 5:17:36 PM com.google.apphosting.utils.jetty.JettyLogger
> warn
> WARNING: Nested in javax.servlet.ServletException: init:
> java.lang.NoClassDefFoundError: hk/com/carfield/core/Context
>at
>
> hk.com.carfield.server.InternetfolderServiceImpl.(InternetfolderServiceImpl.java:
> 27)
>at sun.reflect.Na

retrieve the tomcat java JVM parameter from servlet

2010-05-11 Thread Ho Jimmy
Hi

When the tomcat is running, it is actually a java process.
e.g
[r...@localhost tomcat]# ps -ef|grep java
root 21896 1  0 01:34 ?00:04:51
/usr/java/jdk1.5.0_11//bin/java -server -Xmx500m
-Djava.util.logging.manager=org.apache.juli.ClassLoaderLogManager
-Djava.util.logging.config.file=/usr/local/tomcat/conf/logging.properties
-Djava.endorsed.dirs=/usr/local/tomcat/endorsed -classpath
:/usr/local/tomcat/bin/bootstrap.jar:/usr/local/tomcat/bin/commons-logging-api.jar
-Dcatalina.base=/usr/local/tomcat -Dcatalina.home=/usr/local/tomcat
-Djava.io.tmpdir=/usr/local/tomcat/temp
org.apache.catalina.startup.Bootstrap start
The -Xmx500m means the memory allocated for this JVM.
Is it possible to retrieve this parameter from the servlet?

Thanks
Jimmy

-- 
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: Placing xxx.ui.xml files in different packages than counterpart Java files

2010-05-11 Thread Sripathi Krishnan
If you just want to keep your java, css and ui.xml code in different
folders, there's an easier technique. Create two folders parallel to src -
"uibinder" and "css". Or whatever you want to name it. Then add these
folders to the sourcepath in eclipse. These three folders should have the
same package hierarchy, so GWT will be able to find ui.xml and css files
without any problem.

In our project, the above convention helps us to separate ui code from java
code. Keeps the ui folks from stepping over developers toes.

--Sri


On 11 May 2010 21:23, Yaakov  wrote:

> Hi,
>
> Does anyone know if there is a way to place the ui.xml files in a
> separate from its Java counterpart file package?
>
> What I have to have is essentially the following package structure:
> view - All Java uibinder classes
> view.uibinder - All .ui.xml files
> view.uibinder.resources - All .css files.
>
> I found the @UiTemplate annotation that allowed me to successfully
> move the ui.xml files into the view.uibinder package and just refer to
> those in the Java file with @UiTemplate("uibinder/someView.ui.xml").
>
> Unfortunately, all the references to the resources, although showing
> no errors in Eclipse, start breaking on GWT compile. So, for example,
> if I have the following in my ui.xml:
> 
>
> When compiled, the error says that it can't find the style when lookin
> in view/resources/styles.css. Note the lack of "uibinder" directory in
> the error message!
>
> Upon further testing, it seems clear that when the ui.xml files gets
> ingested into its Java counter part, it copies that 'src' path
> verbatum, without adjusting it first. I know this because if I put "../
> resources/style.css", the error message will come with that it can't
> find the path and show that it's looking in "view/../resources/
> style.css"
>
> Is there some annotation or some flag I am supposed to provide to get
> this to work or is the location of the .ui.xml file forever stuck with
> the location of its counterpart Java file?
>
> Thanks,
> Yaakov.
>
> --
> You received this message because you are subscribed to the Google Groups
> "Google Web Toolkit" group.
> To post to this group, send email to google-web-tool...@googlegroups.com.
> To unsubscribe from this group, send email to
> google-web-toolkit+unsubscr...@googlegroups.com
> .
> For more options, visit this group at
> http://groups.google.com/group/google-web-toolkit?hl=en.
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To post to this group, send email to google-web-tool...@googlegroups.com.
To unsubscribe from this group, send email to 
google-web-toolkit+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/google-web-toolkit?hl=en.



Re: GWT 1.7 to 2.0 upgrading problem: no longer working: GWTCanvas, gwt-diagrams2

2010-05-11 Thread Sorinel C
It's always good to use the latest version (except for the cases when
there are critical bugs), like I did myself last year, jumping from
1.7 to 2.0

Here are some of my discoveries:

http://ui-programming.blogspot.com/2009/12/update-your-application-to-gwt-20.html

So, generate first a simple GWT 2.0 project using the Eclipse plugin,
and then update your module MainApplication.gwt.xml and
MainApplication.html according with the recommendations...

Success!

-- 
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: Placing xxx.ui.xml files in different packages than counterpart Java files

2010-05-11 Thread Yaakov Chaikin
Hi Sri,

This wouldn't really work for me as we are using maven and maven has
specific standard directory structure. I guess, I could modify the
pom.xml to see those additional directories as source directories as
well, but all that work in maven that would kinda defeat the purpose
for me, i.e., it would now move the "mess" to maven and having to deal
with maven over this is not worth it for us at this point.

I just want to know if it's possible to do this with pure GWT solution or not.

Anyone know?

Thanks,
Yaakov.

On Tue, May 11, 2010 at 2:39 PM, Sripathi Krishnan
 wrote:
> If you just want to keep your java, css and ui.xml code in different
> folders, there's an easier technique. Create two folders parallel to src -
> "uibinder" and "css". Or whatever you want to name it. Then add these
> folders to the sourcepath in eclipse. These three folders should have the
> same package hierarchy, so GWT will be able to find ui.xml and css files
> without any problem.
> In our project, the above convention helps us to separate ui code from java
> code. Keeps the ui folks from stepping over developers toes.
> --Sri
>
>
> On 11 May 2010 21:23, Yaakov  wrote:
>>
>> Hi,
>>
>> Does anyone know if there is a way to place the ui.xml files in a
>> separate from its Java counterpart file package?
>>
>> What I have to have is essentially the following package structure:
>> view - All Java uibinder classes
>> view.uibinder - All .ui.xml files
>> view.uibinder.resources - All .css files.
>>
>> I found the @UiTemplate annotation that allowed me to successfully
>> move the ui.xml files into the view.uibinder package and just refer to
>> those in the Java file with @UiTemplate("uibinder/someView.ui.xml").
>>
>> Unfortunately, all the references to the resources, although showing
>> no errors in Eclipse, start breaking on GWT compile. So, for example,
>> if I have the following in my ui.xml:
>> 
>>
>> When compiled, the error says that it can't find the style when lookin
>> in view/resources/styles.css. Note the lack of "uibinder" directory in
>> the error message!
>>
>> Upon further testing, it seems clear that when the ui.xml files gets
>> ingested into its Java counter part, it copies that 'src' path
>> verbatum, without adjusting it first. I know this because if I put "../
>> resources/style.css", the error message will come with that it can't
>> find the path and show that it's looking in "view/../resources/
>> style.css"
>>
>> Is there some annotation or some flag I am supposed to provide to get
>> this to work or is the location of the .ui.xml file forever stuck with
>> the location of its counterpart Java file?
>>
>> Thanks,
>> Yaakov.
>>
>> --
>> 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: RPC Serialization Issue may be?

2010-05-11 Thread Sorinel C
Yup, that's the most common problem, easy to fix :)

Here's the problem I had using serialization of the Date, in case you
have any problems:

http://ui-programming.blogspot.com/2010/02/gwt-date-and-timestamp-rpc.html

Cheers!

-- 
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: Transfer problem from clien side to server side

2010-05-11 Thread Emeric Heneffe
Hello,
The fact is that normally I had to use gilead to save pojos in a db.
But, before using this, I had to transfer
these pojo to server side. To do this, I use a simple rpc request with
my classes that extend Serializable (and not
IsSerializable because I don't want that my core package has
dependencies with gwt)... But when I transfer some pojo
coming from my core package, there is a problem and I can't transfer
it, no exception but at server side, all reference
of the transfered object are null.. However, if I want to transfer a
class that is present in client package (see my organization
in first post), there is no problem...

On 10 mai, 20:32, Sorinel C  wrote:
> Why not using the simple GWT RPC to send objects from the server to
> client?
>
> You have just to extend the IsSerializable interface and that's your
> kind of  POJO :-)
>
> [code]
> public class MyObject extends IsSerializable {
>
>    /* mandatory constructor to be serializable */
>    public MyObject () {
>    }
>
> }
>
> [/code]
>
> See more hints about GWT and more here:http://ui-programming.blogspot.com/
>
> Cheers!
>
> --
> 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.

-- 
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: 1.7 to 2.0, GWT doesn't work any more

2010-05-11 Thread Sorinel C
If you still play with both versions (1.7 and 2.0), due to support the
older deployed versions, you might have problems (like I had), but you
can get rid of them if you do cleaning, like I wrote in this article:

http://ui-programming.blogspot.com/2009/12/update-your-application-to-gwt-20.html

Success!

-- 
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 webgl smartgwt

2010-05-11 Thread Alan Chaney

Hi

I've started to build an application using GWT 2 which will needs an 
HTML 5 canvas element to display WebGL. I was intending to use smartgwt 
for the bulk of the UI. Sadly, smartgwt gives layout problems when I add 
the  required by HTML 5 to the main html page of my app.


Hopefully this will be fixed in a future version of smartgwt, but does 
anyone have any ideas for a workaround? For example, could I create a 
widget which wrapped an iframe and set the URL of the iframe to a page 
with an html 5 doctype? I could then use this widget to "embed" my webgl 
viewer.


Any suggestions welcome!

Thanks!

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: Can we check uploaded file Size at client side in GWT by Reading the "header info" of the file

2010-05-11 Thread kozura
You don't have to wait for the server to download the entire file to
give a response, you can get it right away and send back an error
immediately; just the cost of a quick round trip to the server.

As suggested in many similar posts, gwt-upload is a pretty good
solution for file uploads in GWT: http://code.google.com/p/gwtupload/.

On May 11, 7:04 am, Frank Harper  wrote:
> Because it is a much better user experience to show an error message right
> away rather than letting the user wait for a long time and then telling him
> the upload has failed.
>

-- 
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 1.7 to 2.0 upgrading problem: no longer working: GWTCanvas, gwt-diagrams2

2010-05-11 Thread kozura
The  indicates that the browser should be running in
standards mode, which is required for GWT 2.0's new LayoutPanel type
of layout.  However just using the original layout panels (FlowPanel,
HorizontalPanel, etc) still works the same as ever, in quirks mode.
So if a library you want to use doesn't work in standards mode, then
just stick with the previous non-LayoutPanels; no need to go back a
version.

http://code.google.com/webtoolkit/doc/latest/DevGuideUiPanels.html

On May 11, 6:28 am, Navigateur  wrote:
> Is there a way to get these things working in GWT 2.0?
>
> I've found that gwt-diagrams2 works when deleting  from
> the html file, but other things don't work then!
>
> Would anybody recommend me going back to GWT 1.7?
>
> Many thanks, 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 
> athttp://groups.google.com/group/google-web-toolkit?hl=en.

-- 
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To post to this group, send email to google-web-tool...@googlegroups.com.
To unsubscribe from this group, send email to 
google-web-toolkit+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/google-web-toolkit?hl=en.



Re: help for sending e-mail using rpc / gwt

2010-05-11 Thread kozura
What have you tried?  For example, have you looked at the plentiful
example code included with GWT, which includes examples of how to do
RPC:

http://code.google.com/webtoolkit/examples/

And of course the RPC documentation with example code:

http://code.google.com/webtoolkit/doc/latest/DevGuideServerCommunication.html

The xxxService and xxxServiceAsync are interfaces, which you implement
on the server side (xxxService) and call on the client side
(xxxServiceAsync), as shown in those examples.  Not going to write
your application for you...but certainly willing to help you out with
specific questions or problems..

On May 11, 11:02 am, Felipe Guarda  wrote:
> Abhi, you could best describe what must be put on every piece of code?
> You sent me a piece of code that must remain in the Class
> EmailServiceImpl server.side. My doubts are now, I need to create some
> kind of interface EmailService and EmailServiceAsync?
> In cliente.side.code how do I send the e-mail? Should I instantiate
> that class?
> Sorry for the stupid questions, I am now getting this world java /
> gwt.
>
> thanks,
>
> Felipe

-- 
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 webgl smartgwt

2010-05-11 Thread rakesh wagh
Use emulateIE7 in your html page. I personally had limited luck with
this.
Another work around is: frames.
If your underlying layout is in smartgwt, load your canvas piece as
different module html in a frame and vice versa.

Both are really bad options, however smartgwt and gwt2 mix and match
does not really work well!

Rakesh Wagh

On May 11, 2:25 pm, Alan Chaney  wrote:
> Hi
>
> I've started to build an application using GWT 2 which will needs an
> HTML 5 canvas element to display WebGL. I was intending to use smartgwt
> for the bulk of the UI. Sadly, smartgwt gives layout problems when I add
> the  required by HTML 5 to the main html page of my app.
>
> Hopefully this will be fixed in a future version of smartgwt, but does
> anyone have any ideas for a workaround? For example, could I create a
> widget which wrapped an iframe and set the URL of the iframe to a page
> with an html 5 doctype? I could then use this widget to "embed" my webgl
> viewer.
>
> Any suggestions welcome!
>
> Thanks!
>
> 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 
> athttp://groups.google.com/group/google-web-toolkit?hl=en.

-- 
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To post to this group, send email to google-web-tool...@googlegroups.com.
To unsubscribe from this group, send email to 
google-web-toolkit+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/google-web-toolkit?hl=en.



Re: gwt webgl smartgwt

2010-05-11 Thread ckendrick
What layout issue on what browser with what code?  This is not a known
issue, so to get it addressed, post a test case to the SmartGWT
forums:

http://forums.smartclient.com/forumdisplay.php?f=14

On May 11, 12:25 pm, Alan Chaney  wrote:
> Hi
>
> I've started to build an application using GWT 2 which will needs an
> HTML 5 canvas element to display WebGL. I was intending to use smartgwt
> for the bulk of the UI. Sadly, smartgwt gives layout problems when I add
> the  required by HTML 5 to the main html page of my app.
>
> Hopefully this will be fixed in a future version of smartgwt, but does
> anyone have any ideas for a workaround? For example, could I create a
> widget which wrapped an iframe and set the URL of the iframe to a page
> with an html 5 doctype? I could then use this widget to "embed" my webgl
> viewer.
>
> Any suggestions welcome!
>
> Thanks!
>
> 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 
> athttp://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.



Debugger stopped connecting

2010-05-11 Thread David Given
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

I've been trying to integrate the web-socket-js Flash-based WebSocket
emulation library (from here: http://github.com/gimite/web-socket-js)
into my app.

I have it working, but as a side effect my app no longer debugs. I have
to compile it and run it in a browser to make it actually do anything.

What happens is that I start the debug session, get prompted with the
URL to load, load it in Firefox, and just nothing happens. No errors, no
Eclipse console messages, no Javascript console messages, nothing.
Normally there's a long delay while Eclipse compiles all the Java
classes and the app runs.

Does anyone have any suggestions of where to look to find out what's
going on? My app is rather large, taking several minutes to compile, and
I kinda need a working debugger!

This is GWT 2.0 and Firefox 3.6.3 on Linux.

- -- 
┌─── dg@cowlark.com ─ http://www.cowlark.com ─
│
│ "There is no Fermi Paradox. Any time space faring aliens make it to
│ Earth, the cows get them." --- Sam Starfall
-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.10 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/

iD8DBQFL6edWf9E0noFvlzgRAkbsAJwMiQ6m6YxbOgEzckrpiyMa41/9pQCeJnBc
rMebnzXA2PVbEEXwZ3YeA1o=
=I29d
-END PGP SIGNATURE-

-- 
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: Placing xxx.ui.xml files in different packages than counterpart Java files

2010-05-11 Thread Zak
Perhaps you can use the @UiTemplate annotation?

Check out the very bottom of 
http://code.google.com/webtoolkit/doc/latest/DevGuideUiBinder.html

I can't find any documentation about the specifics of this, but it
looks promising.

On May 11, 2:51 pm, Yaakov Chaikin  wrote:
> Hi Sri,
>
> This wouldn't really work for me as we are using maven and maven has
> specific standard directory structure. I guess, I could modify the
> pom.xml to see those additional directories as source directories as
> well, but all that work in maven that would kinda defeat the purpose
> for me, i.e., it would now move the "mess" to maven and having to deal
> with maven over this is not worth it for us at this point.
>
> I just want to know if it's possible to do this with pure GWT solution or not.
>
> Anyone know?
>
> Thanks,
> Yaakov.
>
> On Tue, May 11, 2010 at 2:39 PM, Sripathi Krishnan
>
>
>
>  wrote:
> > If you just want to keep your java, css and ui.xml code in different
> > folders, there's an easier technique. Create two folders parallel to src -
> > "uibinder" and "css". Or whatever you want to name it. Then add these
> > folders to the sourcepath in eclipse. These three folders should have the
> > same package hierarchy, so GWT will be able to find ui.xml and css files
> > without any problem.
> > In our project, the above convention helps us to separate ui code from java
> > code. Keeps the ui folks from stepping over developers toes.
> > --Sri
>
> > On 11 May 2010 21:23, Yaakov  wrote:
>
> >> Hi,
>
> >> Does anyone know if there is a way to place the ui.xml files in a
> >> separate from its Java counterpart file package?
>
> >> What I have to have is essentially the following package structure:
> >> view - All Java uibinder classes
> >> view.uibinder - All .ui.xml files
> >> view.uibinder.resources - All .css files.
>
> >> I found the @UiTemplate annotation that allowed me to successfully
> >> move the ui.xml files into the view.uibinder package and just refer to
> >> those in the Java file with @UiTemplate("uibinder/someView.ui.xml").
>
> >> Unfortunately, all the references to the resources, although showing
> >> no errors in Eclipse, start breaking on GWT compile. So, for example,
> >> if I have the following in my ui.xml:
> >> 
>
> >> When compiled, the error says that it can't find the style when lookin
> >> in view/resources/styles.css. Note the lack of "uibinder" directory in
> >> the error message!
>
> >> Upon further testing, it seems clear that when the ui.xml files gets
> >> ingested into its Java counter part, it copies that 'src' path
> >> verbatum, without adjusting it first. I know this because if I put "../
> >> resources/style.css", the error message will come with that it can't
> >> find the path and show that it's looking in "view/../resources/
> >> style.css"
>
> >> Is there some annotation or some flag I am supposed to provide to get
> >> this to work or is the location of the .ui.xml file forever stuck with
> >> the location of its counterpart Java file?
>
> >> Thanks,
> >> Yaakov.
>
> >> --
> >> 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 
> athttp://groups.google.com/group/google-web-toolkit?hl=en.

-- 
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To post to this group, send email to google-web-tool...@googlegroups.com.
To unsubscribe from this group, send email to 
google-web-toolkit+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/google-web-toolkit?hl=en.



Re: gwt webgl smartgwt

2010-05-11 Thread Alan Chaney
Label text appears to ignore the Alignment.CENTER (at least vertically) 
when placed within a VLayout. I haven't actually noticed anything else, 
but I didn't want to get a long way into what's going to be a very big 
project and hit a show stopper, so I'm was looking for a workaround 
should something critical turn up. So far, I've only checked one version 
of one browser on one OS.


I thought I had seen a mention that smartgwt should be used in "quirks" 
mode, but I can't find the reference. I'm happy to work with you to 
solve any issues arising out of using an "html" doctype, that's 
obviously the best solution.


I've done as you asked and placed a small sample on the forum.

Regards

Alan

ckendrick wrote:

What layout issue on what browser with what code?  This is not a known
issue, so to get it addressed, post a test case to the SmartGWT
forums:

http://forums.smartclient.com/forumdisplay.php?f=14

On May 11, 12:25 pm, Alan Chaney  wrote:
  

Hi

I've started to build an application using GWT 2 which will needs an
HTML 5 canvas element to display WebGL. I was intending to use smartgwt
for the bulk of the UI. Sadly, smartgwt gives layout problems when I add
the  required by HTML 5 to the main html page of my app.

Hopefully this will be fixed in a future version of smartgwt, but does
anyone have any ideas for a workaround? For example, could I create a
widget which wrapped an iframe and set the URL of the iframe to a page
with an html 5 doctype? I could then use this widget to "embed" my webgl
viewer.

Any suggestions welcome!

Thanks!

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 
athttp://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: Placing xxx.ui.xml files in different packages than counterpart Java files

2010-05-11 Thread Yaakov Chaikin
Zak,

If you read my post a bit further, most of the post discusses my
experience with using @UiTemplate.

Yaakov.

On Tue, May 11, 2010 at 7:37 PM, Zak  wrote:
> Perhaps you can use the @UiTemplate annotation?
>
> Check out the very bottom of 
> http://code.google.com/webtoolkit/doc/latest/DevGuideUiBinder.html
>
> I can't find any documentation about the specifics of this, but it
> looks promising.
>
> On May 11, 2:51 pm, Yaakov Chaikin  wrote:
>> Hi Sri,
>>
>> This wouldn't really work for me as we are using maven and maven has
>> specific standard directory structure. I guess, I could modify the
>> pom.xml to see those additional directories as source directories as
>> well, but all that work in maven that would kinda defeat the purpose
>> for me, i.e., it would now move the "mess" to maven and having to deal
>> with maven over this is not worth it for us at this point.
>>
>> I just want to know if it's possible to do this with pure GWT solution or 
>> not.
>>
>> Anyone know?
>>
>> Thanks,
>> Yaakov.
>>
>> On Tue, May 11, 2010 at 2:39 PM, Sripathi Krishnan
>>
>>
>>
>>  wrote:
>> > If you just want to keep your java, css and ui.xml code in different
>> > folders, there's an easier technique. Create two folders parallel to src -
>> > "uibinder" and "css". Or whatever you want to name it. Then add these
>> > folders to the sourcepath in eclipse. These three folders should have the
>> > same package hierarchy, so GWT will be able to find ui.xml and css files
>> > without any problem.
>> > In our project, the above convention helps us to separate ui code from java
>> > code. Keeps the ui folks from stepping over developers toes.
>> > --Sri
>>
>> > On 11 May 2010 21:23, Yaakov  wrote:
>>
>> >> Hi,
>>
>> >> Does anyone know if there is a way to place the ui.xml files in a
>> >> separate from its Java counterpart file package?
>>
>> >> What I have to have is essentially the following package structure:
>> >> view - All Java uibinder classes
>> >> view.uibinder - All .ui.xml files
>> >> view.uibinder.resources - All .css files.
>>
>> >> I found the @UiTemplate annotation that allowed me to successfully
>> >> move the ui.xml files into the view.uibinder package and just refer to
>> >> those in the Java file with @UiTemplate("uibinder/someView.ui.xml").
>>
>> >> Unfortunately, all the references to the resources, although showing
>> >> no errors in Eclipse, start breaking on GWT compile. So, for example,
>> >> if I have the following in my ui.xml:
>> >> 
>>
>> >> When compiled, the error says that it can't find the style when lookin
>> >> in view/resources/styles.css. Note the lack of "uibinder" directory in
>> >> the error message!
>>
>> >> Upon further testing, it seems clear that when the ui.xml files gets
>> >> ingested into its Java counter part, it copies that 'src' path
>> >> verbatum, without adjusting it first. I know this because if I put "../
>> >> resources/style.css", the error message will come with that it can't
>> >> find the path and show that it's looking in "view/../resources/
>> >> style.css"
>>
>> >> Is there some annotation or some flag I am supposed to provide to get
>> >> this to work or is the location of the .ui.xml file forever stuck with
>> >> the location of its counterpart Java file?
>>
>> >> Thanks,
>> >> Yaakov.
>>
>> >> --
>> >> 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 
>> athttp://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 

Re: Newbie question: How does one write a Unit test for MyClass extends RemoteServiceServlet ???

2010-05-11 Thread Trung
You can use SyncProxy to test the GWT RPC services

See http://www.gdevelop.com/w/blog/2010/01/10/testing-gwt-rpc-services/
for details



On May 5, 9:28 pm, Eric  wrote:
> On May 5, 12:33 am, Mike  wrote:
>
> > Hello
>
> > Am trying to write tests for my code, and want to ensure that any
> > class I write which extends RemoteServiceServlet;
> > however, I'm not quite catching on to what I need to do in order to
> > get a test to be runnable in that context...
>
> Have the servlet do all its work in another class, and test that
> class,
> I guess. One project I was later assigned to had made a suboptimal
> decision to do all the serious work of the application in Struts
> Action
> classes directly. Then, they tried to add web services, and now the
> services had to create Struts beans and actions.  Don't go that way.
>
> If you use a library like gwt-dispatcher, this is done for you
> naturally.
>
> Respectfully,
> Eric Jablow
>
> --
> 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.

-- 
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.



Widget from DOM element

2010-05-11 Thread lineman78
I have had difficulty finding this and figure it must be something
stupid I can't find, but how do you create a widget from an element
already in the DOM so you can get eventing, or one not in the DOM so
you can add it to a panel?

-- 
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.



Google API Library for GWT updated for GWT 2.0

2010-05-11 Thread Eric Ayers
We are pleased to announce updates to the Google API Libraries for the
Google Web Toolkit  project. The Google API Libraries for GWT project
allows GWT developers to access some of Google's popular JavaScript
APIs. This release includes updates of five libraries: Visualization,
Gears, Gadgets, Search, Language, and AjaxLoader.

Highlights of this release include:
- Libraries updated to GWT 2.0 compatibility
- Samples refactored to use war project structure
- Added Eclipse project files and ant script to all samples
Visualization:
- Added support for all image-charts: ImageAreaChart, ImageBarChart,
ImageLineChart, ImagePieChart, ImageSparklineChart
- Added wrapper for Toolbar
- Updated Visualization API bindings to be up-to-date with published
documentation
Gears:
- Added support for the BlobBuilder class and Blob.getBytes() method
- Added support for the Gears Canvas and Desktop's BlobMetaData object
Gadgets:
- Added support for multiple views and the Views API mapping
Language:
- Added support for new languages (Amharic, Greek, Persian, Russian,
Sanskrit, Serbian, Tigrinya, Yiddish)
AjaxLoader:
- Added support for the google.loader.ClientLocation API
- Added support for custom hostnames for enterprise users

For more detailed information please refer to the release notes.

These updates are now available for download at the Google API
Libraries for GWT project hosted on Google Code.

http://code.google.com/p/gwt-google-apis/

-The Google API Library for GWT Team

-- 
Eric Z. Ayers
Google Web Toolkit, Atlanta, GA USA

-- 
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: Hide/Show Table Row with UIBinder

2010-05-11 Thread Craigo
Thanks Bufferings.  UIObject.setVisible works a treat!  Cheers.

On May 9, 1:33 am, bufferings  wrote:
> hi Craigo
> I think the following is better.
>
> // show
> UIObject.setVisible(myTableRow, true);
>
> // hide
> UIObject.setVisible(myTableRow, false);
>
> This is what UIObjects#setVisible(boolean) uses.
>
> hope this helps
> --
> bufferings
>
> --
> 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.

-- 
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: Developer plug-in hangs

2010-05-11 Thread Charan
Hi,

Found issue for AttachDetachException.

Actually i was overridden the onLoad method in which i was calling
center(), inside PopupPanel.center is calling show() which in turns
calls again my onLoad() overriden method which goes to Infinite loop
finally causes the AttachDetachException.

Regards,
Charan

On May 11, 11:29 am, Charan  wrote:
> Hi,
>
> I was trying some code in GWT 2.0.3 with DialogBox and panels, dialog
> box is not showing which is throwing the AttachDetachException in FF
> firebug.
>
> I used the developer plugin to debug see the exactly which panel is
> throwing this exception i getting debug points and able to debug it
> does not showed any exception with panels (setWidget() or
> add() )properly adavnced to next line of code.
> on show() of dialog box, i tried to see any error on the developer
> plug in window it hanged not opened.
>
> When i see in Window task manager it is taking 50% of CPU usage and
> memory usage  to around 1.5gb.
>
> Because of this i am unable to figure out which panel is throwing
> exception.
>
> Regards,
> Charan
>
> --
> 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.

-- 
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.



Dynamic tab content load in TabLayoutPanel

2010-05-11 Thread Toni
Hi there!
I have a regular TabLayoutPanel and I'm trying to make the content of
each tab load dynamically when the user clicks on a particular tab. I
tried using a SelectionHandler with no luck, for tab content can't be
modified (or that's what I found out so far) and removing/adding a tab
is not an elegant option.
I also looked up gwt incubator but seems there's no widget in this
direction.
Any ideas?

Cheers!

-- 
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.