Re: ui:image, image within an anchor or a button

2010-05-31 Thread Ray
I got the same situation.
Currently my solution is only has anchor in ***.ui.xml image part was
added using code.
eg:
Image myImage = new Image();
monitorOverImage = new Image();

monitorImage.setUrl(IFMResources.INSTANCE.vehicleMonitor().getURL());

monitorOverImage.setUrl(IFMResources.INSTANCE.vehicleMonitor_over().getURL());
Is there any better solution?

On 4月24日, 上午12時38分, Carlos Aguayo carlos.agu...@gmail.com wrote:
 I'd like to have an image within an anchor or a button tag. I'm using
 the UiBinder and I need the anchor or button to be a widget so I can
 use their HasClickHandlers interface.

 I wanted to use an image widget so I can use an ImageResource,
 something like this:

 !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:with field='res' type='com.test.Test.Resources'/

   g:HTMLPanel
     g:Anchorg:Image resource={res.add} / Add/g:Anchor
   /g:HTMLPanel

 /ui:UiBinder

 But since neither the Anchor nor the Button can take widgets, I get
 the Found widget in an HTML context error.

 I've seen posts mentioning the ui:image tag but couldn't find
 documentation on how to use it and I couldn't get it to work.

 If I do:

 !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'

   g:HTMLPanel
     ui:image src=add.gif /
   /g:HTMLPanel

 /ui:UiBinder

 It's doing something since it won't compile if add.gif is not under
 the right package. However when I see it in the browser, the ui:image
 didn't get compiled into an image.

 Do you know what am I missing here?

 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 
 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: Unable to get upload results from FileUpload

2010-05-31 Thread Fahim
Hi Manuel,

I am not using GWTUpload library. You are right, It is text/xml issue.
It works fine with text/html or text/plain. I already requested server
side team to change it for me.

Thanks for your help.

Fahim

On May 29, 11:06 am, Manuel Carrasco Moñino man...@apache.org wrote:
 Note that in this example you are using gwtupload library, which is
 not the matter of this issue.

 When you use FileUpload in a FormPanel, the only way to realize the
 form has been submitted is adding a SubmitCompleteHandler to the form
 panel, in this handler you can call the method response.getResults()
 which is the html content of the iframe used to submit the form. So,
 this is the reason I pointed to use a content-type text/plain or
 text/html in the server response, using any other content-type the
 call to get the iframe content returns null in many browsers.

 You can not use the method response.getText() which is specific for
 asynchronous ajax calls using RequestCallback, and this is not the
 case.

 btw: gwtupload library is able to realize that the upload has finished
 not only when the FormPanel executes the SubmitCompleteHandler, but
 when the server notifies the client, because the client is asking
 continuously to the server to the status progress using ajax.

 Cheers
 -Manolo

 On Fri, May 28, 2010 at 4:38 PM, Jeff Chimene jchim...@gmail.com wrote:
  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...()

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

Nokia Java ME Networking and Messaging Training Course

2010-05-31 Thread James Baker
Just came across this fantastic Java ME training course intended for
experienced and intermediate developers interested in adding
connectivity features to an MIDP application.

This course includes five lectures with incentive lab exercises. The
lectures cover Networking, Wireless Messaging API 2.0, Location API,
Bluetooth API for Java ME, and Web Services.

Download it here http://bit.ly/b6wgwi

Its great guys, check it out!!

-- 
You received this message because you are subscribed to the Google Groups 
Google Web Toolkit group.
To post to this group, send email to google-web-tool...@googlegroups.com.
To unsubscribe from this group, send email 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: ui:image, image within an anchor or a button

2010-05-31 Thread Thomas Broyer


On 23 avr, 18:38, Carlos Aguayo carlos.agu...@gmail.com wrote:
 I'd like to have an image within an anchor or a button tag. I'm using
 the UiBinder and I need the anchor or button to be a widget so I can
 use their HasClickHandlers interface.

 I wanted to use an image widget so I can use an ImageResource,
 something like this:

 !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:with field='res' type='com.test.Test.Resources'/

   g:HTMLPanel
     g:Anchorg:Image resource={res.add} / Add/g:Anchor
   /g:HTMLPanel

 /ui:UiBinder

 But since neither the Anchor nor the Button can take widgets, I get
 the Found widget in an HTML context error.

See also http://code.google.com/p/google-web-toolkit/issues/detail?id=3080

 I've seen posts mentioning the ui:image tag but couldn't find
 documentation on how to use it and I couldn't get it to work.

ui:image is just a way of defining an ImageResource within the
implicit UiBinder ClientBundle (the one where your ui:style will be
added). There's also ui:data to define a DataResource. The main goal
of ui:image and ui:data is that they can be referenced in your
ui:style rules (to define a @sprite's gwt-image, or @def'ine a
variable using a url() ).

 If I do:

 !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'

   g:HTMLPanel
     ui:image src=add.gif /
   /g:HTMLPanel

 /ui:UiBinder

 It's doing something since it won't compile if add.gif is not under
 the right package. However when I see it in the browser, the ui:image
 didn't get compiled into an image.

 Do you know what am I missing here?

How about using a @sprite in an ui:style and use it on the g:Anchor/
g:Button or a child element?

-- 
You received this message because you are subscribed to the Google Groups 
Google Web Toolkit group.
To post to this group, send email to google-web-tool...@googlegroups.com.
To unsubscribe from this group, send email 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: Optimizing Dev Module with user.agent?

2010-05-31 Thread Thomas Broyer


On 31 mai, 04:27, Andrew Hughes ahhug...@gmail.com wrote:
 Hi,

 I'm told that dev mode run's directly against java classes. Could I expect
 reduced compile+build times by specifying my specific user.agent when
 running in dev mode? Is the user.agent even used when running in dev mode?

No, it won't change anything. As deferred-binding is done on the
fly, DevMode already knows which user-agent is currently running the
module.

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



Re: wrapping existing HTML form

2010-05-31 Thread xfyre
  I need to wrap an existing HTML instead of creating widgets
  dynamically, so that end user will have the entire form displayed
  before initialization of GWT components. But then there is a problem:
  if you attach RootPanel to an existing div element and then use
  Widget.wrap ( element ) for the FormPanel and its input controls, you
  get the exception:

  java.lang.AssertionError: A widget that has an existing parent widget
  may not be added to the detach list

  I've googled about the problem and found out that this exception
  prevents code from messing up widgets hierarchy; this is totally
  understandable point, but is there any way to get the job done? For a
  number of reasons I really need those widgets to initialize from HTML
  instead of being created dynamically.

  Any ideas?

 Either:
  1. do not use a RootPanel on an ancestor div of your form (obviously)

Even if I initialize the form before RootPanel, I get the same error,
but for the form controls.
For example TextBox.wrap ( element ) produces the same error when
called after FormPanel.wrap ( element )

  2. Reverse the order of the calls: FormPanel::wrap() first, then
 RootPanel.get(); see issue 
 3528http://code.google.com/p/google-web-toolkit/issues/detail?id=3528

I saw this one. Completely reversing call order doesn't look good.

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



Persisting web pages locally

2010-05-31 Thread bcw
The usual model is a source serving pages, and the source persists the
data in various ways.

I am writing a note-taking (and other uses) application using GWT.
Properly, a lot of the smarts will reside on the server, but I must
make choices about persisting the information the user enters.  The
primary entry is by handwriting.

It would be useful if the user could save in a format that displays
the writing even when opened on a machine that does not have the smart
server, keeping the notes visible, and embedded in an HTML document.
I am already experimenting with rendering the writing with PNG
images.  I'm expecting to save the handwriting data as InkML, and
there may be other related information (such as the interpreted text).

