Re: Unable to get upload results from FileUpload

2010-05-28 Thread Manuel Carrasco Moñino
The problem is in the response, you have to take care of two issues in
order to have event.getResults() working:
1.- You can not read the response if the server is not the same of
your application (cross domain).
2.- The content type must be text/html or text/plain.

If you had the control of the server side, I recommend using the
gwtupload library which makes it easier.

-Manolo

On Thu, May 27, 2010 at 10:05 AM, Fahim fahimr...@gmail.com wrote:
 Hi All,

 I am using FileUpload widget to upload a file. Either file is being
 uploaded successfully or failed I am not able to get the results using
 event.getResults() in onSubmitComplete event because it is always
 null. The response type of the service which I am calling to upload is
 text/xml. Here is the response copied from fiddler:

 HTTP/1.1 200 OK
 Date: Wed, 26 May 2010 19:16:42 GMT
 Server: Apache
 X-UA-Compatible: IE=EmulateIE7
 Cache-Control: no-store, no-cache, must-revalidate, post-check=0, pre-
 check=0
 Connection: close
 Content-Type: text/xml

 xmlResponsestatuscode500/codemessageAn unknown system error
 occurred while processing the request./messagesubcode500/
 subcode/status/xmlResponse


 Any thoughts why am I not getting the above xml in in
 event.getResults()?


 Thanks,
 Fahim

 --
 You received this message because you are subscribed to the Google Groups 
 Google Web Toolkit group.
 To post to this group, send email to google-web-tool...@googlegroups.com.
 To unsubscribe from this group, send email 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: Unable to get upload results from FileUpload

2010-05-28 Thread Fahim
Hi Jeff,

I think there isn't any response.getText() when you are using
FileUpload widget. Is there?

Thanks,
Fahim

On May 28, 2:25 am, Jeff Chimene jchim...@gmail.com wrote:
 On 05/27/2010 01:17 PM, Fahim wrote:



  Hi Jeff,

  Thanks for your response.

  Actually server is not in my control. Though I can send request for
  log file but it will take some time. And I don't think that there is
  any issue on server side. We use the same service call for file upload
  in our silverlight client, which we are porting to GWT now, and it
  work just fine there.

  I guess there is something wrong with the behavior of GWT FileUpload
  control. Does it accept/return the response text of type text/xml?
  May be it only supports the content type of text/html. Any ideas?

  Thanks,
  Fahim

  On May 27, 7:05 pm, Jeff Chimene jchim...@gmail.com wrote:
  Hi Fahim:

  Check your server error log.

  On Thu, May 27, 2010 at 1:05 AM, Fahim fahimr...@gmail.com wrote:
  Hi All,

  I am using FileUpload widget to upload a file. Either file is being
  uploaded successfully or failed I am not able to get the results using
  event.getResults() in onSubmitComplete event because it is always
  null. The response type of the service which I am calling to upload is
  text/xml. Here is the response copied from fiddler:

  HTTP/1.1 200 OK
  Date: Wed, 26 May 2010 19:16:42 GMT
  Server: Apache
  X-UA-Compatible: IE=EmulateIE7
  Cache-Control: no-store, no-cache, must-revalidate, post-check=0, pre-
  check=0
  Connection: close
  Content-Type: text/xml

  xmlResponsestatuscode500/codemessageAn unknown system error
  occurred while processing the request./messagesubcode500/
  subcode/status/xmlResponse

  Any thoughts why am I not getting the above xml in in
  event.getResults()?

  Thanks,
  Fahim

 Hi Fahim:

 I have to admit that the above puzzles me. Why are you looking in
 event.getResults()? The server response will be found in
 response.getText(). 
 Seehttp://google-web-toolkit.googlecode.com/svn/javadoc/2.0/com/google/g...()

-- 
You received this message because you are subscribed to the Google Groups 
Google Web Toolkit group.
To post to this group, send email to google-web-tool...@googlegroups.com.
To unsubscribe from this group, send email 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: Triggering download in GWT via RPC

2010-05-28 Thread andreas
The goal is to download files to be stored by the user on disk. The
context application is a graphical editor which allows export of a
document in two formats. At the moment these are txt and ppt files.
They are generated separately so there is no problem with conflicting
MIME types or similar. By now I thought content type application/
octet-stream together with content-disposition attachment and a
file name would be enough.

Triggering download via IFrame URL or Window.open(URL, ...) works
fine, BUT how to pass information needed for server side file
generation. In particular I want to actually pass the whole document
currently edited in the browser application to the servlet that
generates to download file out of that document. One could surely use
parameters in the URL but I wonder if this way the passed information
is more vulnerable to interception than it would be when it was
located in the body of a request; like it is in the GWT rpc. That's
why I would have loved to use GWT rpc client side, pure HttpServlet on
the server side and finally forget about any sort of GWT CallBack back
in the browser but let the browser do a download based on response
headers. It is also very easy to get the parameters out of the request
again using GWT utility classes.

From what I also read in Sris response I quess I have to use FormPanel
submission or pass information using parameters in the URL which is
then opened via IFrame or Window.open(...).

Thank you very much for your response.

On 27 Mai, 16:28, Jeff Chimene jchim...@gmail.com wrote:
 Hi Andreas:

 It's quite possible to ... trigger a download via GWT... You don't say
 what MIME type you're wanting. For example, I trigger a download of PDF
 document. GWT code cannot handle that, so the trigger is a GWT write to an
 IFrame URL. The browser then renders the PDF in that frame.

 Perhaps you want to download HTML? If so, you have to stuff those results
 into some GWT widget. I usually do something like a MIME type of text/json,
 which can be handled using a Javascript overlay type.
 { status:%S-Success, cargo:divstuff/div}

 which can handle situations like
 {status:%F-Fail,cargo:divrequested data not found/div}

 On Thu, May 27, 2010 at 7:17 AM, andreas 
 horst.andrea...@googlemail.comwrote:



  Hi,

  I'm trying to trigger a download via GWT rpc and/or GWT
  RequestBuilder. The motivation of using rpc and/or RequestBuilder is
  the ability to send data required for the on-the-fly generated
  download files that way.

  I already managed to modify the underlying request by using
  RequestBuilder as return value of the rpc service method. The request
  is routed to a HttpServlet implementing the doPost method. GWT utility
  classes are used to obtain the RPCRequest instance and the given
  parameters of the rpc service call successfully out of the
  HttpRequest. After using the parameters and assembling the file on the
  servlet in the doPost method the HttpResponse instance is used to
  write that file. Headers 'content-disposition' and 'content-type' are
  set accordingly to trigger a download in the browser.

  However a download does not start. The response is accessible in the
  RequestCallback instance assigned to the request. The point I do not
  get about this is why the browser does not react to the content
  disposition by downloading the file and instead passing the response
  back to the ajax-world. I know that the rpc or request would fail
  otherwise but that would be perfectly fine, since no response is
  desired but a download.

  Related posts:

 http://groups.google.com/group/google-web-toolkit/browse_thread/threa...

 http://groups.google.com/group/google-web-toolkit/browse_thread/threa...

  I know that there are solutions with backposts and passing data via
  parameters in the request url, but i would love to just stick to one
  mechanism which is GWT rpc. I read a lot about that doing what i would
  like to do is not possible but no one really said why. I especially
  wonder why the browser does not do its thing since it is surely the
  one that gets the response before the ajax code doesn't he?

  I would like to hear about other solutions and if possible about why
  exactly it is not possible to trigger download via GWT rpc. After all
  escaping the GWT rpc mechanism on the server side works fine but on
  the browser side not. Any ideas?

  Greetings,
  Andreas

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

-- 
You received this message because you are subscribed to the Google Groups 
Google Web Toolkit group.
To post to this group, send email to 

Re: Triggering download in GWT via RPC

2010-05-28 Thread andreas
So when I get it right, it is a huge difference if the request is
issued sort of by hand using browser mechanisms like Links or
programmatic paste of URLs by opening a new browser window or IFrame
with a given URL COMPARED TO programmatic issued requests using GWT
rpc and/or RequestBuilder. I always thought that in the end these were
the same mechanisms.

I regard this as a limitation to me as a developer. Of course people
click OK without noticing it but in my case people would click Export
As... before clicking that dangerous OK button ... :-/

Anyway thank you very much for this information. I will have to stick
to other well known techniques issuing requests by URL also mentioned
above.

On 27 Mai, 17:36, Sripathi Krishnan sripathi.krish...@gmail.com
wrote:
  The point I do not get about this is why the browser does not react to the
  content disposition by downloading the file and instead passing the
  response back to the ajax-world... snip ... I read a lot about that doing
  what i would like to do is not possible but no one really said why.

 Browsers don't allow it because it is a major security issue. If it were
 possible, websites would start delivering malware using these mechanisms.
 Many people are stupid to just click okay.

 There is no way to automatically trigger a file download in a browser. File
 download can only begin when the user explicitly takes an action - such as
 clicking on a link.

 --Sri

 On 27 May 2010 19:47, andreas horst.andrea...@googlemail.com wrote:



  Hi,

  I'm trying to trigger a download via GWT rpc and/or GWT
  RequestBuilder. The motivation of using rpc and/or RequestBuilder is
  the ability to send data required for the on-the-fly generated
  download files that way.

  I already managed to modify the underlying request by using
  RequestBuilder as return value of the rpc service method. The request
  is routed to a HttpServlet implementing the doPost method. GWT utility
  classes are used to obtain the RPCRequest instance and the given
  parameters of the rpc service call successfully out of the
  HttpRequest. After using the parameters and assembling the file on the
  servlet in the doPost method the HttpResponse instance is used to
  write that file. Headers 'content-disposition' and 'content-type' are
  set accordingly to trigger a download in the browser.

  However a download does not start. The response is accessible in the
  RequestCallback instance assigned to the request. The point I do not
  get about this is why the browser does not react to the content
  disposition by downloading the file and instead passing the response
  back to the ajax-world. I know that the rpc or request would fail
  otherwise but that would be perfectly fine, since no response is
  desired but a download.

  Related posts:

 http://groups.google.com/group/google-web-toolkit/browse_thread/threa...

 http://groups.google.com/group/google-web-toolkit/browse_thread/threa...

  I know that there are solutions with backposts and passing data via
  parameters in the request url, but i would love to just stick to one
  mechanism which is GWT rpc. I read a lot about that doing what i would
  like to do is not possible but no one really said why. I especially
  wonder why the browser does not do its thing since it is surely the
  one that gets the response before the ajax code doesn't he?

  I would like to hear about other solutions and if possible about why
  exactly it is not possible to trigger download via GWT rpc. After all
  escaping the GWT rpc mechanism on the server side works fine but on
  the browser side not. Any ideas?

  Greetings,
  Andreas

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

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



Re: How to achieve traditional website behavior with layout panels?

2010-05-28 Thread googelybear
@Stefan: I know the term sucks, but it was the best I could come up
with ;-) As you concluded my main goal is to have browser scrollbar
scrolling and not the inner scrolling (lots of individual scrollbars
inside the containers itself, an example for this is google wave).

So in your words (...) you have to allow the parents to grow with its
child.   That's exactly the behavior of the old panels. I'm not
really clear on how we could emulate this on the new panels (all my
attempts so far failed).

