Re: Some advice to argue for GWT vs JSF

2013-12-17 Thread Dapeng
going pure GWT can never be wrong, if u want to play safe, make ur server 
talking only JSON/rest not GWT-RPC

by that u can later decided to throw away the presentation layer if another 
promising client framework should become popular

so far, java's tooling system is too good to give up ... 



On Friday, December 13, 2013 9:35:27 AM UTC+8, Willie Slepecki wrote:
>
> My team just wrapped up an evaluation comparing gwt to jsf to be used in a 
> new series of applications we are planning.  My team chose pure gwt over 
> jsf and vaadin for a variety of reasons.  
>
> Our problem is two of the primary decision makers are convinced that gwt 
> is going to dilute and within 7 to 10 years be irrelevant and ended as a 
> product.   Where did they get this idea?  A blog. Post obviously.  On the 
> other hand, since jsf is part of jee, it's going to be alive and vibrant 
> forever.   
>
> I'm not asking to argue the validity of their claims  I already know why 
> they say that and it's political, not technological.  What I'm asking is, 
> can you help me come up with an idea to impress upon the other members of 
> the selection committee that this idea is unfounded and gwt would be a safe 
> choice?I already. Have the vaadin report they generate, but that I fear 
> isn't going to hold much weight.   
>
> Maybe some records from red hat saying how many developers are dedicated 
> to the project, estimated annual budget senscia is spending on gwt core 
> development, stung like that is what these guys will care about.
>
> Any ideas?  Thanks
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-web-toolkit+unsubscr...@googlegroups.com.
To post to this group, send email to google-web-toolkit@googlegroups.com.
Visit this group at http://groups.google.com/group/google-web-toolkit.
For more options, visit https://groups.google.com/groups/opt_out.


what is need of including gwt plug in browser

2013-12-17 Thread Patnaidu Landa

what is need of including gwt plug in browser

i want solution as early al possible

-- 
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-web-toolkit+unsubscr...@googlegroups.com.
To post to this group, send email to google-web-toolkit@googlegroups.com.
Visit this group at http://groups.google.com/group/google-web-toolkit.
For more options, visit https://groups.google.com/groups/opt_out.


Re: Automatically generated GWT Wrapper

2013-12-17 Thread Jozef Môstka


Dňa streda, 5. júna 2013 3:25:05 UTC+2 Martin Kimmel napísal(-a):
>
>
> Else I would like to try programming such a tool.
> Do you have any input what things I have to consider when doing so?
>

Hi,
Im actualy working on gwt wraper generator. Its not public now. So if you 
wont help, send Email and I will give you svn access, and I'll explain the 
principles.
 

-- 
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-web-toolkit+unsubscr...@googlegroups.com.
To post to this group, send email to google-web-toolkit@googlegroups.com.
Visit this group at http://groups.google.com/group/google-web-toolkit.
For more options, visit https://groups.google.com/groups/opt_out.


Re: Suggestions for transferring a GWT project to javascript?