Are there any approaches using GWT to allow me to save PNG images
along with a local copy of a page, so it's readable without the server
to interpret it?  I would need to fetch the images from the server and
them write it all locally.  I could have the server do this while
connected, or the browser (if that's practical), but I would like a
one-file format that could be opened in the browser on another machine
and show the writing/PNG.

Later I'm thinking of other content as well, so general pointers would
be helpful.

Thanks for any ideas,
bcw

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

2010-05-31 Thread Thomas Broyer


On 31 mai, 01:28, Navigateur naveen.c...@googlemail.com wrote:
 When I came into GWT I thought it was going to be write-once for all
 browsers. Since I've been using it, I've had all kinds of cross-
 browser problems, in particular with events and graphics, and
 sometimes widgets. And I've had to do workarounds (which I still
 haven't fully resolved) to make it work the same in different
 browsers.

 I just wondered if everybody else has had smooth-sailing with browsers
 or if there are others with similar issues?

I haven't had that much issues. I can't say I didn't face any, but
they (almost) always had easy workarounds IIRC.

The main problem with GWT is that because developers don't see
JavaScript they think they don't even have to know HTML, JavaScript or
CSS, and sometimes even tend to forget they're coding a browser-base
app. Coding in Java means better (or, at least, different) tooling and
sharing code with the server (though it's moot as JavaScript tends to
come back to the server nowadays).

 I know this is a vent, but sometimes I wish I had used Flash instead!

I've been told that Flash isn't a silver-bullet. Might be browser-
engine agnostic (though still depends on the browser's plugin API) but
not platform (OS) agnostic.

 Maybe Google can write clear guidelines for third-party library
 developers, since some of their libraries with respect to events and
 graphics seem to contribute to (but are not the only) problem. And
 treat cross-browser differences as a priority e.g. the fact that the
 core widget focusPanel doesn't seem to register mouseMove events in
 Internet Explorer except on the widgets contained on it, but does so
 fine in Firefox/Chrome.

Internet Explorer is so strangely coded (with strong constraints on
backwards compat with its own bugs, embedded API, etc.) that it has
weird bugs that have to be solved on a case-by-case basis.
http://code.google.com/p/google-web-toolkit/issues/detail?id=4985

 I hope everything written in GWT works the same in all browsers one
 day.

Given Internet Explorer's release schedule and update rate, you might
be dead and buried before it happens. Internet Explorer apart, it
might very well happen much sooner, if not already the case.

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



help with gwtunit test cases, how to access the document?

2010-05-31 Thread jamesmikedup...@googlemail.com
Dear GWT team,
thank you so much for this great tool. I am learning a lot, also
making progress with the josm port.
now I need to find a way to speed this up, so I wanted to write tests
for the svg rendering and test that outside of the app in a hosted
browser.

have a problem with gwtunit, how can I test graphical components?

here is my bug report :
http://fmtyewtk.blogspot.com/2010/05/using-orgvaadingwtgraphicsclientdrawing.html

they need a document container, but I dont seem to find the docs.
please some pointers?
thanks,
mike

-- 
You received this message because you are subscribed to the Google Groups 
Google Web Toolkit group.
To post to this group, send email to google-web-tool...@googlegroups.com.
To unsubscribe from this group, send email 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: An implementation of Selection/Cursor for RichTextArea

2010-05-31 Thread Yanick
If there is a selectAll(); method in the RichTextArea's formatter,
having a getSelection(); and a setSelection(Selection); methods would
be very nice for this widget.

+1 for a more complete text selection API for the RichTextArea

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



Re: MVP + appController useful for the big projects ?

2010-05-31 Thread Rizen
Yes I think it's probably the best solution for the big project. So
now I need to learn it ^^
Thanks very much.

On May 30, 7:09 pm, Subhrajyoti Moitra subhrajyo...@gmail.com wrote:
 i think one of the mvp frameworks could help.
 gwt-dispatch,gwt-presenter, mvp4g.. there are more..

 HTH.
 Subhro.

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



Personalized table using thead / tfoot / tbody

2010-05-31 Thread Rizen
Hello everybody !

I'm trying to create a table using thead, tfoot and tbody.
Moreover I have to reuse an existing CSS file. This one is using few
table
properties like thead, tbody, tfoot and others styles name.
So I must create a personalized table thanks to the DOM tree.

First of all, I tried to use the function DOM.createTable(). But my
table is hugh and it's
very long to coding step by step.
Then I used the innerHTML method, faster but I don't think it's the
best solution.

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.

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



Label for form-element using UIBindings

2010-05-31 Thread Stephan T
How do I achieve this code this using UI Bindings?

label for=someUniqueFieldIdFirst name/label
input type=text id=someUniqueFieldId name=firstname/

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

2010-05-31 Thread Matt
Hi,

you won't be able to use this custom widget directly within an
UiBinder file due to this issue: 
http://code.google.com/p/google-web-toolkit/issues/detail?id=4342.

You should be able to wrap it into a Composite and then reference that
Composite in your UiBinder file though.

Hth,
Matt

On 18 Mai, 15:58, rkvaja rikesh.v...@gmail.com wrote:
 I'm trying to use this with UIBinder but getting issues telling me
 that I am missing required attributes barUnit, barHeight etc. Has
 anybody got this working with UIBinder?

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

2010-05-31 Thread achilles.hector...@gmail.com
sorry for the spelling mistake,
I am using GWT to create my application.
Now i am stuck to this problem. I have more than 3 lakh records.
Could you suggest me any other way to export in excel file.
If GWTprovide any  feature kinly give example or link.


On May 30, 12:40 pm, Sripathi Krishnan sripathi.krish...@gmail.com
wrote:
 He means 3 *lac http://en.wikipedia.org/wiki/Lakh* rows, which is 300,000
 thousand rows.
 This isn't really a GWT discussion - but 65536 rows is the maximum excel can
 support. You can however create multiple sheets and get around that.

 --Sri

 On 30 May 2010 06:45, mP miroslav.poko...@gmail.com wrote:



  What is 3 lack of rows as a simple number? If you need to export more
  than
  65536 rows and poi/jexcel can't handle that large amount maybe you
  need to ask the respective communities of eachnof those libs. It can't
  be a coincidence both libs only support 65536 rows, does excel support
  more than 65536 ?
  t

  --
  You received this message because you are subscribed to the Google Groups
  Google Web Toolkit group.
  To post 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: Status of Joda/Goda time, future of Date handling

2010-05-31 Thread Paul Stockley
I did that already. There isn't really anything that can easily be
removed. There is just a lot of code. The jar is 839kb including
source. In java your don't really notice it. I am looking for
something more lightweight.

On May 30, 9:57 pm, Chris Lercher cl_for_mail...@gmx.net wrote:
 On May 31, 2:26 am, Paul Stockley pstockl...@gmail.com wrote:

  I am using gwt-time. I haven't had any issues as yet. However, the
  biggest
  problem is that it adds 250 - 300 kb to the project js download.

 That's massive, and it would be way too much for my project. I wonder,
 why it's that large - What does the SOYC compile report say? If it's
 mainly the timezone tables, maybe there's a way to reduce them.

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



Re: MVP + appController useful for the big projects ?

2010-05-31 Thread Tristan
gwtp, and handlebars are some others

On May 31, 5:35 am, Rizen vianney.dep...@gmail.com wrote:
 Yes I think it's probably the best solution for the big project. So
 now I need to learn it ^^
 Thanks very much.

 On May 30, 7:09 pm, Subhrajyoti Moitra subhrajyo...@gmail.com wrote:



  i think one of the mvp frameworks could help.
  gwt-dispatch,gwt-presenter, mvp4g.. there are more..

  HTH.
  Subhro.

-- 
You received this message because you are subscribed to the Google Groups 
Google Web Toolkit group.
To post to this group, send email to google-web-tool...@googlegroups.com.
To unsubscribe from this group, send email 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-31 Thread Tristan
If you're using EasyMock, this is a very easy way to mock a service.
Been using this for a long time.

http://robvanmaris.jteam.nl/2008/04/22/test-driven-development-for-gwt-ui-code-with-asynchronous-rpc/

Take a particular look at AsyncCallbackMockSupport class.

Cheers!

Tristan

On May 30, 8:16 pm, Trung gwtdevelo...@gmail.com wrote:
 See this thread

 http://groups.google.com/group/google-web-toolkit/browse_thread/threa...
 discussing GWT RPC calls from Java

 On May 28, 3:39 pm, 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

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



Map-Based Model in Large Scaled Applications

2010-05-31 Thread buz...@gmail.com
Hello,

Wanted to share an approach we are using in large scaled enterprise
level applications since GWT 1.4 and up to now.

http://buzdin.blogspot.com/2010/05/gwt-dynamic-model.html

Would be great to know opinion of the community on the Dynamic Model
(Generic Transfer Object) approach and whether it will be still
feasible in post 2.0 world. Are there any plans to propose default
approach to serialization of server-side model aside of Enhanced
Classes Serialization?

The reason behind this thread is that I am still in doubt if it will
be a good start-up for yet another gwt-related open source project, or
problems described in the post are too specific and already solved in
some other way.

Regards,
Dmitry

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



Re: Label for form-element using UIBindings

2010-05-31 Thread Thomas Broyer

On 31 mai, 13:08, Stephan T stephan.tern...@gmail.com wrote:
 How do I achieve this code this using UI Bindings?

 label for=someUniqueFieldIdFirst name/label
 input type=text id=someUniqueFieldId name=firstname/

See https://docs.google.com/Doc?docid=0AQcd-Zsy2T-YZG1mZG5jNl84Z3NkMmJuZHohl=en
The original can be found on Wave:
https://wave.google.com/wave/#restored:wave:googlewave.com!w%252BEI8yh67GA

Pay attention to the usage example subsection of what can be done
now?, which gives code you can use right now!

-- 
You received this message because you are subscribed to the Google Groups 
Google Web Toolkit group.
To post to this group, send email to google-web-tool...@googlegroups.com.
To unsubscribe from this group, send email 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: Personalized table using thead / tfoot / tbody

2010-05-31 Thread Thomas Broyer


On 31 mai, 12:53, Rizen vianney.dep...@gmail.com wrote:
 Hello everybody !

 I'm trying to create a table using thead, tfoot and tbody.
 Moreover I have to reuse an existing CSS file. This one is using few
 table
 properties like thead, tbody, tfoot and others styles name.
 So I must create a personalized table thanks to the DOM tree.

 First of all, I tried to use the function DOM.createTable(). But my
 table is hugh and it's
 very long to coding step by step.
 Then I used the innerHTML method, faster but I don't think it's the
 best solution.

You won't find anything faster; but yes you have to be careful about
the HTML you're producing.

 Is the TableElement class better ?

TableElement isn't different from DOM.createTable(). It's a different
API around the exact same underlying DOM manipulation; just that the
DOM class will be deprecated in a future release and TableElement
should be preferred in new development (code is more readable too).

 Cause I don't know how to create a
 tbody element in my HTML page with this.

Document.get().createTBodyElement()

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



Which is the best: Hibernate, Ibatis, Toplink??

2010-05-31 Thread fomba collins
Hi,
    I wish to know which of the following ORMs is the best to use with GWT and 
why. 
Regards
   


  

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



Re: Persisting web pages locally

2010-05-31 Thread kozura
Well this is the idea behind Google Gears, allowing you to locally
persist data in a little lightweight db.  Normal js won't allow this
due to the myriad security issues; with gears the user installs it and
allows client side code to access it.  But the status of gears going
forward is a little unclear, for instance I haven't seen some major
issues that cause browsers to hang being addressed..  However the GWT-
gears lib is up to date: 
http://code.google.com/p/gwt-google-apis/wiki/GearsGettingStarted


On May 31, 2:46 am, bcw bcw1...@gmail.com wrote:
 The usual model is a source serving pages, and the source persists the
 data in various ways.

 I am writing a note-taking (and other uses) application using GWT.
 Properly, a lot of the smarts will reside on the server, but I must
 make choices about persisting the information the user enters.  The
 primary entry is by handwriting.

 It would be useful if the user could save in a format that displays
 the writing even when opened on a machine that does not have the smart
 server, keeping the notes visible, and embedded in an HTML document.
 I am already experimenting with rendering the writing with PNG
 images.  I'm expecting to save the handwriting data as InkML, and
 there may be other related information (such as the interpreted text).

 Are there any approaches using GWT to allow me to save PNG images
 along with a local copy of a page, so it's readable without the server
 to interpret it?  I would need to fetch the images from the server and
 them write it all locally.  I could have the server do this while
 connected, or the browser (if that's practical), but I would like a
 one-file format that could be opened in the browser on another machine
 and show the writing/PNG.

 Later I'm thinking of other content as well, so general pointers would
 be helpful.

 Thanks for any ideas,
 bcw

-- 
You received this message because you are subscribed to the Google Groups 
Google Web Toolkit group.
To post to this group, send email to google-web-tool...@googlegroups.com.
To unsubscribe from this group, send email 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: An implementation of Selection/Cursor for RichTextArea

2010-05-31 Thread kozura
FYI in lieu of getting it into GWT, I posted a standalone library to
the issue mentioned above, with some caveats of a few cases that still
need addressed.

On May 31, 3:55 am, Yanick yanick.roc...@gmail.com wrote:
 If there is a selectAll(); method in the RichTextArea's formatter,
 having a getSelection(); and a setSelection(Selection); methods would
 be very nice for this widget.

 +1 for a more complete text selection API for the RichTextArea

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



Updating Google App Engine datastore

2010-05-31 Thread Víctor Mayoral
Hello,
I've just an applications using GWT and GAE. After reading the docs
and doing some examples I decided to begin coding but soon I reach
something tricky.

My application data would be at the GAE datastore. I want to assume
that the app will live. Let me explain this:
The entities at the datastore will change. This means that some
properties would be added and some of them maybe removed what leaves
me with a ton of exceptions to handle. Knowing this, which should be
the way to update the datastore entities? One by one after a change is
made? Should I handle exceptions and then change just the entitie
requested? Is there a way to do this cleaner?

I've been thinking about how to do this stuff with my actual knowledge
and i think that the most logical way to proceed is get the object,
remove it from the database, create a new one based on this old object
and then persist it again.

To sum up the question is about if there's a way to add a property to
an stored entitie in the datastore (GAE) easily.

I hope you to understand my lines. Any suggestion would be
appreciated.

Thanks,

Víctor.

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



DockPanel - how to maximize center?

2010-05-31 Thread Magnus
Hi,

I use the following code to create my screen. I want a MenuBar at
the top and that the content in the middle is always centered:

  pnl = new DockPanel ();
  pnl_Center = new VerticalPanel ();

  pnl_Center.setHorizontalAlignment (VerticalPanel.ALIGN_CENTER);
  pnl_Center.setVerticalAlignment(VerticalPanel.ALIGN_MIDDLE);
  pnl_Center.setSize(100%, 100%);

  pnl.setSize(100%,100%);
  pnl.add (mnb,DockPanel.NORTH);
  pnl.add (pnl_Center,DockPanel.CENTER);

  RootLayoutPanel root = RootLayoutPanel.get();
  root.add (pnl);

However, I noticed the following: The north part of pnl is a little
bit heigher than the MenuBar. And: When I add small content to
pnl_Center, its heigher than when I add big content to the center.

How can I achieve that the north part is just as high as the MenuBar?

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.



Rebar: Gears workers, jdbc, and jpa for GWT

2010-05-31 Thread Alex Bertram
Hi all,

I just wanted to share the link for a few modules related to GWT /
gears / HTML5 that we've recently packaged as open source at
http://code.google.com/p/rebar, which includes:

* GWT linker for building (Gears) workers, complete with RPC support
* JDBC emulation layer that facilitates testing,
* An experimental JPA implementation for client-side GWT (and it
works!)

We'll be adding deferred bindings for browsers that support HTML5 in
the coming month, but right now the suite works nicely with Gears. I
think there's a few folks out there that have used it in their
projects successfully, so thought it might be a good moment to share
with the newsgroup.

Best,

Alex at
be data driven
com

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



Using SliderBar from incubator

2010-05-31 Thread leslie
GWT 2.0.3
Eclipse 3.5
Mac OS X 10.5
Java 5

Hello,

I'm attempting to use the SliderBar in the incubator project.  The
name of the incubator file I've obtained was called gwt-
incubator.jar.  My import statement for the SliderBar looks like
this:

import com.google.gwt.widgetideas.client.SliderBar;

I can see the SliderBar, I have the css set up and I can manipulate
the values of the slider programmatically, like

mySliderBar.setCurrentValue(Double.parseDouble(10));

But I'd like to be able to manipulate the position of the slider
manually, by sliding the image with the mouse, like you can do here:

http://google-web-toolkit-incubator.googlecode.com/svn/trunk/demo/SliderBar/index.html

But when I attempt to mouse over my slider nothing happens.  Nothing
moves.  Clearly I'm missing listener information.  If anyone can point
me in the direction of finding more information about the use of
SliderBar I'd be grateful.  For example, is it possible to see the
code that operates the SliderBar in the link I've given above?  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: Persisting web pages locally

2010-05-31 Thread bcw
I understand Gears allows local storage of remotely sourced web data.
I don't know of any way it solves the problem of embedding PNG in a
locally saved html file so the file can be viewed on a machine which
doesn't have my server installed, and which may not be connected to
the network at the time.

This is a note taking application at first, with the idea of making
the notes 'smarter' in later versions.  I'd like to have the notes
always viewable just with a browser, just as with any locally saved
html file.  The notes would be read-only, and not smart, but
accessible.

So my question is more how to embed (PNG) data presented with a GWT
Image widget into a saved html file so it can be displayed in a 'dumb'
browser.  The Image is how the handwriting is shown, with backing
smarts in the full application.

Thanks.

On Jun 1, 5:17 am, kozura koz...@gmail.com wrote:
 Well this is the idea behind Google Gears, allowing you to locally
 persist data in a little lightweight db.  Normal js won't allow this
 due to the myriad security issues; with gears the user installs it and
 allows client side code to access it.  But the status of gears going
 forward is a little unclear, for instance I haven't seen some major
 issues that cause browsers to hang being addressed..  However the GWT-
 gears lib is up to 
 date:http://code.google.com/p/gwt-google-apis/wiki/GearsGettingStarted

 On May 31, 2:46 am, bcw bcw1...@gmail.com wrote:



  The usual model is a source serving pages, and the source persists the
  data in various ways.

  I am writing a note-taking (and other uses) application using GWT.
  Properly, a lot of the smarts will reside on the server, but I must
  make choices about persisting the information the user enters.  The
  primary entry is by handwriting.

  It would be useful if the user could save in a format that displays
  the writing even when opened on a machine that does not have the smart
  server, keeping the notes visible, and embedded in an HTML document.
  I am already experimenting with rendering the writing with PNG
  images.  I'm expecting to save the handwriting data as InkML, and
  there may be other related information (such as the interpreted text).

  Are there any approaches using GWT to allow me to save PNG images
  along with a local copy of a page, so it's readable without the server
  to interpret it?  I would need to fetch the images from the server and
  them write it all locally.  I could have the server do this while
  connected, or the browser (if that's practical), but I would like a
  one-file format that could be opened in the browser on another machine
  and show the writing/PNG.

  Later I'm thinking of other content as well, so general pointers would
  be helpful.

  Thanks for any ideas,
  bcw

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



Re: Help to find only clickable panel except focuspanel

2010-05-31 Thread Stefan Bachert
Hi Deepak,

I tried your corrected code (I use g: instead of gwt, gwr).
However, no input are is created.

I am using FF. May this is a workaround for other browser.
Did you checked the issues?

--
container.getElement().getChild(container.getTabIndex()).removeFromParent();

Please provide your suggestions, is it a correct way to remove this
tabindex ?


The above may accidently work. Logically it is wrong. A tabIndex is in
general not a element child index.

Stefan Bachert
http://gwtworld.de

On 29 Mai, 20:27, Deepak Bammi deepak.ba...@gmail.com wrote:
 Hi Stefan,

 Thanks for your response.

 I'm using focuspanel to create a simple div element which is clickable so
 that i can embed any widget.

 e.g
 Using UiBinder.

  gwt:FocusPanel
    gwt:FlowPanel
                // Widget.
    /gwr:FlowPanel
  /gwt:FocusPanel

 The above code creates two div element (one for focuspanel and other for
 flowpanel), but the focus panel will automatically inserts the textbox
 before the second div element into DOM and i want to remove this textbox
 from fouspanel.

 I think now you will get the problem and if still you have any doubt please
 feel free to share.

 Thanks,
 Dev
 On Sat, May 29, 2010 at 7:55 PM, Stefan Bachert stefanbach...@yahoo.dewrote:

  Hi Deepak,

  I use focusPanel with a ClickHandler for the tab of an own TabPanel.
  I don't understand what your problem is?
  Did you also added a textbox into the focus panel?

  Or do you call the focus marquise as input box?
  When yes, remove the attribute tabIndex.
  (getElement().removeArribute())

  Otherwise we need more information about your issue

  Stefan Bachert
 http://gwtworld.de

  On 29 Mai, 11:55, Deepak Bammi deepak.ba...@gmail.com wrote:
   Hi All,

   I need a panel which is clickable.I found focuspanel but it has one
  drawback
   in my case that it automatically embeds the input box which causes a
  problem
   for me.

   Please share to access the input box in the focus panel or to find the
   clickable panel.

   Thanks,
   Dev

  --
  You received this message because you are subscribed to the Google Groups
  Google Web Toolkit group.
  To post 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: Personalized table using thead / tfoot / tbody

2010-05-31 Thread Stefan Bachert
Hi,

when you are trying to re-use existing css, you need to create exactly
the same structure.
This means: either a GWT-widget supports this structure, or you have
to build one of your own.
It seems that you are going the latter, but this is tedious.

Stefan Bachert
http://gwtworld.de

On 31 Mai, 12:53, Rizen vianney.dep...@gmail.com wrote:
 Hello everybody !

 I'm trying to create a table using thead, tfoot and tbody.
 Moreover I have to reuse an existing CSS file. This one is using few
 table
 properties like thead, tbody, tfoot and others styles name.
 So I must create a personalized table thanks to the DOM tree.

 First of all, I tried to use the function DOM.createTable(). But my
 table is hugh and it's
 very long to coding step by step.
 Then I used the innerHTML method, faster but I don't think it's the
 best solution.

 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.

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

2010-05-31 Thread Stefan Bachert
Hi,

Gears supports this but Gears will discontinue further development.
The reason is that HTML5 will support some way of persisting data on
the client.

However, this means that you have to use a Html5 capable browser. And
IE is not.

Stefan Bachert
http://gwtworld.de

On 31 Mai, 10:46, bcw bcw1...@gmail.com wrote:
 The usual model is a source serving pages, and the source persists the
 data in various ways.

 I am writing a note-taking (and other uses) application using GWT.
 Properly, a lot of the smarts will reside on the server, but I must
 make choices about persisting the information the user enters.  The
 primary entry is by handwriting.

 It would be useful if the user could save in a format that displays
 the writing even when opened on a machine that does not have the smart
 server, keeping the notes visible, and embedded in an HTML document.
 I am already experimenting with rendering the writing with PNG
 images.  I'm expecting to save the handwriting data as InkML, and
 there may be other related information (such as the interpreted text).

 Are there any approaches using GWT to allow me to save PNG images
 along with a local copy of a page, so it's readable without the server
 to interpret it?  I would need to fetch the images from the server and
 them write it all locally.  I could have the server do this while
 connected, or the browser (if that's practical), but I would like a
 one-file format that could be opened in the browser on another machine
 and show the writing/PNG.

 Later I'm thinking of other content as well, so general pointers would
 be helpful.

 Thanks for any ideas,
 bcw

-- 
You received this message because you are subscribed to the Google Groups 
Google Web Toolkit group.
To post to this group, send email to google-web-tool...@googlegroups.com.
To unsubscribe from this group, send email 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: Personalized table using thead / tfoot / tbody

2010-05-31 Thread jocke eriksson
Sounds like something the ui binder and html panel can solve.

2010/5/31 Stefan Bachert stefanbach...@yahoo.de

 Hi,

 when you are trying to re-use existing css, you need to create exactly
 the same structure.
 This means: either a GWT-widget supports this structure, or you have
 to build one of your own.
 It seems that you are going the latter, but this is tedious.

 Stefan Bachert
 http://gwtworld.de

 On 31 Mai, 12:53, Rizen vianney.dep...@gmail.com wrote:
  Hello everybody !
 
  I'm trying to create a table using thead, tfoot and tbody.
  Moreover I have to reuse an existing CSS file. This one is using few
  table
  properties like thead, tbody, tfoot and others styles name.
  So I must create a personalized table thanks to the DOM tree.
 
  First of all, I tried to use the function DOM.createTable(). But my
  table is hugh and it's
  very long to coding step by step.
  Then I used the innerHTML method, faster but I don't think it's the
  best solution.
 
  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.

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

2010-05-31 Thread Stefan Bachert
Hi Kirt,

FF has a problem using absolute mode with input and resize. When
your problem is just an extension of this bug, there is a fix
available.

http://code.google.com/p/google-web-toolkit/issues/detail?id=4348

Stefan Bachert
http://gwtworld.de


On 31 Mai, 06:27, kirtcathey kirtcat...@gmail.com wrote:
 Hi All. Back again. I have nailed this problem down to a rich text
 editor resize problem in Firefox. Other browsers work okay, but not
 great... very jerky. Any other widget resizes. I am now looking at the
 possible solutions with TinyMCE or just using something rolled with
 HTML5 as a rich text editor.

 On May 2, 12:39 am, kozura koz...@gmail.com wrote:

  As much as it tries to abstract, GWT is still bound underneath to html
  elements and thus you must tinker with styling/CSS to get layout
  right.  And unlike most layout systems out there, there is no great
  child-type independent layout containers that work perfectly.
  LayoutPanels try, but still not perfect.  Myself not coming into GWT
  as a CSS expert, I recommend using Firebug and a willingness to dicker
  with the different elements styling with height:100% or whatnot to
  figure out exactly what's needed to get the correct layout and
  repositioning/resizing action.

  Also, be sure you are following everything 
  here:http://code.google.com/webtoolkit/doc/latest/DevGuideUiPanels.html#La...,
  standard html mode, rootlayoutpanel to hold the SplitLayoutPanel or
  explicit sizing of it, etc.

  For #2, this is more the responsibility of your tomcat/jetty engine,
  which have the tools for dealing with this.

  Dunno what you're trying to do in #3, if you clear a listbox and
  repopulate it with new data, the new data should show up just fine?

  On Apr 30, 2:59 am, kirtcathey kirtcat...@gmail.com wrote:

   Hi All.

   Relatively new to GWT, but have given it about a 20,000 line test
   drive and  oh, yeah I like. I like :-))
   Just got all working on a hosting service a couple nights ago and am
   impressed with performance as well.

   A couple of questions  (will update the post if I find the answer
   before response)
   1) In my application I am implementing a splitlayoutpanel with two
   rich text editors - one in the NORTH panel and one in the CENTER panel
   (top and bottom). When the vertical adjustment  slides up, I would
   like to anchor the bottom of the rich text editor to the bottom and of
   the CENTER split layout panel, and vice versa for the rich text editor
   that is in the NORTH panel. In other languages, there is usually a
   'bind' or 'anchor' command on such sliders.

   I looked high and low for examples of resize, but found very little.
   If there is explanatory code, please send a link.

   2) Is there a way with Java servlets to gauge the amount of sessions
   being served on a JVM - trying to setup a poor man's load balancer.

   3) I cannot get any of my list boxes to refresh. I call
   projectListBox.clear(); and that seems to work, but the data that
   comes back up on the list boxes are the same. Is there a way to do
   this efficiently?

   Thank you.
   Kirt Cathey
   sysrisk.com

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



