Register your company if you are using GWT

2012-03-14 Thread Kanagaraj M
If you are using GWT for your projects/products, please register it in the 
following link. so that we can see how many are using GWT.

http://gwtreferencelist.appspot.com/  

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



Re: iframe change listener?

2012-03-14 Thread ThomasDalla
Hi,

Why not using the LoadHandler:

Frame f = new Frame();
f.addLoadHandler(new LoadHandler() {

@Override
public void onLoad(LoadEvent event) {
_logger.info("LoadEvent: " + event.toString() + "\n" + 
 "New URL: " + f.getUrl() + "\n" + 
 "Relative Element: " + 
event.getRelativeElement());
}

});

It doesn't catch the POST parameters, but JS doesn't neither, isn't it?

Cheers,

Thomas

On Wednesday, 16 January 2008 06:21:06 UTC+9, aarnott wrote:
>
> I would like my application to include an iframe and I would like to 
> be able to detect when a link has been clicked in that iframe (and 
> also get information about the new page).  For example, supposing the 
> iframe points to http://code.google.com/webtoolkit/, I would like to 
> be able to detect when the user clicks a link and then be able to read 
> the new page and make the text between the  tags be the content 
> in a lower panel of my application. 
>
> To set the iframe, I am using the following lines of code: 
>
> HTML data = new HTML(""); 
> panel.add(data); 
>
> where URL is the url of the page. 
>
> I have tried using a click listener: 
>
> data.addClickListener(new ClickListener (){ 
>
> public void onClick(Widget w) { 
> System.out.print("click"); 
> } 
> }); 
>
> But nothing is printed to the console.  How can I make this work?  Am 
> I using the correct approach? 
>
> Thanks, 
>
> Andrew


On Wednesday, 16 January 2008 06:21:06 UTC+9, aarnott wrote:
>
> I would like my application to include an iframe and I would like to 
> be able to detect when a link has been clicked in that iframe (and 
> also get information about the new page).  For example, supposing the 
> iframe points to http://code.google.com/webtoolkit/, I would like to 
> be able to detect when the user clicks a link and then be able to read 
> the new page and make the text between the  tags be the content 
> in a lower panel of my application. 
>
> To set the iframe, I am using the following lines of code: 
>
> HTML data = new HTML(""); 
> panel.add(data); 
>
> where URL is the url of the page. 
>
> I have tried using a click listener: 
>
> data.addClickListener(new ClickListener (){ 
>
> public void onClick(Widget w) { 
> System.out.print("click"); 
> } 
> }); 
>
> But nothing is printed to the console.  How can I make this work?  Am 
> I using the correct approach? 
>
> Thanks, 
>
> Andrew

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



Re: Performance GWT-RPC, JavaScript Overlays, RequestFactory etc.

2012-03-14 Thread Elizabeth Lemon
Thanks so much for replying!

I read that JavaScriptObjects are an opaque handle in the javadoc
http://google-web-toolkit.googlecode.com/svn/javadoc/1.6/com/google/gwt/core/client/JavaScriptObject.html

When you mentioned how server side performance is different, is it
because of the protocol used to marshall and unmarshall the data once
it arrives on the server?

You mentioned that the DOM is much more of an issue? In what sense?
And how does one go about optimizing for this?

I always believed that gwt's deserialization via gwtrpc back into the
client side was the bottleneck.  Which is why I began to consider
other options such as JavaScript Overlay Types.  But then again, I
guess forgot that I would have to manage the JSON (or turn them into
POJOs, the advantage of GWTRPC you were speaking of I assume?) on the
server as well.  I suppose the plus side to this is that there is very
little deserialization that is needed to be done on the client side.