2013-12-17 Thread Ümit Seren
Alterantively you could check out DWT (http://dartwebtoolkit.com/) which 
tries to mimic the GWT features in Dart. 
But I guess this would be more involved than using gwt-exporter. 

In case you  missed the recent GWT.create conference. There are plans for 
GWT 3.0 to make the interoparability between JS and GWT much much easier 
and with web-components you can write JS code and then easily use it in 
GWT. 



On Tuesday, December 17, 2013 1:36:12 AM UTC+1, rjcarr wrote:
>
> I have a pretty large project that's over 7 years old that has used GWT 
> from the very early days and is nearly 100% GWT (i.e., there's very little 
> manually written javascript).  However, we'd like to transition the client 
> to be written in javascript, but if possible, we'd like to retain the GWT 
> services (i.e., the serialization).
>
> Basically, we'd like to keep all of the RemoteService, RemoteServiceAsync, 
> and RemoteServiceServlet (and the accompanying object serialization) but 
> write the client / visualization portions manually in javascript.
>
> Is there any way to divorce the data serialization from the visualization 
> without the messiness of JSNI?
>
> Note that we don't have any problem with GWT, it's actually been great in 
> most every way, but at this point we have many more javascript developers 
> that are uncomfortable with java and it's hard to get the level of 
> contribution we need to the project in its current state.
>
> Thanks!
>

-- 
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-web-toolkit+unsubscr...@googlegroups.com.
To post to this group, send email to google-web-toolkit@googlegroups.com.
Visit this group at http://groups.google.com/group/google-web-toolkit.
For more options, visit https://groups.google.com/groups/opt_out.


Re: Textbox width according to the characters present in the textbox.

2013-12-17 Thread Andrei
You can only approximate.

(1) Users may not have a specified font. Browsers will try to substitute 
this font, and the width of characters maybe different for a substitute 
font.

(2) Users can zoom in or out, changing the font size from the one you set.


I need to set the size of the text box according to the length of the text 
> inside that box, it may contain localized characters like Chinese. Is any 
> we can calculate the length in pixels for this?
>

-- 
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-web-toolkit+unsubscr...@googlegroups.com.
To post to this group, send email to google-web-toolkit@googlegroups.com.
Visit this group at http://groups.google.com/group/google-web-toolkit.
For more options, visit https://groups.google.com/groups/opt_out.


celltable does not respond to right padding unless text is right aligned

2013-12-17 Thread Yan
Hi there, 

I am aware of the issue that CellTable vertical scrollbar overlaps with 
last column, and is trying to add some right padding to fully show the last 
column. 

However, even in GWT showcase cell table example running in Chrome, adding 
or reducing right padding on a cell makes no difference, however, adding or 
reducing left/top/bottom padding all take effect appropriately. 

I set the cell text to right aligned, and then I can see right padding is 
taking effect.  Why is that?

With my use case, the only workaround I can think of is to add a dummy 
column to avoid vertical scrollbar overlapping last column. Any better idea?

Thanks,
yan

-- 
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-web-toolkit+unsubscr...@googlegroups.com.
To post to this group, send email to google-web-toolkit@googlegroups.com.
Visit this group at http://groups.google.com/group/google-web-toolkit.
For more options, visit https://groups.google.com/groups/opt_out.


Project to Generate a Single JavaScript file for each browser.

2013-12-17 Thread Martin Kersten
Hi,

 I am setting up a GWT project to produce the JavaScript code for a web 
site. The application is only 
going to argument the dynamic elements of a web page providing the glue to 
hold everything dynamic 
together by creating a single entry point and discovering the required 
functionality by inspecting the dom
tree on startup.

The HTML page is completely dynamic and is generated by a in-house 
framework meaning I am totally in control
over every aspect of page creation.

Since the JavaScript is developed independently at different speed, I want 
to be able to compile the project
to update the JS assets of another project and this newly compiled JS gets 
committed within the project.

To simplify the generation and usage and also to remove the clutter I want 
to have a single JavaScript file
for each browser version that my web page will draw from depending on the 
user-agent that is transmitted.

I also wonder what is needed in such a setup to debug the client code using 
the development mode. I guess
I have to run GWT with the -noserver argument and also add the ?code-server 
query parameter in the 
web-framework. Right?


Thanks,

Martin (Kersten),
Germany

-- 
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-web-toolkit+unsubscr...@googlegroups.com.
To post to this group, send email to google-web-toolkit@googlegroups.com.
Visit this group at http://groups.google.com/group/google-web-toolkit.
For more options, visit https://groups.google.com/groups/opt_out.


Re: GWT support Comet/Server-side-push ?

2013-12-17 Thread dhoffer
The two that I am aware of are Atmosphere 
https://github.com/Atmosphere/atmosphere and CometD both high quality 
libraries with somewhat differing feature sets, I think one downside to 
CometD is there is no provided GWT client whereas Atmosphere does have a 
GWT client.

-Dave

On Friday, December 13, 2013 9:26:44 AM UTC-7, Zhong-zheng Xiao wrote:
>
> I want to use GWT to build a rich web apps, including subscribe-push model.
>

-- 
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-web-toolkit+unsubscr...@googlegroups.com.
To post to this group, send email to google-web-toolkit@googlegroups.com.
Visit this group at http://groups.google.com/group/google-web-toolkit.
For more options, visit https://groups.google.com/groups/opt_out.


Re: Automatically generated GWT Wrapper

2013-12-17 Thread dhoffer
That would be great of Google could open source what Ray/Google has...it 
would be very useful.

-Dave

On Tuesday, June 4, 2013 7:25:05 PM UTC-6, Martin Kimmel wrote:
>
> Hello,
>
> I just thought that it would be pretty cool to have a tool which analyses 
> JavaScript Libraries and automatically generates some Java/GWT Files as a 
> Wrapper (using JSNI, JavaScript Overlays, ...)
> Do you know if something like this already exists?
>
> Else I would like to try programming such a tool.
> Do you have any input what things I have to consider when doing so?
>
> Best regards,
> Martin
>

-- 
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-web-toolkit+unsubscr...@googlegroups.com.
To post to this group, send email to google-web-toolkit@googlegroups.com.
Visit this group at http://groups.google.com/group/google-web-toolkit.
For more options, visit https://groups.google.com/groups/opt_out.


Re: Project to Generate a Single JavaScript file for each browser.

2013-12-17 Thread Thomas Broyer

On Tuesday, December 17, 2013 3:20:12 PM UTC+1, Martin Kersten wrote:
>
> Hi,
>
>  I am setting up a GWT project to produce the JavaScript code for a 
> web site. The application is only 
> going to argument the dynamic elements of a web page providing the glue to 
> hold everything dynamic 
> together by creating a single entry point and discovering the required 
> functionality by inspecting the dom
> tree on startup.
>
> The HTML page is completely dynamic and is generated by a in-house 
> framework meaning I am totally in control
> over every aspect of page creation.
>
> Since the JavaScript is developed independently at different speed, I want 
> to be able to compile the project
> to update the JS assets of another project and this newly compiled JS gets 
> committed within the project.
>
> To simplify the generation and usage and also to remove the clutter I want 
> to have a single JavaScript file
> for each browser version that my web page will draw from depending on the 
> user-agent that is transmitted.
>
> I also wonder what is needed in such a setup to debug the client code 
> using the development mode. I guess
> I have to run GWT with the -noserver argument and also add the 
> ?code-server query parameter in the 
> web-framework. Right?
>

What you're trying to do is basically move the selection script to the 
server side. This is exactly what Google is doing for years (you'll find 
mentions of  in comments, commits or issues, standing for Server-Side 
Selection Script).
What you need is a special Linker to output each permutation's script in a 
standalone script (rather than one that expects to be loaded by a JS 
selection script). I never really thought about how it would/should work so 
I'm afraid I can't provide more info on this (ask Googlers though; I 
believe they somehow extend CrossSiteIframeLinker).
To choose the right script to use, the CrossSiteIframeLinker generates a 
file with the property mappings which you should be able to use.
I wonder what kind of work would be needed if you have other binding 
properties than user.agent (and/or locale) that couldn't be determined on 
the server-side. Maybe you'd need to collapse those so that the selection 
script only deals with properties that can be computed on the server-side 
(again, ask Googlers if they can help).

And for DevMode, you'd have to load devmode.js somehow instead of your 
permutation. That can easily be triggered by the presence of ?gwt.codesvr 
in the query-string.
That said, I have no idea what's needed otherwise (e.g. if you want to use 
your server-side-computed property values)