Calling Methode using JSNI failed

2010-05-31 Thread malibubu
Hi,

I've the following class:

package de.test;
public class Designer {

public native void addNode() {
   alert(Pre JSNI);
   th...@de.test.designer::sendNode(Ljava/lang/String;Ljava/land/
Integer)(TEST,100);
   alert(Post JSNI);
}

void sendNode(String id, Integer x) {
   GWT.log(It Works!);
}

}

If addNode() is called, the first Alert is shown. Then, the following
JS-Error occurs (IE8):

Details zum Fehler auf der Webseite
Benutzer-Agent: Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 5.1;
Trident/4.0)
Zeitstempel: Mon, 31 May 2010 21:15:12 UTC
Meldung: Das Objekt unterstützt diese Eigenschaft oder Methode nicht.
Zeile: 11460
Zeichen: 7
Code: 0
URI: http://localhost:8080/test/test/DDB7CB660FDE7BAFEE5000321CF27CD1.cache.html


Any ideas what I'm doing wrong?

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: Calling Methode using JSNI failed

2010-05-31 Thread kozura
Maybe try with int x and use I instead of the Integer class.  Also
even as is, your Integer method signature isn't quite right: land-
lang.

On May 31, 3:15 pm, malibubu webmas...@mailball.de wrote:
 Hi,

 I've the following class:

 package de.test;
 public class Designer {

 public native void addNode() {
    alert(Pre JSNI);
    th...@de.test.designer::sendNode(Ljava/lang/String;Ljava/land/
 Integer)(TEST,100);
    alert(Post JSNI);

 }

 void sendNode(String id, Integer x) {
    GWT.log(It Works!);

 }
 }

 If addNode() is called, the first Alert is shown. Then, the following
 JS-Error occurs (IE8):

 Details zum Fehler auf der Webseite
 Benutzer-Agent: Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 5.1;
 Trident/4.0)
 Zeitstempel: Mon, 31 May 2010 21:15:12 UTC
 Meldung: Das Objekt unterstützt diese Eigenschaft oder Methode nicht.
 Zeile: 11460
 Zeichen: 7
 Code: 0
 URI:http://localhost:8080/test/test/DDB7CB660FDE7BAFEE5000321CF27CD1.cach...

 Any ideas what I'm doing wrong?

 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: Calling Methode using JSNI failed