To make a simple example: I have a DockLayoutPanel and somewhere a
button. There is a FlowPanel in the center. Clicking on that button
adds a label to the center panel. Repeatedly clicking that button
fills the center panel and at some point additional labels are not
displayed anymore (simulates the dynamic content). This is as you
wrote because of the overflow:hidden/auto which is set on the
DockPanel - in the LayoutPanels in general - (and is IMPOSSIBLE to
override by the programmer - at least I didn't succeed). If I add a
scrollPanel to the center as parent of the FlowPanel I get said inner
scrolling But what I would like to have is that the DockLayoutPanel
itself grows (vertically) which forces the browser to display
scrollbars.

I uploaded the (very simple) demo project here (Just import in eclipse
and run): http://drop.io/gwt_dock_panel

It would be really great if you could share how to achieve the
behavior described above.

thanks,
Dennis



On May 27, 6:55 pm, Stefan Bachert stefanbach...@yahoo.de wrote:
 Hi Dennis,

 I still think what traditionalbehaviour should be. (? not following
 the standards?)

 However, you don't want scrollbars at your LayoutPanel.

 The reason why any widget gets a scrollbar is because it is larger
 than its parent and the style overflow is set to auto or scroll.
 When the wrong widget get a scrollbar you have to change the size of
 the panel (div) hierarchy.
 Or you have to allow the parents to grow with its child.

 When you do not succeed you need to show us your code or at least the
 hierarchy ofpanels.

 Stefan Bacherthttp://gwtworld.de

 On 26 Mai, 10:33, googelybear googelyb...@gmail.com wrote:



  Hi,

  I am developing a webapp that should behave like atraditionalweb
  page, meaning that when the content grows in height the browser should
  display a vertical scroll bar. Unfortunately I was foolish and jumped
  right in on the new, shinylayoutpanels. As I found out later these
  are not suitable for me, as they create a more application-like look
  and feel with scrollbars displayed in the individual gwtpanels
  instead of the browser (try resizing e.g. google wave - When the
  available area is too small scrollbars will appear inside all the
 panels, the browser will never display any scrollbars) and also they
  are working with lots of fixed sizes (in my case the content is
  dynamic).
  I tried toachievethetraditionalbehaviorwith my LayoutPanels but
  failed. I couldn't get the browser to display scrollbars, only inner-
  panel scrolling, and stuffing a layoutpanel inside a scrollpanel is
  not the desirable approach (stuffinglayoutpanelsinside non-layout
 panelsusually ended badly for me..).
  So my conclusion is to revert to the old schoolpanels. But I am
  afraid that support of these will be dropped soon. What do you think?
  Are there better alternatives? Anyone fought with a similar problem?

  thanks for any suggestions,
  Dennis

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



How to run a unittest for a class in client folder of gwt which makes Async calls to the server

2010-05-28 Thread Sumit Somani

I am an engineering intern and want to write a test for a class which
makes a Async Request to the server How do I juct mock it up or use
some pre-built library. Please provide advise on resources

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



Any projects with python + gwt

2010-05-28 Thread mariyan nenchev
Hi,

does someone works on python + gwt/pyjamas projects?

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



Share access beween two UiBinder files?

2010-05-28 Thread Mark
Hello,

I need your help! I've got two files:

Buttons.ui.xml / Buttons.java
TextFields.ui.xml / TextFields.java

Now I need to change the content of the TextFields in the Buttons and
vice versa. Is it possible to do this without merging the two ui and
java files? I hope you understand what I mean.

Thank you very much for your help!
Mark

-- 
You received this message because you are subscribed to the Google Groups 
Google Web Toolkit group.
To post to this group, send email to google-web-tool...@googlegroups.com.
To unsubscribe from this group, send email 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 center a VerticalPanel on page with UiBinder

2010-05-28 Thread Mark
I finally found out how to do this:
g:VerticalPanel ui:field=vertialPanel
styleName='{style.centerStyle}'

Hopefully this will help anybody else.

On 27 Mai, 13:27, Mark rausch.pi...@gmail.com wrote:
 Hello,

 I am new to gwt and I hope you can help me. I want to center a
 VerticalPanel on the page.

 g:VerticalPanel ui:field=vertialPanel !-- this panel should be in
 the middle of the page --
         g:Label Login Settings/g:Label
         g:Labeltitle/g:Label
         g:Labelplaceholder/g:Label
         g:TextAreatext1/g:TextArea
         g:TextAreatext2/g:TextArea
         g:Labelstats/g:Label
 /g:VerticalPanel

 I tried several things like:

 ui:style
         .centerStyle {
         width: 800px;
         margin: 0 auto 0 auto;
         }
 /ui:style
 g:VerticalPanel ui:field=vertialPanel class='{style.centerStyle}'

 or

 @UiField
 VerticalPanel vertialPanel;

 public void onModuleLoad() {

 vertialPanel.setHorizontalAlignment(HasHorizontalAlignment.ALIGN_CENTER);
         vertialPanel.setWidth(100%);
         RootLayoutPanel.get().add(uiBinder.createAndBindUi(this));

 }

 My solutions all ended up with a page showing nothing...
 Can you perhaps give me a hint where to read more about this hole Ui
 Binder stuff? I think the google page is not very detailed...

 Thank you very much.

 Mark

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



Submit Entertainment Apps and win Cash!!!

2010-05-28 Thread James Baker
Hey Fellow Developers

Here’s our chance to submit apps that are all about FUN! This includes
music, multimedia, and of course games!

They’re basically looking for applications that truly show off all the
cool features and functionality available on today’s Nokia devices.
This could be apps designed to run on any of Nokia’s platforms – the
choice is ours – including Series 40, S60 and Maemo. Equally, it is up
to us what technologies we use to create our app, but let’s be clear:
be ready to impress them. Great huh?

What can we win:

The top three submissions will receive the following cash prizes:

•   Grand Prize: 30,000 USD in cash.
•   2nd Prize: 15,000 USD in cash.
•   3rd Prize: 5,000 USD in cash.

To submit click here http://bit.ly/aR6Vfo

Hurry guys, Deadline for submissions: 10 June 2010!!

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



FastTree in GWT 2.0.3

2010-05-28 Thread jla
Hi,

Are there any known problems about the GWT-Incubator fastTree and GWT
2.0.3. I can't seem to be able to get it to work properly. Even when
copying the demo source code into my project. On the other hand the
native Tree control is working fine.

Thanks,
Jerome

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



How to add an Element object into a Widget.

2010-05-28 Thread Rizen
Hello,

For my project, I would like to create a table in HTML by means of the
DOM tree.
For this, I'm just using the functions DOM.createTable(),
DOM.createTBody(), DOM.createTR()...
However the generated table is an Element type.

Except that I'm using the MVP as a pattern for my application. So I
have to init the main Widget with the function initWidget(), which
takes a Widget object as parameter. I was looking for a panel like the
HTMLPanel but no method can change or add an Element into a Widget.

Is there a method that I can use to cast the Element object in Widget
object ?

Here is an example of code :

public class View extends Composite {

public View() {
Element table = DOM.createTable();
Element tbody = DOM.createTBody();
Element tr = DOM.createTR();
Element td = DOM.createTD();

tr.appendChild(td);
tbody.appendChild(tr);
table.appendChild(tbody);

// Need a Widget as a type
initWidget(table);
}
}

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



Unable to download gwt-2.0.3.zip

2010-05-28 Thread Luis Daniel Mesa Velasquez
I downloaded gwt-2.0.3.zip (aprox. 36MB) but when i try to unzip it i
get a message stating the file is corrupt or is empty. When i try to
extract it using 7zip i only get 15 MB extracted and a list of error
messages saying certain files use non-valid compression methods. Can
anyone help me unzip it or download it properly? Thanks in advance.

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



compatibility with all IE

2010-05-28 Thread dhiraj
i am developing a project in which i want to show image after
browsing.My problem is when i browse image at IE6 or previous version
it displayed but this ih not work at IE7, IE8 and Firefox browsers.


please help me .
Dhiraj Kumar

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



Convert a DOM Element to Widget

2010-05-28 Thread Rizen
Hello !

For my project, I'm using the MVP pattern and inside my view I need to
create a table from the DOM tree. For this, I just use the functions
DOM.createTable(), DOM.createTBody()... no difficulty for the moment.
But the view in the MVP pattern extends the Composite class, so I need
to init the main Widget with initWidget whereas my table is an Element
object.

I don't know how can I implement my table into the view, using the DOM
tree. Do I need to use an other container like a panel or something
like that ?
Thanks a lot for your help.

Here is an example of code :

public class View extends Composite {
   public View() {
}
}

-- 
You received this message because you are subscribed to the Google Groups 
Google Web Toolkit group.
To post to this group, send email to google-web-tool...@googlegroups.com.
To unsubscribe from this group, send email 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 center a VerticalPanel on page with UiBinder

2010-05-28 Thread Mike
Where did it get the definition for: {style.centerStyle} ???

Does UiBinder have access to all of the default style information
provided by GWT?

Usually, to center something horizontally, the technique is this:

.centerStyle {
   margin-left: auto;
   margin-right: auto;
}

(I believe)

Cheers
Mike

On May 28, 7:07 am, Mark rausch.pi...@gmail.com wrote:
 I finally found out how to do this:
 g:VerticalPanel ui:field=vertialPanel
 styleName='{style.centerStyle}'

 Hopefully this will help anybody else.

 On 27 Mai, 13:27, Mark rausch.pi...@gmail.com wrote:



  Hello,

  I am new to gwt and I hope you can help me. I want to center a
  VerticalPanel on the page.

  g:VerticalPanel ui:field=vertialPanel !-- this panel should be in
  the middle of the page --
          g:Label Login Settings/g:Label
          g:Labeltitle/g:Label
          g:Labelplaceholder/g:Label
          g:TextAreatext1/g:TextArea
          g:TextAreatext2/g:TextArea
          g:Labelstats/g:Label
  /g:VerticalPanel

  I tried several things like:

  ui:style
          .centerStyle {
          width: 800px;
          margin: 0 auto 0 auto;
          }
  /ui:style
  g:VerticalPanel ui:field=vertialPanel class='{style.centerStyle}'

  or

  @UiField
  VerticalPanel vertialPanel;

  public void onModuleLoad() {

  vertialPanel.setHorizontalAlignment(HasHorizontalAlignment.ALIGN_CENTER);
          vertialPanel.setWidth(100%);
          RootLayoutPanel.get().add(uiBinder.createAndBindUi(this));

  }

  My solutions all ended up with a page showing nothing...
  Can you perhaps give me a hint where to read more about this hole Ui
  Binder stuff? I think the google page is not very detailed...

  Thank you very much.

  Mark

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



Re: Disable/Enable CSS obfuscating in gwt.xml ?

2010-05-28 Thread Chris Lercher
It can be done:

com.gwt.resources.Resources.gwt.xml defines the CssResource.style
property. Looking into
com.google.gwt.resources.rg.CssResourceGenerator.init() shows, that we
can set the property to pretty - so in your .gwt.xml file you would
write:

set-configuration-property name=CssResource.style value=pretty/

The resulting name is still complex (because it has to be unique
across multiple CSS resources), but at least it contains the original
class name at the end of the name - I'm not sure, if you can use this
in your situation?

Chris


On May 27, 9:01 pm, Ed post2edb...@gmail.com wrote:
 How is it possible to disable/enable CSS obfuscating in the gwt.xml
 file ?

 This should be very handy as I have many css styles that aren't
 allowed to be obfuscated during testing as they are used by Selenium.
 At the moment I disable obfuscating with the annotation @external, but
 that is fixed. I would love if this would be adjustable in the gwt.xml
 file.

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



Joseph Favara/HQ/Corp/OAI is out of the office.

2010-05-28 Thread Joseph . Favara

I will be out of the office starting  05/28/2010 and will not return until
06/01/2010.

I will respond to your message when I return. If this is urgnet please
contact Paul Frasceschini at 105628

-- 
You received this message because you are subscribed to the Google Groups 
Google Web Toolkit group.
To post to this group, send email to google-web-tool...@googlegroups.com.
To unsubscribe from this group, send email 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: Convert a DOM Element to Widget

2010-05-28 Thread Rizen
I'm so sorry I don't know why I have two discussions but the real
discussion is here : 
http://groups.google.com/group/google-web-toolkit/browse_thread/thread/7ce36cd0423f5428#

Please reply on the other discussion.
Really sorry.
Thank you.

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



Re: How to achieve traditional website behavior with layout panels?

2010-05-28 Thread Olivier Monaco
You must not use *LayoutPanel for this purpose. Why not native HTML?

MyApp.ui.xml
!DOCTYPE ui:UiBinder SYSTEM http://dl.google.com/gwt/DTD/xhtml.ent;
ui:UiBinder xmlns:ui=urn:ui:com.google.gwt.uibinder
xmlns:g='urn:import:com.google.gwt.user.client.ui'
  ui:style
.top {
  height: 120px;
}
  /ui:style
  HTMLPanel
div class={style.top}
  g:Button ui:field=buttonClick me/g:Button
/div
g:FlowPanel ui:field=content /
  /HTMLPanel
/ui:UiBinder


MyApp.java
public class MyApp extends Composite {
  ... // UiBinder stuff

  public MyApp() {
initWidget(binder.createAndBind(this));
  }

  @UiHandler(button)
  void onButtonClick(ClickEvent event) {
content.add(new Label(Hello world);
  }
}


Not tested...

Olivier
On 28 mai, 10:39, googelybear googelyb...@gmail.com wrote:
 @Stefan: I know the term sucks, but it was the best I could come up
 with ;-) As you concluded my main goal is to have browser scrollbar
 scrolling and not the inner scrolling (lots of individual scrollbars
 inside the containers itself, an example for this is google wave).

 So in your words (...) you have to allow the parents to grow with its
 child.   That's exactly the behavior of the old panels. I'm not
 really clear on how we could emulate this on the new panels (all my
 attempts so far failed).

 To make a simple example: I have a DockLayoutPanel and somewhere a
 button. There is a FlowPanel in the center. Clicking on that button
 adds a label to the center panel. Repeatedly clicking that button
 fills the center panel and at some point additional labels are not
 displayed anymore (simulates the dynamic content). This is as you
 wrote because of the overflow:hidden/auto which is set on the
 DockPanel - in the LayoutPanels in general - (and is IMPOSSIBLE to
 override by the programmer - at least I didn't succeed). If I add a
 scrollPanel to the center as parent of the FlowPanel I get said inner
 scrolling But what I would like to have is that the DockLayoutPanel
 itself grows (vertically) which forces the browser to display
 scrollbars.

 I uploaded the (very simple) demo project here (Just import in eclipse
 and run):http://drop.io/gwt_dock_panel

 It would be really great if you could share how to achieve the
 behavior described above.

 thanks,
 Dennis

 On May 27, 6:55 pm, Stefan Bachert stefanbach...@yahoo.de wrote:

  Hi Dennis,

  I still think what traditionalbehaviour should be. (? not following
  the standards?)

  However, you don't want scrollbars at your LayoutPanel.

  The reason why any widget gets a scrollbar is because it is larger
  than its parent and the style overflow is set to auto or scroll.
  When the wrong widget get a scrollbar you have to change the size of
  the panel (div) hierarchy.
  Or you have to allow the parents to grow with its child.

  When you do not succeed you need to show us your code or at least the
  hierarchy ofpanels.

  Stefan Bacherthttp://gwtworld.de

  On 26 Mai, 10:33, googelybear googelyb...@gmail.com wrote:

   Hi,

   I am developing a webapp that should behave like atraditionalweb
   page, meaning that when the content grows in height the browser should
   display a vertical scroll bar. Unfortunately I was foolish and jumped
   right in on the new, shinylayoutpanels. As I found out later these
   are not suitable for me, as they create a more application-like look
   and feel with scrollbars displayed in the individual gwtpanels
   instead of the browser (try resizing e.g. google wave - When the
   available area is too small scrollbars will appear inside all the
  panels, the browser will never display any scrollbars) and also they
   are working with lots of fixed sizes (in my case the content is
   dynamic).
   I tried toachievethetraditionalbehaviorwith my LayoutPanels but
   failed. I couldn't get the browser to display scrollbars, only inner-
   panel scrolling, and stuffing a layoutpanel inside a scrollpanel is
   not the desirable approach (stuffinglayoutpanelsinside non-layout
  panelsusually ended badly for me..).
   So my conclusion is to revert to the old schoolpanels. But I am
   afraid that support of these will be dropped soon. What do you think?
   Are there better alternatives? Anyone fought with a similar problem?

   thanks for any suggestions,
   Dennis



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



Re: Disable/Enable CSS obfuscating in gwt.xml ?

2010-05-28 Thread Thomas Broyer


On May 28, 3:29 pm, Chris Lercher cl_for_mail...@gmx.net wrote:
 It can be done:

 com.gwt.resources.Resources.gwt.xml defines the CssResource.style
 property. Looking into
 com.google.gwt.resources.rg.CssResourceGenerator.init() shows, that we
 can set the property to pretty - so in your .gwt.xml file you would
 write:

 set-configuration-property name=CssResource.style value=pretty/

Note that you didn't have to digg into the code, this is a documented
switch:
http://code.google.com/webtoolkit/doc/latest/DevGuideClientBundle.html#Levers_and_Knobs

 The resulting name is still complex (because it has to be unique
 across multiple CSS resources), but at least it contains the original
 class name at the end of the name - I'm not sure, if you can use this
 in your situation?

See 
http://code.google.com/webtoolkit/doc/latest/DevGuideClientBundle.html#Selector_obfuscation
Though I don't know what it exactly does to change the
obfuscationPrefix.

-- 
You received this message because you are subscribed to the Google Groups 
Google Web Toolkit group.
To post to this group, send email to google-web-tool...@googlegroups.com.
To unsubscribe from this group, send email 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: Convert a DOM Element to Widget

2010-05-28 Thread Thomas Broyer


On May 27, 8:49 pm, Rizen vianney.dep...@gmail.com wrote:
 Hello !

 For my project, I'm using the MVP pattern and inside my view I need to
 create a table from the DOM tree. For this, I just use the functions
 DOM.createTable(), DOM.createTBody()... no difficulty for the moment.
 But the view in the MVP pattern extends the Composite class, so I need
 to init the main Widget with initWidget whereas my table is an Element
 object.

 I don't know how can I implement my table into the view, using the DOM
 tree. Do I need to use an other container like a panel or something
 like that ?

It looks like your view should just extend Widget and call
setElement() (almost-equivalent to Composite's initWidget()).

-- 
You received this message because you are subscribed to the Google Groups 
Google Web Toolkit group.
To post to this group, send email to google-web-tool...@googlegroups.com.
To unsubscribe from this group, send email 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 add an Element object into a Widget.

2010-05-28 Thread Olivier Monaco
Replace Composite by Widget and initWidget by setElement...

You can also you GWT tables...

Olivier

On 28 mai, 13:08, Rizen vianney.dep...@gmail.com wrote:
 Hello,

 For my project, I would like to create a table in HTML by means of the
 DOM tree.
 For this, I'm just using the functions DOM.createTable(),
 DOM.createTBody(), DOM.createTR()...
 However the generated table is an Element type.

 Except that I'm using the MVP as a pattern for my application. So I
 have to init the main Widget with the function initWidget(), which
 takes a Widget object as parameter. I was looking for a panel like the
 HTMLPanel but no method can change or add an Element into a Widget.

 Is there a method that I can use to cast the Element object in Widget
 object ?

 Here is an example of code :

 public class View extends Composite {

         public View() {
                 Element table = DOM.createTable();
                 Element tbody = DOM.createTBody();
                 Element tr = DOM.createTR();
                 Element td = DOM.createTD();

                 tr.appendChild(td);
                 tbody.appendChild(tr);
                 table.appendChild(tbody);

                 // Need a Widget as a type
                 initWidget(table);
         }

 }



-- 
You received this message because you are subscribed to the Google Groups 
Google Web Toolkit group.
To post to this group, send email to google-web-tool...@googlegroups.com.
To unsubscribe from this group, send email 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 run a unittest for a class in client folder of gwt which makes Async calls to the server

2010-05-28 Thread Thomas Broyer


On May 28, 10:39 am, Sumit Somani sumitsom...@google.com wrote:
 I am an engineering intern and want to write a test for a class which
 makes a Async Request to the server How do I juct mock it up or use
 some pre-built library. Please provide advise on resources

Some pointers:
Actually making the calls:
http://code.google.com/webtoolkit/doc/latest/DevGuideTesting.html#DevGuideAsynchronousTesting
Mocking the service so you can test the calling code:
http://code.google.com/webtoolkit/articles/testing_methodologies_using_gwt.html
http://googletesting.blogspot.com/2009/08/tott-testing-gwt-without-gwttest.html
http://googletesting.blogspot.com/2009/02/with-all-sport-drug-scandals-of-late.html
http://googletesting.blogspot.com/2008/06/taming-beast-aka-how-to-test-ajax.html
http://googletesting.blogspot.com/2008/08/taming-beast.html

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



Re: Synchronous Calls with RPC??

2010-05-28 Thread Olivier Monaco
Carl,

Your proposal is interesting. But as a user, if I have to wait, I
leave... So many be an application needing some wait a minute popup
is not a good approach for the future. Imagine your browser putting a
popup each time a page is loading. Tabs will become useless, multi-
core computer too and so one...

Okay, it's not easy to do such application without popups. And I'm the
first to use popup ;). But it can be really, really better.

Olivier

On 28 mai, 06:36, Carl Pritchett bogusggem...@gmail.com wrote:
 I'm on the synchronous calls are the wrong approach side, but what
 would really be useful would be some utility classes that allowed
 synchronous like approaches.

 Specifically :
 - an async batcher that given a list of async services calls all at
 once and then executes a specified action when all return (it keeps an
 internal count of async calls returned)
 - a serialized async batcher that calls a list of async services one
 at a time and then executes a specified action when the last one
 returns (each callback triggers the next async call)

 So you could block all (or part) of the UI with a modal overlay, call
 the async batcher and set the return action to fire an event to
 unblock the UI.

 I found this pattern helpful when loading data from different services
 while making the user wait till all the data has arrived. It can be a
 bit more flexible that building lots of services (and the returned
 objects) into one call.

 Regards,
 Carl

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



How do you share css resources across multiple modules?

2010-05-28 Thread tobirius
Hi all,

In my application I need to include several gwt modules into a page.
They all inherit from the same base module which provides some
CssResources.
Is it possible to inject the css of these resources only once using it
across all included modules?
Currently I need to inject the same styles for each module as the
obfuscated class names differe from one module to the other.
Is there any way to ensure the same class names at different compile
times?

Greetings, Tobias

-- 
You received this message because you are subscribed to the Google Groups 
Google Web Toolkit group.
To post to this group, send email to google-web-tool...@googlegroups.com.
To unsubscribe from this group, send email 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: Fastest way to create lots of similar elements

2010-05-28 Thread Thomas Broyer


On May 28, 1:48 am, Chris Lercher cl_for_mail...@gmx.net wrote:
 Hi George,

 absolutely - the other browsers are fine with simple DOM manipulation.

 Inspired by the (a little bit outdated) benchmark [1], I changed my
 code to join arrays instead of strings:

 --
 void attachImages(...) {
   final JsArrayString array = JavaScriptObject.createArray().cast();
   for (...) {
      boolean flag = ...;
      array.push(flag ? img src='images/a.gif' style='left: : img
 src='images/b.gif' style='top:);
      array.push(String.valueOf(i));
      array.push(em'/);
   }
   div1.setHTML(array.join());

 }

 --

 This also only calls setHTML() once at the end of the loop.

 Does anybody see possibilities for optimization - either improving
 performance or resulting in cleaner code?

Use a StringBuilder, it'll optimize dependending on the browser
(pushing into an array and then joining the items, or concatenating
strings, whichever has been benchmarked the fastest by the GWT team)

-- 
You received this message because you are subscribed to the Google Groups 
Google Web Toolkit group.
To post to this group, send email to google-web-tool...@googlegroups.com.
To unsubscribe from this group, send email 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: Triggering download in GWT via RPC

2010-05-28 Thread Jeff Chimene
Hi Andreas:

You can certainly send the two files to the server via GWTUpload. As Sri
observed, the user must EXPLICITLY REQUEST THAT ACTION. Your browser app
cannot do that on behalf of the user.

You can receive stuff in the browser from the server. If it's a custom
file structure, you'll have to open the app that handles that structure
(like the browser opens Acrobat to handle PDF, or Office to handle Word Doc
format) In order for this to work, you'll have to do a two-step process
after sending the document to the server via GWTUpload
Step 1: Receive the processing results from the server; which is the
standard AJAX/GWTUpload response handling mechanism
Step 2: Do the IFrame trick to actually request the document from the
server. As you know, the server will send the appropriate headers to trigger
the custom app to open the document.

On Fri, May 28, 2010 at 12:31 AM, andreas horst.andrea...@googlemail.comwrote:

 The goal is to download files to be stored by the user on disk. The
 context application is a graphical editor which allows export of a
 document in two formats. At the moment these are txt and ppt files.
 They are generated separately so there is no problem with conflicting
 MIME types or similar. By now I thought content type application/
 octet-stream together with content-disposition attachment and a
 file name would be enough.

 Triggering download via IFrame URL or Window.open(URL, ...) works
 fine, BUT how to pass information needed for server side file
 generation. In particular I want to actually pass the whole document
 currently edited in the browser application to the servlet that
 generates to download file out of that document. One could surely use
 parameters in the URL but I wonder if this way the passed information
 is more vulnerable to interception than it would be when it was
 located in the body of a request; like it is in the GWT rpc. That's
 why I would have loved to use GWT rpc client side, pure HttpServlet on
 the server side and finally forget about any sort of GWT CallBack back
 in the browser but let the browser do a download based on response
 headers. It is also very easy to get the parameters out of the request
 again using GWT utility classes.

 From what I also read in Sris response I quess I have to use FormPanel
 submission or pass information using parameters in the URL which is
 then opened via IFrame or Window.open(...).

 Thank you very much for your response.

 On 27 Mai, 16:28, Jeff Chimene jchim...@gmail.com wrote:
  Hi Andreas:
 
  It's quite possible to ... trigger a download via GWT... You don't say
  what MIME type you're wanting. For example, I trigger a download of PDF
  document. GWT code cannot handle that, so the trigger is a GWT write to
 an
  IFrame URL. The browser then renders the PDF in that frame.
 
  Perhaps you want to download HTML? If so, you have to stuff those results
  into some GWT widget. I usually do something like a MIME type of
 text/json,
  which can be handled using a Javascript overlay type.
  { status:%S-Success, cargo:divstuff/div}
 
  which can handle situations like
  {status:%F-Fail,cargo:divrequested data not found/div}
 
  On Thu, May 27, 2010 at 7:17 AM, andreas horst.andrea...@googlemail.com
 wrote:
 
 
 
   Hi,
 
   I'm trying to trigger a download via GWT rpc and/or GWT
   RequestBuilder. The motivation of using rpc and/or RequestBuilder is
   the ability to send data required for the on-the-fly generated
   download files that way.
 
   I already managed to modify the underlying request by using
   RequestBuilder as return value of the rpc service method. The request
   is routed to a HttpServlet implementing the doPost method. GWT utility
   classes are used to obtain the RPCRequest instance and the given
   parameters of the rpc service call successfully out of the
   HttpRequest. After using the parameters and assembling the file on the
   servlet in the doPost method the HttpResponse instance is used to
   write that file. Headers 'content-disposition' and 'content-type' are
   set accordingly to trigger a download in the browser.
 
   However a download does not start. The response is accessible in the
   RequestCallback instance assigned to the request. The point I do not
   get about this is why the browser does not react to the content
   disposition by downloading the file and instead passing the response
   back to the ajax-world. I know that the rpc or request would fail
   otherwise but that would be perfectly fine, since no response is
   desired but a download.
 
   Related posts:
 
  http://groups.google.com/group/google-web-toolkit/browse_thread/threa.
 ..
 
  http://groups.google.com/group/google-web-toolkit/browse_thread/threa.
 ..
 
   I know that there are solutions with backposts and passing data via
   parameters in the request url, but i would love to just stick to one
   mechanism which is GWT rpc. I read a lot about that doing what i would
   like to do is not possible but no one 

Re: How do you share css resources across multiple modules?

2010-05-28 Thread Mark
I am not sure if this is exactly what you want to do - but have a look
at this page:
http://code.google.com/intl/de-DE/webtoolkit/doc/latest/DevGuideUiBinder.html#Share_resource_instances

On 28 Mai, 16:25, tobirius t.herrm...@alkacon.com wrote:
 Hi all,

 In my application I need to include several gwt modules into a page.
 They all inherit from the same base module which provides some
 CssResources.
 Is it possible to inject the css of these resources only once using it
 across all included modules?
 Currently I need to inject the same styles for each module as the
 obfuscated class names differe from one module to the other.
 Is there any way to ensure the same class names at different compile
 times?

 Greetings, Tobias

-- 
You received this message because you are subscribed to the Google Groups 
Google Web Toolkit group.
To post to this group, send email to google-web-tool...@googlegroups.com.
To unsubscribe from this group, send email 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: Unable to download gwt-2.0.3.zip

2010-05-28 Thread Chris Conroy
I just verified that the download site is working.

Check the sha1sum of your download:
$ sha1sum gwt-2.0.3.zip
1dabd25a02b9299f6fa84c51c97210a3373a663e  gwt-2.0.3.zip

If it matches, then you need to troubleshoot your unzip process. If it
doesn't, you need to re-download.

On Fri, May 28, 2010 at 4:52 AM, Luis Daniel Mesa Velasquez
luisdanielm...@gmail.com wrote:
 I downloaded gwt-2.0.3.zip (aprox. 36MB) but when i try to unzip it i
 get a message stating the file is corrupt or is empty. When i try to
 extract it using 7zip i only get 15 MB extracted and a list of error
 messages saying certain files use non-valid compression methods. Can
 anyone help me unzip it or download it properly? Thanks in advance.

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





-- 
Chris Conroy
Software Engineer
Google, Atlanta

-- 
You received this message because you are subscribed to the Google Groups 
Google Web Toolkit group.
To post to this group, send email to google-web-tool...@googlegroups.com.
To unsubscribe from this group, send email 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 do you share css resources across multiple modules?

2010-05-28 Thread Tobias Herrmann
No, that is not what I was looking for. I know how to use the same 
CssResource across several widgets.
In my case, I need to share the same resource across several modules, 
not compiled together but one after the other.


Mark schrieb:

I am not sure if this is exactly what you want to do - but have a look
at this page:
http://code.google.com/intl/de-DE/webtoolkit/doc/latest/DevGuideUiBinder.html#Share_resource_instances

On 28 Mai, 16:25, tobirius t.herrm...@alkacon.com wrote:
  

Hi all,

In my application I need to include several gwt modules into a page.
They all inherit from the same base module which provides some
CssResources.
Is it possible to inject the css of these resources only once using it
across all included modules?
Currently I need to inject the same styles for each module as the
obfuscated class names differe from one module to the other.
Is there any way to ensure the same class names at different compile
times?

Greetings, Tobias



  


--
You received this message because you are subscribed to the Google Groups Google 
Web Toolkit group.
To post to this group, send email to google-web-tool...@googlegroups.com.
To unsubscribe from this group, send email 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: Unable to get upload results from FileUpload

2010-05-28 Thread Jeff Chimene
Hi Faim:

Sorry, yes, you're right.

Here is a working example:
private final IUploader.OnFinishUploaderHandler onFinishUploaderHandler =
new IUploader.OnFinishUploaderHandler() {
public void onFinish(IUploader uploader) {
if (uploader.getStatus() == Status.SUCCESS) {
  STUFF
}
};

used as follows:

/*
 * Add a finish handler which will load the image once the upload
 * ... finishes
 */
singleUploader.addOnFinishUploadHandler(onFinishUploaderHandler);
singleUploader.setServletPath(cgi-bin/jsupload.cgi);

I'm still not sure where your event.getResults() comes from.

Not to belabor the point, but do you have the server error log yet?

On Thu, May 27, 2010 at 11:51 PM, Fahim fahimr...@gmail.com wrote:

 Hi Jeff,

 I think there isn't any response.getText() when you are using
 FileUpload widget. Is there?

 Thanks,
 Fahim

 On May 28, 2:25 am, Jeff Chimene jchim...@gmail.com wrote:
  On 05/27/2010 01:17 PM, Fahim wrote:
 
 
 
   Hi Jeff,
 
   Thanks for your response.
 
   Actually server is not in my control. Though I can send request for
   log file but it will take some time. And I don't think that there is
   any issue on server side. We use the same service call for file upload
   in our silverlight client, which we are porting to GWT now, and it
   work just fine there.
 
   I guess there is something wrong with the behavior of GWT FileUpload
   control. Does it accept/return the response text of type text/xml?
   May be it only supports the content type of text/html. Any ideas?
 
   Thanks,
   Fahim
 
   On May 27, 7:05 pm, Jeff Chimene jchim...@gmail.com wrote:
   Hi Fahim:
 
   Check your server error log.
 
   On Thu, May 27, 2010 at 1:05 AM, Fahim fahimr...@gmail.com wrote:
   Hi All,
 
   I am using FileUpload widget to upload a file. Either file is being
   uploaded successfully or failed I am not able to get the results
 using
   event.getResults() in onSubmitComplete event because it is always
   null. The response type of the service which I am calling to upload
 is
   text/xml. Here is the response copied from fiddler:
 
   HTTP/1.1 200 OK
   Date: Wed, 26 May 2010 19:16:42 GMT
   Server: Apache
   X-UA-Compatible: IE=EmulateIE7
   Cache-Control: no-store, no-cache, must-revalidate, post-check=0,
 pre-
   check=0
   Connection: close
   Content-Type: text/xml
 
   xmlResponsestatuscode500/codemessageAn unknown system error
   occurred while processing the request./messagesubcode500/
   subcode/status/xmlResponse
 
   Any thoughts why am I not getting the above xml in in
   event.getResults()?
 
   Thanks,
   Fahim
 
  Hi Fahim:
 
  I have to admit that the above puzzles me. Why are you looking in
  event.getResults()? The server response will be found in
  response.getText(). Seehttp://
 google-web-toolkit.googlecode.com/svn/javadoc/2.0/com/google/g...()http://google-web-toolkit.googlecode.com/svn/javadoc/2.0/com/google/g...%28%29

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



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



Re: Share access beween two UiBinder files?

2010-05-28 Thread Tristan
like this?

Buttons buttons = new Buttons();
TextFields fields = new TextFields();
buttons.setFieds(fields);
fields.setButtons(buttons);

??

Can you elaborate?

On May 28, 7:05 am, Mark rausch.pi...@gmail.com wrote:
 Hello,

 I need your help! I've got two files:

 Buttons.ui.xml / Buttons.java
 TextFields.ui.xml / TextFields.java

 Now I need to change the content of the TextFields in the Buttons and
 vice versa. Is it possible to do this without merging the two ui and
 java files? I hope you understand what I mean.

 Thank you very much for your help!
 Mark

-- 
You received this message because you are subscribed to the Google Groups 
Google Web Toolkit group.
To post to this group, send email to google-web-tool...@googlegroups.com.
To unsubscribe from this group, send email 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 RPC calls from java

2010-05-28 Thread ussuri
Hello! I know that the question has been asked several times, but the
last discussion I was able to find dates back to 2009, so I'll ask the
question again:

Can I _easily_ call GWT-RPC server side from a pure java client
application? If not, is the ability on the roadmap? What are the best
alternatives?

Basically, what I need to do:

1. a GWT-based client
2. a GAE-based server (java flavor)
3. a Java desktop client (Swing)

As everything is developed in Java, we are going to re-use a lot of
code; ideally we would prefer to have only the GUI part to be
different b/w our GWT and our Swing clients. However, we can't find a
way to call into GAE from GWT and stand-alone java other than low-
level HTML calls.

Thanks,
MG

-- 
You received this message because you are subscribed to the Google Groups 
Google Web Toolkit group.
To post to this group, send email to google-web-tool...@googlegroups.com.
To unsubscribe from this group, send email 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: Fastest way to create lots of similar elements

2010-05-28 Thread Eric


On May 27, 3:33 pm, Chris Lercher cl_for_mail...@gmx.net wrote:
 Hi,

 I need to create lots (hundreds) of image tags, and attach them
 dynamically to several plain div class=xy/div elements:

 div class=xy
   img src=images/a.gif style=top: 1em;/
   img src=images/a.gif style=top: 2em;/
   img src=images/b.gif style=top: 3em;/
   ...
 /div

Isn't this what ImageBundle does?  That combines various images
into a simgle one at compile time, and uses CSS to show only
the desired portion the combined image when used.

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 at 
http://groups.google.com/group/google-web-toolkit?hl=en.



Re: Unable to download gwt-2.0.3.zip

2010-05-28 Thread Stefan Bachert
Hi Luis,

try it to download again or use different tools. Sometimes a download
fails.

I did not had any problem (but I am using ubuntu)

Stefan Bachert
http://gwtworld.de


On 28 Mai, 10:52, Luis Daniel Mesa Velasquez
luisdanielm...@gmail.com wrote:
 I downloaded gwt-2.0.3.zip (aprox. 36MB) but when i try to unzip it i
 get a message stating the file is corrupt or is empty. When i try to
 extract it using 7zip i only get 15 MB extracted and a list of error
 messages saying certain files use non-valid compression methods. Can
 anyone help me unzip it or download it properly? Thanks in advance.

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



Re: Share access beween two UiBinder files?

2010-05-28 Thread Mark Schewe
First of all thank you for the answer.
I am new to GWT so I am a bit confused and not know yet the correct
terminology :)

Main.ui.xml:

g:FlowPanel
g:VerticalPanel
r:TextFields  / // calls TextFields.ui.xml
r:Buttons  /  // calls Buttons.ui.xml
/g:VerticalPanel
/g:FlowPanel


Buttons.ui.xml:

g:HorizontalPanel
g:Button ui:field=prevButtonprev/g:Button
g:Button ui:field=nextButtonnext/g:Button
/g:HorizontalPanel


TextFields.ui.xml:

g:VerticalPanel
g:TextArea ui:field=taText blah/g:TextArea
/g:VerticalPanel


Buttons.java:

@UiHandler(nextButton)
void onClickNext(ClickEvent click) {
// change text field in TextFields.ui.xml
}

In this last handler I need to access the textfield. I hope my problem
is now easier to understand. I guess this has something to do with
@UiFactory  but I just don't get it.

2010/5/28 Tristan tristan.slomin...@gmail.com:
 like this?

 Buttons buttons = new Buttons();
 TextFields fields = new TextFields();
 buttons.setFieds(fields);
 fields.setButtons(buttons);

 ??

 Can you elaborate?

 On May 28, 7:05 am, Mark rausch.pi...@gmail.com wrote:
 Hello,

 I need your help! I've got two files:

 Buttons.ui.xml / Buttons.java
 TextFields.ui.xml / TextFields.java

 Now I need to change the content of the TextFields in the Buttons and
 vice versa. Is it possible to do this without merging the two ui and
 java files? I hope you understand what I mean.

 Thank you very much for your help!
 Mark

 --
 You received this message because you are subscribed to the Google Groups 
 Google Web Toolkit group.
 To post to this group, send email to google-web-tool...@googlegroups.com.
 To unsubscribe from this group, send email 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: Share access beween two UiBinder files?

2010-05-28 Thread Tristan Slominski
Hmm...

Why don't you do it in main? It's the one thing that knows about both.

Buttons.java:

@UiHandler(nextButton)
void onClickNext(ClickEvent click) {
  getMain().onClickNext();
}

Main.java:

public void onClickNext(){
  getTextFields.setText(something);
}

On Fri, May 28, 2010 at 10:19, Mark Schewe schewe.m...@gmail.com wrote:

 First of all thank you for the answer.
 I am new to GWT so I am a bit confused and not know yet the correct
 terminology :)

 Main.ui.xml:

 g:FlowPanel
g:VerticalPanel
r:TextFields  / // calls TextFields.ui.xml
r:Buttons  /  // calls Buttons.ui.xml
/g:VerticalPanel
 /g:FlowPanel


 Buttons.ui.xml:

 g:HorizontalPanel
g:Button ui:field=prevButtonprev/g:Button
g:Button ui:field=nextButtonnext/g:Button
 /g:HorizontalPanel


 TextFields.ui.xml:

 g:VerticalPanel
g:TextArea ui:field=taText blah/g:TextArea
 /g:VerticalPanel


 Buttons.java:

 @UiHandler(nextButton)
 void onClickNext(ClickEvent click) {
// change text field in TextFields.ui.xml
 }

 In this last handler I need to access the textfield. I hope my problem
 is now easier to understand. I guess this has something to do with
 @UiFactory  but I just don't get it.

 2010/5/28 Tristan tristan.slomin...@gmail.com:
  like this?
 
  Buttons buttons = new Buttons();
  TextFields fields = new TextFields();
  buttons.setFieds(fields);
  fields.setButtons(buttons);
 
  ??
 
  Can you elaborate?
 
  On May 28, 7:05 am, Mark rausch.pi...@gmail.com wrote:
  Hello,
 
  I need your help! I've got two files:
 
  Buttons.ui.xml / Buttons.java
  TextFields.ui.xml / TextFields.java
 
  Now I need to change the content of the TextFields in the Buttons and
  vice versa. Is it possible to do this without merging the two ui and
  java files? I hope you understand what I mean.
 
  Thank you very much for your help!
  Mark
 
  --
  You received this message because you are subscribed to the Google Groups
 Google Web Toolkit group.
  To post to this group, send email to google-web-toolkit@googlegroups.com
 .
  To unsubscribe from this group, send email to
 google-web-toolkit+unsubscr...@googlegroups.comgoogle-web-toolkit%2bunsubscr...@googlegroups.com
 .
  For more options, visit this group at
 http://groups.google.com/group/google-web-toolkit?hl=en.
 
 

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



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



Re: Disable/Enable CSS obfuscating in gwt.xml ?

2010-05-28 Thread Ed Bras
Hi,

That sounds nice, I shall have a closer look at it.
It should be nice if it could be more fine-grained, as it normally concern a
few styles that should be annotated with @external for testing.

Ed


On Fri, May 28, 2010 at 3:29 PM, Chris Lercher cl_for_mail...@gmx.netwrote:

 It can be done:

 com.gwt.resources.Resources.gwt.xml defines the CssResource.style
 property. Looking into
 com.google.gwt.resources.rg.CssResourceGenerator.init() shows, that we
 can set the property to pretty - so in your .gwt.xml file you would
 write:

 set-configuration-property name=CssResource.style value=pretty/

 The resulting name is still complex (because it has to be unique
 across multiple CSS resources), but at least it contains the original
 class name at the end of the name - I'm not sure, if you can use this
 in your situation?

 Chris


 On May 27, 9:01 pm, Ed post2edb...@gmail.com wrote:
  How is it possible to disable/enable CSS obfuscating in the gwt.xml
  file ?
 
  This should be very handy as I have many css styles that aren't
  allowed to be obfuscated during testing as they are used by Selenium.
  At the moment I disable obfuscating with the annotation @external, but
  that is fixed. I would love if this would be adjustable in the gwt.xml
  file.

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



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



Re: Fastest way to create lots of similar elements

2010-05-28 Thread Chris Lercher
On May 28, 4:28 pm, Thomas Broyer t.bro...@gmail.com wrote:
 Use a StringBuilder, it'll optimize dependending on the browser
 (pushing into an array and then joining the items, or concatenating
 strings, whichever has been benchmarked the fastest by the GWT team)

You're right - I just looked into StringBuilderImpl, and now I'm
convinced, it's really something I should leave to GWT!

I'm still looking for a solution that would remove the need for all
the manual concatenation. I'd like to use either some templating (as
with UiBinder), or some API (as with GWT widgets, or GQuery), but it
would have to give me approximately the same performance...

Then again, the amount of code that creates widgets in this low-level
way is limited to two methods in my code, so I could probably live
with it.

-- 
You received this message because you are subscribed to the Google Groups 
Google Web Toolkit group.
To post to this group, send email to google-web-tool...@googlegroups.com.
To unsubscribe from this group, send email 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: Share access beween two UiBinder files?

2010-05-28 Thread Mark
Ah, ok.
Thank you very much!

On 28 Mai, 17:27, Tristan Slominski tristan.slomin...@gmail.com
wrote:
 Hmm...

 Why don't you do it in main? It's the one thing that knows about both.

 Buttons.java:

 @UiHandler(nextButton)
 void onClickNext(ClickEvent click) {
   getMain().onClickNext();

 }

 Main.java:

 public void onClickNext(){
   getTextFields.setText(something);



 }
 On Fri, May 28, 2010 at 10:19, Mark Schewe schewe.m...@gmail.com wrote:
  First of all thank you for the answer.
  I am new to GWT so I am a bit confused and not know yet the correct
  terminology :)

  Main.ui.xml:

  g:FlowPanel
         g:VerticalPanel
                 r:TextFields  / // calls TextFields.ui.xml
                 r:Buttons  /  // calls Buttons.ui.xml
         /g:VerticalPanel
  /g:FlowPanel

  Buttons.ui.xml:

  g:HorizontalPanel
         g:Button ui:field=prevButtonprev/g:Button
         g:Button ui:field=nextButtonnext/g:Button
  /g:HorizontalPanel

  TextFields.ui.xml:

  g:VerticalPanel
         g:TextArea ui:field=taText blah/g:TextArea
  /g:VerticalPanel

  Buttons.java:

  @UiHandler(nextButton)
  void onClickNext(ClickEvent click) {
         // change text field in TextFields.ui.xml
  }

  In this last handler I need to access the textfield. I hope my problem
  is now easier to understand. I guess this has something to do with
  @UiFactory  but I just don't get it.

  2010/5/28 Tristan tristan.slomin...@gmail.com:
   like this?

   Buttons buttons = new Buttons();
   TextFields fields = new TextFields();
   buttons.setFieds(fields);
   fields.setButtons(buttons);

   ??

   Can you elaborate?

   On May 28, 7:05 am, Mark rausch.pi...@gmail.com wrote:
   Hello,

   I need your help! I've got two files:

   Buttons.ui.xml / Buttons.java
   TextFields.ui.xml / TextFields.java

   Now I need to change the content of the TextFields in the Buttons and
   vice versa. Is it possible to do this without merging the two ui and
   java files? I hope you understand what I mean.

   Thank you very much for your help!
   Mark

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

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

-- 
You received this message because you are subscribed to the Google Groups 
Google Web Toolkit group.
To post to this group, send email to google-web-tool...@googlegroups.com.
To unsubscribe from this group, send email 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 achieve traditional website behavior with layout panels?

2010-05-28 Thread Stefan Bachert
Hi Dennis,

a DockLayout will not grow will the content in center is growing.
The center of DockLayout get just the remaining space.

I see two ways at the moment
a) After adding widget to the center measure its size and increase
the DockLayout accordingly.
The pitfall is the box model. It may be tricky to get the size you
really need (on the other hand, just make it a little bit larger)