-- 
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-web-toolkit+unsubscr...@googlegroups.com.
To post to this group, send email to google-web-toolkit@googlegroups.com.
Visit this group at http://groups.google.com/group/google-web-toolkit.
For more options, visit https://groups.google.com/groups/opt_out.


Re: Suggestions for transferring a GWT project to javascript?

2013-12-17 Thread Robert J. Carr
Thanks for the gwt-exporter suggestion (it was already on my radar) and
thanks for the alternative dart web toolkit.  I didn't catch the conference
but that is very interesting about GWT 3.0.  Do you have any white papers
on that specific topic?


On Tue, Dec 17, 2013 at 5:17 AM, Ümit Seren  wrote:

> Alterantively you could check out DWT (http://dartwebtoolkit.com/) which
> tries to mimic the GWT features in Dart.
> But I guess this would be more involved than using gwt-exporter.
>
> In case you  missed the recent GWT.create conference. There are plans for
> GWT 3.0 to make the interoparability between JS and GWT much much easier
> and with web-components you can write JS code and then easily use it in
> GWT.
>
>
>
> On Tuesday, December 17, 2013 1:36:12 AM UTC+1, rjcarr wrote:
>>
>> I have a pretty large project that's over 7 years old that has used GWT
>> from the very early days and is nearly 100% GWT (i.e., there's very little
>> manually written javascript).  However, we'd like to transition the client
>> to be written in javascript, but if possible, we'd like to retain the GWT
>> services (i.e., the serialization).
>>
>> Basically, we'd like to keep all of the RemoteService,
>> RemoteServiceAsync, and RemoteServiceServlet (and the accompanying
>> object serialization) but write the client / visualization portions
>> manually in javascript.
>>
>> Is there any way to divorce the data serialization from the visualization
>> without the messiness of JSNI?
>>
>> Note that we don't have any problem with GWT, it's actually been great in
>> most every way, but at this point we have many more javascript developers
>> that are uncomfortable with java and it's hard to get the level of
>> contribution we need to the project in its current state.
>>
>> Thanks!
>>
>  --
> You received this message because you are subscribed to a topic in the
> Google Groups "Google Web Toolkit" group.
> To unsubscribe from this topic, visit
> https://groups.google.com/d/topic/google-web-toolkit/r1_7U5uq7rs/unsubscribe
> .
> To unsubscribe from this group and all its topics, send an email to
> google-web-toolkit+unsubscr...@googlegroups.com.
> To post to this group, send email to google-web-toolkit@googlegroups.com.
> Visit this group at http://groups.google.com/group/google-web-toolkit.
> For more options, visit https://groups.google.com/groups/opt_out.
>

-- 
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-web-toolkit+unsubscr...@googlegroups.com.
To post to this group, send email to google-web-toolkit@googlegroups.com.
Visit this group at http://groups.google.com/group/google-web-toolkit.
For more options, visit https://groups.google.com/groups/opt_out.


Re: Suggestions for transferring a GWT project to javascript?

2013-12-17 Thread Ümit Seren
There is a demo: https://www.youtube.com/watch?v=wFMD1GXR2Tg and there
should be somewhere a spec (have to look for the link)


On Tue, Dec 17, 2013 at 6:34 PM, Robert J. Carr  wrote:

> Thanks for the gwt-exporter suggestion (it was already on my radar) and
> thanks for the alternative dart web toolkit.  I didn't catch the conference
> but that is very interesting about GWT 3.0.  Do you have any white papers
> on that specific topic?
>
>
> On Tue, Dec 17, 2013 at 5:17 AM, Ümit Seren  wrote:
>
>> Alterantively you could check out DWT (http://dartwebtoolkit.com/) which
>> tries to mimic the GWT features in Dart.
>> But I guess this would be more involved than using gwt-exporter.
>>
>> In case you  missed the recent GWT.create conference. There are plans for
>> GWT 3.0 to make the interoparability between JS and GWT much much easier
>> and with web-components you can write JS code and then easily use it in
>> GWT.
>>
>>
>>
>> On Tuesday, December 17, 2013 1:36:12 AM UTC+1, rjcarr wrote:
>>>
>>> I have a pretty large project that's over 7 years old that has used GWT
>>> from the very early days and is nearly 100% GWT (i.e., there's very little
>>> manually written javascript).  However, we'd like to transition the client
>>> to be written in javascript, but if possible, we'd like to retain the GWT
>>> services (i.e., the serialization).
>>>
>>> Basically, we'd like to keep all of the RemoteService,
>>> RemoteServiceAsync, and RemoteServiceServlet (and the accompanying
>>> object serialization) but write the client / visualization portions
>>> manually in javascript.
>>>
>>> Is there any way to divorce the data serialization from the
>>> visualization without the messiness of JSNI?
>>>
>>> Note that we don't have any problem with GWT, it's actually been great
>>> in most every way, but at this point we have many more javascript
>>> developers that are uncomfortable with java and it's hard to get the level
>>> of contribution we need to the project in its current state.
>>>
>>> Thanks!
>>>
>>  --
>> You received this message because you are subscribed to a topic in the
>> Google Groups "Google Web Toolkit" group.
>> To unsubscribe from this topic, visit
>> https://groups.google.com/d/topic/google-web-toolkit/r1_7U5uq7rs/unsubscribe
>> .
>> To unsubscribe from this group and all its topics, send an email to
>> google-web-toolkit+unsubscr...@googlegroups.com.
>> To post to this group, send email to google-web-toolkit@googlegroups.com.
>> Visit this group at http://groups.google.com/group/google-web-toolkit.
>> For more options, visit https://groups.google.com/groups/opt_out.
>>
>
>  --
> You received this message because you are subscribed to a topic in the
> Google Groups "Google Web Toolkit" group.
> To unsubscribe from this topic, visit
> https://groups.google.com/d/topic/google-web-toolkit/r1_7U5uq7rs/unsubscribe
> .
> To unsubscribe from this group and all its topics, send an email to
> google-web-toolkit+unsubscr...@googlegroups.com.
> To post to this group, send email to google-web-toolkit@googlegroups.com.
> Visit this group at http://groups.google.com/group/google-web-toolkit.
> For more options, visit https://groups.google.com/groups/opt_out.
>

-- 
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-web-toolkit+unsubscr...@googlegroups.com.
To post to this group, send email to google-web-toolkit@googlegroups.com.
Visit this group at http://groups.google.com/group/google-web-toolkit.
For more options, visit https://groups.google.com/groups/opt_out.


Re: SingleSelectionModel with KeyProvider does not update selected object when data is refreshed

2013-12-17 Thread Gordan Krešić
I just hit the same issue.

Tripple checked that DataGrid, ListDataProvider and SingleSelectionModel 
all use the same KeyProvider (that itself uses stableId() from contained 
EntityProxies).

Updates are pushed via ListDataProvider.getList().set(int, T) and they are 
shown in table with selection preserved.

Still, SingleSelectionModel.getSelectedObject() (called in separate (later) 
event, just to eliminate missed flush()-es from ListDataProvider) returns 
old object as it were before update.

On Friday, December 6, 2013 3:35:46 PM UTC+1, stuckagain wrote:
>
> Hi,
>
> I noticed an issue in the SingleSelectionModel when used in combination 
> with a KeyProvider and updating the cell table with new data.
>
> The idea is that I want to retain selection, and that seems to work. What 
> does not work is when I use the getSelectedObject method I get an older 
> version of the object instead of the refreshed version.
> Is that the way it is supposed to work ? Wouldn't it be smarter to 
> recalculate selection when the data in the table is updated ?
>
> I currently implemented a workaround that uses the KeyProvider to find the 
> item in the table that has the same key as the previous selection.
>
> David
>

-- 
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-web-toolkit+unsubscr...@googlegroups.com.
To post to this group, send email to google-web-toolkit@googlegroups.com.
Visit this group at http://groups.google.com/group/google-web-toolkit.
For more options, visit https://groups.google.com/groups/opt_out.


GWT 2.5.0: Compilation: Out of Memory

2013-12-17 Thread manstis
Hi,

We have a reasonably sized web-app, comprised of ~50 modules.

For every day use, we compile for a single browser-platform and locale; but 
for releases we target all browsers (supported by GWT) and 7 locales which 
gives ~40 permutations.

We are finding that we're running out of memory during the Maven GWT 
compilation phase on a 26GB server and are looking for ideas (other than 
reducing the number of permutations).

I seen mention of 
-Dgwt.jjs.permutationWorkerFactory=com.google.gwt.dev.ThreadedPermutationWorkerFactory
 
on this forum that I'm asking our release engineer to try.

At the moment we compile each module separately first (plain Java 
compilation, packaged as a JAR); and then aggregate them together into a 
single web app that is really just a collection of dependencies.

It is the final compilation where the OOM occurs. This is also the only 
module where we actually perform a GWT compilation.

Any recommendations warmly received.

With kind regards,

Mike

-- 
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-web-toolkit+unsubscr...@googlegroups.com.
To post to this group, send email to google-web-toolkit@googlegroups.com.
Visit this group at http://groups.google.com/group/google-web-toolkit.
For more options, visit https://groups.google.com/groups/opt_out.


Handle request factory server exception in client

2013-12-17 Thread Yan
Hi there,

I am using GWT 2.5.1 request factory. On client, after I fire the request, 
I have this block to display any error message from server.   

public void onFailure(ServerFailure error)  {
// do something with error.getMessage()
}


On server, I extended ServceLayerDecorator like this,  but I do not know 
how to handle exception so that the message will show up in 
ServerFailure.getMessage().

I tried simply rethrowing the exception, I am getting HTML text such as 
server 500 error in ServerFailure.getMessage().

@Override
public Object invoke(Method domainMethod, Object... args) {
try {
// some business logic such as check user role, etc. 
return super.invoke(domainMethod, args);
} catch (Exception ex) {
throw new RuntimeException(ex); 
}   
}

How does this exception on Server side gets translated into ServerFailure 
on client and who is doing that? Maybe that is where I need to override?

Thanks,
Yan

-- 
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-web-toolkit+unsubscr...@googlegroups.com.
To post to this group, send email to google-web-toolkit@googlegroups.com.
Visit this group at http://groups.google.com/group/google-web-toolkit.
For more options, visit https://groups.google.com/groups/opt_out.


Re: GWT 2.5.0: Compilation: Out of Memory

2013-12-17 Thread Jens
Are you using Maven along with the gwt maven plugin for compilation? If yes 
then you might want to try to decrease the amount of local workers spawned 
by the gwt maven plugin. By default it uses the amount of processors in the 
system. This default can quickly eat up your memory if you have a high 
number of processors available and the compilation of a single permutation 
already requires a good amount of RAM.

Also try upgrading to GWT 2.6. It contains some changes to make compilation 
a bit faster and less resource hungry.

-- J.

-- 
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-web-toolkit+unsubscr...@googlegroups.com.
To post to this group, send email to google-web-toolkit@googlegroups.com.
Visit this group at http://groups.google.com/group/google-web-toolkit.
For more options, visit https://groups.google.com/groups/opt_out.


Re: SingleSelectionModel with KeyProvider does not update selected object when data is refreshed

2013-12-17 Thread David
Hi Gordan,

Ah great, then I was not alone having this issue. Problem was that we are
using a highly customized layer on top of the DataGrid so I was not entire
sure that it was caused by my team additions or not.

David


On Tue, Dec 17, 2013 at 8:13 PM, Gordan Krešić
wrote:

> I just hit the same issue.
>
> Tripple checked that DataGrid, ListDataProvider and SingleSelectionModel
> all use the same KeyProvider (that itself uses stableId() from contained
> EntityProxies).
>
> Updates are pushed via ListDataProvider.getList().set(int, T) and they are
> shown in table with selection preserved.
>
> Still, SingleSelectionModel.getSelectedObject() (called in separate
> (later) event, just to eliminate missed flush()-es from ListDataProvider)
> returns old object as it were before update.
>
> On Friday, December 6, 2013 3:35:46 PM UTC+1, stuckagain wrote:
>>
>> Hi,
>>
>> I noticed an issue in the SingleSelectionModel when used in combination
>> with a KeyProvider and updating the cell table with new data.
>>
>> The idea is that I want to retain selection, and that seems to work. What
>> does not work is when I use the getSelectedObject method I get an older
>> version of the object instead of the refreshed version.
>> Is that the way it is supposed to work ? Wouldn't it be smarter to
>> recalculate selection when the data in the table is updated ?
>>
>> I currently implemented a workaround that uses the KeyProvider to find
>> the item in the table that has the same key as the previous selection.
>>
>> David
>>
>  --
> You received this message because you are subscribed to the Google Groups
> "Google Web Toolkit" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to google-web-toolkit+unsubscr...@googlegroups.com.
> To post to this group, send email to google-web-toolkit@googlegroups.com.
> Visit this group at http://groups.google.com/group/google-web-toolkit.
> For more options, visit https://groups.google.com/groups/opt_out.
>

-- 
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-web-toolkit+unsubscr...@googlegroups.com.
To post to this group, send email to google-web-toolkit@googlegroups.com.
Visit this group at http://groups.google.com/group/google-web-toolkit.
For more options, visit https://groups.google.com/groups/opt_out.


Re: Handle request factory server exception in client

2013-12-17 Thread Jens
You can call report() or die() depending on what you want to do. report() 
re-throws a ReportableException while die() will re-throw an 
UnexpectedException.

Also with your above implementation you are "hiding" the exception logic of 
super.invoke() as it might also call report() or die() when it encounters 
certain exceptions. I think a better implementation would be

@Override
public Object invoke(Method domainMethod, Object... args) {
try {
// some business logic such as check user role, etc. 
} catch (Exception ex) {
// only catch exceptions from your custom code
// call report() or die()
}   
return super.invoke(domainMethod, args); // assume super.invoke() 
will do the right thing if it encounters exceptions
}


The generation of a ServerFailure is done in the DefaultExceptionHandler. 
But you can also provide your own implementation by extending the 
RequestFactoryServlet and provide your custom exception handler through the 
constructor.

-- J.

-- 
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-web-toolkit+unsubscr...@googlegroups.com.
To post to this group, send email to google-web-toolkit@googlegroups.com.
Visit this group at http://groups.google.com/group/google-web-toolkit.
For more options, visit https://groups.google.com/groups/opt_out.


Re: Project to Generate a Single JavaScript file for each browser.

2013-12-17 Thread Martin Kersten
Hello Mr. Broyer,

Thanks for the information. This is exactly what I am aiming for. Do 
you know any open source project that uses this kind of setup (so I can 
take a look) or do you know any Googler willing to share the needed 
information? 


Thanks,

Martin (Kersten),
Köthen,
Germany

Am Dienstag, 17. Dezember 2013 15:44:56 UTC+1 schrieb Thomas Broyer:
>
>
> On Tuesday, December 17, 2013 3:20:12 PM UTC+1, Martin Kersten wrote:
>>
>> Hi,
>>
>>  I am setting up a GWT project to produce the JavaScript code for a 
>> web site. The application is only 
>> going to argument the dynamic elements of a web page providing the glue 
>> to hold everything dynamic 
>> together by creating a single entry point and discovering the required 
>> functionality by inspecting the dom
>> tree on startup.
>>
>> The HTML page is completely dynamic and is generated by a in-house 
>> framework meaning I am totally in control
>> over every aspect of page creation.
>>
>> Since the JavaScript is developed independently at different speed, I 
>> want to be able to compile the project
>> to update the JS assets of another project and this newly compiled JS 
>> gets committed within the project.
>>
>> To simplify the generation and usage and also to remove the clutter I 
>> want to have a single JavaScript file
>> for each browser version that my web page will draw from depending on the 
>> user-agent that is transmitted.
>>
>> I also wonder what is needed in such a setup to debug the client code 
>> using the development mode. I guess
>> I have to run GWT with the -noserver argument and also add the 
>> ?code-server query parameter in the 
>> web-framework. Right?
>>
>
> What you're trying to do is basically move the selection script to the 
> server side. This is exactly what Google is doing for years (you'll find 
> mentions of  in comments, commits or issues, standing for Server-Side 
> Selection Script).
> What you need is a special Linker to output each permutation's script in a 
> standalone script (rather than one that expects to be loaded by a JS 
> selection script). I never really thought about how it would/should work so 
> I'm afraid I can't provide more info on this (ask Googlers though; I 
> believe they somehow extend CrossSiteIframeLinker).
> To choose the right script to use, the CrossSiteIframeLinker generates a 
> file with the property mappings which you should be able to use.
> I wonder what kind of work would be needed if you have other binding 
> properties than user.agent (and/or locale) that couldn't be determined on 
> the server-side. Maybe you'd need to collapse those so that the selection 
> script only deals with properties that can be computed on the server-side 
> (again, ask Googlers if they can help).
>
> And for DevMode, you'd have to load devmode.js somehow instead of your 
> permutation. That can easily be triggered by the presence of ?gwt.codesvr 
> in the query-string.
> That said, I have no idea what's needed otherwise (e.g. if you want to use 
> your server-side-computed property values)
>

-- 
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-web-toolkit+unsubscr...@googlegroups.com.
To post to this group, send email to google-web-toolkit@googlegroups.com.
Visit this group at http://groups.google.com/group/google-web-toolkit.
For more options, visit https://groups.google.com/groups/opt_out.


Re: Automatically generated GWT Wrapper

2013-12-17 Thread Srini v
It will be great if you can send principles we need such took and may be we
can also help

On Monday, 16 December 2013, Jozef Môstka wrote:

>
>
> Dňa streda, 5. júna 2013 3:25:05 UTC+2 Martin Kimmel napísal(-a):
>>
>>
>> Else I would like to try programming such a tool.
>> Do you have any input what things I have to consider when doing so?
>>
>
> Hi,
> Im actualy working on gwt wraper generator. Its not public now. So if you
> wont help, send Email and I will give you svn access, and I'll explain the
> principles.
>
>
> --
> You received this message because you are subscribed to the Google Groups
> "Google Web Toolkit" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to google-web-toolkit+unsubscr...@googlegroups.com 'cvml',
> 'google-web-toolkit%2bunsubscr...@googlegroups.com');>.
> To post to this group, send email to 
> google-web-toolkit@googlegroups.com 'google-web-toolkit@googlegroups.com');>
> .
> Visit this group at http://groups.google.com/group/google-web-toolkit.
> For more options, visit https://groups.google.com/groups/opt_out.
>