2010-05-31 Thread malibubu
Sorry, this was a typo.

I also tried the signature

  th...@de.test.designer::sendNode(Ljava/lang/String;I)(TEST,100);

with methode sendNode(String id, int x)

Same problem :(

On 31 Mai, 23:48, kozura koz...@gmail.com wrote:
 Maybe try with int x and use I instead of the Integer class.  Also
 even as is, your Integer method signature isn't quite right: land-

 lang.

 On May 31, 3:15 pm, malibubu webmas...@mailball.de wrote:



  Hi,

  I've the following class:

  package de.test;
  public class Designer {

  public native void addNode() {
     alert(Pre JSNI);
     th...@de.test.designer::sendNode(Ljava/lang/String;Ljava/land/
  Integer)(TEST,100);
     alert(Post JSNI);

  }

  void sendNode(String id, Integer x) {
     GWT.log(It Works!);

  }
  }

  If addNode() is called, the first Alert is shown. Then, the following
  JS-Error occurs (IE8):

  Details zum Fehler auf der Webseite
  Benutzer-Agent: Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 5.1;
  Trident/4.0)
  Zeitstempel: Mon, 31 May 2010 21:15:12 UTC
  Meldung: Das Objekt unterstützt diese Eigenschaft oder Methode nicht.
  Zeile: 11460
  Zeichen: 7
  Code: 0
  URI:http://localhost:8080/test/test/DDB7CB660FDE7BAFEE5000321CF27CD1.cach...

  Any ideas what I'm doing wrong?

  Thank you!- Zitierten Text ausblenden -

 - Zitierten Text anzeigen -