Would I be correct in saying that, since I can't change the speed of
my client's computer, I should place the deserialization/serialization
work on the server (which I could always allocate more resources for?

I guess really I'm looking for bottlenecks or an architecture that
would give great scalability~

On Mar 14, 3:43 pm, Thomas Broyer  wrote:
> On Wednesday, March 14, 2012 4:35:27 PM UTC+1, Elizabeth Lemon wrote:
> > Hello everyone,
> > I have been looking around for a really long time now on these client-
> > server communication strategies and have had a difficult time choosing
> > the right approach for my application.  It also doesn't help that I
> > don't have a very strong background on server sided coding :P
>
> > In any case, I am trying to find the approach that would give the best
> > performance on the client-side.
>
> > I know that GWT-RPC uses it's own protocol to get you to the server
> > side.  It is built on top of RequestBuilder and converts your data
> > into a content-type of (what I read was) text/plain.  From here, it
> > will reconstruct your java object onto the servlet.
>
> > JavaScript Overlays says that it has no overhead.
>
> > RequestFactory is supposed to be even faster than GWT-RPC.  No
> > serialization is required, but apparently deserialization is.
>
> > Upon these, there is the old RequestBuilder with a JSONParser.
>
> > I want to minimize the amount of time it takes for the client to
> > deserialize it's data with a balance of data size.
>
> > My objects aren't too deep.  At most, an object would contain a couple
> > of strings, and two arraylists of 100 objects than contain a couple of
> > other strings.
>
> > But if I can avoid the deserialization part (where I believe most of
> > the response time is being consumed by) by a simple eval on a JSON or
> > something, that would be great.
>
> > Other notes: I have flexibility in what server I can use.  However,
> > eventually I would like to make web services for non-gwt platforms,
> > though I feel like I could reuse the same business logic and use a
> > different entry point to the service.
> > QUESTIONS:
> > 1. What does it mean for JavaScript Overlays to have no overhead?
>
> JSOs are a way of coding in Java against JavaScript objects. The JSO class is 
> a shim that get totally compiled out: no overhead, no wrapping of the JS 
> object.
>
> > 2. Which one would you say is fastest in terms of client side
> > performance?
>
> Most probably JSOs, with JsonUtils for parsing.
> Next I'd say AutoBeans, then RF, then RPC.
> Note that server side performance is different: the rpc protocol is much 
> simpler than RF, so it's faster.
>
> > 3. What does it mean that JavaScriptObjects are Opaque?
>
> Where did you read that?!
>
> > 4. Since JavaScript Overlays describe us extending JavaScriptObjects,
> > does that mean converting it to a JSON requires less (or even zero)
> > time than would GWT-RPC?
>
> Yes.
> Most browsers can do JSON.stringify(), for others you'd have to use 
> JSONObject.toString(), which has a small overhead.
>
>
>
> > Thank you so much for your input~
>
> Choose what works best for you (in terms of protocol), not necessarily the 
> fastest. These won't be the bottleneck of your app's performance, DOM is much 
> more of an issue (and of course the network and the server)
>
>
>
>
>
>
>
> On Wednesday, March 14, 2012 4:35:27 PM UTC+1, Elizabeth Lemon wrote:
> > Hello everyone,
> > I have been looking around for a really long time now on these client-
> > server communication strategies and have had a difficult time choosing
> > the right approach for my application.  It also doesn't help that I
> > don't have a very strong background on server sided coding :P
>
> > In any case, I am trying to find the approach that would give the best
> > performance on the client-side.
>
> > I know that GWT-RPC uses it's own protocol to get you to the server
> > side.  It is built on top of RequestBuilder and converts your data
> > into a content-type of (what I read was) te

Requestfactory and CellBrowser Context Problem

2012-03-14 Thread jmbz84
Hello,

I'm trying to use gwt CellBrowser and RequestFactory to show some
stored data as Cells in the cellbrowser. But I can't do it because of
the context of requestfactory.


Any Ideas ?

class CustomTreeModel implements TreeViewModel {
{
...
..
...

List composerproxy = new ArrayList();

private void setComposer() {
testRequestFactory = GWT.create(TestRequestFactory.class);
testRequestFactory.initialize(new SimpleEventBus());

request.getQuery("select a from Composer a").fire(
new Receiver>() {

@Override
public void 
onSuccess(List arg0) {
//Here Is my problem, How
can I transfer the value of arg0 to composerproxy in order to use it
on my CellBrowser ()
   // Tried with a for() to
insert each ComposerProxy individually  and with a separate method
insertcomposerproxy(arg0) but didnt work
composerproxy=arg0;

}
});

}

}

public  NodeInfo getNodeInfo(T value) {

if (value == null) {

setComposer();

 // LEVEL 0.
// We passed null as the root value. Return the 
composers.
// Create a data provider that contains the list of 
composers.

//HERE IS MY PROBLEM. The composerproxy
variable is empty.

ListDataProvider dataProvider = new
ListDataProvider(
composerproxy);



// Create a cell to display a composer.
Cell cell = new 
AbstractCell() {
@Override
public void render(Context context, 
ComposerProxy value,
SafeHtmlBuilder sb) {
if (value != null) {

sb.appendEscaped(value.getName());
}
}
};
// Return a node info that pairs the data provider and 
the cell.
return new DefaultNodeInfo(dataProvider, 
cell);
}
..
.
.
.

}



PD: The getQuery() function works fine and the arg0 variable has data.

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



Re: Performance GWT-RPC, JavaScript Overlays, RequestFactory etc.

2012-03-14 Thread Thomas Broyer
On Wednesday, March 14, 2012 4:35:27 PM UTC+1, Elizabeth Lemon wrote:
> Hello everyone,
> I have been looking around for a really long time now on these client-
> server communication strategies and have had a difficult time choosing
> the right approach for my application.  It also doesn't help that I
> don't have a very strong background on server sided coding :P
> 
> In any case, I am trying to find the approach that would give the best
> performance on the client-side.
> 
> I know that GWT-RPC uses it's own protocol to get you to the server
> side.  It is built on top of RequestBuilder and converts your data
> into a content-type of (what I read was) text/plain.  From here, it
> will reconstruct your java object onto the servlet.
> 
> JavaScript Overlays says that it has no overhead.
> 
> RequestFactory is supposed to be even faster than GWT-RPC.  No
> serialization is required, but apparently deserialization is.
> 
> Upon these, there is the old RequestBuilder with a JSONParser.
> 
> I want to minimize the amount of time it takes for the client to
> deserialize it's data with a balance of data size.
> 
> My objects aren't too deep.  At most, an object would contain a couple
> of strings, and two arraylists of 100 objects than contain a couple of
> other strings.
> 
> But if I can avoid the deserialization part (where I believe most of
> the response time is being consumed by) by a simple eval on a JSON or
> something, that would be great.
> 
> Other notes: I have flexibility in what server I can use.  However,
> eventually I would like to make web services for non-gwt platforms,
> though I feel like I could reuse the same business logic and use a
> different entry point to the service.
> QUESTIONS:
> 1. What does it mean for JavaScript Overlays to have no overhead?

JSOs are a way of coding in Java against JavaScript objects. The JSO class is a 
shim that get totally compiled out: no overhead, no wrapping of the JS object.

> 2. Which one would you say is fastest in terms of client side
> performance?

Most probably JSOs, with JsonUtils for parsing.
Next I'd say AutoBeans, then RF, then RPC.
Note that server side performance is different: the rpc protocol is much 
simpler than RF, so it's faster.

> 3. What does it mean that JavaScriptObjects are Opaque?

Where did you read that?!

> 4. Since JavaScript Overlays describe us extending JavaScriptObjects,
> does that mean converting it to a JSON requires less (or even zero)
> time than would GWT-RPC?

Yes.
Most browsers can do JSON.stringify(), for others you'd have to use 
JSONObject.toString(), which has a small overhead.

> 
> Thank you so much for your input~

Choose what works best for you (in terms of protocol), not necessarily the 
fastest. These won't be the bottleneck of your app's performance, DOM is much 
more of an issue (and of course the network and the server)


On Wednesday, March 14, 2012 4:35:27 PM UTC+1, Elizabeth Lemon wrote:
> Hello everyone,
> I have been looking around for a really long time now on these client-
> server communication strategies and have had a difficult time choosing
> the right approach for my application.  It also doesn't help that I
> don't have a very strong background on server sided coding :P
> 
> In any case, I am trying to find the approach that would give the best
> performance on the client-side.
> 
> I know that GWT-RPC uses it's own protocol to get you to the server
> side.  It is built on top of RequestBuilder and converts your data
> into a content-type of (what I read was) text/plain.  From here, it
> will reconstruct your java object onto the servlet.
> 
> JavaScript Overlays says that it has no overhead.
> 
> RequestFactory is supposed to be even faster than GWT-RPC.  No
> serialization is required, but apparently deserialization is.
> 
> Upon these, there is the old RequestBuilder with a JSONParser.
> 
> I want to minimize the amount of time it takes for the client to
> deserialize it's data with a balance of data size.
> 
> My objects aren't too deep.  At most, an object would contain a couple
> of strings, and two arraylists of 100 objects than contain a couple of
> other strings.
> 
> But if I can avoid the deserialization part (where I believe most of
> the response time is being consumed by) by a simple eval on a JSON or
> something, that would be great.
> 
> Other notes: I have flexibility in what server I can use.  However,
> eventually I would like to make web services for non-gwt platforms,
> though I feel like I could reuse the same business logic and use a
> different entry point to the service.
> QUESTIONS:
> 1. What does it mean for JavaScript Overlays to have no overhead?
> 2. Which one would you say is fastest in terms of client side
> performance?
> 3. What does it mean that JavaScriptObjects are Opaque?
> 4. Since JavaScript Overlays describe us extending JavaScriptObjects,
> does that mean converting it to a JSON requires less (or even zero)
> time than would GWT-RPC?
> 
> Thank 

Performance GWT-RPC, JavaScript Overlays, RequestFactory etc.

2012-03-14 Thread Elizabeth Lemon
Hello everyone,
I have been looking around for a really long time now on these client-
server communication strategies and have had a difficult time choosing
the right approach for my application.  It also doesn't help that I
don't have a very strong background on server sided coding :P

In any case, I am trying to find the approach that would give the best
performance on the client-side.

I know that GWT-RPC uses it's own protocol to get you to the server
side.  It is built on top of RequestBuilder and converts your data
into a content-type of (what I read was) text/plain.  From here, it
will reconstruct your java object onto the servlet.

JavaScript Overlays says that it has no overhead.

RequestFactory is supposed to be even faster than GWT-RPC.  No
serialization is required, but apparently deserialization is.

Upon these, there is the old RequestBuilder with a JSONParser.

I want to minimize the amount of time it takes for the client to
deserialize it's data with a balance of data size.

My objects aren't too deep.  At most, an object would contain a couple
of strings, and two arraylists of 100 objects than contain a couple of
other strings.

But if I can avoid the deserialization part (where I believe most of
the response time is being consumed by) by a simple eval on a JSON or
something, that would be great.

Other notes: I have flexibility in what server I can use.  However,
eventually I would like to make web services for non-gwt platforms,
though I feel like I could reuse the same business logic and use a
different entry point to the service.
QUESTIONS:
1. What does it mean for JavaScript Overlays to have no overhead?
2. Which one would you say is fastest in terms of client side
performance?
3. What does it mean that JavaScriptObjects are Opaque?
4. Since JavaScript Overlays describe us extending JavaScriptObjects,
does that mean converting it to a JSON requires less (or even zero)
time than would GWT-RPC?

Thank you so much for your input~

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



Re: how to link with page in gwt without update history stack?

2012-03-14 Thread Jens
I think its only possible if you do the scrolling yourself and do not rely 
on the  tag.

You can probably do something like (untested):

anchor.addClickHandler(new ClickHandler() {
  public void onClick(ClickEvent event) {
Widget jumpTo = getWidgetYouWantToScrollTo();
jumpTo.getElement().scrollIntoView(); //Version 1

scrollPanel.setVerticalScrollPosition(jumpTo.getElement().getOffsetTop()); 
//Version 2
Window.scrollTo(0, jumpTo.getElement().getOffsetTop()); //Version 3
  }
});



-- J.

Am Dienstag, 13. März 2012 22:29:14 UTC+1 schrieb mars:
>
> hi, 
>
> my gwt page has link within itself, like normal html page 
> B 
> point to 
>   
> B 
>
> within the same page, but i don't want to update the 
> history stack by appending '#b' to the end of url. how can 
> i do that? I used anchor instead of hyperlink. 
>
> thanks. 
>

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



Re: how to link with page in gwt without update history stack?

2012-03-14 Thread dodo dard
I don't know if we can do that, because when one click on a link, browser 
native implementation is  to update history stack. It doesn't go through 
GWT.



www.html5bydemo.com


Le mardi 13 mars 2012 22:29:14 UTC+1, mars a écrit :
>
> hi, 
>
> my gwt page has link within itself, like normal html page 
> B 
> point to 
>   
> B 
>
> within the same page, but i don't want to update the 
> history stack by appending '#b' to the end of url. how can 
> i do that? I used anchor instead of hyperlink. 
>
> thanks. 
>

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



Re: GWT and Google Maps Version 3

2012-03-14 Thread nandy
Hi,

I find that most demos don't seem to work on IE9.

On Feb 14, 7:30 pm, Joseph Lust  wrote:
> The lack of deprecated V3 is maddening for GWT and Maps V3. Check out
> the below. It is the only one I know of.
>
> There is a nearly finalized V3 API on 
> googlecodehttp://code.google.com/p/gwt-maps-api/
> . It has every facet of the JS API and is fully functional right now.
> I'm using it without issue. Feel free to check it out of SVN and build
> it.
>
> Joe
>
> On Feb 14, 5:20 am, andrew  wrote:
>
>
>
> > I currently use GWT Maps API 1.1 in our GWT APP and I'd like to update
> > it to use the Google Maps API Version 3.
>
> > Is there a supported, not deprecated, library for GWT to use Google
> > Maps API V3?
>
> > gwt-google-maps-v3
> > ===http://code.google.com/p/gwt-google-maps-v3/
> > Only one committer. Seems abandoned.
> > Latest downloadable JAR is from May 2010.
> > Not compiled for GWT > 2.2 and so fails on latest GWT2.4 (someone
> > posted a new version)
> > Says "This project will soon be merged into gwt-google-apis and hence
> > is depricated", but that comment could be pretty old by now.
>
> > gwt-google-apis
> > ===http://code.google.com/p/gwt-google-apis/
> > Would seem to be the official and logical place to look.
> > But it states: "At the present time, the gwt-maps API only supports
> > Google Maps API version 2."
> > and the Libraries for GWT versions 1.0 and 1.1 (uses GMaps API V2) are
> > both listed as deprecated.
> > Release Notes (1.10) was last updated on May 2010.
>
> > I was convinded this would be the place to find it, and searched but
> > with no luck. Am I missing something?
>
> > I also found:
>
> > gwt-maps3
> > http://code.google.com/p/gwt-maps3/
> > This  seems more up-to-date than gwt-google-maps-v3 and, but less
> > extensive and not Google "approved"?
>
> > If I'm going to rewrite for a new API, I'd like it to be the
> > "definitive", if possible Google sanctioned one, and not face another
> > re-write shortly after.
>
> > Thanks for any help.

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



Re: GWT and Google Maps Version 3

2012-03-14 Thread nandy
Hi,

I find that most demos don't seem to work on IE9.

On Feb 14, 7:30 pm, Joseph Lust  wrote:
> The lack of deprecated V3 is maddening for GWT and Maps V3. Check out
> the below. It is the only one I know of.
>
> There is a nearly finalized V3 API on 
> googlecodehttp://code.google.com/p/gwt-maps-api/
> . It has every facet of the JS API and is fully functional right now.
> I'm using it without issue. Feel free to check it out of SVN and build
> it.
>
> Joe
>
> On Feb 14, 5:20 am, andrew  wrote:
>
>
>
> > I currently use GWT Maps API 1.1 in our GWT APP and I'd like to update
> > it to use the Google Maps API Version 3.
>
> > Is there a supported, not deprecated, library for GWT to use Google
> > Maps API V3?
>
> > gwt-google-maps-v3
> > ===http://code.google.com/p/gwt-google-maps-v3/
> > Only one committer. Seems abandoned.
> > Latest downloadable JAR is from May 2010.
> > Not compiled for GWT > 2.2 and so fails on latest GWT2.4 (someone
> > posted a new version)
> > Says "This project will soon be merged into gwt-google-apis and hence
> > is depricated", but that comment could be pretty old by now.
>
> > gwt-google-apis
> > ===http://code.google.com/p/gwt-google-apis/
> > Would seem to be the official and logical place to look.
> > But it states: "At the present time, the gwt-maps API only supports
> > Google Maps API version 2."
> > and the Libraries for GWT versions 1.0 and 1.1 (uses GMaps API V2) are
> > both listed as deprecated.
> > Release Notes (1.10) was last updated on May 2010.
>
> > I was convinded this would be the place to find it, and searched but
> > with no luck. Am I missing something?
>
> > I also found:
>
> > gwt-maps3
> > http://code.google.com/p/gwt-maps3/
> > This  seems more up-to-date than gwt-google-maps-v3 and, but less
> > extensive and not Google "approved"?
>
> > If I'm going to rewrite for a new API, I'd like it to be the
> > "definitive", if possible Google sanctioned one, and not face another
> > re-write shortly after.
>
> > Thanks for any help.

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



Re: File download and Exception handling using a servlet.

2012-03-14 Thread George Georgovassilis
Hi Albert,

The way I did this is by reading SubmitCompleteEvent.getResults(), i.e.

uploadForm.addSubmitCompleteHandler(new SubmitCompleteHandler() {
public void onSubmitComplete(SubmitCompleteEvent event) {
 if (event.getResults().contains("SizeException")
 Window.alert("Data entry over limit");
}
}

You would just have to make sure that the servlet which handles the upload 
generates some meaningful, machine readable output which you can parse on 
the client


On Monday, March 12, 2012 12:19:29 PM UTC+2, Appien wrote:
>
> Hi guys,
>
> In my GWT application the user can download a PDF file by using a servlet. 
> To start the download I create in GWT a hidden Frame Object which calls the 
> servlet. The happy workflow path works great however I want give the user 
> some feedback when generating the PDF file fails. Since the result of the 
> servlet call gets ‘printed’ in the Frame object, the printed exception also 
> appears in the hidden Frame and not e.g. by a popup for the user.
>
> Unfortunately I don’t see a way so the servlet throws directly exceptions 
> to the AsyncCallback of GWT.
>
> I’ve the following pseudo code for handling my exception. 
>
> My questions are the following: 
> - Is this the right way to do exception handling for servlet exceptions 
> in GWT?
> - If not, which approach should I use for this?
>
> Many thanks for all the help!
>
> Albert
>
>

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



Meetup in Helsinki?

2012-03-14 Thread George Georgovassilis
I'll be in Helsinki Sat-Mon, if anybody wants to catch up over a beer
or whatever it is you northerners consume that'd be great.

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



Re: File download and Exception handling using a servlet.

2012-03-14 Thread dodo dard
Well I found something interesting related to this.

Try to look at this.
https://groups.google.com/forum/?fromgroups#!topic/google-web-toolkit/5TePQVFsSfg
 


=
www.html5bydemo.com

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



gwt,mysql and hibernate.

2012-03-14 Thread vijay
i am new to gwt and hibernate.. and i am doing a project with
gwt,mysql and hibernate please help me with some  example project..

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



GWT compatible serialization techniques

2012-03-14 Thread Kolv
Hi,

I understand that GWT (2.4) implements serialization through isSerializable 
and Serializable. I was wondering if any third party packages could be used 
that advertise faster Java serialization?

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



Passing multiple params to my Presenter

2012-03-14 Thread Will Tan
In my MainPagePresenter I have 2 fields that I would like to pass to
my response presenter, however, I am not sure how to play with the
".with". Please help.

placeManager.revealPlace(new 
PlaceRequest(NameTokens.response).with(
ResponsePresenter.usernameParam, username));

Thanks,

lwt

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



Re: RequestFactory, ServiceLocator and Spring

2012-03-14 Thread Kay Roesler
never mind...

I moved my locator class from client package to server and therethere,
it worked.

sry for spam

On Wed, Mar 14, 2012 at 11:16 AM, kayser  wrote:
> Hi,
>
> I followed an example in this list on how to use a spring bean via
> ServiceLocator. Everything works great using mvn gwt:debug but when I
> try to package everything using mvn package I get compiler errors.
> Here is my code:
>
> import javax.servlet.http.HttpServletRequest;
> import org.springframework.context.ApplicationContext;
> import
> org.springframework.web.context.support.WebApplicationContextUtils;
>
> import
> com.google.web.bindery.requestfactory.server.RequestFactoryServlet;
> import com.google.web.bindery.requestfactory.shared.ServiceLocator;
>
>
> public class EndpointConnectorServiceLocator implements ServiceLocator
> {
>
>        /* (non-Javadoc)
>         * @see
> com.google.web.bindery.requestfactory.shared.ServiceLocator#getInstance(java.lang.Class)
>         */
>        @Override
>        public Object getInstance(Class clazz) {
>
>                HttpServletRequest request =
> RequestFactoryServlet.getThreadLocalRequest();
>                ApplicationContext context =
> WebApplicationContextUtils.getWebApplicationContext(request.getSession().getServletContext());
>                return context.getBean("endpointConnectorService");
>        }
>
> }
>
>
>
> and the mvn message when hitting the error:
>
>
> [INFO]    [ERROR] An internal compiler exception occurred
> [INFO] com.google.gwt.dev.jjs.InternalCompilerException: Failed to get
> JNode
> [INFO]  at com.google.gwt.dev.jjs.impl.TypeMap.get(TypeMap.java:140)
> [INFO]  at com.google.gwt.dev.jjs.impl.TypeMap.get(TypeMap.java:71)
> [INFO]  at
> com.google.gwt.dev.jjs.impl.BuildTypeMap.getType(BuildTypeMap.java:
> 730)
> [INFO]  at com.google.gwt.dev.jjs.impl.BuildTypeMap.access
> $000(BuildTypeMap.java:99)
> [INFO]  at com.google.gwt.dev.jjs.impl.BuildTypeMap
> $BuildDeclMapVisitor.visit(BuildTypeMap.java:195)
> [INFO]  at
> org.eclipse.jdt.internal.compiler.ast.LocalDeclaration.traverse(LocalDeclaration.java:
> 237)
> [INFO]  at
> org.eclipse.jdt.internal.compiler.ast.MethodDeclaration.traverse(MethodDeclaration.java:
> 239)
> [INFO]  at
> org.eclipse.jdt.internal.compiler.ast.TypeDeclaration.traverse(TypeDeclaration.java:
> 1239)
> [INFO]  at
> org.eclipse.jdt.internal.compiler.ast.CompilationUnitDeclaration.traverse(CompilationUnitDeclaration.java:
> 687)
> [INFO]  at
> com.google.gwt.dev.jjs.impl.BuildTypeMap.createPeersForNonTypeDecls(BuildTypeMap.java:
> 637)
> [INFO]  at
> com.google.gwt.dev.jjs.impl.BuildTypeMap.exec(BuildTypeMap.java:514)
> [INFO]  at
> com.google.gwt.dev.jjs.impl.BuildTypeMap.exec(BuildTypeMap.java:523)
> [INFO]  at
> com.google.gwt.dev.jjs.JavaToJavaScriptCompiler.precompile(JavaToJavaScriptCompiler.java:
> 599)
> [INFO]  at
> com.google.gwt.dev.jjs.JavaScriptCompiler.precompile(JavaScriptCompiler.java:
> 33)
> [INFO]  at com.google.gwt.dev.Precompile.precompile(Precompile.java:
> 284)
> [INFO]  at com.google.gwt.dev.Precompile.precompile(Precompile.java:
> 233)
> [INFO]  at com.google.gwt.dev.Precompile.precompile(Precompile.java:
> 145)
> [INFO]  at com.google.gwt.dev.Compiler.run(Compiler.java:232)
> [INFO]  at com.google.gwt.dev.Compiler.run(Compiler.java:198)
> [INFO]  at com.google.gwt.dev.Compiler$1.run(Compiler.java:170)
> [INFO]  at
> com.google.gwt.dev.CompileTaskRunner.doRun(CompileTaskRunner.java:88)
> [INFO]  at
> com.google.gwt.dev.CompileTaskRunner.runWithAppropriateLogger(CompileTaskRunner.java:
> 82)
> [INFO]  at com.google.gwt.dev.Compiler.main(Compiler.java:177)
> [INFO]       [ERROR] : public interface
> javax.servlet.http.HttpServletRequest
> [INFO]  extends java.lang.Object
> [INFO]  implements : Unresolved type javax.servlet.ServletRequest
> [INFO] /*   fields   */
> [INFO] public static final [unresolved] java.lang.String BASIC_AUTH
> [INFO] public static final [unresolved] java.lang.String FORM_AUTH
> [INFO] public static final [unresolved] java.lang.String
> CLIENT_CERT_AUTH
> [INFO] public static final [unresolved] java.lang.String DIGEST_AUTH
> [INFO] /*   methods   */
> [INFO] [unresolved] public abstract java.lang.String getAuthType()
> [INFO] [unresolved] public abstract java.lang.String getContextPath()
> [INFO] [unresolved] public abstract Unresolved type
> javax.servlet.http.Cookie[] getCookies()
> [INFO] [unresolved] public abstract long
> getDateHeader(java.lang.String)
> [INFO] [unresolved] public abstract java.lang.String
> getHeader(java.lang.String)
> [INFO] [unresolved] public abstract Enumeration#RAW getHeaderNames()
> [INFO] [unresolved] public abstract Enumeration#RAW
> getHeaders(java.lang.String)
> [INFO] [unresolved] public abstract int
> getIntHeader(java.lang.String)
> [INFO] [unresolved] public abstract java.lang.String getMethod()
> [INFO] [unresolved] public abstract java.lang.String getPathInfo()
> [INFO] [unresolved] public abstract java.lang.String
> getPathTranslated()
> [INFO] [unres

RequestFactory, ServiceLocator and Spring

2012-03-14 Thread kayser
Hi,

I followed an example in this list on how to use a spring bean via
ServiceLocator. Everything works great using mvn gwt:debug but when I
try to package everything using mvn package I get compiler errors.
Here is my code:

import javax.servlet.http.HttpServletRequest;
import org.springframework.context.ApplicationContext;
import
org.springframework.web.context.support.WebApplicationContextUtils;

import
com.google.web.bindery.requestfactory.server.RequestFactoryServlet;
import com.google.web.bindery.requestfactory.shared.ServiceLocator;


public class EndpointConnectorServiceLocator implements ServiceLocator
{

/* (non-Javadoc)
 * @see
com.google.web.bindery.requestfactory.shared.ServiceLocator#getInstance(java.lang.Class)
 */
@Override
public Object getInstance(Class clazz) {

HttpServletRequest request =
RequestFactoryServlet.getThreadLocalRequest();
ApplicationContext context =
WebApplicationContextUtils.getWebApplicationContext(request.getSession().getServletContext());
return context.getBean("endpointConnectorService");
}

}



and the mvn message when hitting the error:


[INFO][ERROR] An internal compiler exception occurred
[INFO] com.google.gwt.dev.jjs.InternalCompilerException: Failed to get
JNode
[INFO]  at com.google.gwt.dev.jjs.impl.TypeMap.get(TypeMap.java:140)
[INFO]  at com.google.gwt.dev.jjs.impl.TypeMap.get(TypeMap.java:71)
[INFO]  at
com.google.gwt.dev.jjs.impl.BuildTypeMap.getType(BuildTypeMap.java:
730)
[INFO]  at com.google.gwt.dev.jjs.impl.BuildTypeMap.access
$000(BuildTypeMap.java:99)
[INFO]  at com.google.gwt.dev.jjs.impl.BuildTypeMap
$BuildDeclMapVisitor.visit(BuildTypeMap.java:195)
[INFO]  at
org.eclipse.jdt.internal.compiler.ast.LocalDeclaration.traverse(LocalDeclaration.java:
237)
[INFO]  at
org.eclipse.jdt.internal.compiler.ast.MethodDeclaration.traverse(MethodDeclaration.java:
239)
[INFO]  at
org.eclipse.jdt.internal.compiler.ast.TypeDeclaration.traverse(TypeDeclaration.java:
1239)
[INFO]  at
org.eclipse.jdt.internal.compiler.ast.CompilationUnitDeclaration.traverse(CompilationUnitDeclaration.java:
687)
[INFO]  at
com.google.gwt.dev.jjs.impl.BuildTypeMap.createPeersForNonTypeDecls(BuildTypeMap.java:
637)
[INFO]  at
com.google.gwt.dev.jjs.impl.BuildTypeMap.exec(BuildTypeMap.java:514)
[INFO]  at
com.google.gwt.dev.jjs.impl.BuildTypeMap.exec(BuildTypeMap.java:523)
[INFO]  at
com.google.gwt.dev.jjs.JavaToJavaScriptCompiler.precompile(JavaToJavaScriptCompiler.java:
599)
[INFO]  at
com.google.gwt.dev.jjs.JavaScriptCompiler.precompile(JavaScriptCompiler.java:
33)
[INFO]  at com.google.gwt.dev.Precompile.precompile(Precompile.java:
284)
[INFO]  at com.google.gwt.dev.Precompile.precompile(Precompile.java:
233)
[INFO]  at com.google.gwt.dev.Precompile.precompile(Precompile.java:
145)
[INFO]  at com.google.gwt.dev.Compiler.run(Compiler.java:232)
[INFO]  at com.google.gwt.dev.Compiler.run(Compiler.java:198)
[INFO]  at com.google.gwt.dev.Compiler$1.run(Compiler.java:170)
[INFO]  at
com.google.gwt.dev.CompileTaskRunner.doRun(CompileTaskRunner.java:88)
[INFO]  at
com.google.gwt.dev.CompileTaskRunner.runWithAppropriateLogger(CompileTaskRunner.java:
82)
[INFO]  at com.google.gwt.dev.Compiler.main(Compiler.java:177)
[INFO]   [ERROR] : public interface
javax.servlet.http.HttpServletRequest
[INFO]  extends java.lang.Object
[INFO]  implements : Unresolved type javax.servlet.ServletRequest
[INFO] /*   fields   */
[INFO] public static final [unresolved] java.lang.String BASIC_AUTH
[INFO] public static final [unresolved] java.lang.String FORM_AUTH
[INFO] public static final [unresolved] java.lang.String
CLIENT_CERT_AUTH
[INFO] public static final [unresolved] java.lang.String DIGEST_AUTH
[INFO] /*   methods   */
[INFO] [unresolved] public abstract java.lang.String getAuthType()
[INFO] [unresolved] public abstract java.lang.String getContextPath()
[INFO] [unresolved] public abstract Unresolved type
javax.servlet.http.Cookie[] getCookies()
[INFO] [unresolved] public abstract long
getDateHeader(java.lang.String)
[INFO] [unresolved] public abstract java.lang.String
getHeader(java.lang.String)
[INFO] [unresolved] public abstract Enumeration#RAW getHeaderNames()
[INFO] [unresolved] public abstract Enumeration#RAW
getHeaders(java.lang.String)
[INFO] [unresolved] public abstract int
getIntHeader(java.lang.String)
[INFO] [unresolved] public abstract java.lang.String getMethod()
[INFO] [unresolved] public abstract java.lang.String getPathInfo()
[INFO] [unresolved] public abstract java.lang.String
getPathTranslated()
[INFO] [unresolved] public abstract java.lang.String getQueryString()
[INFO] [unresolved] public abstract java.lang.String getRemoteUser()
[INFO] [unresolved] public abstract java.lang.String getRequestURI()
[INFO] [unresolved] public abstract java.lang.StringBuffer
getRequestURL()
[INFO] [unresolved] public abstract java.lang.String
getRequestedSessionId()
[INFO] [unresolved] public abstract 

Accessing GAE UserService from GWT client through requestfactory

2012-03-14 Thread Madz Lang
Hi,

I'm following the Expenses Sample that can be found in the SDK. I'm
writing a demo in which I would authenticate the user via GAE Users
Service.
I hit some problem in which the UserService userService =
UserServiceFactory.getUserService() is always null in the Service
Locator part of the Request Factory anyway here are my sample code.

This are my server side code.

package **.server;

import com.google.appengine.api.users.User;
import com.google.appengine.api.users.UserService;
import com.google.appengine.api.users.UserServiceFactory;
import com.google.web.bindery.requestfactory.shared.ServiceLocator;

/**
 * Gives a RequestFactory system access to the Google AppEngine
UserService.
 */
public class UserServiceLocator implements ServiceLocator {
public UserServiceWrapper getInstance(Class clazz) {
final UserService userService = 
UserServiceFactory.getUserService();
return new UserServiceWrapper() {

public String createLoginURL(String destinationURL) {
String loginURL = 
userService.createLoginURL(destinationURL);
return loginURL;
}

public String createLogoutURL(String destinationURL) {
String logoutURL = 
userService.createLogoutURL(destinationURL);
return logoutURL;
}

public User getCurrentUser() {
User user = userService.getCurrentUser();
return user;
}
};
}
}


public interface UserServiceWrapper {
  public String createLoginURL(String destinationURL);

  public String createLogoutURL(String destinationURL);

  public User getCurrentUser();
}


And here is my shared folder code

package **.shared;

import com.google.web.bindery.requestfactory.shared.ProxyForName;
import com.google.web.bindery.requestfactory.shared.ValueProxy;

/**
 * Client visible proxy of Google AppEngine User class.
 */
@ProxyForName("com.google.appengine.api.users.User")
public interface GaeUserProxy extends ValueProxy {
  String getNickname();
  String getEmail();
}


import com.google.web.bindery.requestfactory.shared.RequestFactory;

public interface MercadoRequestFactory extends RequestFactory{

//  UserEntityRequest userEntityRequest();
GaeUserServiceRequest userServiceRequest();
}

And here is how I instantiate it using GIN

package **.client.ioc

@Provides
@Singleton
public RequestFactory getRequestFactory(EventBus eventBus) {
RequestFactory requestFactory = GWT.create(RequestFactory 
.class);
requestFactory.initialize(eventBus);
return requestFactory;
}

And here is how I use this in my client

package **.client.view

@Inject
RequestFactory requestFactory ;

@Override
public void setUser() {
gaeUserServiceRequest = requestFactory.userServiceRequest();
gaeUserServiceRequest.getCurrentUser().to(new
Receiver() {

@Override
public void onSuccess(GaeUserProxy response) {
if(response == null) {
signingLink.setText("Sign In");
lblUserEmailAddress.setText("Guest");
createLoginURL();
} else {
signingLink.setText("Sign Out");

lblUserEmailAddress.setText(response.getNickname());
createLogoutURL();
}
}
});

gaeUserServiceRequest.fire();
}

The problem here is the GaeUserProxy response is always null. I trace
the problem and found out that the  UserService userService =
UserServiceFactory.getUserService() in my server side
UserServiceLocator  is always null. What seems to be the problem?

I'm using the GWT 2.4 BTW.


TIA

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



Re: JSNI and Flex Intercommunication Problem (through Javascript Interface)

2012-03-14 Thread Deepan
Oh yeah I saw thatUnfortunatley when import that module in to GWT 
project I am not able to get it working.
did u ???

-Nik

On Wednesday, March 14, 2012 9:27:19 AM UTC-4, Ümit Seren wrote:
>
> A Google search returns  Debug Desperado's github project ( 
> https://github.com/debug-desperado/Cytoscape-Web-GWT-Wrapper )  as number 
> one hit :-p
>
>
> On Tuesday, March 13, 2012 6:45:59 PM UTC+1, Deepan wrote:
>>
>> Hi, 
>>
>> I am also trying to use Cytoscape web in GWT. 
>> I was wondering if you successfully created the wrapper.
>>
>> Any help on this topic will be greatly appreciated.
>>
>> thanks.
>> Nik
>>
>> On Sunday, June 5, 2011 1:04:43 AM UTC-4, Debug Desperado wrote:
>>>
>>> Oops, forgot to report back just in case anyone else has this problem. 
>>>
>>> My solution was just to make sure that any array objects created by 
>>> GWT are done with new $wnd.Array(), as nino hinted.  Weirdly there are 
>>> no type conversion errors with Function objects or normal javascript 
>>> Object. 
>>>
>>> On May 26, 6:34 pm, nino  wrote: 
>>> > Sorry i got back at you this late. 
>>> > You  allready spot the problem. 
>>> > try doing somethinf like this 
>>> > 
>>> > var network_json = new $wnd.Object(); 
>>> > network_json.data =  { 
>>> > data: { 
>>> > nodes: [ { id: "1" }, { id: "2" } ], 
>>> > edges: [ { id: "2to1", target: "1", source: "2" } ] 
>>> > } 
>>> > }; 
>>> >  this.draw({network: network_json}); 
>>> > 
>>> > Regards, 
>>> > 
>>> > Alain
>>
>>

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



Re: GWT add JARS

2012-03-14 Thread dodo dard
Hello Vincenz,

Yes you can put those jar into a server. Depends on what server that you 
use, for example if you using tomcat you can put it into 'common/lib' 
(depends on tomcat version).
So look at your server specification.

Dodo

==
www.html5bydemo.com  

Le mardi 13 mars 2012 21:06:51 UTC+1, Vincenz Mössenböck a écrit :
>
> Hello, 
> I'm a student at the HTL Wels and I'm trying to learn myself some GWT. I 
> brought everything running, but there is still st what really annoyes me. I 
> always have to copy all the jars like hibernate jars and postgresql jars to 
> the Webinf .lib folder. Is there a way where I can add these jars to a 
> server or st i just can t find where to put them.
> Can somebody pls help me?
>  
>

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



Re: JSNI and Flex Intercommunication Problem (through Javascript Interface)

2012-03-14 Thread Ümit Seren
A Google search returns  Debug Desperado's github project ( 
https://github.com/debug-desperado/Cytoscape-Web-GWT-Wrapper )  as number 
one hit :-p


On Tuesday, March 13, 2012 6:45:59 PM UTC+1, Deepan wrote:
>
> Hi, 
>
> I am also trying to use Cytoscape web in GWT. 
> I was wondering if you successfully created the wrapper.
>
> Any help on this topic will be greatly appreciated.
>
> thanks.
> Nik
>
> On Sunday, June 5, 2011 1:04:43 AM UTC-4, Debug Desperado wrote:
>>
>> Oops, forgot to report back just in case anyone else has this problem. 
>>
>> My solution was just to make sure that any array objects created by 
>> GWT are done with new $wnd.Array(), as nino hinted.  Weirdly there are 
>> no type conversion errors with Function objects or normal javascript 
>> Object. 
>>
>> On May 26, 6:34 pm, nino  wrote: 
>> > Sorry i got back at you this late. 
>> > You  allready spot the problem. 
>> > try doing somethinf like this 
>> > 
>> > var network_json = new $wnd.Object(); 
>> > network_json.data =  { 
>> > data: { 
>> > nodes: [ { id: "1" }, { id: "2" } ], 
>> > edges: [ { id: "2to1", target: "1", source: "2" } ] 
>> > } 
>> > }; 
>> >  this.draw({network: network_json}); 
>> > 
>> > Regards, 
>> > 
>> > Alain
>
>

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



Re: GWT add JARS

2012-03-14 Thread Ümit Seren
you can use an ant or maven to take care of this automatically.  

On Tuesday, March 13, 2012 9:06:51 PM UTC+1, Vincenz Mössenböck wrote:
>
> Hello, 
> I'm a student at the HTL Wels and I'm trying to learn myself some GWT. I 
> brought everything running, but there is still st what really annoyes me. I 
> always have to copy all the jars like hibernate jars and postgresql jars to 
> the Webinf .lib folder. Is there a way where I can add these jars to a 
> server or st i just can t find where to put them.
> Can somebody pls help me?
>  
>

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



Loading Plus-One-Button dynamically causes Popup to jump in height

2012-03-14 Thread newnoise
Hi,

I'm trying to add a "Plus-One"-Button dynamically to some popups our webapp 
is using. I'm using the following code:


HTML google = new HTML(" annotation=\"none\" href=\"http://somecutomurl.com\";>");
>
> Document doc = Document.get();
> ScriptElement script = doc.createScriptElement();
> script.setSrc("https://apis.google.com/js/plusone.js";);
> script.setType("text/javascript");
> script.setLang("javascript");
> doc.getBody().appendChild(script);
> 
> DOM.setStyleAttribute(google.getElement(), "margin", "0 5px 0 
> 0");
> 
> bottomLine.setCellHorizontalAlignment(google, 
> HasHorizontalAlignment.ALIGN_RIGHT);
> bottomLine.setCellVerticalAlignment(google, 
> HasVerticalAlignment.ALIGN_MIDDLE);
> bottomLine.add(google);
>
 
Where bottomLine is a HorizontalPanel which is added to the Popup 
afterwards. Adding it to the popup directly doesnt help.

The code itself works, the button is added, BUT the Popup enlarges its size 
for a very short second when the button is added and gets back to normal 
size afterwards. It kind of shrugs for a very short moment, which is very 
annoying.

I tried setting a fixed height and max-height for the surrounding div. And 
I tried to use the css "clip" attribute. Both not working. Also I tried 
using "AddThis"-JS-Library to add the button, same effect.

Does anyone has any idea how I can make this work? I'm sure it can be done, 
I saw apps doing exactly the same ...

Thanks!
noise

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



Re: RPC Serialization of an Interface..

2012-03-14 Thread Saik0
Hi and thanks for your reply. 

i've investigated your suggestions and must say it's more complex as i 
thought. Some Interfaces go'es through the rpc serialization, others not. 
The problem is that i have some enum's in my sources and rpc don't accept 
them. I'm currently redesign my model and let you know if it works. ^^

greetings

Am Dienstag, 13. März 2012 10:09:31 UTC+1 schrieb Alex Dobjanschi:
>
> try to use classes first, but you can definitely use interfaces. there are 
> a couple of considerations: 
> 1 interfaces must extend Serializable
> 2 those interfaces must be found by gwt rpc generator, so place them in 
> one of the source imports of gwt module
> 3 implementations of these interfaces must also be visible to gwt rpc 
> generator - that means, also be included in a visible package - along with 
> the usual serialization requirements

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



Re: RichTextArea height size

2012-03-14 Thread Saik0
Hi, thanks for your reply.

You are right. I can't change the area itself. I've put the RichTextArea 
into a VerticalPanel and change the width and the height oft this panel. 
Now my RichTextArea looks fine ^^

greetings

Am Mittwoch, 14. März 2012 09:46:19 UTC+1 schrieb dodo dard:
>
> The height of an html textarea is define by number of colonne, not the 
> content of the area it self. 
> So I think you cant not set it with 100%, try with pixel. 
>
> Dodo 
>
>  
> www.html5bydemo.com 
>
> On Mar 13, 1:17 pm, Saik0  wrote: 
> > Hi @all, 
> > 
> > why could i change the width of the RichTextArea with css but not the 
> > height? What i'm missing :-\ ? 
> > 
> > Source: 
> > RichTextArea area = new RichTextArea(); 
> > area.setSize("100%", "100%");

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



Re: Problem with Window.Location.assign(url)

2012-03-14 Thread Benoit S
We also encountered this problem with GWT 2.4. To complete previous 
messages, we also noticed that it depends on the calling context. But when 
the calling context is an event handler, all browsers don't have the same 
behavior (we have the expected behavior on all browsers but IE any version).

It sounds like the problem comes from the fact that GWT code is in an 
iframe and relative path resolution is done using the calling context 
whereas we could expect GWT to resolve it in the main window context since 
the fact that code is in a iframe is hidden to user.

Here is a GWT code snippet that shows the problem:
public class IERedirectBug
implements EntryPoint
{
@Override
public void onModuleLoad()
{
final Button redirectButton = new Button("Relative Redirection");

RootPanel.get().add(redirectButton);

redirectButton.addClickHandler(new ClickHandler()
{
@Override
public void onClick(ClickEvent event)
{
// Works with all browsers but IE
Location.assign("target.html");
}
});
}
}

To investigate the problem we did several test cases in pure Javascript.

In the first case, we use a frame that is in a subfolder and that contains 
a function (as the GWT frame contains code) that does the main page 
redirection (window.parent.location.assign()). If we call this code from 
the main window (case #1), all browsers resolve correctly relative paths. 
If this code is called from the iframe (next to the function declaration, 
case #2), all browsers resolve the relative path according to the iframe 
location and not the main page location. This shows that calling context 
impacts relative path resolution and all browsers seem to have the same 
behavior (at least Google Chrome and IE 8 & 9 on which we really tested).

Main window (test.html):





   
  main
  redirect



Iframe (folder/frame.html):





  test2
  
function redirect()
{
  window.parent.location.assign('target.html');
}
  



In case #1, we add to the button declaration in test.html the call to the 
redirect function: redirect.
 
This redirects to target.html on any browser, the expected behavior.
In case #2, we call the redirect function from the frame, just after its 
declaration:
  function redirect()
{
  window.parent.location.assign('target.html');
}
  redirect();
It redirects to folder/target.html on any browser.

These examples simply confirm that calling context impacts relative path 
resolution but don't explain why IE hasn't the same behavior as other 
browsers in our GWT case.

So we tried to reproduce in a pure Javascript example the way GWT handles 
events (through the global handler), case #3. This way enabled us to 
reproduce the problem. For modern browsers and IE9, the standard global 
event handling system is used throw $wnd.addEventListener(). For IE 8 it's 
a specific code (case #4). But whatever global event handling system is 
used, Location.replace() and Location.assign() don't have the expected 
behaviour with relative paths on IE.

In case #3, we use this code (just after redirect function declaration):
// Works on any browser but IE9
window.parent.addEventListener('click', function(e) { redirect(); }, true);

In case #4 (IE8), we use this code:
window.parent.document.body.attachEvent('onclick', function(e) { 
redirect(); });

Cases #3 and #4 show that with global handler, IE has the same behavior as 
case #2 while other browsers work as in case #1, which is the expected 
behavior.

Even if the problem can be solved by API users using GWT.getModuleBaseURL(), 
don't you think it sould be fixed in GWT itself since it doesn't respect 
the GWT "execution doesn't depend on browser" principle?
I guess it could be solved by analyzing the parameter given to the assign() 
method. If it starts neither with a protocol (http:// for instance) nor 
with a slash, we can consider it's a relative path (unless I forget cases) 
and thus prefix it with GWT.getModuleBaseUrl().


Le mercredi 16 juillet 2008 23:47:25 UTC+2, Thomas Broyer a écrit :
>
>
>
> On Jul 16, 8:57 pm, jarrod  wrote: 
> > This is even stranger. Observe the following EntryPoint code: 
> > 
> > public void onModuleLoad() { 
> > RootPanel.get().add(new Button("Redirect", new ClickListener() 
> > { 
> > public void onClick(Widget sender) { 
> > Window.Location.assign("index.html"); 
> > } 
> > })); 
> > RootPanel.get("root").add(root); 
> > } 
> > 
> > Click the button, and you get successfully redirected from "/context/ 
> > module.html" to "/context/index.html", just like you would expect. 
>
> The onClick method is called in response to the button's click, and 
> the button lies in the /context/moduleA.html, so this URL is used as 
> the "base URL" for resolving relative URLs. 
>
> > However, given this code (never mind the redirect in module lo

Re: File download and Exception handling using a servlet.

2012-03-14 Thread Albert van Veen
Hi Bowie,

I use the code below. The PDF_HOST_URL variable is the url to my local
servlet. downloadFrame is a GWT Frame object.

pdfService.storeFormInSession(form, new AsyncCallback() {

public void onSuccess(EfPdfData arg0) {

RootPanel.get().remove(downloadFrame);
downloadFrame.setUrl(PDF_HOST_URL);
downloadFrame.setVisible(false);
RootPanel.get().add(downloadFrame);
 downloadFrame.addLoadHandler(new LoadHandler() {

public void onLoad(LoadEvent arg0) {
waitDialog.hide();
 }
});

new ReadyStateWatch(downloadFrame, waitDialog).addReadyStateChangeHandler(
new ValueChangeHandler() {

public void onValueChange(ValueChangeEvent event) {

}
});

}

public void onFailure(Throwable exception) {
new EfDialog(exception.getMessage()).show();
waitDialog.hide();

}
});

On 14 March 2012 10:22, dodo dard  wrote:

> Hi Appien
>>
>
> Ho do you call the servlet ?
>
> 
> http://www.html5bydemo.com/
>
> --
> You received this message because you are subscribed to the Google Groups
> "Google Web Toolkit" group.
> To view this discussion on the web visit
> https://groups.google.com/d/msg/google-web-toolkit/-/WeXfqz5OpVgJ.
>
> To post to this group, send email to google-web-toolkit@googlegroups.com.
> To unsubscribe from this group, send email to
> google-web-toolkit+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/google-web-toolkit?hl=en.
>

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



Re: File download and Exception handling using a servlet.

2012-03-14 Thread dodo dard

>
> Hi Appien
>

Ho do you call the servlet ?

 
http://www.html5bydemo.com/  

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



Re: URL fetch request size in googleaapengine

2012-03-14 Thread learning coding
Hi Joe,
There is nothing related to ASP in my code.
I doing in Java.

And 3.8Mb  is Max limit to To POST from server to repositary

If your file size 3.81Mb is gives you the same error.

  *Cannot access **http://URL* *: The request to API call
urlfetch.Fetch()
was too large.   Can somebody explain me the reason for this.*



On Tue, Mar 13, 2012 at 5:30 PM, Joseph Lust  wrote:

> Learning,
>
> Seems that you're hitting a max file size of 4MB. (4e6 bytes /
> (4*1024*1024))*4 = 3.81, which is what you're getting, since somewhere
> along the line a MB is using 1e6 bytes, not 1048576 bytes.
>
> Are you accessing an ASP application? The default file export limit is 4MB
> there. Perhaps that is the sort of limit your are hitting,
>
> Sincerely,
> Joe
>
> --
> You received this message because you are subscribed to the Google Groups
> "Google Web Toolkit" group.
> To view this discussion on the web visit
> https://groups.google.com/d/msg/google-web-toolkit/-/GYQItAtKswMJ.
> To post to this group, send email to google-web-toolkit@googlegroups.com.
> To unsubscribe from this group, send email to
> google-web-toolkit+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/google-web-toolkit?hl=en.
>

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



Re: RichTextArea height size

2012-03-14 Thread dodo dard
The height of an html textarea is define by number of colonne, not the
content of the area it self.
So I think you cant not set it with 100%, try with pixel.

Dodo


www.html5bydemo.com

On Mar 13, 1:17 pm, Saik0  wrote:
> Hi @all,
>
> why could i change the width of the RichTextArea with css but not the
> height? What i'm missing :-\ ?
>
> Source:
> RichTextArea area = new RichTextArea();
> area.setSize("100%", "100%");

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