-- 
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-web-toolkit+unsubscr...@googlegroups.com.
To post to this group, send email to google-web-toolkit@googlegroups.com.
Visit this group at http://groups.google.com/group/google-web-toolkit.
For more options, visit https://groups.google.com/groups/opt_out.


Re: Layout with nested SplitLayoutPanel

2013-12-17 Thread Patrick Tucker
I took your PortalPanel class above and added it to the page using 
RootLayoutPanel.get().add(Widget)

This is what it took to get your widgets sizing properly:

 public void resetSplitters () {

// parent height

int ph = this.getParent().getOffsetHeight();

// parent width

int pw = this.getParent().getOffsetWidth();

  

slp_Outer.setWidgetSize(slp_North, ph/2);

slp_North.setWidgetSize(fp_West, pw/2);

 }


I was able to call this from both onAttach and onResize.

Hope this helps!

On Monday, December 16, 2013 2:10:26 PM UTC-5, Patrick Tucker wrote:
>
> I'm pretty sure your problem is above PortalPanel.  I will try to put all 
> of the pieces together tonight.
>
> On Monday, December 16, 2013 11:49:50 AM UTC-5, Magnus wrote:
>
>> Hi Patrick,
>>
>> nothing happens. What am I doing wrong?
>>
>> Magnus
>>
>> -
>>
>> public class PortalPanel extends Composite implements RequiresResize
>> {
>>  private static PortalPanelUiBinder uiBinder = GWT.create 
>> (PortalPanelUiBinder.class);
>>  
>>  @UiField SplitLayoutPanel slp_Outer;
>>  @UiField SplitLayoutPanel slp_North;
>>
>>  interface PortalPanelUiBinder extends UiBinder
>>  {
>>  }
>>
>>  public PortalPanel()
>>  {
>>   initWidget (uiBinder.createAndBindUi (this));
>>  }
>>
>>  public void resetSplitters ()
>>  {
>>   int pys = this.getOffsetHeight ();
>>   int ys = pys / 2;
>>   
>>   // Window.alert ("ys: " + ys); // it's a  non zero height when called 
>> from within onResize
>>   slp_North.setHeight (ys + "px");
>>  }
>>  
>>  @Override
>>  public void onResize()
>>  {
>>   resetSplitters ();
>>  }
>> }
>>
>> -
>>
>> http://dl.google.com/gwt/DTD/xhtml.ent";>
>> >  xmlns:g="urn:import:com.google.gwt.user.client.ui">
>>  
>>   
>>  
>>
>>  
>>
>>   
>>  
>> 
>>
>> 
>>  
>>   
>>  
>>
>> 
>>
>> 
>>  
>>   
>>  
>> 
>>
>>
>>   
>>   
>>
>>   
>>
>>
>> 
>>
>>
>>   
>>
>>  
>>
>>  
>>
>>