-- 
You received this message because you are subscribed to the Google Groups 
Google Web Toolkit group.
To post to this group, send email to google-web-tool...@googlegroups.com.
To unsubscribe from this group, send email 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 Compiler fails with 'Too many open files' error / internal compiler error

2010-05-31 Thread googelybear
Hi,

When I compile my gwt project via ant I regularly get the following
error
'[java] Invoking
com.google.gwt.dev.javac.standardgeneratorcont...@28e4f4ad
 [java][ERROR] Generator
'com.google.gwt.uibinder.rebind.UiBinderGenerator' threw threw an
exception while rebinding (...)
[java]  java.lang.RuntimeException: java.io.FileNotFoundException:
(...)web/core/client/ui/LanguageBarPanel.ui.xml (Too many open
files)'
[java]  at
com.google.gwt.uibinder.rebind.W3cDomHelper.documentFor(W3cDomHelper.java:
100)
 [java] at
com.google.gwt.uibinder.rebind.UiBinderGenerator.getW3cDoc(UiBinderGenerator.java:
147)
 [java] at
com.google.gwt.uibinder.rebind.UiBinderGenerator.generateOnce(UiBinderGenerator.java:
124)
 [java] at
com.google.gwt.uibinder.rebind.UiBinderGenerator.generate(UiBinderGenerator.java:
105)
 [java] at
com.google.gwt.dev.javac.StandardGeneratorContext.runGenerator(StandardGeneratorContext.java:
418)
 [java] at
com.google.gwt.dev.cfg.RuleGenerateWith.realize(RuleGenerateWith.java:
38)
 [java] at com.google.gwt.dev.shell.StandardRebindOracle
$Rebinder.tryRebind(StandardRebindOracle.java:108)
 [java] at com.google.gwt.dev.shell.StandardRebindOracle
$Rebinder.rebind(StandardRebindOracle.java:54)
 [java] at
com.google.gwt.dev.shell.StandardRebindOracle.rebind(StandardRebindOracle.java:
154)
 [java] at
com.google.gwt.dev.shell.StandardRebindOracle.rebind(StandardRebindOracle.java:
143)
 [java] at com.google.gwt.dev.Precompile
$DistillerRebindPermutationOracle.getAllPossibleRebindAnswers(Precompile.java:
317)
 [java] at
com.google.gwt.dev.jdt.WebModeCompilerFrontEnd.doFindAdditionalTypesUsingRebinds(WebModeCompilerFrontEnd.java:
95)
 [java] at com.google.gwt.dev.jdt.AbstractCompiler$Sandbox
$CompilerImpl.process(AbstractCompiler.java:200)
 [java] at
org.eclipse.jdt.internal.compiler.Compiler.compile(Compiler.java:444)
 [java] at com.google.gwt.dev.jdt.AbstractCompiler$Sandbox
$CompilerImpl.compile(AbstractCompiler.java:123)
 [java] at com.google.gwt.dev.jdt.AbstractCompiler$Sandbox
$CompilerImpl.compile(AbstractCompiler.java:234)
 [java] at com.google.gwt.dev.jdt.AbstractCompiler$Sandbox
$CompilerImpl.access$200(AbstractCompiler.java:109)
 [java] at
com.google.gwt.dev.jdt.AbstractCompiler.compile(AbstractCompiler.java:
522)
 [java] at
com.google.gwt.dev.jdt.BasicWebModeCompiler.getCompilationUnitDeclarations(BasicWebModeCompiler.java:
112)
 [java] at
com.google.gwt.dev.jdt.WebModeCompilerFrontEnd.getCompilationUnitDeclarations(WebModeCompilerFrontEnd.java:
47)
 [java] at
com.google.gwt.dev.jjs.JavaToJavaScriptCompiler.precompile(JavaToJavaScriptCompiler.java:
422)
 [java] at
com.google.gwt.dev.jjs.JavaScriptCompiler.precompile(JavaScriptCompiler.java:
32)
 [java] at
com.google.gwt.dev.Precompile.precompile(Precompile.java:522)
 [java] at
com.google.gwt.dev.Precompile.precompile(Precompile.java:414)
 [java] at com.google.gwt.dev.Compiler.run(Compiler.java:201)
 [java] at com.google.gwt.dev.Compiler$1.run(Compiler.java:152)
 [java] at
com.google.gwt.dev.CompileTaskRunner.doRun(CompileTaskRunner.java:87)
 [java] at
com.google.gwt.dev.CompileTaskRunner.runWithAppropriateLogger(CompileTaskRunner.java:
81)
 [java] at com.google.gwt.dev.Compiler.main(Compiler.java:159)

followed by (probably subsequent errors) like the following
(truncated):

 [java] java.lang.NullPointerException
 [java] at com.google.gwt.dev.util.Util.copyNoClose(Util.java:
259)
 [java] at com.google.gwt.dev.util.Util.copy(Util.java:180)
 [java] at
com.google.gwt.dev.util.Util.readStreamAsString(Util.java:755)
 [java] at com.google.gwt.dev.javac.Shared.readSource(Shared.java:
150)

Does anyone have similar problems or is this a known bug? Is there any
more information I should provide that could help?

thanks for any help,

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: Using SliderBar from incubator

2010-05-31 Thread Jim Douglas
Leslie --