b) Do not use DockLayout. Anything based on position:absolute (as
an ..LayoutPanels) do not grow with its children.
In general a table based Widget will help, but I usually try to
avoid that. I always found a way with div

When I really know your layout, it it probably achievable with
style=float.

Stefan Bachert
http://gwtworld.de

On 28 Mai, 10:39, googelybear googelyb...@gmail.com wrote:
 @Stefan: I know the term sucks, but it was the best I could come up
 with ;-) As you concluded my main goal is to have browser scrollbar
 scrolling and not the inner scrolling (lots of individual scrollbars
 inside the containers itself, an example for this is google wave).

 So in your words (...) you have to allow the parents to grow with its
 child.   That's exactly the behavior of the old panels. I'm not
 really clear on how we could emulate this on the new panels (all my
 attempts so far failed).

 To make a simple example: I have a DockLayoutPanel and somewhere a
 button. There is a FlowPanel in the center. Clicking on that button
 adds a label to the center panel. Repeatedly clicking that button
 fills the center panel and at some point additional labels are not
 displayed anymore (simulates the dynamic content). This is as you
 wrote because of the overflow:hidden/auto which is set on the
 DockPanel - in the LayoutPanels in general - (and is IMPOSSIBLE to
 override by the programmer - at least I didn't succeed). If I add a
 scrollPanel to the center as parent of the FlowPanel I get said inner
 scrolling But what I would like to have is that the DockLayoutPanel
 itself grows (vertically) which forces the browser to display
 scrollbars.

 I uploaded the (very simple) demo project here (Just import in eclipse
 and run):http://drop.io/gwt_dock_panel

 It would be really great if you could share how to achieve the
 behavior described above.

 thanks,
 Dennis

 On May 27, 6:55 pm, Stefan Bachert stefanbach...@yahoo.de wrote:

  Hi Dennis,

  I still think what traditionalbehaviour should be. (? not following
  the standards?)

  However, you don't want scrollbars at your LayoutPanel.

  The reason why any widget gets a scrollbar is because it is larger
  than its parent and the style overflow is set to auto or scroll.
  When the wrong widget get a scrollbar you have to change the size of
  the panel (div) hierarchy.
  Or you have to allow the parents to grow with its child.

  When you do not succeed you need to show us your code or at least the
  hierarchy ofpanels.

  Stefan Bacherthttp://gwtworld.de

  On 26 Mai, 10:33, googelybear googelyb...@gmail.com wrote:

   Hi,

   I am developing a webapp that should behave like atraditionalweb
   page, meaning that when the content grows in height the browser should
   display a vertical scroll bar. Unfortunately I was foolish and jumped
   right in on the new, shinylayoutpanels. As I found out later these
   are not suitable for me, as they create a more application-like look
   and feel with scrollbars displayed in the individual gwtpanels
   instead of the browser (try resizing e.g. google wave - When the
   available area is too small scrollbars will appear inside all the
  panels, the browser will never display any scrollbars) and also they
   are working with lots of fixed sizes (in my case the content is
   dynamic).
   I tried toachievethetraditionalbehaviorwith my LayoutPanels but
   failed. I couldn't get the browser to display scrollbars, only inner-
   panel scrolling, and stuffing a layoutpanel inside a scrollpanel is
   not the desirable approach (stuffinglayoutpanelsinside non-layout
  panelsusually ended badly for me..).
   So my conclusion is to revert to the old schoolpanels. But I am
   afraid that support of these will be dropped soon. What do you think?
   Are there better alternatives? Anyone fought with a similar problem?

   thanks for any suggestions,
   Dennis

-- 
You received this message because you are subscribed to the Google Groups 
Google Web Toolkit group.
To post to this group, send email to google-web-tool...@googlegroups.com.
To unsubscribe from this group, send email 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 RPC calls from java

2010-05-28 Thread Sripathi Krishnan
Having said that, I wouldn't build a production app that relies on the
library.

If you really want to develop your services for multiple clients, I'd
recommend staying away from GWT RPC. JSON is well suited for the browser,
while XML is better suited for a Swing application. If you build your
services to support both with the same codebase, you can reuse your services
from a wide range of clients (Mobile apps / Swing / GWT etc)

--Sri


On 28 May 2010 21:07, Sripathi Krishnan sripathi.krish...@gmail.com wrote:

 See http://www.gdevelop.com/w/blog/2010/01/10/testing-gwt-rpc-services/.
 That's the best solution that's out there at the moment.

 --Sri



 On 28 May 2010 20:36, ussuri michael.glas...@gmail.com wrote:

 Hello! I know that the question has been asked several times, but the
 last discussion I was able to find dates back to 2009, so I'll ask the
 question again:

 Can I _easily_ call GWT-RPC server side from a pure java client
 application? If not, is the ability on the roadmap? What are the best
 alternatives?

 Basically, what I need to do:

 1. a GWT-based client
 2. a GAE-based server (java flavor)
 3. a Java desktop client (Swing)

 As everything is developed in Java, we are going to re-use a lot of
 code; ideally we would prefer to have only the GUI part to be
 different b/w our GWT and our Swing clients. However, we can't find a
 way to call into GAE from GWT and stand-alone java other than low-
 level HTML calls.

 Thanks,
 MG

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




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



Re: Fastest way to create lots of similar elements

2010-05-28 Thread Chris Lercher
Hi Eric,

yes, I'm considering using an ImageBundle (actually only the getURL()
method from ImageResource) - but that solves a different problem
(reducing the number of requests)! I'll still have to create my
hundreds of similar elements, and add/remove them dynamically,
position them etc.