-- 
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-web-toolkit+unsubscr...@googlegroups.com.
To post to this group, send email to google-web-toolkit@googlegroups.com.
Visit this group at http://groups.google.com/group/google-web-toolkit.
For more options, visit https://groups.google.com/groups/opt_out.


Re: Automatically generated GWT Wrapper

2013-12-17 Thread Jozef Môstka
Hi,

Its simple. I use Nodejs because parser for js exist only in js. 
https://github.com/ariya/esprima .

Im do parser only for styled js syntax. som js must be writed slyle like 
Foo.prototype.func=function. But can be maded for other style.
Also, best result will be only from orifinal js source, not minified, in 
original directory structure.
In first step I will look for all files is floders, so I can create from 
path namespace.
second step I will parse all classes, properties and method. so I get basic 
object structure.
next step I will parse coments, if exist. And try read from there types of 
properties and arguments, its not necessary, but its fastes and more 
corrects.
nex step I will look for types of arguments. So in Each object I will look 
inside all methods, and look how its use his properties. in evry use of 
property I will look whats method and propery is readed from that property 
and remember it. when I look in all object for one property, I will look in 
all object in project and try to find best match for that object. If none 
is find, JavaScriptObject will be used in gwt as type.
same thinks will be used for method arguments. but, (also in public 
property looking can be used) will looking not only inside method, but also 
where method is used. before method is used, value must be initialized, so 
I will look there.
There is also anonimus finctions. so there we bust generate for his good 
names.