We had to fine-tune the incubator classes to work with GWT 2.x; you're
welcome to our tweaked versions of SliderBar, ProgressBar, and
Spinner.  (We've also added vertical orientation to the SliderBar and
ProgressBar.)  I can't figure out how to send attachments to the list
-- let me know if you'd like these, and I'll email them to you, or to
anyone else who wants them.  (I'd be happy to contribute these back to
GWT, but I'm not sure how to do that.)


On May 31, 11:57 am, leslie web...@me.com wrote:
 GWT 2.0.3
 Eclipse 3.5
 Mac OS X 10.5
 Java 5

 Hello,

 I'm attempting to use the SliderBar in the incubator project.  The
 name of the incubator file I've obtained was called gwt-
 incubator.jar.  My import statement for the SliderBar looks like
 this:

 import com.google.gwt.widgetideas.client.SliderBar;

 I can see the SliderBar, I have the css set up and I can manipulate
 the values of the slider programmatically, like

 mySliderBar.setCurrentValue(Double.parseDouble(10));

 But I'd like to be able to manipulate the position of the slider
 manually, by sliding the image with the mouse, like you can do here:

 http://google-web-toolkit-incubator.googlecode.com/svn/trunk/demo/Sli...

 But when I attempt to mouse over my slider nothing happens.  Nothing
 moves.  Clearly I'm missing listener information.  If anyone can point
 me in the direction of finding more information about the use of
 SliderBar I'd be grateful.  For example, is it possible to see the
 code that operates the SliderBar in the link I've given above?  Thanks
 in advance.

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



Re: GWT Compiler fails with 'Too many open files' error / internal compiler error

2010-05-31 Thread Chris Lercher
Hi,

are you on Linux? There's a limit of open files you can have. Google
for Too many open files to find a solution. Here's a good page:
http://confluence.atlassian.com/display/CONF29/Fix+'Too+many+open+files'+error+on+Linux+by+increasing+filehandles

If your parameters are in a normal range before calling the GWT
compiler, then there may be a problem with GWT though, because I'm not
sure, if it's supposed to use so many open files.

HTH
Chris


On Jun 1, 12:28 am, googelybear googelyb...@gmail.com wrote:
 Hi,

 When I compile my gwt project via ant I regularly get the following
 error
 '[java]             Invoking
 com.google.gwt.dev.javac.standardgeneratorcont...@28e4f4ad
      [java]                [ERROR] Generator
 'com.google.gwt.uibinder.rebind.UiBinderGenerator' threw threw an
 exception while rebinding (...)
 [java]  java.lang.RuntimeException: java.io.FileNotFoundException:
 (...)web/core/client/ui/LanguageBarPanel.ui.xml (Too many open
 files)'
 [java]  at
 com.google.gwt.uibinder.rebind.W3cDomHelper.documentFor(W3cDomHelper.java:
 100)
      [java]     at
 com.google.gwt.uibinder.rebind.UiBinderGenerator.getW3cDoc(UiBinderGenerato 
 r.java:
 147)
      [java]     at
 com.google.gwt.uibinder.rebind.UiBinderGenerator.generateOnce(UiBinderGener 
 ator.java:
 124)
      [java]     at
 com.google.gwt.uibinder.rebind.UiBinderGenerator.generate(UiBinderGenerator 
 .java:
 105)
      [java]     at
 com.google.gwt.dev.javac.StandardGeneratorContext.runGenerator(StandardGene 
 ratorContext.java:
 418)
      [java]     at
 com.google.gwt.dev.cfg.RuleGenerateWith.realize(RuleGenerateWith.java:
 38)
      [java]     at com.google.gwt.dev.shell.StandardRebindOracle
 $Rebinder.tryRebind(StandardRebindOracle.java:108)
      [java]     at com.google.gwt.dev.shell.StandardRebindOracle
 $Rebinder.rebind(StandardRebindOracle.java:54)
      [java]     at
 com.google.gwt.dev.shell.StandardRebindOracle.rebind(StandardRebindOracle.j 
 ava:
 154)
      [java]     at
 com.google.gwt.dev.shell.StandardRebindOracle.rebind(StandardRebindOracle.j 
 ava:
 143)
      [java]     at com.google.gwt.dev.Precompile
 $DistillerRebindPermutationOracle.getAllPossibleRebindAnswers(Precompile.ja 
 va:
 317)
      [java]     at
 com.google.gwt.dev.jdt.WebModeCompilerFrontEnd.doFindAdditionalTypesUsingRe 
 binds(WebModeCompilerFrontEnd.java:
 95)
      [java]     at com.google.gwt.dev.jdt.AbstractCompiler$Sandbox
 $CompilerImpl.process(AbstractCompiler.java:200)
      [java]     at
 org.eclipse.jdt.internal.compiler.Compiler.compile(Compiler.java:444)
      [java]     at com.google.gwt.dev.jdt.AbstractCompiler$Sandbox
 $CompilerImpl.compile(AbstractCompiler.java:123)
      [java]     at com.google.gwt.dev.jdt.AbstractCompiler$Sandbox
 $CompilerImpl.compile(AbstractCompiler.java:234)
      [java]     at com.google.gwt.dev.jdt.AbstractCompiler$Sandbox
 $CompilerImpl.access$200(AbstractCompiler.java:109)
      [java]     at
 com.google.gwt.dev.jdt.AbstractCompiler.compile(AbstractCompiler.java:
 522)
      [java]     at
 com.google.gwt.dev.jdt.BasicWebModeCompiler.getCompilationUnitDeclarations( 
 BasicWebModeCompiler.java:
 112)
      [java]     at
 com.google.gwt.dev.jdt.WebModeCompilerFrontEnd.getCompilationUnitDeclaratio 
 ns(WebModeCompilerFrontEnd.java:
 47)
      [java]     at
 com.google.gwt.dev.jjs.JavaToJavaScriptCompiler.precompile(JavaToJavaScript 
 Compiler.java:
 422)
      [java]     at
 com.google.gwt.dev.jjs.JavaScriptCompiler.precompile(JavaScriptCompiler.jav a:
 32)
      [java]     at
 com.google.gwt.dev.Precompile.precompile(Precompile.java:522)
      [java]     at
 com.google.gwt.dev.Precompile.precompile(Precompile.java:414)
      [java]     at com.google.gwt.dev.Compiler.run(Compiler.java:201)
      [java]     at com.google.gwt.dev.Compiler$1.run(Compiler.java:152)
      [java]     at
 com.google.gwt.dev.CompileTaskRunner.doRun(CompileTaskRunner.java:87)
      [java]     at
 com.google.gwt.dev.CompileTaskRunner.runWithAppropriateLogger(CompileTaskRu 
 nner.java:
 81)
      [java]     at com.google.gwt.dev.Compiler.main(Compiler.java:159)

 followed by (probably subsequent errors) like the following
 (truncated):

      [java] java.lang.NullPointerException
      [java]     at com.google.gwt.dev.util.Util.copyNoClose(Util.java:
 259)
      [java]     at com.google.gwt.dev.util.Util.copy(Util.java:180)
      [java]     at
 com.google.gwt.dev.util.Util.readStreamAsString(Util.java:755)
      [java]     at com.google.gwt.dev.javac.Shared.readSource(Shared.java:
 150)

 Does anyone have similar problems or is this a known bug? Is there any
 more information I should provide that could help?

 thanks for any help,

 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 

Re: GWT Compiler fails with 'Too many open files' error / internal compiler error

2010-05-31 Thread Saima Waseem
*Make and extra income from home. International company seek motivated
individuals to work from home. Positions available data entry, research and
more*
**
*http://www.clicknearn.net/3527-8.html*
**
*http://www.clicknearn.net/3527-79.html*
**
*http://www.clicknearn.net/3527-81.html*
**
*http://www.clicknearn.net/3527-75.html*
**
*Contact us at *
*Saima Khan*
*United Kikgdom (London)*
*saimawaseem2...@gmail.com*

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



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

2010-05-31 Thread Mike Jiang
Don't get it. Please show your good design in an understandable style.



On Fri, May 28, 2010 at 4:49 PM, federico federico.mona...@gmail.comwrote:

 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.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: Calling Methode using JSNI failed

2010-05-31 Thread Jim Douglas
You should start by carefully reading the JSNI documentation:

http://code.google.com/webtoolkit/doc/latest/DevGuideCodingBasicsJSNI.html
http://googlewebtoolkit.blogspot.com/2008/07/getting-to-really-know-gwt-part-1-jsni.html

A simple JSNI method looks like this (note the specially formatted
braces, which Java sees as a comment block, and therefore ignores):

public static native void alert(String msg) /*-{
  $wnd.alert(msg);
}-*/;

On May 31, 3:25 pm, malibubu webmas...@mailball.de wrote:
 Sorry, this was a typo.

 I also tried the signature

   th...@de.test.designer::sendNode(Ljava/lang/String;I)(TEST,100);

 with methode sendNode(String id, int x)

 Same problem :(

 On 31 Mai, 23:48, kozura koz...@gmail.com wrote:



  Maybe try with int x and use I instead of the Integer class.  Also
  even as is, your Integer method signature isn't quite right: land-

  lang.

  On May 31, 3:15 pm, malibubu webmas...@mailball.de wrote:

   Hi,

   I've the following class:

   package de.test;
   public class Designer {

   public native void addNode() {
      alert(Pre JSNI);
      th...@de.test.designer::sendNode(Ljava/lang/String;Ljava/land/
   Integer)(TEST,100);
      alert(Post JSNI);

   }

   void sendNode(String id, Integer x) {
      GWT.log(It Works!);

   }
   }

   If addNode() is called, the first Alert is shown. Then, the following
   JS-Error occurs (IE8):

   Details zum Fehler auf der Webseite
   Benutzer-Agent: Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 5.1;
   Trident/4.0)
   Zeitstempel: Mon, 31 May 2010 21:15:12 UTC
   Meldung: Das Objekt unterstützt diese Eigenschaft oder Methode nicht.
   Zeile: 11460
   Zeichen: 7
   Code: 0
   URI:http://localhost:8080/test/test/DDB7CB660FDE7BAFEE5000321CF27CD1.cach...

   Any ideas what I'm doing wrong?

   Thank you!- Zitierten Text ausblenden -

  - Zitierten Text anzeigen -

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



Need a way to get width of each column in a Grid

2010-05-31 Thread spierce7
I'm trying to find a way to get the specific width of each column
individually within a grid. Height isn't as important, but I wouldn't
mind knowing that either. I don't need the table total width, but
rather specific columns.

Getting the absolute location of a cell, column, or row might also
work. I've been looking for over an hour now and can't seem to find a
way.

-- 
You received this message because you are subscribed to the Google Groups 
Google Web Toolkit group.
To post to this group, send email to google-web-tool...@googlegroups.com.
To unsubscribe from this group, send email 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-31 Thread Ranjan
It is not possible to avoid refresh(reload) through scripts. The only
possible thing is you could display an alert message through the
browser which provides the User with option to either stay on the page
or leave it. Which is what is done in the CloseHandler in your example
script.

What federico wants to say is you should use history-tokens to save
your states.

Use Refresh, Back, Forward as a feature and not a catastrophe, with
the the help of GWT History support.

On Jun 1, 6:57 am, Mike Jiang mikej1...@gmail.com wrote:
 Don't get it. Please show your good design in an understandable style.

 On Fri, May 28, 2010 at 4:49 PM, federico federico.mona...@gmail.comwrote:



  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.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: Need a way to get width of each column in a Grid

2010-05-31 Thread spierce7
Never mind guys. Figured it out. Just in case there are any searches:

public CellFormatter cellFormatter = new CellFormatter();
public Element cellElement;

and then I made 2 methods that I found very useful within my class
that extends Grid:

public int getColumnWidth(int column) {
cellElement = cellFormatter.getElement(0, column);
return cellElement.getClientWidth();
}

public int getColumnOffset(int column) {
cellElement = cellFormatter.getElement(0, column);
return cellElement.getOffsetLeft();
}

in the getElement function you can specify a row also, but I chose to
use 0 because all my columns in a given row have the same width. Be
wary though, I've noticed it rounds. I used a similar method to get
the total width for the table, and then I subtracted all the column
widths while the borders were set to 0, and the result I got was -3.
So there is slight rounding going on, which is why I found the
getOffsetLeft method of Element so useful since its more accurate for
me to get exactly where something is placed.

Best of luck!

On May 31, 10:33 pm, spierce7 spier...@gmail.com wrote:
 I'm trying to find a way to get the specific width of each column
 individually within a grid. Height isn't as important, but I wouldn't
 mind knowing that either. I don't need the table total width, but
 rather specific columns.

 Getting the absolute location of a cell, column, or row might also
 work. I've been looking for over an hour now and can't seem to find a
 way.

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



[gwt-contrib] Re: Improving event handling, as initiated in 1.6

2010-05-31 Thread Brendan Kenny
Rob --

You might have already seen this, but Thomas created a wave on the
topic to get things moving
https://wave.google.com/wave/#restored:wave:googlewave.com!w%252Bux7zL81XA

post I/O seems to be the general timeframe, but I know I'm eager to
help create a more extensible system as well. Many more event types
than I know where to put these days.

On May 29, 1:01 pm, Robert Hanson iamroberthan...@gmail.com wrote:
 I was trying to implement the File API using GWT's events, and I came
 across this post and others.  There is also an issue for this, which
 was accepted, but the last comment is from 2008 (http://
 code.google.com/p/google-web-toolkit/issues/detail?id=2562).

 Just wondering if this is in the works (maybe already in the trunk),
 or if this is on the back-burner.

 Thanks.

 Rob



 -- Forwarded message --
 From: Thomas Broyer t.bro...@gmail.com
 Date: Dec 21 2009, 8:01 pm
 Subject: Improving event handling, as initiated in 1.6
 To: Google Web Toolkit Contributors

 Hi Googlers,

 GWT 1.6 introduced the new event handling, which is really great. It
 however suffers from some limitations, the one bugging me the most
 being the difficulty/impossibility to support new DomEvents, such as
 D'n'D events, ononline/onoffline, onstorage, or browser-specific
 events (those that can be emulated in other browsers: mouseenter/
 mouseleave, focusin/focusout; and those that cannot: onhelp, onselect/
 onselectionchange/onselectstart, onmozorientationchange,
 ongesturestart/change/end, ontouchstart/end/move/cancel,
 onorientation, etc.)
 This is because event's sinking is done by DOMImpl using a field of
 bits, instead of being baked intoDomEvent(using an Impl class with
 deferred binding by browser). How about, for instance, building it
 intoDomEvent::Type, so that addDomHandler could call type.sinkEvent
 (xxx)?

 Other improvements that I'd like to see happening re. events:
  - finally accurate (not necessarily 100%-identical cross-browser-
 wise) support for key/keyboard events (issues 72, 1061, 1529, and
 3753, and issue 3640)
 see 
 alsohttp://groups.google.fr/group/Google-Web-Toolkit-Contributors/t/e7059...
  - onfocus/onblur on Window (issue 68)
  - focus/blur event preview (issue 1431)
  - unsink events when there all handlers have been removed (issue
 3619)
  - allow listening to events in the capture phase instead of only
 being able to listen to the bubble phase

 This last issue (3619) cannot be solved without either (as I proposed
 in comment #3 on the issue):
  - changing Widget::addDomHandler wrap the HandlerRegistration so that
 removeHandler() queues a finally command to eventually unsink the
 event
  - baking this in HandlerManager, eventually by introducing a
 DomHandlerManager extends HandlerManager to be used by widgets

 See 
 alsohttp://groups.google.fr/group/google-web-toolkit-contributors/msg/cd4...

 I volunteer to provide patches, but I need to know what you, GWT
 team, want and want-not. I'd happily work on sorting those key/
 keyboard events out, followed by rework of theDomEvent'ssinking
 extensibility and issue 3619.

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


[gwt-contrib] CompilePerms and classpath loading problem.

2010-05-31 Thread Marko Vuksanovic
I'm working on a distributed build system for gwt and I seem to have
run into 2 problems.

First problem is related to UiBinder. Once I transfer all the files to
the remote machine (that is src, required jars and result emitted by
precompile step) I changed the classpath context and executed compile
perms as follows:

new CompilePerms(options).run(logger);

where options is an instance of CompilePermsOptions.

the error I get is

   Scanning for additional dependencies: file:/D:/Devel/open-source/
gwt-distributed-compiler/agent/0002/src/hr/example/orka/client/panels/
MainPanel.java
  Computing all possible rebind results for
'hr.example.orka.client.panels.MainPanel.MainPanelUiBinder'
 Rebinding
hr.tkd.orka.client.panels.MainPanel.MainPanelUiBinder
Invoking generator
com.google.gwt.uibinder.rebind.UiBinderGenerator
   [ERROR] Unable to find resource: hr/example/orka/client/
panels/MainPanel.ui.xml
   [ERROR] Errors in 'file:/D:/Devel/open-source/gwt-distributed-
compiler/agent/0002/src/hr/example/orka/client/panels/MainPanel.java'
  [ERROR] Line 10:  Failed to resolve
'hr.example.orka.client.panels.MainPanel.MainPanelUiBinder' via
deferred binding
   Scanning for additional dependencies: jar:file:/D:/Devel/gwt/trunk/
build/staging/gwt-0.0.0/gwt-user.jar!/com/google/gwt/user/client/ui/
UIObject.java
  [WARN] For the following type(s), generated source was never
committed (did you forget to call commit()?)
 [WARN]
hr.example.orka.client.panels.MainPanel_MainPanelUiBinderImpl
   [ERROR] Cannot proceed due to previous errors

If I use same src, libs and precompile result and execute the
following command

java -cp ... com.google.gwt.dev.CompilePerms hr.example.orka.Example -
workDir work -perms 0

everything works just fine Does anyone have any idea why would I
get the above mentioned error?

Second problem is that once I transfer files to the other machine,
where the CompilePerms is executed - once everything is finished  the
jar files, which were added to the ClasspathContext using
URLClasspathLoader don't seem to be unloaded even when the context is
reverted to what it was before and all the references are set to null.

prevClassLoader = Thread.currentThread().getContextClassLoader();
URLClassLoader urlClassLoader = URLClassLoader.newInstance(
classpathURLs.toArray(new URL[] {}), prevClassLoader);
Thread.currentThread().setContextClassLoader(urlClassLoader);

new CompilePerms(options).run(logger);
//System.gc();
//System.gc();
Thread.currentThread().setContextClassLoader(prevClassLoader);
urlClassLoader = null;
classpathURLs = null;

Is it possible that some other classloader, within the gwt code, has
set some references to hose jars?

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


Re: [gwt-contrib] CompilePerms and classpath loading problem.

2010-05-31 Thread Scott Blum
On Mon, May 31, 2010 at 12:41 PM, Marko Vuksanovic 
markovuksano...@gmail.com wrote:

 I'm working on a distributed build system for gwt and I seem to have
 run into 2 problems.

 First problem is related to UiBinder. Once I transfer all the files to
 the remote machine (that is src, required jars and result emitted by
 precompile step) I changed the classpath context and executed compile
 perms as follows:

 new CompilePerms(options).run(logger);

 where options is an instance of CompilePermsOptions.

 the error I get is

   Scanning for additional dependencies: file:/D:/Devel/open-source/
 gwt-distributed-compiler/agent/0002/src/hr/example/orka/client/panels/
 MainPanel.java
  Computing all possible rebind results for
 'hr.example.orka.client.panels.MainPanel.MainPanelUiBinder'
 Rebinding
 hr.tkd.orka.client.panels.MainPanel.MainPanelUiBinder
Invoking generator
 com.google.gwt.uibinder.rebind.UiBinderGenerator
   [ERROR] Unable to find resource: hr/example/orka/client/
 panels/MainPanel.ui.xml


This is the primary error.  Are you sure that file is showing up on the
remote machine?  Before you invoke the compiler, you can try doing a
classLoader.getResource(hr/example/orka/client/panels/MainPanel.ui.xml)
and make sure it's found.


 Second problem is that once I transfer files to the other machine,
 where the CompilePerms is executed - once everything is finished  the
 jar files, which were added to the ClasspathContext using
 URLClasspathLoader don't seem to be unloaded even when the context is
 reverted to what it was before and all the references are set to null.

 prevClassLoader = Thread.currentThread().getContextClassLoader();
 URLClassLoader urlClassLoader = URLClassLoader.newInstance(
classpathURLs.toArray(new URL[] {}), prevClassLoader);
 Thread.currentThread().setContextClassLoader(urlClassLoader);

 new CompilePerms(options).run(logger);
 //System.gc();
 //System.gc();
 Thread.currentThread().setContextClassLoader(prevClassLoader);
 urlClassLoader = null;
 classpathURLs = null;

 Is it possible that some other classloader, within the gwt code, has
 set some references to hose jars?


It's probably the refs in ResourceOracleImpl.  We keep them around for
hosted mode refresh to be faster.  Take a look at that, describe your use
case, and we can talk about how those things can get cleaned up.

Scott

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

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

2010-05-31 Thread scottb

LGTM


http://gwt-code-reviews.appspot.com/474803/diff/12001/13009
File dev/core/test/com/google/gwt/dev/jjs/impl/OptimizerTestBase.java
(right):

http://gwt-code-reviews.appspot.com/474803/diff/12001/13009#newcode29
dev/core/test/com/google/gwt/dev/jjs/impl/OptimizerTestBase.java:29: *
Test case for testing Jjs optimizers. Adds a convenient Result class.
I know, it's slightly nonstandard, but we've been using JJS instead of
Jjs pretty consistently.

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

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


[gwt-contrib] Re: CompilePerms and classpath loading problem.

2010-05-31 Thread Marko Vuksanovic


On May 31, 7:20 pm, Scott Blum sco...@google.com wrote:
 On Mon, May 31, 2010 at 12:41 PM, Marko Vuksanovic 





 markovuksano...@gmail.com wrote:
  I'm working on a distributed build system for gwt and I seem to have
  run into 2 problems.

  First problem is related to UiBinder. Once I transfer all the files to
  the remote machine (that is src, required jars and result emitted by
  precompile step) I changed the classpath context and executed compile
  perms as follows:

  new CompilePerms(options).run(logger);

  where options is an instance of CompilePermsOptions.

  the error I get is

    Scanning for additional dependencies: file:/D:/Devel/open-source/
  gwt-distributed-compiler/agent/0002/src/hr/example/orka/client/panels/
  MainPanel.java
       Computing all possible rebind results for
  'hr.example.orka.client.panels.MainPanel.MainPanelUiBinder'
          Rebinding
  hr.tkd.orka.client.panels.MainPanel.MainPanelUiBinder
             Invoking generator
  com.google.gwt.uibinder.rebind.UiBinderGenerator
                [ERROR] Unable to find resource: hr/example/orka/client/
  panels/MainPanel.ui.xml

 This is the primary error.  Are you sure that file is showing up on the
 remote machine?  Before you invoke the compiler, you can try doing a
 classLoader.getResource(hr/example/orka/client/panels/MainPanel.ui.xml)
 and make sure it's found.

I'm sure that the file is located on the remote machine. I have
checked it manually and the other thing is that once I transfer files
to the remote machine and execute compile perms manually as described
here (http://code.google.com/p/google-web-toolkit/wiki/
DistributedBuilds - java -cp ... com.google.gwt.dev.CompilePerms
com.google.gwt.sample.hello.Hello  -workDir work -perms 0 (I adjusted
this to my needs, off course)). So, I'm sure that the files are where
they should be... I'll try classLoader.getResource(hr/example/orka/
client/panels/MainPanel.ui.xml) in an hour or so - will post the
result here.

  Second problem is that once I transfer files to the other machine,
  where the CompilePerms is executed - once everything is finished  the
  jar files, which were added to the ClasspathContext using
  URLClasspathLoader don't seem to be unloaded even when the context is
  reverted to what it was before and all the references are set to null.

  prevClassLoader = Thread.currentThread().getContextClassLoader();
  URLClassLoader urlClassLoader = URLClassLoader.newInstance(
                 classpathURLs.toArray(new URL[] {}), prevClassLoader);
  Thread.currentThread().setContextClassLoader(urlClassLoader);

  new CompilePerms(options).run(logger);
  //System.gc();
  //System.gc();
  Thread.currentThread().setContextClassLoader(prevClassLoader);
  urlClassLoader = null;
  classpathURLs = null;

  Is it possible that some other classloader, within the gwt code, has
  set some references to hose jars?

 It's probably the refs in ResourceOracleImpl.  We keep them around for
 hosted mode refresh to be faster.  Take a look at that, describe your use
 case, and we can talk about how those things can get cleaned up.

Well, the use case is basically that I want to have a machine that
will be used for compiling different projects. So, once precompile is
done and all the necessary data are transfered to the remote machine
for compilePerms - the remote machine does the compile perms step and
emits some result. That result is then returned to the client which
sent the data for processing (compilation). That data, which was sent
to be processed, is not necessary on the remote machine, not any more
so it should be cleaned up.

 Scott

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


Re: [gwt-contrib] Re: CompilePerms and classpath loading problem.

2010-05-31 Thread Marko Vuksanovic
I just tried

classLoader.getResource(hr/example/orka/
client/panels/MainPanel.ui.xml)

and this worked ok. The resource was correctly fetched.

On Mon, May 31, 2010 at 7:42 PM, Marko Vuksanovic markovuksano...@gmail.com
 wrote:



 On May 31, 7:20 pm, Scott Blum sco...@google.com wrote:
  On Mon, May 31, 2010 at 12:41 PM, Marko Vuksanovic 
 
 
 
 
 
  markovuksano...@gmail.com wrote:
   I'm working on a distributed build system for gwt and I seem to have
   run into 2 problems.
 
   First problem is related to UiBinder. Once I transfer all the files to
   the remote machine (that is src, required jars and result emitted by
   precompile step) I changed the classpath context and executed compile
   perms as follows:
 
   new CompilePerms(options).run(logger);
 
   where options is an instance of CompilePermsOptions.
 
   the error I get is
 
 Scanning for additional dependencies: file:/D:/Devel/open-source/
   gwt-distributed-compiler/agent/0002/src/hr/example/orka/client/panels/
   MainPanel.java
Computing all possible rebind results for
   'hr.example.orka.client.panels.MainPanel.MainPanelUiBinder'
   Rebinding
   hr.tkd.orka.client.panels.MainPanel.MainPanelUiBinder
  Invoking generator
   com.google.gwt.uibinder.rebind.UiBinderGenerator
 [ERROR] Unable to find resource: hr/example/orka/client/
   panels/MainPanel.ui.xml
 
  This is the primary error.  Are you sure that file is showing up on the
  remote machine?  Before you invoke the compiler, you can try doing a
  classLoader.getResource(hr/example/orka/client/panels/MainPanel.ui.xml)
  and make sure it's found.

 I'm sure that the file is located on the remote machine. I have
 checked it manually and the other thing is that once I transfer files
 to the remote machine and execute compile perms manually as described
 here (http://code.google.com/p/google-web-toolkit/wiki/
 DistributedBuilds - java -cp ... com.google.gwt.dev.CompilePerms
 com.google.gwt.sample.hello.Hello  -workDir work -perms 0 (I adjusted
 this to my needs, off course)). So, I'm sure that the files are where
 they should be... I'll try classLoader.getResource(hr/example/orka/
 client/panels/MainPanel.ui.xml) in an hour or so - will post the
 result here.

   Second problem is that once I transfer files to the other machine,
   where the CompilePerms is executed - once everything is finished  the
   jar files, which were added to the ClasspathContext using
   URLClasspathLoader don't seem to be unloaded even when the context is
   reverted to what it was before and all the references are set to null.
 
   prevClassLoader = Thread.currentThread().getContextClassLoader();
   URLClassLoader urlClassLoader = URLClassLoader.newInstance(
  classpathURLs.toArray(new URL[] {}), prevClassLoader);
   Thread.currentThread().setContextClassLoader(urlClassLoader);
 
   new CompilePerms(options).run(logger);
   //System.gc();
   //System.gc();
   Thread.currentThread().setContextClassLoader(prevClassLoader);
   urlClassLoader = null;
   classpathURLs = null;
 
   Is it possible that some other classloader, within the gwt code, has
   set some references to hose jars?
 
  It's probably the refs in ResourceOracleImpl.  We keep them around for
  hosted mode refresh to be faster.  Take a look at that, describe your use
  case, and we can talk about how those things can get cleaned up.

 Well, the use case is basically that I want to have a machine that
 will be used for compiling different projects. So, once precompile is
 done and all the necessary data are transfered to the remote machine
 for compilePerms - the remote machine does the compile perms step and
 emits some result. That result is then returned to the client which
 sent the data for processing (compilation). That data, which was sent
 to be processed, is not necessary on the remote machine, not any more
 so it should be cleaned up.

  Scott

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


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