On May 28, 5:13 pm, Eric erjab...@gmail.com wrote:
 Isn't this what ImageBundle does?  That combines various images
 into a simgle one at compile time, and uses CSS to show only
 the desired portion the combined image when used.

-- 
You received this message because you are subscribed to the Google Groups 
Google Web Toolkit group.
To post to this group, send email to google-web-tool...@googlegroups.com.
To unsubscribe from this group, send email 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 one panel for the whole browser window?

2010-05-28 Thread Stefan Bachert
Hi Magnus,

you may have a look on the mail sample deliver with GWT.
This sample fills the browser window.

Stefan Bachert
http://gwtworld.de

On 28 Mai, 03:49, Magnus alpineblas...@googlemail.com wrote:
 Hello,

 I would like to build my GUI within one panel that fills the whole
 browser window.

 What do I have to do in the host page and/or in the panel to stretch
 it to this dimensions?

 Thank you!
 Magnus

-- 
You received this message because you are subscribed to the Google Groups 
Google Web Toolkit group.
To post to this group, send email to google-web-tool...@googlegroups.com.
To unsubscribe from this group, send email 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: Fastest way to create lots of similar elements

2010-05-28 Thread Stefan Bachert
Hi Chris,

this looks as you are going to program mine sweeper.
May be you should consider to use HTML5 canvas