It is of course hard to exercise and time. But this things its doing only 
one time.

one detail is, for parsing comments can be maded interface. so in evry code 
can be diferent comment.

I have Idea how must be work, But I have realy not idea, How to write this 
and how to organize code.

If somebody think is good ide, we can create public repository.

Second big think I have is to rewrite also body of functions I will be this 
done. so all javascript will be converted to java.

Dňa streda, 18. decembra 2013 1:35:00 UTC+1 chinni napísal(-a):
>
> It will be great if you can send principles we need such took and may be 
> we can also help
>
> On Monday, 16 December 2013, Jozef Môstka wrote:
>
>>
>>
>> Dňa streda, 5. júna 2013 3:25:05 UTC+2 Martin Kimmel napísal(-a):
>>>
>>>
>>> Else I would like to try programming such a tool.
>>> Do you have any input what things I have to consider when doing so?
>>>
>>
>> Hi,
>> Im actualy working on gwt wraper generator. Its not public now. So if you 
>> wont help, send Email and I will give you svn access, and I'll explain the 
>> principles.
>>  
>>
>> -- 
>> You received this message because you are subscribed to the Google Groups 
>> "Google Web Toolkit" group.
>> To unsubscribe from this group and stop receiving emails from it, send an 
>> email to google-web-toolkit+unsubscr...@googlegroups.com.
>> To post to this group, send email to google-web-toolkit@googlegroups.com.
>> Visit this group at http://groups.google.com/group/google-web-toolkit.
>> For more options, visit https://groups.google.com/groups/opt_out.
>>
>

-- 
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-web-toolkit+unsubscr...@googlegroups.com.
To post to this group, send email to google-web-toolkit@googlegroups.com.
Visit this group at http://groups.google.com/group/google-web-toolkit.
For more options, visit https://groups.google.com/groups/opt_out.