Stefan Bachert
http://gwtworld.de

On 27 Mai, 21:33, Chris Lercher cl_for_mail...@gmx.net wrote:
 Hi,

 I need to create lots (hundreds) of image tags, and attach them
 dynamically to several plain div class=xy/div elements:

 div class=xy
   img src=images/a.gif style=top: 1em;/
   img src=images/a.gif style=top: 2em;/
   img src=images/b.gif style=top: 3em;/
   ...
 /div
 ...

 The img tags can have only two different src urls. But each needs
 individual style attributes (for absolute positioning).

 Question:
 What would be the fastest (and preferably clean) way to do that?

    A) GwtQuery (aka GQuery)?
    B) UiBinder?
    C) Other?

 
 A) The GwtQuery approach:

 As a first pretty clueless attempt, I'm currently using GwtQuery code
 similar to this:

 @UiField
 HTML div1;

 void attachImages(...) {
   for (...) {
     $(div1.getElement()).append(
         img src='images/ + (flag ? a : b) + .gif' style='top:
 + i + em'/);
   }

 }

 @UiHandler(div1)
 void onDivClicked(final ClickEvent event) {
  ...

 }

 This works, but a) it's obviously ugly, and b) I don't know, if
 there's a faster/better way.

 
 B) The UiBinder approach:

 I chose the HTML class, to get a clean div, and still be able to use
 @UiHandler. But it doesn't seem to be possible to attach (UiBinder)
 Composites to it. What else should I choose? Unfortunately, HTMLPanel
 isn't a subclass of HasClickHandlers, so it doesn't work with
 @UiHandler.

 
 C) Other approaches:

 ?

 Thanks
 Chris

-- 
You received this message because you are subscribed to the Google Groups 
Google Web Toolkit group.
To post to this group, send email to google-web-tool...@googlegroups.com.
To unsubscribe from this group, send email 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: Fastest way to create lots of similar elements

2010-05-28 Thread Thomas Broyer


On 28 mai, 17:35, Chris Lercher cl_for_mail...@gmx.net wrote:
 On May 28, 4:28 pm, Thomas Broyer t.bro...@gmail.com wrote:

  Use a StringBuilder, it'll optimize dependending on the browser
  (pushing into an array and then joining the items, or concatenating
  strings, whichever has been benchmarked the fastest by the GWT team)

 You're right - I just looked into StringBuilderImpl, and now I'm
 convinced, it's really something I should leave to GWT!

 I'm still looking for a solution that would remove the need for all
 the manual concatenation. I'd like to use either some templating (as
 with UiBinder), or some API (as with GWT widgets, or GQuery), but it
 would have to give me approximately the same performance...

Messages could help you, even if you don't use its localizable
facet:

public interface Images extends Messages {
   @DefaultMessage(img src='images/{0}.gif' style='top: {1}em;')
   String image(String image, int emTop);
}

Then use it as:
  images.image(flag ? a : b, index);


-- 
You received this message because you are subscribed to the Google Groups 
Google Web Toolkit group.
To post to this group, send email to google-web-tool...@googlegroups.com.
To unsubscribe from this group, send email 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: No new web application project button

2010-05-28 Thread Stefan Bachert
Hi Andrew,

GWT has its own buttons. It it the blue g icon in the tool bar (New
Web Application Project), or in the menu

Stefan Bachert
http://gwtworld.de

On 27 Mai, 04:09, Andrew anyel...@gmail.com wrote:
 I just recently installed Eclipse 3.5 on Windows 7. I followed the
 instructions on installing GWT plugin and SDK and it seems to have
 worked fine, however I do not have the option to create a new web
 application project or anything associated with GWT. What could I have
 done wrong to cause this and what can I do to fix it?

 Thanks,

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



Re: I'm trying out an example I found in a GWT book. In side the .html file, whenever I tried to name a div the same name as the class, nothing will be displayed on the screen.

2010-05-28 Thread googling1000
Crsytal clear!
Thank you very much for your time :)

On May 24, 8:28 am, Sripathi Krishnan sripathi.krish...@gmail.com
wrote:
 GWT creates a hidden iframe with an id equal to whatever your module is
 renamed to. In your case, you had a div with id=Hangman, and GWT inserted
 an iframe with *the exact same id*. This caused the problem you were facing.
 Renaming the div got rid of the duplicate id, and that's why the application
 works.

 Its frustrating, I know.

 --Sri

 On 24 May 2010 20:42, rudolf michael roud...@gmail.com wrote:



  The Id of the DIV always matter whenever you are doing
  RootPanel.get(myDivId) and it is case sensitive also.
  this is applicable since GWT beta releases/

  best regards,
  Rudolf Michael

  On Sat, May 22, 2010 at 2:51 PM, googling1000 googling1...@gmail.comwrote:

  Hi,

  This is my first attempt at GWT. Hope it will be a joyful experience.

  I'm trying out a hangman example from this one book called Google Web
  Toolkit Applications.
  And, I spent the last two days trying to figure out why I couldn't see
  anything on the screen, rather than the word Hangman

  Finally, I noticed that the problem was caused by the name of a div
  inside hangman.html

  Right now, I'm displaying two buttons and a label.

  /**
  This is what I have under hangman.java:
  **/
  public class HangMan implements EntryPoint {
         public void onModuleLoad(){
                 final Button button = new Button(Click me);
                 final Label label = new Label();

                 //to display a button with a letter A
                 final char letter = 'A';
                 final Button alphabutton = new
  Button(Character.toString(letter));
                 RootPanel.get(mydiv).add(alphabutton);  //Please notice
  that I
  named the div mydiv and the program works. Had I named the div
  hangman, I would not have seen anything on the screen, except the
  word Hangman

                 button.addClickHandler(new ClickHandler() {
                        �...@override
                         public void onClick(ClickEvent event) {
                                 if (label.getText().equals())
                                         label.setText(Hello World!);
                                 else
                                         label.setText();
                         }
                 });
                 //to display a button with the word Click me
                 RootPanel.get(slot1).add(button);
                 //to display a label
                 RootPanel.get(slot2).add(label);
         }
  }

  /**
  This is what I have under hangman.html:
  **/
  !doctype html
  html
   head
     meta http-equiv=content-type content=text/html;
  charset=UTF-8
     link type=text/css rel=stylesheet href=HangMan.css

     titleHangman/title
     style
         body,td,a,div, .p{font-family:arial, sans-serif}
         div,td{color:#00}
         a:link,.w,.w a:linnk{color:#cc}
         a:visited{color: #551a8b}
         a:active{color: #ff}
     /style
     script type=text/javascript language=javascript src=hangman/
  hangman.nocache.js/script
   /head

   body
     iframe src=javascript:'' id=__gwt_historyFrame tabIndex='-1'
  style=position:absolute;width:0;height:0;border:0/iframe
     h1Hangman/h1
     div id=mydiv/div   !-- NOTE: when I named this div
  hangman, nothing appeared on the screen --

     table align=center
       tr
         td id=slot1/tdtd id=slot2/td
       /tr
     /table
   /body
  /html

  I would really like someone to help shed some light no this.
  What is the explanation behind this?
  And, the Google Web Toolkit Applications book named the div
  hangman and I believe that means it must have worked fine for the
  author. Does this mean that maybe the name of the div didn't matter
  in the earlier versions of GWT?

  Thank you in advance for any input!
  Fran

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

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

 --
 You received this message because you are 

Re: Fastest way to create lots of similar elements

2010-05-28 Thread Chris Lercher
Hi Stefan,

:-) fortunately, it's not as extreme as it sounds - the images don't
have to be exchanged very often, but when they do, it must be
instantaneous. No problem for Safari/Chrome or Firefox... but it was
just a bit too slow on IE8.

Viele Grüße
Chris

On May 28, 5:55 pm, Stefan Bachert stefanbach...@yahoo.de wrote:
 Hi Chris,

 this looks as you are going to program mine sweeper.
 May be you should consider to use HTML5 canvas

 Stefan Bacherthttp://gwtworld.de

 On 27 Mai, 21:33, Chris Lercher cl_for_mail...@gmx.net wrote:



  Hi,

  I need to create lots (hundreds) of image tags, and attach them
  dynamically to several plain div class=xy/div elements:

  div class=xy
    img src=images/a.gif style=top: 1em;/
    img src=images/a.gif style=top: 2em;/
    img src=images/b.gif style=top: 3em;/
    ...
  /div
  ...

  The img tags can have only two different src urls. But each needs
  individual style attributes (for absolute positioning).

  Question:
  What would be the fastest (and preferably clean) way to do that?

     A) GwtQuery (aka GQuery)?
     B) UiBinder?
     C) Other?

  
  A) The GwtQuery approach:

  As a first pretty clueless attempt, I'm currently using GwtQuery code
  similar to this:

  @UiField
  HTML div1;

  void attachImages(...) {
    for (...) {
      $(div1.getElement()).append(
          img src='images/ + (flag ? a : b) + .gif' style='top:
  + i + em'/);
    }

  }

  @UiHandler(div1)
  void onDivClicked(final ClickEvent event) {
   ...

  }

  This works, but a) it's obviously ugly, and b) I don't know, if
  there's a faster/better way.

  
  B) The UiBinder approach:

  I chose the HTML class, to get a clean div, and still be able to use
  @UiHandler. But it doesn't seem to be possible to attach (UiBinder)
  Composites to it. What else should I choose? Unfortunately, HTMLPanel
  isn't a subclass of HasClickHandlers, so it doesn't work with
  @UiHandler.

  
  C) Other approaches:

  ?

  Thanks
  Chris

-- 
You received this message because you are subscribed to the Google Groups 
Google Web Toolkit group.
To post to this group, send email to google-web-tool...@googlegroups.com.
To unsubscribe from this group, send email 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 RPC calls from java

2010-05-28 Thread mikedshaf...@gmail.com
Another, more recommended method is to isolate the business process
away from the GWT RPC.  So you have a stand alone middle-tier that
you communicate with via GWT-RPC and Swing Clients and whatever else
you want to do.  Don't try to reuse GWT-RPCgo around it.  It's a
better design...

On May 28, 9:40 am, Sripathi Krishnan sripathi.krish...@gmail.com
wrote:
 Having said that, I wouldn't build a production app that relies on the
 library.

 If you really want to develop your services for multiple clients, I'd
 recommend staying away from GWT RPC. JSON is well suited for the browser,
 while XML is better suited for a Swing application. If you build your
 services to support both with the same codebase, you can reuse your services
 from a wide range of clients (Mobile apps / Swing / GWT etc)

 --Sri

 On 28 May 2010 21:07, Sripathi Krishnan sripathi.krish...@gmail.com wrote:



  Seehttp://www.gdevelop.com/w/blog/2010/01/10/testing-gwt-rpc-services/.
  That's the best solution that's out there at the moment.

  --Sri

  On 28 May 2010 20:36, ussuri michael.glas...@gmail.com wrote:

  Hello! I know that the question has been asked several times, but the
  last discussion I was able to find dates back to 2009, so I'll ask the
  question again:

  Can I _easily_ call GWT-RPC server side from a pure java client
  application? If not, is the ability on the roadmap? What are the best
  alternatives?

  Basically, what I need to do:

  1. a GWT-based client
  2. a GAE-based server (java flavor)
  3. a Java desktop client (Swing)

  As everything is developed in Java, we are going to re-use a lot of
  code; ideally we would prefer to have only the GUI part to be
  different b/w our GWT and our Swing clients. However, we can't find a
  way to call into GAE from GWT and stand-alone java other than low-
  level HTML calls.

  Thanks,
  MG

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

 - Show quoted text -

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



Re: Fastest way to create lots of similar elements

2010-05-28 Thread Chris Lercher
On May 28, 6:00 pm, Thomas Broyer t.bro...@gmail.com wrote:
 Messages could help you, even if you don't use its localizable
 facet:

 public interface Images extends Messages {
   �...@defaultmessage(img src='images/{0}.gif' style='top: {1}em;')
    String image(String image, int emTop);

 }

 Then use it as:
   images.image(flag ? a : b, index);

That's a very good idea! It doesn't provide compile-time syntax
validation, but it's so much nicer than concatenation. Thanks - I like
this kind of creative solution!

-- 
You received this message because you are subscribed to the Google Groups 
Google Web Toolkit group.
To post to this group, send email to google-web-tool...@googlegroups.com.
To unsubscribe from this group, send email 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 RPC calls from java

2010-05-28 Thread ussuri
Thanks Sri, Mike! Yes, it seems that a more transparent  light-weight
protocol would be better in the long term.

MG

On May 28, 12:10 pm, mikedshaf...@gmail.com mikedshaf...@gmail.com
wrote:
 Another, more recommended method is to isolate the business process
 away from the GWT RPC.  So you have a stand alone middle-tier that
 you communicate with via GWT-RPC and Swing Clients and whatever else
 you want to do.  Don't try to reuse GWT-RPCgo around it.  It's a
 better design...

 On May 28, 9:40 am, Sripathi Krishnan sripathi.krish...@gmail.com
 wrote:

  Having said that, I wouldn't build a production app that relies on the
  library.

  If you really want to develop your services for multiple clients, I'd
  recommend staying away from GWT RPC. JSON is well suited for the browser,
  while XML is better suited for a Swing application. If you build your
  services to support both with the same codebase, you can reuse your services
  from a wide range of clients (Mobile apps / Swing / GWT etc)

  --Sri


-- 
You received this message because you are subscribed to the Google Groups 
Google Web Toolkit group.
To post to this group, send email to google-web-tool...@googlegroups.com.
To unsubscribe from this group, send email 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: Triggering download in GWT via RPC

2010-05-28 Thread andreas
Thanks again for the response, Sris response already answered my
question: it just can not be done with rpc; that's it.

On 28 Mai, 16:28, Jeff Chimene jchim...@gmail.com wrote:
 Hi Andreas:

 You can certainly send the two files to the server via GWTUpload. As Sri

Sorry Jeff, never wanted to send files to the server, I want to send
them to the client. What is send to the server is data in form of
documents in its abstract meaning (not concrete files).

 observed, the user must EXPLICITLY REQUEST THAT ACTION. Your browser app
 cannot do that on behalf of the user.

That's what answered my original question. Thanks a lot!


 You can receive stuff in the browser from the server. If it's a custom
 file structure, you'll have to open the app that handles that structure
 (like the browser opens Acrobat to handle PDF, or Office to handle Word Doc
 format) In order for this to work, you'll have to do a two-step process
 after sending the document to the server via GWTUpload
 Step 1: Receive the processing results from the server; which is the
 standard AJAX/GWTUpload response handling mechanism
 Step 2: Do the IFrame trick to actually request the document from the
 server. As you know, the server will send the appropriate headers to trigger
 the custom app to open the document.

I already heard about this proceeding but I clearly reject it. Doing
it this way requires temporary storage of the generated files or
session data or whatever AND two requests. It can be done in one
single request using GWT FormPanel. Data is send to the servlet in the
submission of the FormPanel in which the data is embedded as the value
of a TextArea for example. And after receiving the request in a
HttpServlet the content-disposition-magic thing can be done and
voila: the browser starts a download. Again, I just wanted to be sure
that it really can not be done with a rpc request.

Thank you all for the information.


 On Fri, May 28, 2010 at 12:31 AM, andreas 
 horst.andrea...@googlemail.comwrote:



  The goal is to download files to be stored by the user on disk. The
  context application is a graphical editor which allows export of a
  document in two formats. At the moment these are txt and ppt files.
  They are generated separately so there is no problem with conflicting
  MIME types or similar. By now I thought content type application/
  octet-stream together with content-disposition attachment and a
  file name would be enough.

  Triggering download via IFrame URL or Window.open(URL, ...) works
  fine, BUT how to pass information needed for server side file
  generation. In particular I want to actually pass the whole document
  currently edited in the browser application to the servlet that
  generates to download file out of that document. One could surely use
  parameters in the URL but I wonder if this way the passed information
  is more vulnerable to interception than it would be when it was
  located in the body of a request; like it is in the GWT rpc. That's
  why I would have loved to use GWT rpc client side, pure HttpServlet on
  the server side and finally forget about any sort of GWT CallBack back
  in the browser but let the browser do a download based on response
  headers. It is also very easy to get the parameters out of the request
  again using GWT utility classes.

  From what I also read in Sris response I quess I have to use FormPanel
  submission or pass information using parameters in the URL which is
  then opened via IFrame or Window.open(...).

  Thank you very much for your response.

  On 27 Mai, 16:28, Jeff Chimene jchim...@gmail.com wrote:
   Hi Andreas:

   It's quite possible to ... trigger a download via GWT... You don't say
   what MIME type you're wanting. For example, I trigger a download of PDF
   document. GWT code cannot handle that, so the trigger is a GWT write to
  an
   IFrame URL. The browser then renders the PDF in that frame.

   Perhaps you want to download HTML? If so, you have to stuff those results
   into some GWT widget. I usually do something like a MIME type of
  text/json,
   which can be handled using a Javascript overlay type.
   { status:%S-Success, cargo:divstuff/div}

   which can handle situations like
   {status:%F-Fail,cargo:divrequested data not found/div}

   On Thu, May 27, 2010 at 7:17 AM, andreas horst.andrea...@googlemail.com
  wrote:

Hi,

I'm trying to trigger a download via GWT rpc and/or GWT
RequestBuilder. The motivation of using rpc and/or RequestBuilder is
the ability to send data required for the on-the-fly generated
download files that way.

I already managed to modify the underlying request by using
RequestBuilder as return value of the rpc service method. The request
is routed to a HttpServlet implementing the doPost method. GWT utility
classes are used to obtain the RPCRequest instance and the given
parameters of the rpc service call successfully out of the
HttpRequest. After using the parameters and 

deploy gwt project

2010-05-28 Thread leslie
I'm developing a GWT application inside of Eclipse.  I would like to
deploy my application to a remote server online.  Could anyone explain
to me or point me in the direction of online instructions as to how to
do this?

What I've done so far is to copy the directory called war that is
generated in my project folder to another directory, create a war file
from this directory via the standard jar command - jar -cf
myWarFile.war - and then copy this war file into the webapps directory
of my local Tomcat installation.  When I do this I can see the proper
page, but the stylesheet instructions are ignored.  It's as if the
stylesheet isn't being applied.  But I can access the stylesheet via
URL.

When I attempt to copy the war file to my online hosting account via
FTP and access the page that way I get a 404 error.

Thanks for any help.  I appreciate it.

-- 
You received this message because you are subscribed to the Google Groups 
Google Web Toolkit group.
To post to this group, send email to google-web-tool...@googlegroups.com.
To unsubscribe from this group, send email 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: deploy gwt project

2010-05-28 Thread aditya sanas
As far as i understand when we had deploy our application into apache we had
copied *content   from war not war folder. *
and no need to create war file using that command

i.e. if ur apps name is 'demoapp' then create 'demoapp' folder inside
webapps and put that content frm war inside this folder and try and access
this using

http://localhost:8080/demoapp/

i think this will do.

try it out.


Cheers
--
Aditya


On Fri, May 28, 2010 at 10:03 PM, leslie web...@me.com wrote:

 I'm developing a GWT application inside of Eclipse.  I would like to
 deploy my application to a remote server online.  Could anyone explain
 to me or point me in the direction of online instructions as to how to
 do this?

 What I've done so far is to copy the directory called war that is
 generated in my project folder to another directory, create a war file
 from this directory via the standard jar command - jar -cf
 myWarFile.war - and then copy this war file into the webapps directory
 of my local Tomcat installation.  When I do this I can see the proper
 page, but the stylesheet instructions are ignored.  It's as if the
 stylesheet isn't being applied.  But I can access the stylesheet via
 URL.

 When I attempt to copy the war file to my online hosting account via
 FTP and access the page that way I get a 404 error.

 Thanks for any help.  I appreciate it.

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



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



Profiling memory usage

2010-05-28 Thread Twentyseven
Hello,

We're developing a very big application using GWT and we're facing big
memory usage by the browser (sometime 2 Gb on Chrome).
How could I profile/monitor the use of monitor and determine what are
the composite who take the memory ?

thank's

-- 
You received this message because you are subscribed to the Google Groups 
Google Web Toolkit group.
To post to this group, send email to google-web-tool...@googlegroups.com.
To unsubscribe from this group, send email 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 add an Element object into a Widget.

2010-05-28 Thread kozura
Any particular reason not to just use the Grid widget?  The overhead
is negligible and the code a lot simpler..

On May 28, 5:08 am, Rizen vianney.dep...@gmail.com wrote:
 Hello,

 For my project, I would like to create a table in HTML by means of the
 DOM tree.
 For this, I'm just using the functions DOM.createTable(),
 DOM.createTBody(), DOM.createTR()...
 However the generated table is an Element type.

 Except that I'm using the MVP as a pattern for my application. So I
 have to init the main Widget with the function initWidget(), which
 takes a Widget object as parameter. I was looking for a panel like the
 HTMLPanel but no method can change or add an Element into a Widget.

 Is there a method that I can use to cast the Element object in Widget
 object ?

 Here is an example of code :

 public class View extends Composite {

         public View() {
                 Element table = DOM.createTable();
                 Element tbody = DOM.createTBody();
                 Element tr = DOM.createTR();
                 Element td = DOM.createTD();

                 tr.appendChild(td);
                 tbody.appendChild(tr);
                 table.appendChild(tbody);

                 // Need a Widget as a type
                 initWidget(table);
         }

 }

-- 
You received this message because you are subscribed to the Google Groups 
Google Web Toolkit group.
To post to this group, send email to google-web-tool...@googlegroups.com.
To unsubscribe from this group, send email 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: deploy gwt project

2010-05-28 Thread leslie
aditya sanas, Hi, Thank you for your reply.

I've essentially done what you have suggested but in a different way.
That is, I took the contents of the war directory and included them in
the war file that I created.  When I deploy the war file, Tomcat auto
expands the file into a directory which contains the contents.

I've managed to successfully deploy a gwt war file online once
already, but it was several months ago and I can't remember how I did
it.

I've found the following online resource
http://code.google.com/webtoolkit/doc/latest/DevGuideDeploying.html
Which mostly describes the files that are included, web.xml and the
lib directory and so forth, but doesn't help me resolve my problem.
That is I think I understand the components, but I can't seem to
deploy them as a single file in such a way that the application runs
as it does in the development environment of eclipse.

-- 
You received this message because you are subscribed to the Google Groups 
Google Web Toolkit group.
To post to this group, send email to google-web-tool...@googlegroups.com.
To unsubscribe from this group, send email 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: FastTree in GWT 2.0.3

2010-05-28 Thread Paul Robinson
Have you called:
FastTree.addDefaultCSS();

to inject the default CSS?

HTH
Paul

jla wrote:
 Hi,

 Are there any known problems about the GWT-Incubator fastTree and GWT
 2.0.3. I can't seem to be able to get it to work properly. Even when
 copying the demo source code into my project. On the other hand the
 native Tree control is working fine.

 Thanks,
 Jerome

   

-- 
You received this message because you are subscribed to the Google Groups 
Google Web Toolkit group.
To post to this group, send email to google-web-tool...@googlegroups.com.
To unsubscribe from this group, send email 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: Profiling memory usage

2010-05-28 Thread kozura
You might want to generate a compile report and check memory size for
the compiled code: 
http://code.google.com/webtoolkit/doc/latest/DevGuideCompileReport.html.

As for the actual data, any javascript profiler will work, you will
want to compile with the -pretty option to get legible function names.

On May 28, 11:12 am, Twentyseven ebarthel...@gmail.com wrote:
 Hello,

 We're developing a very big application using GWT and we're facing big
 memory usage by the browser (sometime 2 Gb on Chrome).
 How could I profile/monitor the use of monitor and determine what are
 the composite who take the memory ?

 thank's

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



how to center a panel within another panel?

2010-05-28 Thread Magnus
Hi,

I use DockLayoutPanel as the RootPanel for my browser window. And I
want to place another child panel within the dockpanels center.

Well, the child panel is always aligned to the upper left.

How can I achieve that:

a) the DockLayoutPanel really covers the whole browser window
b) the child panel is centered within the DockLayoutPanel's center
(but not resized)

Thank you
Magnus

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



How do i implement in a ListBox a select options trick I do in HTML

2010-05-28 Thread Rob Tanner
I'm rewriting some existing apps using GWT and I've come across a GUI
issue.  In many cases where I have used a select element as a pull
down menu (only 1 item visible at a time), I leave the first item
empty and disabled.  The user has to choose a different option and he/
she cannot go back to the empty element.  Using a ListBox, it's easy
enough to leave the first element (index 0) empty.  But how do I
disable that first element so that it can't be selected?

Thanks,
Rob

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



How can I prevent from reloading the page when the reload button on browser is clicked?

2010-05-28 Thread Mike J
Hi,
   I ran into a problem about clicking the reload button on a web
browser.

   My app is a stateful GWT app. Users need to be authenticated for
login. After login they can surf on various pages. But users sometimes
were used to press the reload button on the browser to refresh the
page.

   The reloading process just bring the screen back to a reboot state,
with all state info lost. That's not what we expect.

   The quick solution is, catch the reload event before the browser
sends the reload request to the web server and prevent the browser
from sending it.

   I have read the relevant posts in this group and found the useful
info that reload event is equivalent to the Window Closing event. So
in the following code snippet I can catch the event,

   Window.addCloseHandler(new CloseHandlerWindow() {
public void onClose(CloseEventWindow event) {
//prevent browser sending the reload request to the
web browser
}
});

   But I don't know how I can stop the browser from sending the
reload request to the web server.

   Thanks for any help,

   Mike J.

-- 
You received this message because you are subscribed to the Google Groups 
Google Web Toolkit group.
To post to this group, send email to google-web-tool...@googlegroups.com.
To unsubscribe from this group, send email 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 add an Element object into a Widget.

2010-05-28 Thread Rizen
Thank you very much, I tried to replace Composite by Widget and for
the moment it seems to work.

I can't use the Grid widget cause I need a Dynamic Table.
Moreover I have to reuse an existing CSS file. This one uses few table
elements like thead, tbody, tfoot et others styles name.
So I must create a personalized table in the DOM tree.

I used the function DOM.createTable(). But my table is hugh and it's
very long to coding step by step.
Is the TableElement class better ? Cause I don't know how to create a
tbody element in my HTML page with this.

Thanks a lot.
P.S. : sorry if my english is a little bad, I'm french ^^.

-- 
You received this message because you are subscribed to the Google Groups 
Google Web Toolkit group.
To post to this group, send email to google-web-tool...@googlegroups.com.
To unsubscribe from this group, send email 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: Unable to download gwt-2.0.3.zip

2010-05-28 Thread Luis Daniel Mesa Velásquez
I tried downloading it 5 times, i used JDownloader in most and i use Opera  
for browsing so i tried downloading through that too... seems the cloud  
is just fast but not reliable. =) I downloaded 2.0.0, 2.0.1, 2.0.2 and  
2.0.3

and got it to work after a while, thanks anyway.

On Fri, 28 May 2010 10:15:14 -0500, Stefan Bachert  
stefanbach...@yahoo.de wrote:



Hi Luis,

try it to download again or use different tools. Sometimes a download
fails.

I did not had any problem (but I am using ubuntu)

Stefan Bachert
http://gwtworld.de


On 28 Mai, 10:52, Luis Daniel Mesa Velasquez
luisdanielm...@gmail.com wrote:

I downloaded gwt-2.0.3.zip (aprox. 36MB) but when i try to unzip it i
get a message stating the file is corrupt or is empty. When i try to
extract it using 7zip i only get 15 MB extracted and a list of error
messages saying certain files use non-valid compression methods. Can
anyone help me unzip it or download it properly? Thanks in advance.





--
Using Opera's revolutionary e-mail client: http://www.opera.com/mail/

--
You received this message because you are subscribed to the Google Groups Google 
Web Toolkit group.
To post to this group, send email to google-web-tool...@googlegroups.com.
To unsubscribe from this group, send email 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: Where to place new Widget class?

2010-05-28 Thread Pavel Byles
GWT is pure client side.

The server package only comes into use for example if u were using GWT +
GAE, then you would put your server-side classes in the server package.  The
server package has no relationship with GWT.

On Thu, May 27, 2010 at 12:25 PM, Magnus alpineblas...@googlemail.comwrote:

 As I said, I am absolutely new to GWT. I don't know, which code to put
 on the server and which on the client. Is there a basic rule, then
 please let me know.

 In general, I would try to put as much as possible to the server, but
 I cannot really judge, what fits where best...

 Thank you
 Magnus

 On May 27, 7:10 pm, Pavel Byles pavelby...@gmail.com wrote:
  Could you say what the purpose of a ServerPanel is?
  Everything for GWT afaik should be placed in the client or shared
 directory.
  I don't think there is much sense in using client-side ui objects on the
  server.
 
  On Thu, May 27, 2010 at 11:55 AM, Magnus alpineblas...@googlemail.com
 wrote:
 
 
 
   Hello,
 
   I am absolutely new to GWT and I would like to start with a generic
   panel as a container for my GUI.
 
   So I created a new Panel derived from SimplePanel and added it to my
   host page:
 
   final MyPanel p = new MyPanel ();
   RootPanel.get(TestContainer).add(p);
 
   Within the panel constructor I create a text box, so that I can verify
   that everything works.
 
   However, I wonder where to place my panel class: I placed a class
   ClientPanel in the client directory and a class ServerPanel in the
   server directory within the eclipse project directory tree.
 
   When I use the ClientPanel, it works. When I use the ServerPanel, I
   get errors within eclipse, e. g.
   [ERROR] [firstwebapp] Unable to find type
   'fwa.Application.client.FirstWebApp'
 
   Any hints?
 
   Thank you
   Magnus
 
   --
   You received this message because you are subscribed to the Google
 Groups
   Google Web Toolkit group.
   To post to this group, send email to
 google-web-tool...@googlegroups.com.
   To unsubscribe from this group, send email to
   google-web-toolkit+unsubscr...@googlegroups.comgoogle-web-toolkit%2bunsubscr...@googlegroups.com
 google-web-toolkit%2bunsubscr...@googlegroups.comgoogle-web-toolkit%252bunsubscr...@googlegroups.com
 
   .
   For more options, visit this group at
  http://groups.google.com/group/google-web-toolkit?hl=en.
 
  --
  -Pav

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




-- 
-Pav

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



Modules as directories

2010-05-28 Thread leslie
My application contains code which is organized into packages like
view, or controller, or persist.  I've identified these packages
as modules in my GWT projecct.  I notice that the compiler has created
directories for these in my war folder.  I also notice that some of
the names are the fully qualified name and others are just the name.
Like one directory is named com.mycompany.foo and the other is just
named bar.  Is there any reason for this difference in naming
convention of modules as directories?

I also notice that some of the modules which are purely server side
nevertheless have folders created for them with a hosted.html file and
a js file.  But what is the need for this?  What have I done wrong in
the effort to define the module?

I realize this is confusing.. Thanks for any help.

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



Re: GWT Compile Issue

2010-05-28 Thread jayanth
I figured out the issue to my own problem and I am posting the
solution for posterity's benefit. This might save somebody a few hours
of frustration.

I had earlier failed to specify the fully qualified module name:

For instance, under program arguments in Eclipse:

I initially specified this:
-war C:\Documents and Settings\Seshadrj\workspace\GIDM\war GIDM

When I changed it to the package qualified module name(shown below),
it started working fine.
-war C:\Documents and Settings\Seshadrj\workspace\GIDM\war
whi.idm.GIDM


On May 25, 11:39 am, jayanth jay.sesha...@gmail.com wrote:
 I am on GWT 2.0.3. I am mentioning this because someone had asked if I
 was on GWT 2.1 M1.

 By the way, I've tried all the options mentioned:

 1. Added the following lines:
 inherits name=com.google.gwt.core.Core/
 inherits name=com.google.gwt.user.History/

 2. Moved my gwt.xml directly under the src directory.

 None of this has helped so far.

 As a matter of fact, I just created the default GreetingService app
 and tried to create a launch configuration to compile. When I use the
 GWTCompile (icon) option available through the plugin, it compiles
 fine. When I create a launch configuration, fails with the same
 message:

 Finding entry point classes
       [ERROR] Unable to find type 'com.example.myproject.client.Jkl'
          [ERROR] Hint: Check that the type name
 'com.example.myproject.client.Jkl' is really what you meant
          [ERROR] Hint: Check that your classpath includes all required
 source roots

 Thanks.

 On May 24, 5:00 am, Thomas Broyer t.bro...@gmail.com wrote:

  On 21 mai, 21:49,jayanthjay.sesha...@gmail.com wrote:

     !-- Specify the app entry point class.                         --
     entry-point class='whi.idm.client.GIDM'/
     source path=whi.idm.client /

  Is your gwt.xml really in the default package ?! (i.e. at the root
  of your source tree)

  --
  You received this message because you are subscribed to the Google Groups 
  Google Web Toolkit group.
  To post to this group, send email to google-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.



Re: deploy gwt project

2010-05-28 Thread leslie
I managed to allow the css file to render on the local deployment
simply by removing the comment tags from around the link tag in the
html file.  That was easy enough.  So now I am able to view and run my
war file on my local machine, my own tomcat instance, but when I view
the page online after deploying the same war file, Tomcat responds
with code 404.  Thanks for any help.

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



Re: How do i implement in a ListBox a select options trick I do in HTML

2010-05-28 Thread leslie
I don't know if it is possible to disable the selection of an index
value other than programmatically.  You could write a small
ChangeHandler for the ListBox and in the onChange method, check the
selected index of the ListBox.  If it's 0, then set it to some other
value like 1.  Just a thought.

-- 
You received this message because you are subscribed to the Google Groups 
Google Web Toolkit group.
To post to this group, send email to google-web-tool...@googlegroups.com.
To unsubscribe from this group, send email 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 can I prevent from reloading the page when the reload button on browser is clicked?

2010-05-28 Thread federico
bad design.
refresh is a feature and you should provide bokmarkable refresh-save
pages.

On 28 Mag, 20:42, Mike J mikej1...@gmail.com wrote:
 Hi,
    I ran into a problem about clicking the reload button on a web
 browser.

    My app is a stateful GWT app. Users need to be authenticated for
 login. After login they can surf on various pages. But users sometimes
 were used to press the reload button on the browser to refresh the
 page.

    The reloading process just bring the screen back to a reboot state,
 with all state info lost. That's not what we expect.

    The quick solution is, catch the reload event before the browser
 sends the reload request to the web server and prevent the browser
 from sending it.

    I have read the relevant posts in this group and found the useful
 info that reload event is equivalent to the Window Closing event. So
 in the following code snippet I can catch the event,

    Window.addCloseHandler(new CloseHandlerWindow() {
             public void onClose(CloseEventWindow event) {
                 //prevent browser sending the reload request to the
 web browser
             }
         });

    But I don't know how I can stop the browser from sending the
 reload request to the web server.

    Thanks for any help,

    Mike J.

-- 
You received this message because you are subscribed to the Google Groups 
Google Web Toolkit group.
To post to this group, send email to google-web-tool...@googlegroups.com.
To unsubscribe from this group, send email 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: Convert a DOM Element to Widget

2010-05-28 Thread Rizen
Oh thank you very much, it seems to work for this moment. I didn't
think to use the Widget class.
Thanks a lot for your help.

But now, I don't know which method is better to construct a table with
the DOM tree. I post the problem here :
http://groups.google.fr/group/google-web-toolkit/browse_thread/thread/7ce36cd0423f5428/d00785f7df3dbad4#d00785f7df3dbad4

-- 
You received this message because you are subscribed to the Google Groups 
Google Web Toolkit group.
To post to this group, send email to google-web-tool...@googlegroups.com.
To unsubscribe from this group, send email 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: Profiling memory usage

2010-05-28 Thread Twentyseven
In fact my problem is not due to the size of the js generated (even if
it's quite big).
I tried the developer tool from chrome but it's that when I do a head
snapshot the result is unreadable.
Do you mean that if I compile with the -pretty option, the snapshot
will be readable ?

Could it have a link betwwen the size of the js file and the memory
took by the browser ?

On May 28, 8:22 pm, kozura koz...@gmail.com wrote:
 You might want to generate a compile report and check memory size for
 the compiled 
 code:http://code.google.com/webtoolkit/doc/latest/DevGuideCompileReport.html.

 As for the actual data, any javascript profiler will work, you will
 want to compile with the -pretty option to get legible function names.

 On May 28, 11:12 am, Twentyseven ebarthel...@gmail.com wrote:



  Hello,

  We're developing a very big application using GWT and we're facing big
  memory usage by the browser (sometime 2 Gb on Chrome).
  How could I profile/monitor the use of monitor and determine what are
  the composite who take the memory ?

  thank's

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



Will gwt 2.1 support Servlet 3.0 ?

2010-05-28 Thread Smiley
I'm wondering if the gwt 2.1 release will include the Servlet 3.0
specification? I'm currently using jetty continuations for suspending
my requests but i would like to switch to Servlet 3.0 API in the
future.

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



Neither

2010-05-28 Thread Andrew
Neither of those buttons show up, that's where the problem is.

-- 
You received this message because you are subscribed to the Google Groups 
Google Web Toolkit group.
To post to this group, send email to google-web-tool...@googlegroups.com.
To unsubscribe from this group, send email 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: No new web application project button

2010-05-28 Thread Andrew
Neither of these buttons show up.

On May 28, 10:04 am, Stefan Bachert stefanbach...@yahoo.de wrote:
 Hi Andrew,

 GWT has its own buttons. It it the blue g icon in the tool bar (New
 Web Application Project), or in the menu

 Stefan Bacherthttp://gwtworld.de

 On 27 Mai, 04:09, Andrew anyel...@gmail.com wrote:

  I just recently installed Eclipse 3.5 on Windows 7. I followed the
  instructions on installing GWT plugin and SDK and it seems to have
  worked fine, however I do not have the option to create a new web
  application project or anything associated with GWT. What could I have
  done wrong to cause this and what can I do to fix it?

  Thanks,

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



Re: Profiling memory usage

2010-05-28 Thread kozura
Yes, -pretty will give you js names that match your java code, vs
obfuscated names.  The code size will have some impact on your browser
mem usage, but mostly it is a concern for download time - code
splitting can help with this.

On May 28, 3:10 pm, Twentyseven ebarthel...@gmail.com wrote:
 In fact my problem is not due to the size of the js generated (even if
 it's quite big).
 I tried the developer tool from chrome but it's that when I do a head
 snapshot the result is unreadable.
 Do you mean that if I compile with the -pretty option, the snapshot
 will be readable ?

 Could it have a link betwwen the size of the js file and the memory
 took by the browser ?

 On May 28, 8:22 pm, kozura koz...@gmail.com wrote:

  You might want to generate a compile report and check memory size for
  the compiled 
  code:http://code.google.com/webtoolkit/doc/latest/DevGuideCompileReport.html.

  As for the actual data, any javascript profiler will work, you will
  want to compile with the -pretty option to get legible function names.

  On May 28, 11:12 am, Twentyseven ebarthel...@gmail.com wrote:

   Hello,

   We're developing a very big application using GWT and we're facing big
   memory usage by the browser (sometime 2 Gb on Chrome).
   How could I profile/monitor the use of monitor and determine what are
   the composite who take the memory ?

   thank's

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



real gwt serialization

2010-05-28 Thread rjcarr
So I understand gwt's rpc serialization and I've been using it for
quite some time.

However, I'm wondering if there is a manual javascript serialization?
Let me explain ...

Passing things over rpc works great for dynamic data, but what if you
have initialization data that doesn't change?  Since it is
initialization data you want it available when the page loads and not
have to worry about timing issues.

So, here's what I'm looking for.  Say you already have a valid rpc
serializable type and you've created an object out of it.  I'd like to
serialize this to javascript so I can write it directly into my
webpage (via php, jsp, etc).  Then, something in gwt would be able to
reconstitute this into a java object for use with gwt.

I know I can write such a thing, and I've done it before, it just
seems so close to rpc serialization that it might already be done?

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



Unable to start App Engine

2010-05-28 Thread Anoop John
I am getting the following error when i starts the AppEngine in Dev
mode in eclipse. I am using AppEngine 1.3.4. Please let me know what
should i do for this.

Starting Jetty on port 
   [WARN] failed org.mortbay.jetty.nio.selectchannelconnecto...@adb1d4
java.lang.NoSuchMethodError: org.mortbay.thread.Timeout.init(Ljava/
lang/Object;)V
at org.mortbay.io.nio.SelectorManager
$SelectSet.init(SelectorManager.java:306)
at org.mortbay.io.nio.SelectorManager.doStart(SelectorManager.java:
223)
at
org.mortbay.component.AbstractLifeCycle.start(AbstractLifeCycle.java:
39)
at
org.mortbay.jetty.nio.SelectChannelConnector.doStart(SelectChannelConnector.java:
303)
at
org.mortbay.component.AbstractLifeCycle.start(AbstractLifeCycle.java:
39)
at org.mortbay.jetty.Server.doStart(Server.java:233)
at
org.mortbay.component.AbstractLifeCycle.start(AbstractLifeCycle.java:
39)
at
com.google.gwt.dev.shell.jetty.JettyLauncher.start(JettyLauncher.java:
543)
at com.google.gwt.dev.DevMode.doStartUpServer(DevMode.java:421)
at com.google.gwt.dev.DevModeBase.startUp(DevModeBase.java:1035)
at com.google.gwt.dev.DevModeBase.run(DevModeBase.java:783)
at com.google.gwt.dev.DevMode.main(DevMode.java:275)
   [WARN] failed selectchannelconnec...@127.0.0.1:
java.lang.NoSuchMethodError: org.mortbay.thread.Timeout.init(Ljava/
lang/Object;)V
at org.mortbay.io.nio.SelectorManager
$SelectSet.init(SelectorManager.java:306)
at org.mortbay.io.nio.SelectorManager.doStart(SelectorManager.java:
223)
at
org.mortbay.component.AbstractLifeCycle.start(AbstractLifeCycle.java:
39)
at
org.mortbay.jetty.nio.SelectChannelConnector.doStart(SelectChannelConnector.java:
303)
at
org.mortbay.component.AbstractLifeCycle.start(AbstractLifeCycle.java:
39)
at org.mortbay.jetty.Server.doStart(Server.java:233)
at
org.mortbay.component.AbstractLifeCycle.start(AbstractLifeCycle.java:
39)
at
com.google.gwt.dev.shell.jetty.JettyLauncher.start(JettyLauncher.java:
543)
log4j:WARN No appenders could be found for logger
(org.apache.jasper.compiler.JspRuntimeContext).
log4j:WARN Please initialize the log4j system properly.
at com.google.gwt.dev.DevMode.doStartUpServer(DevMode.java:421)
at com.google.gwt.dev.DevModeBase.startUp(DevModeBase.java:1035)
at com.google.gwt.dev.DevModeBase.run(DevModeBase.java:783)
at com.google.gwt.dev.DevMode.main(DevMode.java:275)
   [WARN] failed ser...@b5dac4
java.lang.NoSuchMethodError: org.mortbay.thread.Timeout.init(Ljava/
lang/Object;)V
at org.mortbay.io.nio.SelectorManager
$SelectSet.init(SelectorManager.java:306)
at org.mortbay.io.nio.SelectorManager.doStart(SelectorManager.java:
223)
at
org.mortbay.component.AbstractLifeCycle.start(AbstractLifeCycle.java:
39)
at
org.mortbay.jetty.nio.SelectChannelConnector.doStart(SelectChannelConnector.java:
303)
at
org.mortbay.component.AbstractLifeCycle.start(AbstractLifeCycle.java:
39)
at org.mortbay.jetty.Server.doStart(Server.java:233)
at
org.mortbay.component.AbstractLifeCycle.start(AbstractLifeCycle.java:
39)
at
com.google.gwt.dev.shell.jetty.JettyLauncher.start(JettyLauncher.java:
543)
at com.google.gwt.dev.DevMode.doStartUpServer(DevMode.java:421)
at com.google.gwt.dev.DevModeBase.startUp(DevModeBase.java:1035)
at com.google.gwt.dev.DevModeBase.run(DevModeBase.java:783)
at com.google.gwt.dev.DevMode.main(DevMode.java:275)
Exception in thread main java.lang.NoSuchMethodError:
org.mortbay.thread.Timeout.init(Ljava/lang/Object;)V
at org.mortbay.io.nio.SelectorManager
$SelectSet.init(SelectorManager.java:306)
at org.mortbay.io.nio.SelectorManager.doStart(SelectorManager.java:
223)
at
org.mortbay.component.AbstractLifeCycle.start(AbstractLifeCycle.java:
39)
at
org.mortbay.jetty.nio.SelectChannelConnector.doStart(SelectChannelConnector.java:
303)
at
org.mortbay.component.AbstractLifeCycle.start(AbstractLifeCycle.java:
39)
at org.mortbay.jetty.Server.doStart(Server.java:233)
at
org.mortbay.component.AbstractLifeCycle.start(AbstractLifeCycle.java:
39)
at
com.google.gwt.dev.shell.jetty.JettyLauncher.start(JettyLauncher.java:
543)
at com.google.gwt.dev.DevMode.doStartUpServer(DevMode.java:421)
at com.google.gwt.dev.DevModeBase.startUp(DevModeBase.java:1035)
at com.google.gwt.dev.DevModeBase.run(DevModeBase.java:783)
at com.google.gwt.dev.DevMode.main(DevMode.java:275)

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

Re: deploy gwt project

2010-05-28 Thread leslie
My local version information is the following :

GWT 2.0.3
Tomcat 6
Eclipse 3.5 Galileo
working on Mac OS X.
Java 5

-- 
You received this message because you are subscribed to the Google Groups 
Google Web Toolkit group.
To post to this group, send email to google-web-tool...@googlegroups.com.
To unsubscribe from this group, send email 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: real gwt serialization

2010-05-28 Thread kozura
Sounds like you just want a constant, can you just create the objects
as static finals in your client code?  No serialization or any such
needed, just comes as part of the code.

On May 28, 4:38 pm, rjcarr rjc...@gmail.com wrote:
 So I understand gwt's rpc serialization and I've been using it for
 quite some time.

 However, I'm wondering if there is a manual javascript serialization?
 Let me explain ...

 Passing things over rpc works great for dynamic data, but what if you
 have initialization data that doesn't change?  Since it is
 initialization data you want it available when the page loads and not
 have to worry about timing issues.

 So, here's what I'm looking for.  Say you already have a valid rpc
 serializable type and you've created an object out of it.  I'd like to
 serialize this to javascript so I can write it directly into my
 webpage (via php, jsp, etc).  Then, something in gwt would be able to
 reconstitute this into a java object for use with gwt.

 I know I can write such a thing, and I've done it before, it just
 seems so close to rpc serialization that it might already be done?

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



[gwt-contrib] [google-web-toolkit] r8216 committed - Moved the Activity subclasses to the App module to break the circular ...

2010-05-28 Thread codesite-noreply

Revision: 8216
Author: gwt.mirror...@gmail.com
Date: Fri May 28 09:33:23 2010
Log: Moved the Activity subclasses to the App module to break the circular  
dependency between App and ValueStore.


Review at http://gwt-code-reviews.appspot.com/571801

Review by: rj...@google.com
http://code.google.com/p/google-web-toolkit/source/detail?r=8216

Added:
  
/branches/2.1/bikeshed/src/com/google/gwt/app/place/AbstractRecordEditActivity.java
  
/branches/2.1/bikeshed/src/com/google/gwt/app/place/AbstractRecordListActivity.java

Deleted:
  
/branches/2.1/bikeshed/src/com/google/gwt/valuestore/ui/AbstractRecordEditActivity.java
  
/branches/2.1/bikeshed/src/com/google/gwt/valuestore/ui/AbstractRecordListActivity.java

Modified:
  
/branches/2.1/bikeshed/src/com/google/gwt/sample/expenses/gwt/client/ScaffoldMasterActivities.java
  
/branches/2.1/bikeshed/src/com/google/gwt/sample/expenses/gwt/ui/ListActivitiesMapper.java
  
/branches/2.1/bikeshed/src/com/google/gwt/sample/expenses/gwt/ui/employee/EmployeeEditActivity.java
  
/branches/2.1/bikeshed/src/com/google/gwt/sample/expenses/gwt/ui/employee/EmployeeListActivity.java
  
/branches/2.1/bikeshed/src/com/google/gwt/sample/expenses/gwt/ui/report/ReportEditActivity.java
  
/branches/2.1/bikeshed/src/com/google/gwt/sample/expenses/gwt/ui/report/ReportListActivity.java


===
--- /dev/null
+++  
/branches/2.1/bikeshed/src/com/google/gwt/app/place/AbstractRecordEditActivity.java	 
Thu May 27 08:51:15 2010

@@ -0,0 +1,176 @@
+/*
+ * Copyright 2010 Google Inc.
+ *
+ * Licensed under the Apache License, Version 2.0 (the License); you may  
not
+ * use this file except in compliance with the License. You may obtain a  
copy of

+ * the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an AS IS BASIS,  
WITHOUT

+ * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
+ * License for the specific language governing permissions and limitations  
under

+ * the License.
+ */
+package com.google.gwt.app.place;
+
+import com.google.gwt.requestfactory.shared.Receiver;
+import com.google.gwt.requestfactory.shared.RequestFactory;
+import com.google.gwt.user.client.Window;
+import com.google.gwt.valuestore.shared.DeltaValueStore;
+import com.google.gwt.valuestore.shared.Record;
+import com.google.gwt.valuestore.shared.SyncResult;
+import com.google.gwt.valuestore.shared.Value;
+import com.google.gwt.valuestore.ui.RecordEditView;
+
+import java.util.Set;
+
+/**
+ * Abstract activity for editing a record.
+ *
+ * @param R the type of Record being edited
+ */
+public abstract class AbstractRecordEditActivityR extends Record  
implements

+Activity, RecordEditView.Delegate {
+
+  private final RequestFactory requests;
+  private final boolean creating;
+  private final RecordEditViewR view;
+
+  private String id;
+  private String futureId;
+  private DeltaValueStore deltas;
+  private Display display;
+
+  public AbstractRecordEditActivity(RecordEditViewR view, String id,
+  RequestFactory requests) {
+this.view = view;
+this.creating = .equals(id);
+this.id = id;
+this.requests = requests;
+this.deltas = requests.getValueStore().spawnDeltaView();
+  }
+
+  public void cancelClicked() {
+if (willStop()) {
+  deltas = null; // silence the next willStop() call when place changes
+  if (creating) {
+display.showActivityWidget(null);
+  } else {
+exit();
+  }
+}
+  }
+
+  public void onCancel() {
+onStop();
+  }
+
+  public void onStop() {
+this.display = null;
+  }
+
+  public void saveClicked() {
+if (deltas.isChanged()) {
+  view.setEnabled(false);
+
+  final DeltaValueStore toCommit = deltas;
+  deltas = null;
+
+  ReceiverSetSyncResult receiver = new ReceiverSetSyncResult()  
{

+public void onSuccess(SetSyncResult response) {
+  if (display == null) {
+return;
+  }
+  boolean hasViolations = false;
+  for (SyncResult syncResult : response) {
+Record syncRecord = syncResult.getRecord();
+if (creating) {
+  if (futureId == null
+  || !futureId.equals(syncResult.getFutureId())) {
+continue;
+  }
+  id = syncRecord.getId();
+} else {
+  if (!syncRecord.getId().equals(id)) {
+continue;
+  }
+}
+if (syncResult.hasViolations()) {
+  hasViolations = true;
+  view.showErrors(syncResult.getViolations());
+}
+  }
+  if (!hasViolations) {
+exit();
+  } else {
+deltas = toCommit;
+deltas.clearUsed();
+view.setEnabled(true);
+deltas.clearUsed();
+  }
+}
+
+

[gwt-contrib] Re: Introducing PrunerTest. It generates 85% of branch coverage for Pruner. (issue474803)

2010-05-28 Thread aizatsky

http://gwt-code-reviews.appspot.com/474803/show

--
http://groups.google.com/group/Google-Web-Toolkit-Contributors