Fwd: Re: Who are the steering committee members?

2020-06-03 Thread Michael Conrad


Don't know if anyone saw this one.. but it appears the website needs 
updating? And the steering committe mailing list membership updated or 
list removed?


 Forwarded Message 
Subject:Re: Who are the steering committee members?
Date:   Tue, 2 Jun 2020 23:01:48 -0700 (PDT)
From:   'Goktug Gokdogan' via GWT Steering 
Reply-To:   gwt-steer...@googlegroups.com
To: GWT Steering 



Friendly ping.

GWT need a list of active members of Steering committee and functioning 
body; as it is it looks like GWT Steering Committee is silently 
disbanded and no longer making decisions.


On Monday, June 1, 2020 at 12:39:57 PM UTC-7, Julien Dramaix wrote:

   Hi,

   Who are the steering committee members right now ?

   The current list  on the
   website still contains names of people that either communicated
   their intention to leave the committee or are not active for years.

   -Julien

--
You received this message because you are subscribed to the Google 
Groups "GWT Steering" group.
To unsubscribe from this group and stop receiving emails from it, send 
an email to gwt-steering+unsubscr...@googlegroups.com 
.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/gwt-steering/0b3edba9-ec3a-4ff5-8045-b98761d33382%40googlegroups.com 
.


--
You received this message because you are subscribed to the Google Groups "GWT 
Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-web-toolkit+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-web-toolkit/59372724-5d3d-f0ca-27a6-14c29a705cd0%40newsrx.com.


[gwt-contrib] Fwd: Intent to Deprecate and Freeze: The User-Agent string

2020-01-14 Thread t . broyer
This is going to directly impact the selection script and permutation-based 
compilation of GWT 2.x.
I've read several times that some people use a single user.agent value 
(can't remember if it's gecko1_8 or safari), do we have some guarantees 
that this will work reliably across "evergreen browsers"? Time to make 
gecko1_8 and safari permutations converge? (and let's declare ie8/ie9/ie10 
as dead; in other words, time to remove UA-based permutations even before 
GWT3/J2Cl?)

On Tuesday, January 14, 2020 at 12:22:00 PM UTC+1, Yoav Weiss wrote:
>
> Contact emails
>
> yoavwe...@chromium.org , aaron...@chromium.org 
>
> Summary
>
> We want to freeze and unify (but not remove) the User Agent string in 
> HTTP requests as well as in `navigator.userAgent`
>
> Motivation
>
> The User-Agent string is an abundant source of passive fingerprinting 
> information about our users. It contains many details about the user’s 
> browser and device as well as many lies ("Mozilla/5.0", anyone?) that were 
> or are needed for compatibility purposes, as servers grew reliant on bad 
> User Agent sniffing.
>
> On top of those privacy issues, User-Agent sniffing is an abundant source 
> of compatibility issues, in particular for minority browsers, resulting in 
> browsers lying about themselves (generally 
> 
>  
> or to specific sites 
> ),
>  
> and sites (including Google properties) being broken 
> 
>  
> in some browsers for no good reason.
>
> The above abuse makes it desirable to freeze the UA string and replace it 
> with a better mechanism. There have been past attempts at UA string 
> freezing from the Safari team, but without an alternative way to perform UA 
> based content-negotiation, they had to be partially reverted.
>
>  
>
> The User Agent Client Hints  
> (UA-CH) feature provides an alternate source for the information the 
> User-Agent string provides, both in its request header form as well as its 
> JS API one. 
>
> Its main advantages are:
>
>- 
>
>It provides the required information only when the server requests it, 
>over secure connections, making any fingerprinting that relies on it be 
> active 
>fingerprinting, which enables such use to be audited, as well as 
>acted-upon by the browser (e.g. in a future implementation of the Privacy 
>Budget ).
>- 
>
>It provides the information in small increments, so servers are only 
>exposed to the information they need and request, rather than being 
> exposed 
>to the full gamut of the UA string even if they are just trying to figure 
>out one detail about the browser. (e.g. brand and major version)
>- 
>
>Since it provides the information via dedicated fields, it enables 
>better ergonomics and makes it less likely for servers to get it wrong and 
>cause compatibility issues.
>- 
>
>And finally, starting fresh will enable us to drop a lot of the legacy 
>baggage that the UA string carries (“Mozilla/5.0”, “like Gecko”, “like 
>KHTML”, etc) going forward.
>
>
> Once UA-CH ships 
> 
>  
> as an alternative means for browser-specific content adaptation, we would 
> like to freeze the User-Agent string. 
>
> We propose to deprecate at M81 (starting to emit console warnings in pages 
> that read that string in JS), freeze its version information at M83, and 
> unify strings of different devices at M85. See detailed freezing plan 
> below. 
>
> This timeline provides 3 months for developers to move to the new 
> mechanism for their future browser and OS version needs, and 6 months for 
> more sophisticated OS or device specific targeting.
>
> Freezing plan
>
> Different parts of the UA string have different compatibility 
> implications. 
>
> Some parts of it, such as the browser version and the OS version, can be 
> frozen without any backwards compatibility implications. Values that worked 
> in the past will continue to work in the future.
>
> Other parts, such as the model (for mobile devices) and the OS platform, 
> can have implications on sites that tailor their UI to the underlying OS or 
> that target a very specific model in their layout. Such sites will need to 
> migrate to use UA-CH.
>
>
> As such we are planning to freeze the parts that are amenable to freezing 
> fairly early, and gradually unify the rest.
>
>
> Milestone
>
> Stable date
>
> Action
>
> M81
>
> Mid March ‘20
>
> Deprecate access to `navigator.userAgent` 
>
> M83
>
> Early June ‘20
>
> 

Re: [gwt-contrib] Fwd: Happy to announce general access for J2CL!

2018-11-21 Thread 'Roberto Lublinerman' via GWT Contributors
To save you some pain, you should probably use the WSL (Windows Subsystem
for Linux). You can track the progress for and contribute to making it work
natively in https://github.com/google/j2cl/issues/9.

On Wed, Nov 21, 2018 at 4:32 PM Jason Washo  wrote:

> Awesome! I'm starting the process now. Windows user, and looking forward
> to it!
>
> --
> You received this message because you are subscribed to the Google Groups
> "GWT Contributors" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to google-web-toolkit-contributors+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/google-web-toolkit-contributors/433b82b7-0265-41a3-ad63-54ea55dda5f1%40googlegroups.com
> .
> For more options, visit https://groups.google.com/d/optout.
>

-- 
You received this message because you are subscribed to the Google Groups "GWT 
Contributors" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-web-toolkit-contributors+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-web-toolkit-contributors/CAC7T7gkhQfn4UycLAXph4Dy6xbAJ%3DZ_qY8PomAYfhY%3Da4kmLEw%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


[gwt-contrib] Fwd: Happy to announce general access for J2CL!

2018-11-21 Thread Jason Washo
Awesome! I'm starting the process now. Windows user, and looking forward to it!

-- 
You received this message because you are subscribed to the Google Groups "GWT 
Contributors" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-web-toolkit-contributors+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-web-toolkit-contributors/433b82b7-0265-41a3-ad63-54ea55dda5f1%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[gwt-contrib] Fwd: Happy to announce general access for J2CL!

2018-11-13 Thread 'Goktug Gokdogan' via GWT Contributors
-- Forwarded message -
From: Goktug Gokdogan 
Date: Tue, Nov 13, 2018 at 5:38 PM
Subject: Happy to announce general access for J2CL!
To: 


Dear GWTers!

We are happy to announce that we have opened up J2CL repository for general
access:
http://github.com/google/j2cl

Please see the README for details and instructions.

I also would like to use this opportunity to thank all Googlers who
contributed over the years and made this happen.

Enjoy!

Goktug, on behalf of J2CL team

PS: If you are using Windows, you might have a bumpy road but should get
better over time with your feedback and contributions.

-- 
You received this message because you are subscribed to the Google Groups "GWT 
Contributors" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-web-toolkit-contributors+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-web-toolkit-contributors/CAN%3DyUA2sBEt4WqPXMU7XBpL8mwpqJPPJtjUv_dF%2B6wh2pMVZ3A%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: [gwt-contrib] Fwd: jsinterop: @JsFunction .length always 0

2017-06-28 Thread Vassilis Virvilis
Yep I have done it like this exactly but this creates a JSNI dependency. My
reports were assuming that JSNI is a soon to be deprecated thing or at
least further investment on it is should be avoided.

However, thanks for the development insight.


On Wed, Jun 28, 2017 at 7:56 PM, 'Roberto Lublinerman' via GWT Contributors
 wrote:

> Not likely to be implemented in the foreseeable future; your best solution
> is to create two JavaScript methods (or JSNI)
>
> function asAccessor(f) {
>   return function (a) { return f(a); };
> }
>
> function asComparator(f) {
>   return function (a, b) { return f(a, b); };
> }
>
> It would be possible to implement @JsFunction lambdas without a backing
> class and that would result in the function having the same number of
> parameters as the lambda. But as I said this is unlikely to be implemented
> in the foreseeable future as it would require a new Java AST node and thus
> changes throughout the code base.
>
> On Tue, Jun 27, 2017 at 2:28 PM, Vassilis Virvilis 
> wrote:
>
>> Do you want me to report it as issue? If so where?
>>
>> Is it possible for @JsFunction magic to implement it some day? or it is
>> impossible to be implemented with the current design?
>>
>> Thanks again for all the answers so far.
>>
>> Vassilis
>>
>> On Tue, Jun 27, 2017 at 7:40 PM, 'Roberto Lublinerman' via GWT
>> Contributors  wrote:
>>
>>> You can call it a missing feature. Clearly not a bug, not everything
>>> that can be done in JS is available from Java with interop. For these
>>> situations you probably want to have some JS stubs.
>>>
>>> On Tue, Jun 27, 2017 at 1:09 AM, Vassilis Virvilis 
>>> wrote:
>>>
 Ok guys this is the last one - I promise.

 Originally posted in gwt-users.

 Does this count as a bug or at least as a missing feature?

 Thanks

 -- Forwarded message --
 From: Vassilis Virvilis 
 Date: Mon, Mar 6, 2017 at 4:08 PM
 Subject: jsinterop: @JsFunction .length always 0
 To: google-web-tool...@googlegroups.com


 Hi,

 in D3 the bisect function takes a function that can be a comparator or
 an accessor.

 D3 internall figures it out by counting provided function arguments
 length via f.length https://developer.mozilla.org/
 en/docs/Web/JavaScript/Reference/Global_Objects/Function/length

 Trying to pass a java @JsFunction fails because @JsFunction objects are
 lambda with zero arguments that wrap samMethod.apply() call

 Any ideas? Should I file this as a bug?


 --
 Vassilis Virvilis



 --
 Vassilis Virvilis

 --
 You received this message because you are subscribed to the Google
 Groups "GWT Contributors" group.
 To unsubscribe from this group and stop receiving emails from it, send
 an email to google-web-toolkit-contributor
 s+unsubscr...@googlegroups.com.
 To view this discussion on the web visit https://groups.google.com/d/ms
 gid/google-web-toolkit-contributors/CAKbOjEx1_jOohikJ7nBAfps
 E%3DJHtnD6M31PibMzjvcjLn7G1fw%40mail.gmail.com
 
 .
 For more options, visit https://groups.google.com/d/optout.

>>>
>>> --
>>> You received this message because you are subscribed to the Google
>>> Groups "GWT Contributors" group.
>>> To unsubscribe from this group and stop receiving emails from it, send
>>> an email to google-web-toolkit-contributors+unsubscr...@googlegroups.com
>>> .
>>> To view this discussion on the web visit https://groups.google.com/d/ms
>>> gid/google-web-toolkit-contributors/CAC7T7g%3D_JcBzZaNnjBosA
>>> mcQ_Bm8Bn9r-_7LfFi%3DDu5r%2BO1h1A%40mail.gmail.com
>>> 
>>> .
>>> For more options, visit https://groups.google.com/d/optout.
>>>
>>
>>
>>
>> --
>> Vassilis Virvilis
>>
>> --
>> You received this message because you are subscribed to the Google Groups
>> "GWT Contributors" group.
>> To unsubscribe from this group and stop receiving emails from it, send an
>> email to google-web-toolkit-contributors+unsubscr...@googlegroups.com.
>> To view this discussion on the web visit https://groups.google.com/d/ms
>> gid/google-web-toolkit-contributors/CAKbOjEzKqjBGngrz%3DNES1
>> bEe24ejg48mHzBw3L9fLP3JC11_%2BA%40mail.gmail.com
>> 
>> .
>>
>> For more options, visit 

Re: [gwt-contrib] Fwd: jsinterop: @JsFunction .length always 0

2017-06-28 Thread Vassilis Virvilis
@thomas

all valid points and interesting links. Thanks for the insight.

To my defense however I want to state again that I have not devised this
API.

It's the official API of D3

   - v3
   https://github.com/d3/d3-3.x-api-reference/blob/master/Arrays.md#d3_bisector
   - v4 https://github.com/d3/d3-array/blob/master/README.md#bisector


so it is not possible to change the API. If I take a step back (not
realistic) and say that I won't use D3 at all because it has such a bad API
(not true. Generally I enjoy the D3 very much.) I am sure I will hit
similar snags in other js libraries.

So... better the devil you know

 Vassilis


On Wed, Jun 28, 2017 at 4:12 PM, Thomas Broyer  wrote:

>
>
> On Wednesday, June 28, 2017 at 2:21:16 PM UTC+2, Vassilis Virvilis wrote:
>>
>> I am not following the implementation details and I cannot judge on the
>> compromises front.
>>
>> But from a user standpoint this should be implemented because a
>> @JsFunction should generate a js function()  and a js function() happens to
>> have a length member by specification (see https://developer.mozilla.org/
>> en/docs/Web/JavaScript/Reference/Global_Objects/Function/length )
>>
>> Otherwise @JsFunction is not a js function() but something callable
>> instead.
>>
>
> GWT generates a function, but a function with an empty formal parameter
> list (and as a result a length of 0), because it simply uses 'arguments':
> https://github.com/gwtproject/gwt/blob/2.8.1/
> dev/core/super/com/google/gwt/dev/jjs/intrinsic/com/google/
> gwt/lang/Runtime.java#L158-L169
>
>
>> Given the dynamic number of javascript I expect that these kind of checks
>> to be common enough to warrant the effort.
>>
>
> One could argue the reverse: due to the dynamic nature of JS, 'length' of
> a function isn't reliable, and you'd be better off using distinct APIs
> rather than driving behavior by inferring things from inputs, or more
> precisely be explicit with your intent.
> It easily fails you, as soon as you wrap a function to bind, curry,
> memoize it, whatever, using a generic factory (one that uses 'arguments'
> along with Function.prototype.apply or Function.prototype.call; one that
> specifically doesn't use Function.prototype.bind).
> Have a look at the Function.prototype.bind polyfill from the MDN for
> example: https://developer.mozilla.org/en-US/docs/Web/
> JavaScript/Reference/Global_Objects/Function/bind#Polyfill
> Any code targeting IE8 or older (that doesn't necessarily mean new code)
> would need this polyfill, and the returned function (fBound) has a length
> of 0, irrespective of the length of the function to bind.
> There's a polyfill for Function.prototype.bind that returns a function
> with the correct 'length', but it uses new Function() with a string body:
> https://github.com/Raynos/function-bind/blob/
> 83e639ff74e6cd6921285bccec22c1bcf72311bd/implementation.js#L38 so it'd
> break most CSP. While IE8 doesn't support CSP (so it's OK for this
> particular polyfill), that however means you cannot use such a trick for
> other things you'd like to do with a function (such as memoizing it: for
> example, https://github.com/caiogondim/fast-memoize.js returns a function
> with length 0 too).
>
> --
> You received this message because you are subscribed to the Google Groups
> "GWT Contributors" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to google-web-toolkit-contributors+unsubscr...@googlegroups.com.
> To view this discussion on the web visit https://groups.google.com/d/
> msgid/google-web-toolkit-contributors/e12e8c02-c6f0-
> 4818-aaee-fb564935e8ec%40googlegroups.com
> 
> .
>
> For more options, visit https://groups.google.com/d/optout.
>



-- 
Vassilis Virvilis

-- 
You received this message because you are subscribed to the Google Groups "GWT 
Contributors" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-web-toolkit-contributors+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-web-toolkit-contributors/CAKbOjEwwD-hDNBt8QEE2h0k74yxpFWdCsX5J5Lh3%3DsHeGptDcw%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: [gwt-contrib] Fwd: jsinterop: @JsFunction .length always 0

2017-06-28 Thread 'Roberto Lublinerman' via GWT Contributors
Not likely to be implemented in the foreseeable future; your best solution
is to create two JavaScript methods (or JSNI)

function asAccessor(f) {
  return function (a) { return f(a); };
}

function asComparator(f) {
  return function (a, b) { return f(a, b); };
}

It would be possible to implement @JsFunction lambdas without a backing
class and that would result in the function having the same number of
parameters as the lambda. But as I said this is unlikely to be implemented
in the foreseeable future as it would require a new Java AST node and thus
changes throughout the code base.

On Tue, Jun 27, 2017 at 2:28 PM, Vassilis Virvilis 
wrote:

> Do you want me to report it as issue? If so where?
>
> Is it possible for @JsFunction magic to implement it some day? or it is
> impossible to be implemented with the current design?
>
> Thanks again for all the answers so far.
>
> Vassilis
>
> On Tue, Jun 27, 2017 at 7:40 PM, 'Roberto Lublinerman' via GWT
> Contributors  wrote:
>
>> You can call it a missing feature. Clearly not a bug, not everything that
>> can be done in JS is available from Java with interop. For these situations
>> you probably want to have some JS stubs.
>>
>> On Tue, Jun 27, 2017 at 1:09 AM, Vassilis Virvilis 
>> wrote:
>>
>>> Ok guys this is the last one - I promise.
>>>
>>> Originally posted in gwt-users.
>>>
>>> Does this count as a bug or at least as a missing feature?
>>>
>>> Thanks
>>>
>>> -- Forwarded message --
>>> From: Vassilis Virvilis 
>>> Date: Mon, Mar 6, 2017 at 4:08 PM
>>> Subject: jsinterop: @JsFunction .length always 0
>>> To: google-web-tool...@googlegroups.com
>>>
>>>
>>> Hi,
>>>
>>> in D3 the bisect function takes a function that can be a comparator or
>>> an accessor.
>>>
>>> D3 internall figures it out by counting provided function arguments
>>> length via f.length https://developer.mozilla.org/
>>> en/docs/Web/JavaScript/Reference/Global_Objects/Function/length
>>>
>>> Trying to pass a java @JsFunction fails because @JsFunction objects are
>>> lambda with zero arguments that wrap samMethod.apply() call
>>>
>>> Any ideas? Should I file this as a bug?
>>>
>>>
>>> --
>>> Vassilis Virvilis
>>>
>>>
>>>
>>> --
>>> Vassilis Virvilis
>>>
>>> --
>>> You received this message because you are subscribed to the Google
>>> Groups "GWT Contributors" group.
>>> To unsubscribe from this group and stop receiving emails from it, send
>>> an email to google-web-toolkit-contributors+unsubscr...@googlegroups.com
>>> .
>>> To view this discussion on the web visit https://groups.google.com/d/ms
>>> gid/google-web-toolkit-contributors/CAKbOjEx1_jOohikJ7nBAfps
>>> E%3DJHtnD6M31PibMzjvcjLn7G1fw%40mail.gmail.com
>>> 
>>> .
>>> For more options, visit https://groups.google.com/d/optout.
>>>
>>
>> --
>> You received this message because you are subscribed to the Google Groups
>> "GWT Contributors" group.
>> To unsubscribe from this group and stop receiving emails from it, send an
>> email to google-web-toolkit-contributors+unsubscr...@googlegroups.com.
>> To view this discussion on the web visit https://groups.google.com/d/ms
>> gid/google-web-toolkit-contributors/CAC7T7g%3D_JcBzZaNnjBosA
>> mcQ_Bm8Bn9r-_7LfFi%3DDu5r%2BO1h1A%40mail.gmail.com
>> 
>> .
>> For more options, visit https://groups.google.com/d/optout.
>>
>
>
>
> --
> Vassilis Virvilis
>
> --
> You received this message because you are subscribed to the Google Groups
> "GWT Contributors" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to google-web-toolkit-contributors+unsubscr...@googlegroups.com.
> To view this discussion on the web visit https://groups.google.com/d/ms
> gid/google-web-toolkit-contributors/CAKbOjEzKqjBGngrz%3DNES1
> bEe24ejg48mHzBw3L9fLP3JC11_%2BA%40mail.gmail.com
> 
> .
>
> For more options, visit https://groups.google.com/d/optout.
>

-- 
You received this message because you are subscribed to the Google Groups "GWT 
Contributors" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-web-toolkit-contributors+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-web-toolkit-contributors/CAC7T7gnJC5tBdXqwr1B4wYTz4UNLppqxpbp4ydZUe7xx8qYCrg%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: [gwt-contrib] Fwd: jsinterop: @JsFunction .length always 0

2017-06-28 Thread Thomas Broyer


On Wednesday, June 28, 2017 at 2:21:16 PM UTC+2, Vassilis Virvilis wrote:
>
> I am not following the implementation details and I cannot judge on the 
> compromises front.
>
> But from a user standpoint this should be implemented because a 
> @JsFunction should generate a js function()  and a js function() happens to 
> have a length member by specification (see 
> https://developer.mozilla.org/en/docs/Web/JavaScript/Reference/Global_Objects/Function/length
>  
> )
>
> Otherwise @JsFunction is not a js function() but something callable 
> instead.
>

GWT generates a function, but a function with an empty formal parameter 
list (and as a result a length of 0), because it simply uses 
'arguments': 
https://github.com/gwtproject/gwt/blob/2.8.1/dev/core/super/com/google/gwt/dev/jjs/intrinsic/com/google/gwt/lang/Runtime.java#L158-L169
 

> Given the dynamic number of javascript I expect that these kind of checks 
> to be common enough to warrant the effort.
>

One could argue the reverse: due to the dynamic nature of JS, 'length' of a 
function isn't reliable, and you'd be better off using distinct APIs rather 
than driving behavior by inferring things from inputs, or more precisely be 
explicit with your intent.
It easily fails you, as soon as you wrap a function to bind, curry, memoize 
it, whatever, using a generic factory (one that uses 'arguments' along with 
Function.prototype.apply or Function.prototype.call; one that specifically 
doesn't use Function.prototype.bind).
Have a look at the Function.prototype.bind polyfill from the MDN for 
example: 
https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Function/bind#Polyfill
Any code targeting IE8 or older (that doesn't necessarily mean new code) 
would need this polyfill, and the returned function (fBound) has a length 
of 0, irrespective of the length of the function to bind.
There's a polyfill for Function.prototype.bind that returns a function with 
the correct 'length', but it uses new Function() with a string 
body: 
https://github.com/Raynos/function-bind/blob/83e639ff74e6cd6921285bccec22c1bcf72311bd/implementation.js#L38
 
so it'd break most CSP. While IE8 doesn't support CSP (so it's OK for this 
particular polyfill), that however means you cannot use such a trick for 
other things you'd like to do with a function (such as memoizing it: for 
example, https://github.com/caiogondim/fast-memoize.js returns a function 
with length 0 too).

-- 
You received this message because you are subscribed to the Google Groups "GWT 
Contributors" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-web-toolkit-contributors+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-web-toolkit-contributors/e12e8c02-c6f0-4818-aaee-fb564935e8ec%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [gwt-contrib] Fwd: jsinterop: @JsFunction .length always 0

2017-06-28 Thread Vassilis Virvilis
I am not following the implementation details and I cannot judge on the
compromises front.

But from a user standpoint this should be implemented because a @JsFunction
should generate a js function()  and a js function() happens to have a
length member by specification (see
https://developer.mozilla.org/en/docs/Web/JavaScript/Reference/Global_Objects/Function/length
)

Otherwise @JsFunction is not a js function() but something callable instead.

Given the dynamic number of javascript I expect that these kind of checks
to be common enough to warrant the effort.

Now if GWT generated script becomes 2x heavier and 4x slower you may forget
the feature. It still needs to be posted as an issue to host the discussion
though.

Vassilis



On Wed, Jun 28, 2017 at 10:51 AM, Thomas Broyer  wrote:

> I suppose makeLambdaFunction could be "inlined" (possibly into a static
> factory, one per class), with the 'lambda' then generated with the proper
> number of formal arguments to "initialize" its 'length' property? Would
> that hurt "optimizability" a lot?
> Or is that not worth it (too much of an edge case) and the static factory
> (of a wrapper function then) should rather be implemented with JSNI? (or
> the equivalent for j2cl)
>
>
> On Tuesday, June 27, 2017 at 6:41:03 PM UTC+2, Roberto Lublinerman wrote:
>>
>> You can call it a missing feature. Clearly not a bug, not everything that
>> can be done in JS is available from Java with interop. For these situations
>> you probably want to have some JS stubs.
>>
>> On Tue, Jun 27, 2017 at 1:09 AM, Vassilis Virvilis 
>> wrote:
>>
>>> Ok guys this is the last one - I promise.
>>>
>>> Originally posted in gwt-users.
>>>
>>> Does this count as a bug or at least as a missing feature?
>>>
>>> Thanks
>>>
>>> -- Forwarded message --
>>> From: Vassilis Virvilis 
>>> Date: Mon, Mar 6, 2017 at 4:08 PM
>>> Subject: jsinterop: @JsFunction .length always 0
>>> To: google-web-tool...@googlegroups.com
>>>
>>>
>>> Hi,
>>>
>>> in D3 the bisect function takes a function that can be a comparator or
>>> an accessor.
>>>
>>> D3 internall figures it out by counting provided function arguments
>>> length via f.length https://developer.mozilla.org/
>>> en/docs/Web/JavaScript/Reference/Global_Objects/Function/length
>>>
>>> Trying to pass a java @JsFunction fails because @JsFunction objects are
>>> lambda with zero arguments that wrap samMethod.apply() call
>>>
>>> Any ideas? Should I file this as a bug?
>>>
>>>
>>> --
>>> Vassilis Virvilis
>>>
>>>
>>>
>>> --
>>> Vassilis Virvilis
>>>
>>> --
>>> You received this message because you are subscribed to the Google
>>> Groups "GWT Contributors" group.
>>> To unsubscribe from this group and stop receiving emails from it, send
>>> an email to google-web-toolkit-contributors+unsubscr...@googlegroups.com
>>> .
>>> To view this discussion on the web visit https://groups.google.com/d/ms
>>> gid/google-web-toolkit-contributors/CAKbOjEx1_jOohikJ7nBAfps
>>> E%3DJHtnD6M31PibMzjvcjLn7G1fw%40mail.gmail.com
>>> 
>>> .
>>> For more options, visit https://groups.google.com/d/optout.
>>>
>>
>> --
> You received this message because you are subscribed to the Google Groups
> "GWT Contributors" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to google-web-toolkit-contributors+unsubscr...@googlegroups.com.
> To view this discussion on the web visit https://groups.google.com/d/
> msgid/google-web-toolkit-contributors/a07991bc-7767-
> 46cb-80fd-655e1809f15b%40googlegroups.com
> 
> .
>
> For more options, visit https://groups.google.com/d/optout.
>



-- 
Vassilis Virvilis

-- 
You received this message because you are subscribed to the Google Groups "GWT 
Contributors" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-web-toolkit-contributors+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-web-toolkit-contributors/CAKbOjEzdoAN2MadkgMQv%3DSk22nfJ8%2BHHKdDUwQGuRgf%3D4a%3DWUQ%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: [gwt-contrib] Fwd: jsinterop: @JsFunction .length always 0

2017-06-28 Thread Thomas Broyer
I suppose makeLambdaFunction could be "inlined" (possibly into a static 
factory, one per class), with the 'lambda' then generated with the proper 
number of formal arguments to "initialize" its 'length' property? Would 
that hurt "optimizability" a lot?
Or is that not worth it (too much of an edge case) and the static factory 
(of a wrapper function then) should rather be implemented with JSNI? (or 
the equivalent for j2cl)

On Tuesday, June 27, 2017 at 6:41:03 PM UTC+2, Roberto Lublinerman wrote:
>
> You can call it a missing feature. Clearly not a bug, not everything that 
> can be done in JS is available from Java with interop. For these situations 
> you probably want to have some JS stubs.
>
> On Tue, Jun 27, 2017 at 1:09 AM, Vassilis Virvilis  
> wrote:
>
>> Ok guys this is the last one - I promise.
>>
>> Originally posted in gwt-users.
>>
>> Does this count as a bug or at least as a missing feature?
>>
>> Thanks
>>
>> -- Forwarded message --
>> From: Vassilis Virvilis 
>> Date: Mon, Mar 6, 2017 at 4:08 PM
>> Subject: jsinterop: @JsFunction .length always 0
>> To: google-web-tool...@googlegroups.com
>>
>>
>> Hi,
>>
>> in D3 the bisect function takes a function that can be a comparator or an 
>> accessor.
>>
>> D3 internall figures it out by counting provided function arguments 
>> length via f.length 
>> https://developer.mozilla.org/en/docs/Web/JavaScript/Reference/Global_Objects/Function/length
>>
>> Trying to pass a java @JsFunction fails because @JsFunction objects are 
>> lambda with zero arguments that wrap samMethod.apply() call
>>
>> Any ideas? Should I file this as a bug?
>>
>>
>> -- 
>> Vassilis Virvilis
>>
>>
>>
>> -- 
>> Vassilis Virvilis
>>
>> -- 
>> You received this message because you are subscribed to the Google Groups 
>> "GWT Contributors" group.
>> To unsubscribe from this group and stop receiving emails from it, send an 
>> email to google-web-toolkit-contributors+unsubscr...@googlegroups.com.
>> To view this discussion on the web visit 
>> https://groups.google.com/d/msgid/google-web-toolkit-contributors/CAKbOjEx1_jOohikJ7nBAfpsE%3DJHtnD6M31PibMzjvcjLn7G1fw%40mail.gmail.com
>>  
>> 
>> .
>> For more options, visit https://groups.google.com/d/optout.
>>
>
>

-- 
You received this message because you are subscribed to the Google Groups "GWT 
Contributors" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-web-toolkit-contributors+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-web-toolkit-contributors/a07991bc-7767-46cb-80fd-655e1809f15b%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [gwt-contrib] Fwd: jsinterop: @JsFunction .length always 0

2017-06-27 Thread Vassilis Virvilis
Do you want me to report it as issue? If so where?

Is it possible for @JsFunction magic to implement it some day? or it is
impossible to be implemented with the current design?

Thanks again for all the answers so far.

Vassilis

On Tue, Jun 27, 2017 at 7:40 PM, 'Roberto Lublinerman' via GWT Contributors
 wrote:

> You can call it a missing feature. Clearly not a bug, not everything that
> can be done in JS is available from Java with interop. For these situations
> you probably want to have some JS stubs.
>
> On Tue, Jun 27, 2017 at 1:09 AM, Vassilis Virvilis 
> wrote:
>
>> Ok guys this is the last one - I promise.
>>
>> Originally posted in gwt-users.
>>
>> Does this count as a bug or at least as a missing feature?
>>
>> Thanks
>>
>> -- Forwarded message --
>> From: Vassilis Virvilis 
>> Date: Mon, Mar 6, 2017 at 4:08 PM
>> Subject: jsinterop: @JsFunction .length always 0
>> To: google-web-tool...@googlegroups.com
>>
>>
>> Hi,
>>
>> in D3 the bisect function takes a function that can be a comparator or an
>> accessor.
>>
>> D3 internall figures it out by counting provided function arguments
>> length via f.length https://developer.mozilla.org/
>> en/docs/Web/JavaScript/Reference/Global_Objects/Function/length
>>
>> Trying to pass a java @JsFunction fails because @JsFunction objects are
>> lambda with zero arguments that wrap samMethod.apply() call
>>
>> Any ideas? Should I file this as a bug?
>>
>>
>> --
>> Vassilis Virvilis
>>
>>
>>
>> --
>> Vassilis Virvilis
>>
>> --
>> You received this message because you are subscribed to the Google Groups
>> "GWT Contributors" group.
>> To unsubscribe from this group and stop receiving emails from it, send an
>> email to google-web-toolkit-contributors+unsubscr...@googlegroups.com.
>> To view this discussion on the web visit https://groups.google.com/d/ms
>> gid/google-web-toolkit-contributors/CAKbOjEx1_jOohikJ7nBAfps
>> E%3DJHtnD6M31PibMzjvcjLn7G1fw%40mail.gmail.com
>> 
>> .
>> For more options, visit https://groups.google.com/d/optout.
>>
>
> --
> You received this message because you are subscribed to the Google Groups
> "GWT Contributors" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to google-web-toolkit-contributors+unsubscr...@googlegroups.com.
> To view this discussion on the web visit https://groups.google.com/d/
> msgid/google-web-toolkit-contributors/CAC7T7g%3D_
> JcBzZaNnjBosAmcQ_Bm8Bn9r-_7LfFi%3DDu5r%2BO1h1A%40mail.gmail.com
> 
> .
> For more options, visit https://groups.google.com/d/optout.
>



-- 
Vassilis Virvilis

-- 
You received this message because you are subscribed to the Google Groups "GWT 
Contributors" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-web-toolkit-contributors+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-web-toolkit-contributors/CAKbOjEzKqjBGngrz%3DNES1bEe24ejg48mHzBw3L9fLP3JC11_%2BA%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: [gwt-contrib] Fwd: jsinterop: @JsFunction .length always 0

2017-06-27 Thread 'Roberto Lublinerman' via GWT Contributors
You can call it a missing feature. Clearly not a bug, not everything that
can be done in JS is available from Java with interop. For these situations
you probably want to have some JS stubs.

On Tue, Jun 27, 2017 at 1:09 AM, Vassilis Virvilis 
wrote:

> Ok guys this is the last one - I promise.
>
> Originally posted in gwt-users.
>
> Does this count as a bug or at least as a missing feature?
>
> Thanks
>
> -- Forwarded message --
> From: Vassilis Virvilis 
> Date: Mon, Mar 6, 2017 at 4:08 PM
> Subject: jsinterop: @JsFunction .length always 0
> To: google-web-tool...@googlegroups.com
>
>
> Hi,
>
> in D3 the bisect function takes a function that can be a comparator or an
> accessor.
>
> D3 internall figures it out by counting provided function arguments length
> via f.length https://developer.mozilla.org/en/docs/Web/JavaScript/Referen
> ce/Global_Objects/Function/length
>
> Trying to pass a java @JsFunction fails because @JsFunction objects are
> lambda with zero arguments that wrap samMethod.apply() call
>
> Any ideas? Should I file this as a bug?
>
>
> --
> Vassilis Virvilis
>
>
>
> --
> Vassilis Virvilis
>
> --
> You received this message because you are subscribed to the Google Groups
> "GWT Contributors" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to google-web-toolkit-contributors+unsubscr...@googlegroups.com.
> To view this discussion on the web visit https://groups.google.com/d/
> msgid/google-web-toolkit-contributors/CAKbOjEx1_jOohikJ7nBAfpsE%
> 3DJHtnD6M31PibMzjvcjLn7G1fw%40mail.gmail.com
> 
> .
> For more options, visit https://groups.google.com/d/optout.
>

-- 
You received this message because you are subscribed to the Google Groups "GWT 
Contributors" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-web-toolkit-contributors+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-web-toolkit-contributors/CAC7T7g%3D_JcBzZaNnjBosAmcQ_Bm8Bn9r-_7LfFi%3DDu5r%2BO1h1A%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


[gwt-contrib] Fwd: jsinterop: @JsFunction .length always 0

2017-06-27 Thread Vassilis Virvilis
Ok guys this is the last one - I promise.

Originally posted in gwt-users.

Does this count as a bug or at least as a missing feature?

Thanks

-- Forwarded message --
From: Vassilis Virvilis 
Date: Mon, Mar 6, 2017 at 4:08 PM
Subject: jsinterop: @JsFunction .length always 0
To: google-web-tool...@googlegroups.com


Hi,

in D3 the bisect function takes a function that can be a comparator or an
accessor.

D3 internall figures it out by counting provided function arguments length
via f.length https://developer.mozilla.org/en/docs/Web/JavaScript/
Reference/Global_Objects/Function/length

Trying to pass a java @JsFunction fails because @JsFunction objects are
lambda with zero arguments that wrap samMethod.apply() call

Any ideas? Should I file this as a bug?


-- 
Vassilis Virvilis



-- 
Vassilis Virvilis

-- 
You received this message because you are subscribed to the Google Groups "GWT 
Contributors" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-web-toolkit-contributors+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-web-toolkit-contributors/CAKbOjEx1_jOohikJ7nBAfpsE%3DJHtnD6M31PibMzjvcjLn7G1fw%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: [gwt-contrib] Fwd: jsinterop woes: Part 2: return Double[]

2017-06-27 Thread Vassilis Virvilis
@Roberto,

Agreed in all points. double[] and Double[] is not the same thing in java
although it may be possible to be the same in js.

So until java supports autoboxing and unboxing in arrays I can see your
point.

Vassilis

On Tue, Jun 27, 2017 at 1:41 AM, 'Roberto Lublinerman' via GWT Contributors
 wrote:

>
>> @Roberto
>> Please note that I am not mixing stuff (java and js objects in the same
>> array, or different kind of objects in the same array).
>>
>> D3 is doing the correct thing here. If you pass an array of something,
>> let's say T[] you can expect that you will be getting T and T[] out of D3
>> functions (can't really remember the specifics). What I am passing are pure
>> js objects modeled with jsinterop, and they still count as js, not java. So
>> I am expecting to get back what I feed in / declared at the start.
>>
>>
> D3 is a JS api, even if some function says it will return an array of T,
> it is a JavaScript array, so there is no (type) guarantee that the array is
> of T. So it is an array of things, all of them of type T.
>
> A java T[] has even stronger semantics, if you set an element it will
> check that it is the correct type. So the D3 array is like an Object[] that
> happens to be filled all with Ts.
>
>
>> So what do I want: Double[] to be castable to double[] in the GWT js
>> context (not in the java context). I don't know if this is possible but it
>> is definitely desirable. (The same for String[] and Boolean[]) and a pony
>> of course :-)
>>
>>
> Again here Double[] and double[] have very different semantics in Java.
>
> - you can cast Double[] to Object[] but not double[] to Object[]
> - you can store nulls in Double[] but not in double[].
>
> They are semantically different. I agree that in some circumstances it
> seems convenient to ignore those. But in general GWT follows Java semantics
> (with a few exceptions)
>
>
>> Thanks again.
>>
>> --
>> You received this message because you are subscribed to the Google Groups
>> "GWT Contributors" group.
>> To unsubscribe from this group and stop receiving emails from it, send an
>> email to google-web-toolkit-contributors+unsubscr...@googlegroups.com.
>> To view this discussion on the web visit https://groups.google.com/d/ms
>> gid/google-web-toolkit-contributors/CAKbOjExku8sLUm3Ky7B6OF-
>> gx%3DvgvdP_v8nd-Pi0WNeqzyv06g%40mail.gmail.com
>> 
>> .
>>
>> For more options, visit https://groups.google.com/d/optout.
>>
>
> --
> You received this message because you are subscribed to the Google Groups
> "GWT Contributors" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to google-web-toolkit-contributors+unsubscr...@googlegroups.com.
> To view this discussion on the web visit https://groups.google.com/d/
> msgid/google-web-toolkit-contributors/CAC7T7gkupiRhKbO9CAmnKO9LUSh26
> veVjnQ0LqAGemeJvFWm9A%40mail.gmail.com
> 
> .
>
> For more options, visit https://groups.google.com/d/optout.
>



-- 
Vassilis Virvilis

-- 
You received this message because you are subscribed to the Google Groups "GWT 
Contributors" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-web-toolkit-contributors+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-web-toolkit-contributors/CAKbOjEz55x2WgHoWt88fScf%2BkCrAfR7%2BUb5Zhx_Qu5x45VcUpg%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: [gwt-contrib] Fwd: jsinterop woes: Part 2: return Double[]

2017-06-26 Thread 'Roberto Lublinerman' via GWT Contributors
>
>
> @Roberto
> Please note that I am not mixing stuff (java and js objects in the same
> array, or different kind of objects in the same array).
>
> D3 is doing the correct thing here. If you pass an array of something,
> let's say T[] you can expect that you will be getting T and T[] out of D3
> functions (can't really remember the specifics). What I am passing are pure
> js objects modeled with jsinterop, and they still count as js, not java. So
> I am expecting to get back what I feed in / declared at the start.
>
>
D3 is a JS api, even if some function says it will return an array of T, it
is a JavaScript array, so there is no (type) guarantee that the array is of
T. So it is an array of things, all of them of type T.

A java T[] has even stronger semantics, if you set an element it will check
that it is the correct type. So the D3 array is like an Object[] that
happens to be filled all with Ts.


> So what do I want: Double[] to be castable to double[] in the GWT js
> context (not in the java context). I don't know if this is possible but it
> is definitely desirable. (The same for String[] and Boolean[]) and a pony
> of course :-)
>
>
Again here Double[] and double[] have very different semantics in Java.

- you can cast Double[] to Object[] but not double[] to Object[]
- you can store nulls in Double[] but not in double[].

They are semantically different. I agree that in some circumstances it
seems convenient to ignore those. But in general GWT follows Java semantics
(with a few exceptions)


> Thanks again.
>
> --
> You received this message because you are subscribed to the Google Groups
> "GWT Contributors" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to google-web-toolkit-contributors+unsubscr...@googlegroups.com.
> To view this discussion on the web visit https://groups.google.com/d/
> msgid/google-web-toolkit-contributors/CAKbOjExku8sLUm3Ky7B6OF-gx%
> 3DvgvdP_v8nd-Pi0WNeqzyv06g%40mail.gmail.com
> 
> .
>
> For more options, visit https://groups.google.com/d/optout.
>

-- 
You received this message because you are subscribed to the Google Groups "GWT 
Contributors" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-web-toolkit-contributors+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-web-toolkit-contributors/CAC7T7gkupiRhKbO9CAmnKO9LUSh26veVjnQ0LqAGemeJvFWm9A%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: [gwt-contrib] Fwd: jsinterop woes: Part 2: return Double[]

2017-06-26 Thread Vassilis Virvilis
Hi and thanks for answering.

I also tend to believe this is not a bug - but - it is definitely in my
wish list.

@Colin jsinterop is certainly kind of fragile but if you bang your head
against it at the end you start understanding the errors. In most cases you
can fix the error by making the java code or the jsinterop declaration
__better__. This is a case that I had to uglify my bindings. So I don't
believe that is fails in new, unique and interesting ways. It is rather
consistent. It may be somewhat fragile and cryptic but it is consistent and
I don't believe that you will have a problem with element[] (assuming
element is a jsinterop native, and com.google.dom.dontremember.element),
double[] or boolean[]. But you will be in world of hurt if you try to
communicate Double[], Boolean[], String[].

@Roberto
Please note that I am not mixing stuff (java and js objects in the same
array, or different kind of objects in the same array).

D3 is doing the correct thing here. If you pass an array of something,
let's say T[] you can expect that you will be getting T and T[] out of D3
functions (can't really remember the specifics). What I am passing are pure
js objects modeled with jsinterop, and they still count as js, not java. So
I am expecting to get back what I feed in / declared at the start.

That part works.

I am putting Date[] --> I am getting back Date[] . Correct
I am putting double[] --> I am getting back double[] . Correct
I am putting Double[] --> I am getting back exception. Not so nice.

That basically means that I can't have a generic function that will work
with all kind of GenericTypes because double is not an object in java. That
means I have to special case the interface like this

  V get(T t); --> works great for JsObects as it should
  double getDouble(T t) --> ugly huh?

So what do I want: Double[] to be castable to double[] in the GWT js
context (not in the java context). I don't know if this is possible but it
is definitely desirable. (The same for String[] and Boolean[]) and a pony
of course :-)

Thanks again.

-- 
You received this message because you are subscribed to the Google Groups "GWT 
Contributors" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-web-toolkit-contributors+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-web-toolkit-contributors/CAKbOjExku8sLUm3Ky7B6OF-gx%3DvgvdP_v8nd-Pi0WNeqzyv06g%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: [gwt-contrib] Fwd: jsinterop woes: Part 2: return Double[]

2017-06-26 Thread Ignacio Baca Moreno-Torres
Oh, the classic array problem! ;)
https://github.com/gwtproject/gwt/issues/9318

IMO as you are wrapping a client lib, and this code is not going to be
shared (used in JRE), so just use elemental2.core.Array. Probably
JsArrayLike is enough as an argument but returning an Array it is easier to
use.

I use native arrays extensively in DTO, but I stick to some limitations and
it works pretty well. I only use primitive, Boolean, Double or
JsType(native) arrays. And as I use it in DTOs if I want to do anything I
always make defensive copies. In practice, this makes much sense because
you almost everytime need to do some filter/mapping/peek with those arrays,
so I just use Stream.of(array) do whatever I want (filter/map/...) and
either use forEach/collect/toArray. So the resulting collection has type
markers so it gets back to safety.

In general using native arrays with JS libs it's not a good idea for does
problems. So try to avoid. You can always overload this method so you can
pass a native array but returns a JsType Array. And anyways, returning a
native array is not very friendly as you are probably expecting something
mutable (add/remove) so the java native array is really not a good
container here. In some weird cases, I have been using the manolo's hack ;)
(
https://github.com/manolo/gwt-api-generator/blob/master/lib/com/vaadin/polymer/Polymer.java#L522)
to make it mutable as a Java List, but it is pretty hacky.

On Mon, Jun 26, 2017 at 7:32 PM 'Roberto Lublinerman' via GWT Contributors <
google-web-toolkit-contributors@googlegroups.com> wrote:

> On Mon, Jun 26, 2017 at 10:16 AM, Colin Alworth 
> wrote:
>
>> The example isn't doing instanceof though, it is just making that the
>> return type for the method (albeit through the use of generics). Does this
>> suggest that we should stop using arrays to refer to raw JS data, or at
>> least expect that generics may fail in interesting ways around them (and at
>> runtime of all places)?
>>
>
> It is the programmers responsibility to make sure JS methods that are
> called satisfy the Java contract they declare, same thing as in JSNI. If
> you use non native arrays in JsInterop members you should be getting
> "unusable-by-js" warnings.
>
> Also I forgot to mention that you can definitely return JS arrays as
> Object[] too.
>
> Of course you can do tricks (as people used to in JSNI) if you know the
> edges in the semantics. E.g. returning a Date[] if you are sure there will
> be no casts. You also have to be aware that when you use generics there
> will be casts at the invocation sites.
>
> If you have raw JS array you should model it with either a NativeJsType[]
> or an Object[].
>
>
>> elemental2.Array is full of cases where [] or ... are used as arguments,
>> though this includes generic arrays (as opposed to generics _of_ arrays).
>> If I understand you correctly, valid Java code that is passed a String[] or
>> Double[] (or for example Element[]) may fail in exciting ways if passed one
>> of these 'arrays'.
>>
>
> varargs is a different animal, JS varargs are always cast appropriately
> (there is always prelude on Java methods that implement a native method
> with JS varargs that takes care of this).
>
> Yes valid Java code might fail for instance if there is a (instanceof
> String[] call, etc).
>
>
>>
>> In case those are correctly handled, and it is important only to tell
>> JsInterop about an array of generics  instead of generic representing an
>> array, perhaps Vassilis should have another AccessorFunction which handles
>> arrays instead? (Actually maye need 3 more, , , ,
>> so I don't think this is a serious suggestion).
>> Otherwise your email seems to suggest that we need a type in
>> jsinterop.base for all JS arrays instead of our current situation of
>> pretending that java arrays and js arrays are compatible.
>>
>
> You can always use Object[], and nothing will fail.
>
>
>>
>> --
>>   Colin Alworth
>>   co...@colinalworth.com
>>
>>
>>
>> On Mon, Jun 26, 2017, at 12:09 PM, 'Roberto Lublinerman' via GWT
>> Contributors wrote:
>>
>> The short answer is that this is also not a bug.
>>
>> Java arrays are typed, JS arrays are not. So none of the examples you
>> have will fully work.
>>
>> E.g. If you do array instanceof Date[] on an array built in JS filled
>> with Dates it will fail.
>>
>> A native array is best modeled as SomeNativeJsType[] where there are not
>> expectations on the contents of the array from the Java perspective.
>>
>> We would have loved to have a more seamless array JsInterop.
>>
>>
>>
>> On Mon, Jun 26, 2017 at 1:31 AM, Vassilis Virvilis 
>> wrote:
>>
>> Originally posted in gwt-users.
>> The question here is the same with the previous one.
>>
>> Is this considered a bug? Should I report it as an issue? and if so where?
>>
>>  Thanks.
>>
>>
>> -- Forwarded message --
>> From: *Vassilis Virvilis* 
>> Date: Fri, Feb 24, 2017 at 

Re: [gwt-contrib] Fwd: jsinterop woes: Part 2: return Double[]

2017-06-26 Thread 'Roberto Lublinerman' via GWT Contributors
On Mon, Jun 26, 2017 at 10:16 AM, Colin Alworth 
wrote:

> The example isn't doing instanceof though, it is just making that the
> return type for the method (albeit through the use of generics). Does this
> suggest that we should stop using arrays to refer to raw JS data, or at
> least expect that generics may fail in interesting ways around them (and at
> runtime of all places)?
>

It is the programmers responsibility to make sure JS methods that are
called satisfy the Java contract they declare, same thing as in JSNI. If
you use non native arrays in JsInterop members you should be getting
"unusable-by-js" warnings.

Also I forgot to mention that you can definitely return JS arrays as
Object[] too.

Of course you can do tricks (as people used to in JSNI) if you know the
edges in the semantics. E.g. returning a Date[] if you are sure there will
be no casts. You also have to be aware that when you use generics there
will be casts at the invocation sites.

If you have raw JS array you should model it with either a NativeJsType[]
or an Object[].


> elemental2.Array is full of cases where [] or ... are used as arguments,
> though this includes generic arrays (as opposed to generics _of_ arrays).
> If I understand you correctly, valid Java code that is passed a String[] or
> Double[] (or for example Element[]) may fail in exciting ways if passed one
> of these 'arrays'.
>

varargs is a different animal, JS varargs are always cast appropriately
(there is always prelude on Java methods that implement a native method
with JS varargs that takes care of this).

Yes valid Java code might fail for instance if there is a (instanceof
String[] call, etc).


>
> In case those are correctly handled, and it is important only to tell
> JsInterop about an array of generics  instead of generic representing an
> array, perhaps Vassilis should have another AccessorFunction which handles
> arrays instead? (Actually maye need 3 more, , , ,
> so I don't think this is a serious suggestion).
> Otherwise your email seems to suggest that we need a type in
> jsinterop.base for all JS arrays instead of our current situation of
> pretending that java arrays and js arrays are compatible.
>

You can always use Object[], and nothing will fail.


>
> --
>   Colin Alworth
>   co...@colinalworth.com
>
>
>
> On Mon, Jun 26, 2017, at 12:09 PM, 'Roberto Lublinerman' via GWT
> Contributors wrote:
>
> The short answer is that this is also not a bug.
>
> Java arrays are typed, JS arrays are not. So none of the examples you have
> will fully work.
>
> E.g. If you do array instanceof Date[] on an array built in JS filled with
> Dates it will fail.
>
> A native array is best modeled as SomeNativeJsType[] where there are not
> expectations on the contents of the array from the Java perspective.
>
> We would have loved to have a more seamless array JsInterop.
>
>
>
> On Mon, Jun 26, 2017 at 1:31 AM, Vassilis Virvilis 
> wrote:
>
> Originally posted in gwt-users.
> The question here is the same with the previous one.
>
> Is this considered a bug? Should I report it as an issue? and if so where?
>
>  Thanks.
>
>
> -- Forwarded message --
> From: *Vassilis Virvilis* 
> Date: Fri, Feb 24, 2017 at 2:44 PM
> Subject: jsinterop woes: Part 2: return Double[]
> To: google-web-tool...@googlegroups.com
>
>
> Hi,
>
> I am not sure if it is a bug but it kills my beautiful jsinterop mappings.
> Let's say that I have a native js function (d3.extent) that returns an
> array of something. It may be dates it may be doubles..
>
> This is mapped nicely with
>
> public static native  V[] extent(T[] data,
> AccessorFunction accessor);
>
>
> Where AccessorFunction is
>
> @JsFunction
> public static interface AccessorFunction {
> public V get(T d);
> }
>
>
> The above scheme works for Date and other objects but it fails with
> Double. If I specify another variant of d3.extent that returns double[] it
> works
> Here is the javascript exception
>
> Uncaught Error: java.lang.ClassCastException
> at java_lang_ClassCastException_ClassCastException__V.java_lang
> _Throwable_createError__Ljava_lang_String_2Ljava_lang_Object_2 [as
> package_private$java_lang$createError__Ljava_lang_String_2Ljava_lang_Object_2]
> (dashboard-0.js:7245)
> at java_lang_ClassCastException_ClassCastException__V.java_lang
> _Throwable_initializeBackingError__V [as 
> private$java_lang_Throwable$initializeBackingError__V]
> (dashboard-0.js:7300)
> at 
> java_lang_ClassCastException_ClassCastException__V.java_lang_Throwable_Throwable__V
> (dashboard-0.js:7133)
> at 
> java_lang_ClassCastException_ClassCastException__V.java_lang_Exception_Exception__V
> (dashboard-0.js:7381)
> at java_lang_ClassCastException_ClassCastException__V.java_lang
> _RuntimeException_RuntimeException__V (dashboard-0.js:29760)
> at 

Re: [gwt-contrib] Fwd: jsinterop woes: Part 2: return Double[]

2017-06-26 Thread Colin Alworth
The example isn't doing instanceof though, it is just making that the
return type for the method (albeit through the use of generics). Does
this suggest that we should stop using arrays to refer to raw JS data,
or at least expect that generics may fail in interesting ways around
them (and at runtime of all places)?
elemental2.Array is full of cases where [] or ... are used as arguments,
though this includes generic arrays (as opposed to generics _of_
arrays). If I understand you correctly, valid Java code that is passed a
String[] or Double[] (or for example Element[]) may fail in exciting
ways if passed one of these 'arrays'.
In case those are correctly handled, and it is important only to tell
JsInterop about an array of generics  instead of generic representing an
array, perhaps Vassilis should have another AccessorFunction which
handles arrays instead? (Actually maye need 3 more, , ,
, so I don't think this is a serious suggestion).
Otherwise your email seems to suggest that we need a type in
jsinterop.base  for all JS arrays instead of our current situation of
pretending that java arrays and js arrays are compatible.
--
  Colin Alworth
  co...@colinalworth.com



On Mon, Jun 26, 2017, at 12:09 PM, 'Roberto Lublinerman' via GWT Contributors 
wrote:> The short answer is that this is also not a bug.
> 
> Java arrays are typed, JS arrays are not. So none of the examples you
> have will fully work.> 
> E.g. If you do array instanceof Date[] on an array built in JS filled
>  with Dates it will fail.> 
> A native array is best modeled as SomeNativeJsType[] where there are
> not expectations on the contents of the array from the Java
> perspective.> 
> We would have loved to have a more seamless array JsInterop.
> 
> 
> 
> On Mon, Jun 26, 2017 at 1:31 AM, Vassilis Virvilis
>  wrote:>> Originally posted in gwt-users.
>> The question here is the same with the previous one.
>> 
>> Is this considered a bug? Should I report it as an issue? and if
>> so where?>> 
>>  Thanks.
>> 
>> 
>> -- Forwarded message --
>> From: *Vassilis Virvilis* 
>> Date: Fri, Feb 24, 2017 at 2:44 PM
>> Subject: jsinterop woes: Part 2: return Double[]
>> To: google-web-tool...@googlegroups.com
>> 
>> 
>> Hi,
>> 
>> I am not sure if it is a bug but it kills my beautiful jsinterop
>> mappings.>> Let's say that I have a native js function (d3.extent) that 
>> returns
>> an array of something. It may be dates it may be doubles..>> 
>> This is mapped nicely with 
>> 
>>> public static native  V[] extent(T[] data,
>>> AccessorFunction accessor);
>> 
>> Where AccessorFunction is 
>> 
>>> @JsFunction
>>> public static interface AccessorFunction {
>>> public V get(T d);
>>> }
>> 
>> The above scheme works for Date and other objects but it fails with
>> Double. If I specify another variant of d3.extent that returns
>> double[] it works>> Here is the javascript exception
>> 
>>> Uncaught Error: java.lang.ClassCastException
>>> at java_lang_ClassCastException_ClassCastException__V.java_lang-
>>> _Throwable_createError__Ljava_lang_String_2Ljava_lang_Object_2
>>> [as package_private$java_lang$createError__Ljava_lang_String_2L-
>>> java_lang_Object_2] (dashboard-0.js:7245)>>> at 
>>> java_lang_ClassCastException_ClassCastException__V.java_lang-
>>> _Throwable_initializeBackingError__V [as
>>> private$java_lang_Throwable$initializeBackingError__V] (dashboard-
>>> 0.js:7300)>>> at 
>>> java_lang_ClassCastException_ClassCastException__V.java_lang-
>>> _Throwable_Throwable__V (dashboard-0.js:7133)>>> at 
>>> java_lang_ClassCastException_ClassCastException__V.java_lang-
>>> _Exception_Exception__V (dashboard-0.js:7381)>>> at 
>>> java_lang_ClassCastException_ClassCastException__V.java_lang-
>>> _RuntimeException_RuntimeException__V (dashboard-0.js:29760)>>> at 
>>> java_lang_ClassCastException_ClassCastException__V (dashboard-
>>> 0.js:57310)>>> at 
>>> javaemul_internal_InternalPreconditions_checkCriticalType__ZV
>>> (dashboard-0.js:72171)>>> at 
>>> javaemul_internal_InternalPreconditions_checkType__ZV (dashboard-
>>> 0.js:72378)>>> at 
>>> com_google_gwt_lang_Cast_castTo__Ljava_lang_Object_2Lcom_goo-
>>> gle_gwt_core_client_JavaScriptObject_2Ljava_lang_Object_2 (dashboard-
>>> 0.js:647)>> 
>> It goes here
>>> function com_google_gwt_lang_Cast_castTo__Ljava_lang_Object_2Lcom_g-
>>> oogle_gwt_core_client_JavaScriptObject_2Ljava_lang_Object_2(src_0,
>>> dstId){>>>   com_google_gwt_lang_Cast_$clinit__V();
>>>   javaemul_internal_InternalPreconditions_checkType__ZV(com_google_-
>>>   gwt_lang_Cast_jsEquals__Ljava_lang_Object_2Ljava_lang_Object_2Z(s-
>>>   rc_0, null) || com_google_gwt_lang_Cast_canCast__Ljava_lang_Objec-
>>>   t_2Lcom_google_gwt_core_client_JavaScriptObject_2Z(src_0, dstId));>>>   
>>> return src_0;
>>> }
>> 
>> 

Re: [gwt-contrib] Fwd: jsinterop woes: Part 2: return Double[]

2017-06-26 Thread 'Roberto Lublinerman' via GWT Contributors
The short answer is that this is also not a bug.

Java arrays are typed, JS arrays are not. So none of the examples you have
will fully work.

E.g. If you do array instanceof Date[] on an array built in JS filled with
Dates it will fail.

A native array is best modeled as SomeNativeJsType[] where there are not
expectations on the contents of the array from the Java perspective.

We would have loved to have a more seamless array JsInterop.



On Mon, Jun 26, 2017 at 1:31 AM, Vassilis Virvilis 
wrote:

> Originally posted in gwt-users.
>
> The question here is the same with the previous one.
>
> Is this considered a bug? Should I report it as an issue? and if so where?
>
>  Thanks.
>
>
> -- Forwarded message --
> From: Vassilis Virvilis 
> Date: Fri, Feb 24, 2017 at 2:44 PM
> Subject: jsinterop woes: Part 2: return Double[]
> To: google-web-tool...@googlegroups.com
>
>
> Hi,
>
> I am not sure if it is a bug but it kills my beautiful jsinterop mappings.
>
> Let's say that I have a native js function (d3.extent) that returns an
> array of something. It may be dates it may be doubles..
>
> This is mapped nicely with
>
> public static native  V[] extent(T[] data,
>> AccessorFunction accessor);
>>
>
> Where AccessorFunction is
>
> @JsFunction
>> public static interface AccessorFunction {
>> public V get(T d);
>> }
>>
>
> The above scheme works for Date and other objects but it fails with
> Double. If I specify another variant of d3.extent that returns double[] it
> works
>
> Here is the javascript exception
>
> Uncaught Error: java.lang.ClassCastException
>> at java_lang_ClassCastException_ClassCastException__V.java_lang
>> _Throwable_createError__Ljava_lang_String_2Ljava_lang_Object_2 [as
>> package_private$java_lang$createError__Ljava_lang_String_2Ljava_lang_Object_2]
>> (dashboard-0.js:7245)
>> at java_lang_ClassCastException_ClassCastException__V.java_lang
>> _Throwable_initializeBackingError__V [as 
>> private$java_lang_Throwable$initializeBackingError__V]
>> (dashboard-0.js:7300)
>> at 
>> java_lang_ClassCastException_ClassCastException__V.java_lang_Throwable_Throwable__V
>> (dashboard-0.js:7133)
>> at 
>> java_lang_ClassCastException_ClassCastException__V.java_lang_Exception_Exception__V
>> (dashboard-0.js:7381)
>> at java_lang_ClassCastException_ClassCastException__V.java_lang
>> _RuntimeException_RuntimeException__V (dashboard-0.js:29760)
>> at java_lang_ClassCastException_ClassCastException__V
>> (dashboard-0.js:57310)
>> at javaemul_internal_InternalPreconditions_checkCriticalType__ZV
>> (dashboard-0.js:72171)
>> at javaemul_internal_InternalPreconditions_checkType__ZV
>> (dashboard-0.js:72378)
>> at com_google_gwt_lang_Cast_castTo__Ljava_lang_Object_2Lcom_
>> google_gwt_core_client_JavaScriptObject_2Ljava_lang_Object_2
>> (dashboard-0.js:647)
>>
>
> It goes here
>
>> function com_google_gwt_lang_Cast_castTo__Ljava_lang_Object_2Lcom_
>> google_gwt_core_client_JavaScriptObject_2Ljava_lang_Object_2(src_0,
>> dstId){
>>   com_google_gwt_lang_Cast_$clinit__V();
>>   javaemul_internal_InternalPreconditions_checkType__ZV(com_
>> google_gwt_lang_Cast_jsEquals__Ljava_lang_Object_2Ljava_lang_Object_2Z(src_0,
>> null) || com_google_gwt_lang_Cast_canCast__Ljava_lang_Object_2Lcom_
>> google_gwt_core_client_JavaScriptObject_2Z(src_0, dstId));
>>   return src_0;
>> }
>>
>
> Arguments:
>
>- src_0:
>   - evaluated: js array of numbers as it should be
>   - dstId:
>   - evaluated: 2396
>
> and then it goes to
>
> function com_google_gwt_lang_Cast_canCast__Ljava_lang_Object_2Lcom_
>> google_gwt_core_client_JavaScriptObject_2Z(src_0, dstId){
>>   com_google_gwt_lang_Cast_$clinit__V();
>>   if (com_google_gwt_lang_Cast_instanceOfString__Ljava_lang_Object_2Z(src_0))
>> {
>> return !!com_google_gwt_lang_Cast_stringCastMap[dstId];
>>   }
>>else if (src_0.java_lang_Object_castableTypeMap) {
>> return !!src_0.java_lang_Object_castableTypeMap[dstId];
>>   }
>>else if 
>> (com_google_gwt_lang_Cast_instanceOfDouble__Ljava_lang_Object_2Z(src_0))
>> {
>> return !!com_google_gwt_lang_Cast_doubleCastMap[dstId];
>>   }
>>else if 
>> (com_google_gwt_lang_Cast_instanceOfBoolean__Ljava_lang_Object_2Z(src_0))
>> {
>> return !!com_google_gwt_lang_Cast_booleanCastMap[dstId];
>>   }
>>   return false;
>> }
>>
>
> where it fails.
>
> Would it be possible to handle transparently also Double[] (and possibly
> String[])? as double[]?
>
>Thank you for reading that far...
>
> Vassilis
>
>
>
>
>
>
>
> --
> Vassilis Virvilis
>
>
>
> --
> Vassilis Virvilis
>
> --
> You received this message because you are subscribed to the Google Groups
> "GWT Contributors" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to google-web-toolkit-contributors+unsubscr...@googlegroups.com.
> To view this discussion on the web visit 

[gwt-contrib] Fwd: jsinterop woes: Part 2: return Double[]

2017-06-26 Thread Vassilis Virvilis
Originally posted in gwt-users.

The question here is the same with the previous one.

Is this considered a bug? Should I report it as an issue? and if so where?

 Thanks.


-- Forwarded message --
From: Vassilis Virvilis 
Date: Fri, Feb 24, 2017 at 2:44 PM
Subject: jsinterop woes: Part 2: return Double[]
To: google-web-tool...@googlegroups.com


Hi,

I am not sure if it is a bug but it kills my beautiful jsinterop mappings.

Let's say that I have a native js function (d3.extent) that returns an
array of something. It may be dates it may be doubles..

This is mapped nicely with

public static native  V[] extent(T[] data,
> AccessorFunction accessor);
>

Where AccessorFunction is

@JsFunction
> public static interface AccessorFunction {
> public V get(T d);
> }
>

The above scheme works for Date and other objects but it fails with Double.
If I specify another variant of d3.extent that returns double[] it works

Here is the javascript exception

Uncaught Error: java.lang.ClassCastException
> at java_lang_ClassCastException_ClassCastException__V.java_
> lang_Throwable_createError__Ljava_lang_String_2Ljava_lang_Object_2 [as
> package_private$java_lang$createError__Ljava_lang_String_2Ljava_lang_Object_2]
> (dashboard-0.js:7245)
> at java_lang_ClassCastException_ClassCastException__V.java_
> lang_Throwable_initializeBackingError__V [as 
> private$java_lang_Throwable$initializeBackingError__V]
> (dashboard-0.js:7300)
> at 
> java_lang_ClassCastException_ClassCastException__V.java_lang_Throwable_Throwable__V
> (dashboard-0.js:7133)
> at 
> java_lang_ClassCastException_ClassCastException__V.java_lang_Exception_Exception__V
> (dashboard-0.js:7381)
> at java_lang_ClassCastException_ClassCastException__V.java_
> lang_RuntimeException_RuntimeException__V (dashboard-0.js:29760)
> at java_lang_ClassCastException_ClassCastException__V
> (dashboard-0.js:57310)
> at javaemul_internal_InternalPreconditions_checkCriticalType__ZV
> (dashboard-0.js:72171)
> at javaemul_internal_InternalPreconditions_checkType__ZV
> (dashboard-0.js:72378)
> at com_google_gwt_lang_Cast_castTo__Ljava_lang_Object_
> 2Lcom_google_gwt_core_client_JavaScriptObject_2Ljava_lang_Object_2
> (dashboard-0.js:647)
>

It goes here

> function com_google_gwt_lang_Cast_castTo__Ljava_lang_Object_
> 2Lcom_google_gwt_core_client_JavaScriptObject_2Ljava_lang_Object_2(src_0,
> dstId){
>   com_google_gwt_lang_Cast_$clinit__V();
>   javaemul_internal_InternalPreconditions_checkType__ZV(com_google_gwt_
> lang_Cast_jsEquals__Ljava_lang_Object_2Ljava_lang_Object_2Z(src_0, null)
> || com_google_gwt_lang_Cast_canCast__Ljava_lang_Object_
> 2Lcom_google_gwt_core_client_JavaScriptObject_2Z(src_0, dstId));
>   return src_0;
> }
>

Arguments:

   - src_0:
  - evaluated: js array of numbers as it should be
  - dstId:
  - evaluated: 2396

and then it goes to

function com_google_gwt_lang_Cast_canCast__Ljava_lang_Object_
> 2Lcom_google_gwt_core_client_JavaScriptObject_2Z(src_0, dstId){
>   com_google_gwt_lang_Cast_$clinit__V();
>   if (com_google_gwt_lang_Cast_instanceOfString__Ljava_lang_Object_2Z(src_0))
> {
> return !!com_google_gwt_lang_Cast_stringCastMap[dstId];
>   }
>else if (src_0.java_lang_Object_castableTypeMap) {
> return !!src_0.java_lang_Object_castableTypeMap[dstId];
>   }
>else if 
> (com_google_gwt_lang_Cast_instanceOfDouble__Ljava_lang_Object_2Z(src_0))
> {
> return !!com_google_gwt_lang_Cast_doubleCastMap[dstId];
>   }
>else if 
> (com_google_gwt_lang_Cast_instanceOfBoolean__Ljava_lang_Object_2Z(src_0))
> {
> return !!com_google_gwt_lang_Cast_booleanCastMap[dstId];
>   }
>   return false;
> }
>

where it fails.

Would it be possible to handle transparently also Double[] (and possibly
String[])? as double[]?

   Thank you for reading that far...

Vassilis







-- 
Vassilis Virvilis



-- 
Vassilis Virvilis

-- 
You received this message because you are subscribed to the Google Groups "GWT 
Contributors" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-web-toolkit-contributors+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-web-toolkit-contributors/CAKbOjEzUf3LAK90Gnq%2B8B5Yzq7akyZPC%3DJ9ch1DFieqoOCJJVA%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: [gwt-contrib] Fwd: jsinterop woes: Part 1: instanceof function in generics casting

2017-06-25 Thread Vassilis Virvilis
 I was not remembering correctly and my last comment was off. I am not
using a create() method. So the editorial correction is

 s/and have a create() method instead of ordinal() that generates the
object//g



On Sun, Jun 25, 2017 at 6:23 PM, Vassilis Virvilis 
wrote:

> Hm...
>
> For me this d3 ordinal thing like implementing the () operator in c++. Is
> it a function with members and methods or is it an object with the ability
> to be called as a function?
>
> Anyway if you and Roberto say it is not a bug then it's not a bug.
>
> When I revisit my D3 bindings I will explore your proposals - but AFAIK
> there is no easy solution that resembles the original javascript API.
> Currently I prefer to copy paste among the inheritance pyramid (there are 2
> or 3 subtypes) and have a create() method instead of ordinal() that
> generates the object.
>
> If there is no objection I will post another stumbling block I encountered
> in my jsinterop journey.
>
>
> On Sun, Jun 25, 2017 at 5:35 PM, Thomas Broyer  wrote:
>
>>
>>
>> On Sunday, June 25, 2017 at 1:24:40 PM UTC+2, Vassilis Virvilis wrote:
>>>
>>> Ηι,
>>>
>>> thanks for answering
>>>
>>> d3.ordinal does not exist as you said. However d3.scale.ordinal exists
>>> and that part works great.
>>>
>>
>> But it is not a type, so you cannot use 'instanceof' on it.
>>
>>
>>> in d3 ordinal is both a function ordinal() which returns an ordinal
>>> instance and an object with more methods such as range() which is the crux
>>> of my issue.
>>>
>>> The problem there is that
>>>
>>>- public native  O range(I[] values);   *// this doesn't
>>>work*
>>>- // public native  Ordinal range(I[] values); *// this works*
>>>
>>> I would like to use the first definition because it allows reusing some
>>> code between different scales. Otherwise I have to copy-paste the range()
>>> method multiple times instead of put it in a base class.
>>>
>>
>> In Java, generics are more or less syntactic sugar for using the erased
>> type and casting values. So when using the first one, GWT will, when used
>> with O==Ordinal, generate a cast from Object to Ordinal, which IIUC is
>> what's causing the error, because your JsType is not a type that can be
>> checked (a cast is translated in JS to a type-check using 'instanceof').
>>
>>
>>> The problem is on the exceptions generated by the attempting casting.
>>>
>>> As you said this may not be a bug but not for the reason you mentioned.
>>>
>>> So the question remains: Should I report it as an issue?
>>>
>>
>> I would say no. Your @JsType is wrong. You should either use an interface
>> with @JsType(isNative=true, name="?", namespace=JsPackage.GLOBAL), or if
>> you want to use fields use a class with @JsType(isNative=true,
>> name="Object", namespace=JsPackage.GLOBAL)
>>
>> --
>> You received this message because you are subscribed to the Google Groups
>> "GWT Contributors" group.
>> To unsubscribe from this group and stop receiving emails from it, send an
>> email to google-web-toolkit-contributors+unsubscr...@googlegroups.com.
>> To view this discussion on the web visit https://groups.google.com/d/ms
>> gid/google-web-toolkit-contributors/6206fb29-d3c1-48de-ab04-
>> 0610cbb3c2bd%40googlegroups.com
>> 
>> .
>>
>> For more options, visit https://groups.google.com/d/optout.
>>
>
>
>
> --
> Vassilis Virvilis
>



-- 
Vassilis Virvilis

-- 
You received this message because you are subscribed to the Google Groups "GWT 
Contributors" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-web-toolkit-contributors+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-web-toolkit-contributors/CAKbOjEz_uocutZGGp%3DsvDbUSf1eW9gnziGsCtVOkvd1iGRT%2Bjg%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: [gwt-contrib] Fwd: jsinterop woes: Part 1: instanceof function in generics casting

2017-06-25 Thread Vassilis Virvilis
Hm...

For me this d3 ordinal thing like implementing the () operator in c++. Is
it a function with members and methods or is it an object with the ability
to be called as a function?

Anyway if you and Roberto say it is not a bug then it's not a bug.

When I revisit my D3 bindings I will explore your proposals - but AFAIK
there is no easy solution that resembles the original javascript API.
Currently I prefer to copy paste among the inheritance pyramid (there are 2
or 3 subtypes) and have a create() method instead of ordinal() that
generates the object.

If there is no objection I will post another stumbling block I encountered
in my jsinterop journey.


On Sun, Jun 25, 2017 at 5:35 PM, Thomas Broyer  wrote:

>
>
> On Sunday, June 25, 2017 at 1:24:40 PM UTC+2, Vassilis Virvilis wrote:
>>
>> Ηι,
>>
>> thanks for answering
>>
>> d3.ordinal does not exist as you said. However d3.scale.ordinal exists
>> and that part works great.
>>
>
> But it is not a type, so you cannot use 'instanceof' on it.
>
>
>> in d3 ordinal is both a function ordinal() which returns an ordinal
>> instance and an object with more methods such as range() which is the crux
>> of my issue.
>>
>> The problem there is that
>>
>>- public native  O range(I[] values);   *// this doesn't
>>work*
>>- // public native  Ordinal range(I[] values); *// this works*
>>
>> I would like to use the first definition because it allows reusing some
>> code between different scales. Otherwise I have to copy-paste the range()
>> method multiple times instead of put it in a base class.
>>
>
> In Java, generics are more or less syntactic sugar for using the erased
> type and casting values. So when using the first one, GWT will, when used
> with O==Ordinal, generate a cast from Object to Ordinal, which IIUC is
> what's causing the error, because your JsType is not a type that can be
> checked (a cast is translated in JS to a type-check using 'instanceof').
>
>
>> The problem is on the exceptions generated by the attempting casting.
>>
>> As you said this may not be a bug but not for the reason you mentioned.
>>
>> So the question remains: Should I report it as an issue?
>>
>
> I would say no. Your @JsType is wrong. You should either use an interface
> with @JsType(isNative=true, name="?", namespace=JsPackage.GLOBAL), or if
> you want to use fields use a class with @JsType(isNative=true,
> name="Object", namespace=JsPackage.GLOBAL)
>
> --
> You received this message because you are subscribed to the Google Groups
> "GWT Contributors" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to google-web-toolkit-contributors+unsubscr...@googlegroups.com.
> To view this discussion on the web visit https://groups.google.com/d/
> msgid/google-web-toolkit-contributors/6206fb29-d3c1-
> 48de-ab04-0610cbb3c2bd%40googlegroups.com
> 
> .
>
> For more options, visit https://groups.google.com/d/optout.
>



-- 
Vassilis Virvilis

-- 
You received this message because you are subscribed to the Google Groups "GWT 
Contributors" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-web-toolkit-contributors+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-web-toolkit-contributors/CAKbOjExtFzAEo2fL66Z3gDrfzNA%3DnF90moVCvGg2BUjjDVqJfg%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: [gwt-contrib] Fwd: jsinterop woes: Part 1: instanceof function in generics casting

2017-06-25 Thread Thomas Broyer


On Sunday, June 25, 2017 at 1:24:40 PM UTC+2, Vassilis Virvilis wrote:
>
> Ηι,
>
> thanks for answering
>
> d3.ordinal does not exist as you said. However d3.scale.ordinal exists and 
> that part works great.
>

But it is not a type, so you cannot use 'instanceof' on it.
 

> in d3 ordinal is both a function ordinal() which returns an ordinal 
> instance and an object with more methods such as range() which is the crux 
> of my issue.
>
> The problem there is that 
>
>- public native  O range(I[] values);   *// this doesn't 
>work*
>- // public native  Ordinal range(I[] values); *// this works*
>
> I would like to use the first definition because it allows reusing some 
> code between different scales. Otherwise I have to copy-paste the range() 
> method multiple times instead of put it in a base class.
>

In Java, generics are more or less syntactic sugar for using the erased 
type and casting values. So when using the first one, GWT will, when used 
with O==Ordinal, generate a cast from Object to Ordinal, which IIUC is 
what's causing the error, because your JsType is not a type that can be 
checked (a cast is translated in JS to a type-check using 'instanceof').
 

> The problem is on the exceptions generated by the attempting casting.
>
> As you said this may not be a bug but not for the reason you mentioned.
>
> So the question remains: Should I report it as an issue?
>

I would say no. Your @JsType is wrong. You should either use an interface 
with @JsType(isNative=true, name="?", namespace=JsPackage.GLOBAL), or if 
you want to use fields use a class with @JsType(isNative=true, 
name="Object", namespace=JsPackage.GLOBAL) 

-- 
You received this message because you are subscribed to the Google Groups "GWT 
Contributors" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-web-toolkit-contributors+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-web-toolkit-contributors/6206fb29-d3c1-48de-ab04-0610cbb3c2bd%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [gwt-contrib] Fwd: jsinterop woes: Part 1: instanceof function in generics casting

2017-06-25 Thread Vassilis Virvilis
Ηι,

thanks for answering

d3.ordinal does not exist as you said. However d3.scale.ordinal exists and
that part works great.

in d3 ordinal is both a function ordinal() which returns an ordinal
instance and an object with more methods such as range() which is the crux
of my issue.

The problem there is that

   - public native  O range(I[] values);   *// this doesn't work*
   - // public native  Ordinal range(I[] values); *// this works*

I would like to use the first definition because it allows reusing some
code between different scales. Otherwise I have to copy-paste the range()
method multiple times instead of put it in a base class.

The problem is on the exceptions generated by the attempting casting.

As you said this may not be a bug but not for the reason you mentioned.

So the question remains: Should I report it as an issue?

   Vassilis


On Sun, Jun 25, 2017 at 3:24 AM, 'Roberto Lublinerman' via GWT Contributors
 wrote:

> The declaration
>
>   package somepackage;
>
>   @JsNative(isTrue, name = "ordinal")
>   class Ordinal {
>   
>   }
>
> effectively says that there is a native type "somepackage.ordinal", which
> d3.ordinal is not.
>
> You can model it as a native interface for example where there is not such
> expectation.
>
> So as I understand your report this is not a bug but just an error in
> modellin
>
> On Sat, Jun 24, 2017 at 7:58 AM, Vassilis Virvilis 
> wrote:
>
>> Originally posted in gwt-users.
>>
>> Two questions:
>>
>>1. Do you want me to report it as a bug somewhere? and where that
>>would be?
>>2. I have two more. Do you want me to post them here or this is not
>>the right place to post at all?
>>
>>
>>
>> -- Forwarded message --
>> From: Vassilis Virvilis 
>> Date: Fri, Feb 24, 2017 at 2:26 PM
>> Subject: jsinterop woes: Part 1: instanceof function in generics casting
>> To: google-web-tool...@googlegroups.com
>>
>>
>> Hi,
>>
>> again I don't know if this is a bug but it hurts my style
>>
>> D3 defines d3.scale.ordinal as both a function and an object.
>> $wnd.d3.scale.ordinal returns function() in the browser's console though
>>
>>
>>@JsType(isNative = true, name = "ordinal")
>>>   public static class Ordinal {
>>>/** @todo TODO: this crashes. Why? */
>>>public native  O range(I[] values);   // this
>>> doesn't work
>>>//public native  Ordinal range(I[] values); // this works
>>>   }
>>>
>>
>> I want the generic type because then I can put it in a base class and
>> share some code.
>>
>> I am using it like this
>>
>>> D3.Scale.Ordinal color = D3.Scale.ordinal().range(new String[]
>>> {"#98abc5", "#8a89a6"});
>>>
>>
>> Here is the javascript exception:
>>
>> Error: java.lang.ClassCastException
>>> at java_lang_ClassCastException_ClassCastException__V.java_lang
>>> _Throwable_createError__Ljava_lang_String_2Ljava_lang_Object_2 [as
>>> package_private$java_lang$createError__Ljava_lang_String_2Ljava_lang_Object_2]
>>> (dashboard-0.js:7245)
>>> at java_lang_ClassCastException_ClassCastException__V.java_lang
>>> _Throwable_initializeBackingError__V [as 
>>> private$java_lang_Throwable$initializeBackingError__V]
>>> (dashboard-0.js:7300)
>>> at 
>>> java_lang_ClassCastException_ClassCastException__V.java_lang_Throwable_Throwable__V
>>> (dashboard-0.js:7133)
>>> at 
>>> java_lang_ClassCastException_ClassCastException__V.java_lang_Exception_Exception__V
>>> (dashboard-0.js:7381)
>>> at java_lang_ClassCastException_ClassCastException__V.java_lang
>>> _RuntimeException_RuntimeException__V (dashboard-0.js:29724)
>>> at java_lang_ClassCastException_ClassCastException__V
>>> (dashboard-0.js:57274)
>>> at javaemul_internal_InternalPreconditions_checkCriticalType__ZV
>>> (dashboard-0.js:72135)
>>> at javaemul_internal_InternalPreconditions_checkType__ZV
>>> (dashboard-0.js:72342)
>>> at com_google_gwt_lang_Cast_castToNative__Ljava_lang_Object_2Lc
>>> om_google_gwt_core_client_JavaScriptObject_2Ljava_lang_Object_2
>>> (dashboard-0.js:707)
>>>
>>
>> In
>>
>>> function com_google_gwt_lang_Cast_castToNative__Ljava_lang_Object_2Lc
>>> om_google_gwt_core_client_JavaScriptObject_2Ljava_lang_Object_2(src_0,
>>> jsType){
>>>   com_google_gwt_lang_Cast_$clinit__V();
>>>   javaemul_internal_InternalPreconditions_checkType__ZV(com_go
>>> ogle_gwt_lang_Cast_jsEquals__Ljava_lang_Object_2Ljava_lang_Object_2Z(src_0,
>>> null) || com_google_gwt_lang_Cast_jsinstanceOf__Ljava_lang_Object_2Lc
>>> om_google_gwt_core_client_JavaScriptObject_2Z(src_0, jsType));
>>>   return src_0;
>>> }
>>>
>>
>> Arguments:
>>
>>- src_0:
>>   - passed:
>>   - evaluated: function scale(x)
>>- jsType:
>>   - passed: $wnd.scale.ordinal
>>   - evaluated: function anonymous()
>>
>> The reason it fails is that
>>
>>> function com_google_gwt_lang_Cast_jsinstanceOf__Ljava_lang_Object_2Lc

Re: [gwt-contrib] Fwd: jsinterop woes: Part 1: instanceof function in generics casting

2017-06-24 Thread 'Roberto Lublinerman' via GWT Contributors
The declaration

  package somepackage;

  @JsNative(isTrue, name = "ordinal")
  class Ordinal {
  
  }

effectively says that there is a native type "somepackage.ordinal", which
d3.ordinal is not.

You can model it as a native interface for example where there is not such
expectation.

So as I understand your report this is not a bug but just an error in
modellin

On Sat, Jun 24, 2017 at 7:58 AM, Vassilis Virvilis 
wrote:

> Originally posted in gwt-users.
>
> Two questions:
>
>1. Do you want me to report it as a bug somewhere? and where that
>would be?
>2. I have two more. Do you want me to post them here or this is not
>the right place to post at all?
>
>
>
> -- Forwarded message --
> From: Vassilis Virvilis 
> Date: Fri, Feb 24, 2017 at 2:26 PM
> Subject: jsinterop woes: Part 1: instanceof function in generics casting
> To: google-web-tool...@googlegroups.com
>
>
> Hi,
>
> again I don't know if this is a bug but it hurts my style
>
> D3 defines d3.scale.ordinal as both a function and an object.
> $wnd.d3.scale.ordinal returns function() in the browser's console though
>
>
>@JsType(isNative = true, name = "ordinal")
>>   public static class Ordinal {
>>/** @todo TODO: this crashes. Why? */
>>public native  O range(I[] values);   // this
>> doesn't work
>>//public native  Ordinal range(I[] values); // this works
>>   }
>>
>
> I want the generic type because then I can put it in a base class and
> share some code.
>
> I am using it like this
>
>> D3.Scale.Ordinal color = D3.Scale.ordinal().range(new String[]
>> {"#98abc5", "#8a89a6"});
>>
>
> Here is the javascript exception:
>
> Error: java.lang.ClassCastException
>> at java_lang_ClassCastException_ClassCastException__V.java_lang
>> _Throwable_createError__Ljava_lang_String_2Ljava_lang_Object_2 [as
>> package_private$java_lang$createError__Ljava_lang_String_2Ljava_lang_Object_2]
>> (dashboard-0.js:7245)
>> at java_lang_ClassCastException_ClassCastException__V.java_lang
>> _Throwable_initializeBackingError__V [as 
>> private$java_lang_Throwable$initializeBackingError__V]
>> (dashboard-0.js:7300)
>> at 
>> java_lang_ClassCastException_ClassCastException__V.java_lang_Throwable_Throwable__V
>> (dashboard-0.js:7133)
>> at 
>> java_lang_ClassCastException_ClassCastException__V.java_lang_Exception_Exception__V
>> (dashboard-0.js:7381)
>> at java_lang_ClassCastException_ClassCastException__V.java_lang
>> _RuntimeException_RuntimeException__V (dashboard-0.js:29724)
>> at java_lang_ClassCastException_ClassCastException__V
>> (dashboard-0.js:57274)
>> at javaemul_internal_InternalPreconditions_checkCriticalType__ZV
>> (dashboard-0.js:72135)
>> at javaemul_internal_InternalPreconditions_checkType__ZV
>> (dashboard-0.js:72342)
>> at com_google_gwt_lang_Cast_castToNative__Ljava_lang_Object_2Lc
>> om_google_gwt_core_client_JavaScriptObject_2Ljava_lang_Object_2
>> (dashboard-0.js:707)
>>
>
> In
>
>> function com_google_gwt_lang_Cast_castToNative__Ljava_lang_Object_2Lc
>> om_google_gwt_core_client_JavaScriptObject_2Ljava_lang_Object_2(src_0,
>> jsType){
>>   com_google_gwt_lang_Cast_$clinit__V();
>>   javaemul_internal_InternalPreconditions_checkType__ZV(com_go
>> ogle_gwt_lang_Cast_jsEquals__Ljava_lang_Object_2Ljava_lang_Object_2Z(src_0,
>> null) || com_google_gwt_lang_Cast_jsinstanceOf__Ljava_lang_Object_2Lc
>> om_google_gwt_core_client_JavaScriptObject_2Z(src_0, jsType));
>>   return src_0;
>> }
>>
>
> Arguments:
>
>- src_0:
>   - passed:
>   - evaluated: function scale(x)
>- jsType:
>   - passed: $wnd.scale.ordinal
>   - evaluated: function anonymous()
>
> The reason it fails is that
>
>> function com_google_gwt_lang_Cast_jsinstanceOf__Ljava_lang_Object_2Lc
>> om_google_gwt_core_client_JavaScriptObject_2Z(obj, jsType){
>>   com_google_gwt_lang_Cast_$clinit__V();
>>   return obj && (jsType && obj instanceof jsType);
>> }
>>
>
> obj is src_0 != null and jsType = function anonymous() != null but (obj
> instanceof jsType) === false
>
> Any idea about that?
>
> --
> Vassilis Virvilis
>
>
>
> --
> Vassilis Virvilis
>
> --
> You received this message because you are subscribed to the Google Groups
> "GWT Contributors" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to google-web-toolkit-contributors+unsubscr...@googlegroups.com.
> To view this discussion on the web visit https://groups.google.com/d/ms
> gid/google-web-toolkit-contributors/CAKbOjEx1v%3D-%3DVHd0Z5p
> cgTbKTPzFktR7nxoCx2Sr9yutZHtxiw%40mail.gmail.com
> 
> .
> For more options, visit https://groups.google.com/d/optout.
>

-- 
You received this message because you are subscribed to the Google Groups "GWT 

[gwt-contrib] Fwd: jsinterop woes: Part 1: instanceof function in generics casting

2017-06-24 Thread Vassilis Virvilis
Originally posted in gwt-users.

Two questions:

   1. Do you want me to report it as a bug somewhere? and where that would
   be?
   2. I have two more. Do you want me to post them here or this is not the
   right place to post at all?



-- Forwarded message --
From: Vassilis Virvilis 
Date: Fri, Feb 24, 2017 at 2:26 PM
Subject: jsinterop woes: Part 1: instanceof function in generics casting
To: google-web-tool...@googlegroups.com


Hi,

again I don't know if this is a bug but it hurts my style

D3 defines d3.scale.ordinal as both a function and an object.
$wnd.d3.scale.ordinal returns function() in the browser's console though


   @JsType(isNative = true, name = "ordinal")
>   public static class Ordinal {
>/** @todo TODO: this crashes. Why? */
>public native  O range(I[] values);   // this doesn't
> work
>//public native  Ordinal range(I[] values); // this works
>   }
>

I want the generic type because then I can put it in a base class and share
some code.

I am using it like this

> D3.Scale.Ordinal color = D3.Scale.ordinal().range(new String[] {"#98abc5",
> "#8a89a6"});
>

Here is the javascript exception:

Error: java.lang.ClassCastException
> at java_lang_ClassCastException_ClassCastException__V.java_lang
> _Throwable_createError__Ljava_lang_String_2Ljava_lang_Object_2 [as
> package_private$java_lang$createError__Ljava_lang_String_2Ljava_lang_Object_2]
> (dashboard-0.js:7245)
> at java_lang_ClassCastException_ClassCastException__V.java_lang
> _Throwable_initializeBackingError__V [as 
> private$java_lang_Throwable$initializeBackingError__V]
> (dashboard-0.js:7300)
> at 
> java_lang_ClassCastException_ClassCastException__V.java_lang_Throwable_Throwable__V
> (dashboard-0.js:7133)
> at 
> java_lang_ClassCastException_ClassCastException__V.java_lang_Exception_Exception__V
> (dashboard-0.js:7381)
> at java_lang_ClassCastException_ClassCastException__V.java_lang
> _RuntimeException_RuntimeException__V (dashboard-0.js:29724)
> at java_lang_ClassCastException_ClassCastException__V
> (dashboard-0.js:57274)
> at javaemul_internal_InternalPreconditions_checkCriticalType__ZV
> (dashboard-0.js:72135)
> at javaemul_internal_InternalPreconditions_checkType__ZV
> (dashboard-0.js:72342)
> at com_google_gwt_lang_Cast_castToNative__Ljava_lang_Object_2Lc
> om_google_gwt_core_client_JavaScriptObject_2Ljava_lang_Object_2
> (dashboard-0.js:707)
>

In

> function com_google_gwt_lang_Cast_castToNative__Ljava_lang_Object_2Lc
> om_google_gwt_core_client_JavaScriptObject_2Ljava_lang_Object_2(src_0,
> jsType){
>   com_google_gwt_lang_Cast_$clinit__V();
>   javaemul_internal_InternalPreconditions_checkType__ZV(com_go
> ogle_gwt_lang_Cast_jsEquals__Ljava_lang_Object_2Ljava_lang_Object_2Z(src_0,
> null) || com_google_gwt_lang_Cast_jsinstanceOf__Ljava_lang_Object_2Lc
> om_google_gwt_core_client_JavaScriptObject_2Z(src_0, jsType));
>   return src_0;
> }
>

Arguments:

   - src_0:
  - passed:
  - evaluated: function scale(x)
   - jsType:
  - passed: $wnd.scale.ordinal
  - evaluated: function anonymous()

The reason it fails is that

> function com_google_gwt_lang_Cast_jsinstanceOf__Ljava_lang_Object_2Lc
> om_google_gwt_core_client_JavaScriptObject_2Z(obj, jsType){
>   com_google_gwt_lang_Cast_$clinit__V();
>   return obj && (jsType && obj instanceof jsType);
> }
>

obj is src_0 != null and jsType = function anonymous() != null but (obj
instanceof jsType) === false

Any idea about that?

-- 
Vassilis Virvilis



-- 
Vassilis Virvilis

-- 
You received this message because you are subscribed to the Google Groups "GWT 
Contributors" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-web-toolkit-contributors+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-web-toolkit-contributors/CAKbOjEx1v%3D-%3DVHd0Z5pcgTbKTPzFktR7nxoCx2Sr9yutZHtxiw%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: [gwt-contrib] Fwd: Usage of file handles/file streams in GWT source code

2017-06-12 Thread Colin Alworth
I fixed a few of these once upon a time in 2.6 or so to deal with an fd
exhaustion issue on linux, would be willing to take on more. In that
case even in success they were leaking, as opposed to only causing
issues in cases of failures (more on this below).
If you have a list of cases that are used wrong (returning an
InputStream isn't necessarily bad of course, since the calling code
itself might have a try-with-resources), I can hit them and see what
falls out.
I'm not sure copying literally every InputStream you see into a
ByteArrayInputStream is a constructive suggestion, since of course to be
defensive, anything given an InputStream needs to make yet another copy,
or all of these APIs need to be adjusted to take ByteArrayInputStream,
etc as a parameter to be clear that the stream has been closed. Is there
another best practice that can make this cleaner, perhaps rewritting
something like the Response interface so it implements AutoClosable so
that _it_ can be try-with-resource'd?
Quickly reviewing all cases where Responses.newBinaryStreamResponse is
called (transitively), all usages either return right away (so no error
can happen), or com.google.gwt.dev.codeserver.WebServer#handleRequest
where yes, it is possible for a NPE or something could happen prior to
page-send (which then cleans up correctly in a try/finally), but that
would point to rather broken code. Response can't be null, target can't
be null, the logger really shouldn't throw and the response shouldn't be
able to throw in setHeader). Or is there something concerning in
handleRequest that you see which can surprisingly error out before
page.send(...) can be reached?
--
  Colin Alworth
  co...@colinalworth.com



On Mon, Jun 12, 2017, at 04:29 AM, Thomas Broyer wrote:
> Moving discussion to GWT Contrib.
> 
> On Sunday, June 11, 2017 at 9:35:30 PM UTC+2, mr.g...@gmail.com wrote:>> 
> Reading and writing of files should only be done using try-with-
>> resources. This might not be an issue on Linux, but it is a serious
>> issue on Windows where I repeatedly get conflicts with GWT DevMode
>> server not releasing file handles, ie. resulting in situations where
>> it cannot even read its own cache files.>> 
>> One example: Output.openSourceFile returns a file input stream.
>> SourceHandler.makeSourcePage then does>> 
>> return Responses.newBinaryStreamResponse("text/plain", pageBytes);
>> 
>> where it eventually might get closed if no error happens... and on
>> top of that the stream is kept open as long as the client wishes to
>> stall reading the response data.>> 
>> I suggest setting up a GWT-internal standard for handling file
>> resources. My recommendation would be to use try-with-resources and
>> processing a file copy that is stored fully in RAM.>> 
>> 
> 


> --
>  You received this message because you are subscribed to the Google
>  Groups "GWT Contributors" group.>  To unsubscribe from this group and stop 
> receiving emails from it,
>  send an email to google-web-toolkit-
>  contributors+unsubscr...@googlegroups.com.>  To view this discussion on the 
> web visit
>  
> https://groups.google.com/d/msgid/google-web-toolkit-contributors/ec381da9-f031-4a37-940d-748c32a4b826%40googlegroups.com[1].>
>   For more options, visit https://groups.google.com/d/optout.


Links:

  1. 
https://groups.google.com/d/msgid/google-web-toolkit-contributors/ec381da9-f031-4a37-940d-748c32a4b826%40googlegroups.com?utm_medium=email_source=footer

-- 
You received this message because you are subscribed to the Google Groups "GWT 
Contributors" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-web-toolkit-contributors+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-web-toolkit-contributors/1497279445.1859930.1006679184.782BF228%40webmail.messagingengine.com.
For more options, visit https://groups.google.com/d/optout.


[gwt-contrib] Fwd: Usage of file handles/file streams in GWT source code

2017-06-12 Thread Thomas Broyer
Moving discussion to GWT Contrib.

On Sunday, June 11, 2017 at 9:35:30 PM UTC+2, mr.g...@gmail.com wrote:
>
> Reading and writing of files should only be done using try-with-resources. 
> This might not be an issue on Linux, but it is a serious issue on Windows 
> where I repeatedly get conflicts with GWT DevMode server not releasing file 
> handles, ie. resulting in situations where it cannot even read its own 
> cache files.
>
> One example: Output.openSourceFile returns a file input stream. 
> SourceHandler.makeSourcePage then does
>
> return Responses.newBinaryStreamResponse("text/plain", pageBytes);
>
> where it eventually might get closed if no error happens... and on top of 
> that the stream is kept open as long as the client wishes to stall reading 
> the response data.
>
> I suggest setting up a GWT-internal standard for handling file resources. 
> My recommendation would be to use try-with-resources and processing a file 
> copy that is stored fully in RAM.
>
>
>

-- 
You received this message because you are subscribed to the Google Groups "GWT 
Contributors" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-web-toolkit-contributors+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-web-toolkit-contributors/ec381da9-f031-4a37-940d-748c32a4b826%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Fwd: Immediately Need Role Windows admin At Reston, Virginia

2014-12-26 Thread anusha reddy
Hi Friends,

 Hope you are doing well,



We have an urgent requirement below , please let me know if you are
comfortable and available for the below position.



Job Title : *Windows admin*

duration : 6 Months

Work Location : Reston, Virginia



Job Description



*Preferred*

· Experience in a Retail domain environment.

· Ability to pull a diverse group of individuals with different
goals together and facilitate productive discussions.

· Comfortable working in a fast-paced, results-oriented environment

· Excellent collaboration skills to effectively communicate with
both business and technical IT teams



*Required*

· Expertise in building Windows server infrastructure and
configuration

· 6+ years of relevant experience should include implementation and
operations support of the following:

· Windows 2008 – Windows 2012

· Microsoft Clustering

· Active Directory

· IIS

· SCOM, SCCM, SCEP

· VMware vSphere, View

· Cisco UCS

· HP Servers

· EMC VMAX

· Strong communication skills required (oral and written)

· Troubleshoot the environment and identify the root cause of the
problem and proposes the resolution.

· Ability to cross skill on the technologies required for the
project.

· Ability to work with onshore/offshore teams, and communicate
using virtual communication tools (phone, conferencing, online meeting)

· Ability to support working outside of normal business hours to
provide after hour or on-call support when necessary to solve high
profile issues or complete critical path projects





Thanks  Regards



Amusha  Reddy

Technical Recruiter



*TekisHub Consulting Services LLC*

1000 N West Street, Suite 1200, Wilmington, Delaware, 19801

(D) 302 613 2500 Ext:  211 (F) 617 830 0525



*[image: E-Verify - Employment Eligibility Verification banner with
E-Verify logo.]* https://e-verify.uscis.gov/esp/cpshome.aspx  *An E-
Verified Company*

-- 
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/d/optout.


Fwd: [gwt-contrib] Questions about @JsProperty and JsType.prototype()

2014-07-01 Thread 田传武
Hi,
When i translate a pure java library to a javascript library using
JsInterop, i get confused about @JsProperty and JsType.prototype().

The java code looks like this:

@JsType
@JsNamespace($wnd.realtime.store)
public class TextInsertedEvent {

  /**
   * The index of the change.
   */
  public final int index;

  /**
   * The inserted text
   */
  public final String text;


  /**
   * @param serialized The serialized event object.
   */
  TextInsertedEvent(JsonObject serialized) {

this.index = (int) serialized.getNumber(index);

this.text = serialized.getString(text);

  }


  public int index() {

return index;
  }


  public String text() {

return text;
  }
}


This TextInsertedEvent class is not allowed to be instantiated directly in
javascript, so do not need to export its constructor.

When someone using the translated js library in a pure javascript web
application:

1. How to prevent the prototype name from obfuscated?
e.g. realtime.store.TextInsertedEvent.isPrototypeOf(evt) should returns true
evt is a TextInsertEvent instance created from the translated library


2. How to translate to dotted property accessor instead of method calls?
e.g. enable users to call evt.text to get the actual string value, not
evt.text()


Thanks for help :)

-- 
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/d/optout.


Fwd: [gwt-contrib] Translated to null.nullField when using JsInterop @JsType

2014-06-30 Thread 田传武
Hello,
The newest @JsType feature is really very fascinating, and works in most
cases. The only issue i found was the wrong null.nullField javascript
output.

the compile command:

java -cp xxx com.google.gwt.dev.Compiler -war xxx -XnoclassMetadata
-XnocheckCasts -XjsInteropMode JS -XclosureCompiler -style
PRETTY com.goodow.realtime.store.StoreProd


Java code:

public CollaborativeOperation compose(JsonArray operations) {
final CollaborativeOperation first =
operations.CollaborativeOperation get(0);
if (operations.length() == 1) {
  return first;
}
final JsonArray components = Json.createArray();
operations.forEach(...);
return new CollaborativeOperation(first.userId, first.sessionId,
components);
  }


translated to the following javascript:

 function $compose(operations) {
  var components;
  components = operations[0];
  if (1 == operations.length) {
return components;
  }
  components = [];
  $forEach(operations, new CollaborativeTransformer$1(components));
  return new CollaborativeOperation(null.nullField, null.nullField,
components);
}



There's an easy workaround to fix this: using the -draftCompile options
when compilation. Here is the full compilation log:
https://travis-ci.org/goodow/realtime-store/builds/28777579 (search
for ./gwt-compile.sh)

-- 
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/d/optout.


[gwt-contrib] Fwd: Abridged summary of gwt-steer...@googlegroups.com - 1 update in 1 topic

2014-05-14 Thread 'Goktug Gokdogan' via GWT Contributors
Just for clarification: HttpThrowableReporter is still not deleted in 2.7;
I'm waiting on what to be decided on the policy.

-- Forwarded message --
From: gwt-steer...@googlegroups.com
Date: Tue, May 13, 2014 at 7:27 PM
Subject: Abridged summary of gwt-steer...@googlegroups.com - 1 update in 1
topic
To: Abridged recipients gwt-steer...@googlegroups.com


  Today's topic summary

Group: http://groups.google.com/group/gwt-steering/topics

   - Steering committee meeting this week
#145f88e70f5be1f9_group_thread_0[1 Update]

  Steering committee meeting this
weekhttp://groups.google.com/group/gwt-steering/t/cb4da354b7bdb648

   Thomas Broyer t.bro...@gmail.com May 13 03:00AM -0700

   If I can find time to write my thoughts down before the meeting, I'd
   like
   we settle on a deprecation policy and discuss versionning besides the
   tic-toc schedule (a guideline for what to include
...morehttp://groups.google.com/group/gwt-steering/msg/b9f1272ac6441155

   Back to top #145f88e70f5be1f9_digest_top

 --
You received this message because you are subscribed to the Google Groups
GWT Steering group.
To unsubscribe from this group and stop receiving emails from it, send an
email to gwt-steering+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

-- 
You received this message because you are subscribed to the Google Groups GWT 
Contributors group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-web-toolkit-contributors+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-web-toolkit-contributors/CAN%3DyUA1_wUN7fe72Wa8dGCUbou9AFxzqKexqnjJzhSFXxnMtGQ%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


[gwt-contrib] Fwd: Thoughts on GWT 3.0 re: Java 8 and IE 8/9

2013-10-25 Thread Thomas Broyer
Forwarded from the GWT group, so it's not lost in the middle of support 
questions.
Link to the topic (there's some feedback there as 
well): 
https://groups.google.com/d/topic/google-web-toolkit/Ll0W3Ui1CAI/discussion

On Friday, October 25, 2013 4:50:38 PM UTC+2, Andy wrote:

 I just read through the notes from the GWT steering 
 committeehttps://groups.google.com/d/msg/gwt-steering/ldyo7OXUnHQ/ogtT-kPFoaoJand
  would like to share our perspective. I know you have a lot of survey 
 results and we're just 1 company, but here's some more info based on our 
 needs.

 *Java 8 only*

 I would encourage and support this move. I've been writing a ton of 
 Javascript for the past few weeks and really miss the functional style when 
 I come back to Java. Lambdas in Java 8 are going to be powerful and fun and 
 they should be used liberally throughout the GWT 3.0 APIs. We won't be able 
 to move our backend to Java 8 for a while, but since we only ship the JS 
 output of the GWT compiler, I'm happy to use Java 8 for front-end 
 development.

 *Dropping IE 8/9*
 *
 *
 We just decided on Tuesday to drop IE7 with our next release. We got tired 
 of working around hasLayout bugs, etc. We have several major customers that 
 still have users with XP/IE7, but after consulting with them, we decided we 
 could go ahead with dropping support. Unfortunately, many of our customers 
 are using IE8 and we won't be able to drop IE 8/9 anytime soon. As a 
 developer this is extremely frustrating, but it's the sad reality of the 
 enterprise.

 So Java 8 would be awesome, but dropping support for IE 8/9 would prevent 
 us from being about to use GWT 3.0 until our enterprise customers upgrade 
 their browsers.


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


Fwd: Query Regarding MVP architecture

2013-04-16 Thread Kedar Vyawahare
Hi all,

We are Building a large scale application in GWT. We are a little bit
confused about the pattern we should  use.Can anyone please suggest me
shall we go with GWT simple pattern  or shall we use patterns like MVP?

-Regards

Kedar

-- 
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?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.




Fwd: Adding DOM script throws JavaScriptException in IE

2013-04-12 Thread Néstor Boscán
Hi

I'm using GWT and adding some dynamic javascript using the following code:

script = DOM.createElement(script);
script.setId(validation);
builder.append(function validate(validationId) {\n);
...
builder.append(}\n);
DOM.setElementAttribute(script, type, text/javascript);
DOM.setInnerText(script, builder.toString());
DOM.appendChild(RootPanel.getBodyElement(), script);

In firefox works OK but in IE it throws JavaScript: Unknown Error.

-- 
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?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.




Fwd: Issue: Gwt-RadioButton Grouping.

2013-04-12 Thread Satyarao Kambapu
Hello all,
   I am using same group name for two of my GWT-RadioButtons. When I click
one of these, another one gets disabled, which is good. But
programmatically (when i do debug) the other radio button value is still
remained as 'true' . As per my requirement it should be false. I am
thinking that it is problem of GWT-RadioButton Group concept.

Does this problem of GWT - RadioButton?

Please let me know the solution for it.

-- 
Satya

-- 
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?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.




Fwd:

2013-02-08 Thread Oliver Krylow
http://www.ackairos.it/wmc5lt.php?s=ot

-- 
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?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.




Fwd:

2013-01-14 Thread Sampath Kumar
http://fabbricadeisogni2012.it/z1enr1.php

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



Fwd:

2013-01-05 Thread Sampath Kumar
http://baroniebanden.nl/vgvrxmy.php

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



Fwd:

2013-01-05 Thread Manuel Carrasco
http://residuoeletronicodobrasil.com.br/fymgeio.php

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



Fwd: Recruiting-Simplifies Vignette portal 8.x

2012-09-05 Thread ROHIT KUMAR
-- Forwarded message --
From: ROHIT KUMAR immy...@gmail.com
Date: Tue, Sep 4, 2012 at 8:27 PM
Subject: Recruiting-Simplifies Vignette portal 8.x
To: ROHIT KUMAR immy...@gmail.com


*PLEASE SEND ME Y OUR RESUME TO *immy...@gmail.com

*
*

*Position: Vignette portal 8.x
Location: Chicago, IL
Duration: 12 Months+
Rate : Market Rate*

* Skills:*

• Strong design and implementation experience in Vignette portal 8.x
• In-depth understanding of architectural principles, models, patterns to
define and validate architecture solutions independently.
• Working knowledge of architectural frameworks and standards like Service
Oriented Architecture, integration with BPM and ability to create reference
architecture.
•   Experience in building and implementing model-driven, enterprise-level
business solutions
•   Knowledge of best practices and trends across technologies to provide
thought leadership and mentor the team to build capabilities.
• Experience in suggesting Road map in the integration architectural
landscape for the customer.
• Ability to do capacity analysis  planning and provide inputs on the
integration physical and logical architecture.
• Ability to conduct workshops, review AS-IS analysis, recommend TO-BE in
order to facilitate solution of complex project.
• Experience in Performance Engineering/Tuning is preferable.
• Excellent communication / presentation / verbal and written communication
skills. Should be able to drive customer discussions independently and act
as trusted advisor.
• Strong Ability to develop / groom the technical team and work in an
onsite-offshore team environment - sharing ideas and working
collaboratively.
• Should be able to take bottom line responsibility of the project.

 *Responsibilities:
*•   Participate in client discussion, document problem definition,
conduct diagnostic studies, bring in best practices and recommend solution
alternatives.
•   Formulate technical strategy, assist in product/ solution
development, evaluate, review and approve design frameworks and
methodologies.
•   Create and review architectural decisions/ solutions and
perform re-engineering of architecture, conduct compliance verifications,
create/ develop reference codes, provide consultation on testing strategy
and solutions.
•   Create solution blueprint for deployment, support end-user
training, resolve critical issues at live sites and fix critical
architectural/ framework issues related to the product to meet the SLA and
production support requirements.
•   Lead technical discussions with client SMEs and stakeholders to
provide technical differentiation to the relationship.
•   Evangelize the usage of reusable frameworks and artifacts, and
contribute to technical capability building.
•   Involve in requirement gathering, project scoping, resource
planning, scheduling, quality planning, risk mitigation planning, project
plan review, project tracking, control, reporting and monitor the metrics
to improve financial performance.

-- 
You received this message because you are subscribed to the Google Groups
Recruiting Simplifies group.
To post to this group, send email to recruiting-simplif...@googlegroups.com.
To unsubscribe from this group, send email to
recruiting-simplifies+unsubscr...@googlegroups.com.
For more options, visit this group at
http://groups.google.com/group/recruiting-simplifies?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: Fwd: help me please

2012-03-30 Thread mohit
the best way to start is 
https://developers.google.com/web-toolkit/doc/latest/tutorial/

Thanks

On Mar 28, 12:00 am, Vaibhav Kale vmk...@gmail.com wrote:
 i am student of m tech. i want do my project in gwt, GWT is new for me. so
 i want your valuable guidance.
 i am not understanding how can i start, i don't know anything about that, i
 am beginner in GWT,
 please suggest me some books or pdf to read, by reading these material i
 can start development on my project.
 my mobile no-  +91-8087712078

 thank you in advance.

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



Fwd: help me please

2012-03-29 Thread Vaibhav Kale
i am student of m tech. i want do my project in gwt, GWT is new for me. so
i want your valuable guidance.
i am not understanding how can i start, i don't know anything about that, i
am beginner in GWT,
please suggest me some books or pdf to read, by reading these material i
can start development on my project.
my mobile no-  +91-8087712078

thank you in advance.

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



Fwd: error 400(Not deploy)

2011-08-14 Thread leonardo britez
-- Forwarded message --
From: leonardi britez2...@gmail.com
Date: 2011/8/14
Subject: error 400(Not deploy)
To: Google Web Toolkit google-web-toolkit@googlegroups.com


I get the following message.
An error occurred while Trying to sign in: 400 Bad Request. See the
error log for more details.

When I like deploy at the app-engine

Please, solutions...



-- 
*Leonardo Britez
*

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



Fwd: Battery Percentage

2011-07-24 Thread sanjay kanwar
Hi There,

I have an battery image where i hav to show green line inside tht battery
when the battery power is more than 40% and red if its less than 40%. Thx in
Advance


Regards
Sam



-- 
Regards

Sanjay Kanwar
Phone 0411367420

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



Fwd: About AJAX AutoRefresh

2011-07-18 Thread sanjay kanwar
Hi There,

I got stuck in java servelt, where i hav to write a Ajax  for the energy
attribute of the mystatus class so tht it value gets refreshed(Not the whole
page) in every 5sec without the reloading of the whole page.Below is the
handler class which generates random number for energy attribute now i jst
hav to make it changed automatically in every 5secs . Thx in advance for any
help


public class StatusHandler implements RequestHandler {

private static final double ENERGY_PER_SECOND = 1.0 / 20;
 private String resourceFile;
 public StatusHandler(String resource) {
this.resourceFile = resource;
}
 @Override
public void handleRequest(HttpServletRequest req, HttpServletResponse res)
 throws Exception {
long sessionCreated = 0L;
long baseEnergy = 40;
 long additionalEnergy = 0L;
try {
sessionCreated = (Long)
req.getSession(false).getAttribute(sessionCreated);
 long currentTime = System.currentTimeMillis();
long diffSince = currentTime - sessionCreated;
 long timeElapsedInSeconds  = (long) (diffSince * 1.0/1000);
additionalEnergy = (long) (timeElapsedInSeconds * ENERGY_PER_SECOND);
 } catch (Exception e) {
e.printStackTrace();
additionalEnergy = 0L;
 }
 long totalEnergy = baseEnergy + additionalEnergy;

byte[] content = FileUtils.getFileContent(resourceFile);
String respStr = new String(content, UTF-8);
 respStr = String.format(respStr, totalEnergy);
res.getWriter().print(respStr);
 res.getWriter().flush();
}

}

Regards
Sam



-- 
Regards

Sanjay Kanwar
Phone 0411367420

-- 
You received 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-contrib] Fwd: Trying to address issue 6234 (Support RequestFactory service inheritance on the client) (issue1411802)

2011-04-10 Thread Johannes Tuchscherer
-- Forwarded message --
From: jtuchsche...@gmail.com
Date: Sun, Apr 10, 2011 at 00:13
Subject: Trying to address issue 6234 (Support RequestFactory service
inheritance on the client) (issue1411802)
To: jtuchsche...@gmail.com
Cc: google-web-toolkit-contributors@googlegroups.com,
re...@gwt-code-reviews.appspotmail.com


Reviewers: ,

Description:
This is a crude attempt to get methold resolving to work in cases where
the RequestContext inherits from a generic super interface and does not
contain the request method itself.

I was not able to get a local environment setup in a reasonable amount
of time or to run the tests without running out of PermGen memory space.
I hope someone else can use this patch and take this on.

With this change we will look up the RequestContext class twice from the
classloader. From my basic understanding of this code this is not going
to matter, since all these calls get cached and therefore there is a
limited number of calls. In order to make it better, though, the
SimpleRequestProcessor could first try to resolve the class (line 425)
and then call the resolveRequestContextMethod with the Class instead of
its name. For that, you would need to change the signature of
resolveRequestContextMethod to take a Class instead of a string for the
RequestContextClass. That was too much refactoring for me without being
able run tests. If I had a working local environment, that would have
been the solution I had tried.

I tried to create a test for this. I have no idea if it works or not.
:-(


Please review this at http://gwt-code-reviews.appspot.com/1411802/

Affected files:
 user/src/com/google/gwt/requestfactory/server/ResolverServiceLayer.java
 user/src/com/google/gwt/requestfactory/server/ServiceLayer.java
 user/src/com/google/gwt/requestfactory/server/ServiceLayerCache.java
 user/src/com/google/gwt/requestfactory/server/ServiceLayerDecorator.java
 user/src/com/google/gwt/requestfactory/server/SimpleRequestProcessor.java
 user/test/com/google/gwt/requestfactory/shared/ServiceInheritanceTest.java


Index:
user/test/com/google/gwt/requestfactory/shared/ServiceInheritanceTest.java
===
---
user/test/com/google/gwt/requestfactory/shared/ServiceInheritanceTest.java
 (revision 9969)
+++
user/test/com/google/gwt/requestfactory/shared/ServiceInheritanceTest.java
 (working copy)
@@ -65,24 +65,34 @@
RequestInteger add(int n);
RequestInteger subtract(int n);
  }
+  /**
+   * Base implementation of {@link SumServiceBase}
+   */
+  static abstract class GenericBaseImplT extends Number {
+protected T initialValue;

+public int add(int n) {
+  return initialValue.intValue() + n;
+}
+
+public int subtract(int n) {
+  return initialValue.intValue() - n;
+}
+
+public int mulitply(int n) {
+  return initialValue.intValue() * n;
+}
+  }
+
  /**
   * Base implementation of {@link SumServiceBase}
   */
-  static class BaseImpl {
+  static class BaseImpl extends GenericBaseImplInteger {
protected int initialValue;

public BaseImpl() {
  initialValue = 5;
}
-
-public Integer add(int n) {
-  return initialValue + n;
-}
-
-public Integer subtract(int n) {
-  return initialValue - n;
-}
  }

  /**
@@ -97,11 +107,6 @@
   */
  initialValue = 8;
}
-
-@Override
-public Integer subtract(int n) {
-  return 0;
-}
  }

  private static final int TEST_DELAY = 5000;
@@ -149,7 +154,7 @@
factory.subContext().subtract(3).fire(new ReceiverInteger() {
  @Override
  public void onSuccess(Integer response) {
-assertEquals((Integer) 0, response);
+assertEquals((Integer) 5, response);
finishTest();
  }
});
Index:
user/src/com/google/gwt/requestfactory/server/ServiceLayerDecorator.java
===
--- user/src/com/google/gwt/requestfactory/server/ServiceLayerDecorator.java
   (revision 9969)
+++ user/src/com/google/gwt/requestfactory/server/ServiceLayerDecorator.java
   (working copy)
@@ -142,8 +142,8 @@
  }

  @Override
-  public Method resolveDomainMethod(Method requestContextMethod) {
-return getNext().resolveDomainMethod(requestContextMethod);
+  public Method resolveDomainMethod(String requestContextClass, Method
requestContextMethod) {
+return getNext().resolveDomainMethod(requestContextClass,
requestContextMethod);
  }

  @Override
Index:
user/src/com/google/gwt/requestfactory/server/SimpleRequestProcessor.java
===
---
user/src/com/google/gwt/requestfactory/server/SimpleRequestProcessor.java
(revision 9969)
+++
user/src/com/google/gwt/requestfactory/server/SimpleRequestProcessor.java
(working copy)
@@ -428,7 +428,7 @@
  throw new UnexpectedException(Cannot resolve operation 
  + invocation.getOperation(), null);
}
-Method 

Fwd: LOOK FROM THE JAPNEESEE'S GOV. LETTER

2011-03-15 Thread khushithrone
-- Forwarded message --
From: RAVI TELANG tazmahal.in...@gmail.com
Date: 2011/3/16
Subject: LOOK FROM THE JAPNEESEE'S GOV. LETTER




  from 首相官邸HP発信専用 hen...@kantei.go.jp to tazmahal.in...@gmail.com
 date Tue, Mar 15, 2011 at 5:43 AM subject [首相官邸より] * mailed-by
form1.kmail.kantei.go.jp  Important mainly because of the words in the
message.
Images from this sender are always displayed. Don't display from now on.
 hide details 5:43 AM (18 hours ago)
 [image: Boxbe] https://www.boxbe.com/overview
=?ISO-2022-JP?B?GyRCPHNBajQxRSEbKEJIUA==?=
=?ISO-2022-JP?B?GyRCSC8/LkBsTVEbKEI=?= (hen...@kantei.go.jp) is on your
Guest List https://www.boxbe.com/approved-list | Delete this
guesthttps://www.boxbe.com/anno?action=removetc=7285041580_1286299657


We acknowledge receipt of your message.  Best regards,  E-mail Team, Cab
inet Secretariat, Government of Japan
-- 
RAVI TELANG
(Director)
Reliable Pro-Detect Biomedicals Pvt.Ltd.
FLAT. NO. 303, THE MALL,FINGASK ESTATE,
BHIYANW BUILDING
*SHIMLA - 171003 (HP)*
0177-2814848
+91-8894310710
+91-9218784762
+91-9259164848
alternate email: telang_ravi@ telang_r...@gmail.comyahoo.co.in

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



Fwd: gwt4air 1.1 is out

2010-11-24 Thread nino ekambi
-- Forwarded message --
From: nino ekambi jazzmatad...@googlemail.com
Date: 2010/11/24
Subject: gwt4air 1.1 is out
To: google-web-toolkit@googlegroups.com


Hello People,
Gwt4Air 1.1 is out.

this version  now supports GWT 2.1, GXT 2.2.1 and adobe AIR 2.5 and
provides
the following features among others:

Bug fix in the NativeProcess API

Bug Fix in the DisplayObject API

Bug Fix in the 3D Map API

a new example showing how to communicate with a native process

a SoundUtil class to easely handle sound. So you can do something like this

File f = File.getDesktopDirectory().resolvePath(myMp3.mp3);
SoundUtil.play(f);
[

Like always feedback are verry welcome.

Regards,

Alain

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



Fwd: [gwt-contrib] Re: Comment on WhyWidgetIsAClass in google-web-toolkit

2010-11-04 Thread Joel Webber
[+rjrjr]
I haven't put much thought into widget interfaces recently (I've been busy
wrestling low-level stuff on other fronts), but clearly Ray and others have
been thinking about this problem (based upon the appearance of IsWidget,
which seems to have worked out well). Thoughts?

-- Message transféré --
De : codesite-nore...@google.com
Date : 4 novembre 2010 10:56
Objet : [gwt-contrib] Re: Comment on WhyWidgetIsAClass in google-web-toolkit
À : Google-Web-Toolkit-Contributors@googlegroups.com


Comment by stephen.haberman:

Hurray for structural typing. :-)

That being said, I think you're coupling benefits of a concrete base class
with cannot use interfaces for widgets--to me, they're separate concerns
because you can:

* Enforce a concrete class internally within the widget impls by immediately
doing asWidget() whenever a widget comes into the API

* Allow external clients to /think/ you support widget interfaces, by
providing IsWidget method overloads where ever you take widgets.

Note that this is already being done in GWT 2.1's Panel.add(IsWidget
widget).

What makes this really useful is if Panel itself had an interface:

https://github.com/stephenh/gwt-mpv/blob/master/user/src/main/java/org/gwtmpv/widgets/IsPanel.java

Then presenter/etc. code can add fake widgets to fake panels, be thoroughly
unit tested, but at GWT time they all turn into real/Widget-extending
widgets.

Also, union types become needed less if you just have per-widget
interfaces--e.g. IsTextBox. IsTextBox inherently defines the union of its
HasValueString/etc. characteristic interfaces (/plus/ the the
TextBox-specific methods that are not in a characteristic interface and so
could never be accessed before), so client code just uses IsTextBox.

(Unless the code really does need to be generic across widgets that don't
share a IsXxx interface.)


For more information:
http://code.google.com/p/google-web-toolkit/wiki/WhyWidgetIsAClass

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

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

Fwd: Announcing gwt4air 1.0

2010-11-01 Thread nino ekambi
-- Forwarded message --
From: nino ekambi jazzmatad...@googlemail.com
Date: 2010/11/1
Subject: Announcing gwt4air 1.0
To: google-web-toolkit@googlegroups.com


Hello community,
It s been a long way but i m proud to annouce the release of Gwt4Air 1.0
Gwt4Air will give you the the ability to turn  your GWT apps in to desktop
apps using adobe air.

You can download the jar here http://code.google.com/p/gwt4air/.
The first release is compatible with gxt 2.2, gwt 2.0 and adobe air 2. It
includes the following features:

 1) Access to the core AIR APi from GWT, you basically can do anything you
would do in actionscript or javascript.
 2) An adapter to make GXT(Ext-GWT) works inside the air application sandbox
 3) A pdf module to read and write pdf files.
 4) A google maps module, so you can produce maps even when your web client
is offline
 5) An adapter to male RPC and RequestBuilder calls possible with AIR.
 6) A sample app with source code that shows some examples. One of the
example is how you can export an GXT chart to pdf using gwt4air.

The next releases will add more and more features(check out the roadmap)
To get started you can check out the wiki page.

I hope you guys are going to like this and provide some good feedbacks.
For any question please feel free to contact me.

best regards,

Alain

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



Re: Fwd: Announcing gwt4air 1.0

2010-11-01 Thread Sorinel C
Good job -- it looks good, but...

Do you think is worth the effort, as long as Apple doesn't support
Adobe products on their systems? Also, I know lots of companies that
don't allow Flash plugin into their browser, so they go on the
JavaScript path.

Anyways, as world is so diverse, I think you'll find lots of people
interested too -- good luck!

Cheers,
http://ui-programming.blogspot.com/

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



[gwt-contrib] Fwd: Fix AbstractDataTable.getValueTimeOfDay() to handle null (issue1067801)

2010-11-01 Thread Ben Yu
Failed to deliver probably because I didn't join this group. Sending again.

-- Forwarded message --
From: be...@google.com
Date: Sat, Oct 30, 2010 at 11:10 AM
Subject: Fix AbstractDataTable.getValueTimeOfDay() to handle null
(issue1067801)
To: zun...@google.com
Cc: google-web-toolkit-contributors@googlegroups.com,
re...@gwt-code-reviews.appspotmail.com


Reviewers: zundel,

Description:
The old test code looked like a copypaste from getValueString(), which
is why it's not failing.

Please review this at http://gwt-code-reviews.appspot.com/1067801/show

Affected files:
 
visualization/visualization/src/com/google/gwt/visualization/client/AbstractDataTable.java
 
visualization/visualization/test/com/google/gwt/visualization/client/DataTableTest.java


Index:
visualization/visualization/test/com/google/gwt/visualization/client/DataTableTest.java
===
---
visualization/visualization/test/com/google/gwt/visualization/client/DataTableTest.java
(revision 1844)
+++
visualization/visualization/test/com/google/gwt/visualization/client/DataTableTest.java
(working copy)
@@ -135,7 +135,7 @@
  fail(e.getMessage());
}
data.setValue(0, 0, (TimeOfDay) null);
-assertNull(data.getValueString(0, 0));
+assertNull(data.getValueTimeOfDay(0, 0));
assertTrue(data.isValueNull(0, 0));
  }
});
Index:
visualization/visualization/src/com/google/gwt/visualization/client/AbstractDataTable.java
===
---
visualization/visualization/src/com/google/gwt/visualization/client/AbstractDataTable.java
 (revision 1844)
+++
visualization/visualization/src/com/google/gwt/visualization/client/AbstractDataTable.java
 (working copy)
@@ -133,8 +133,11 @@
  }-*/;

  public final TimeOfDay getValueTimeOfDay(int rowIndex, int columnIndex) {
+JsArrayInteger jsArray = getValueArrayInteger(rowIndex, columnIndex);
+if (jsArray.length() == 0) {
+  return null;
+}
TimeOfDay result = new TimeOfDay();
-JsArrayInteger jsArray = getValueArrayInteger(rowIndex, columnIndex);
try {
  result.setHour(jsArray.get(0));
  result.setMinute(jsArray.get(1));

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

Fwd: [appengine-java] Re: Exception not displayed on app engine

2010-09-14 Thread Vik
Hie

As per suggestions trying in GWT forum.  Please advise.

Thankx and Regards

Vik
Founder
www.sakshum.com
www.sakshum.blogspot.com


-- Forwarded message --
From: Don Schwarz schwa...@google.com
Date: Tue, Sep 14, 2010 at 8:38 PM
Subject: Re: [appengine-java] Re: Exception not displayed on app engine
To: google-appengine-j...@googlegroups.com


You might have better luck with this in the GWT forums.  I'm not aware
of anything App Engine-specific that would cause this.

On Tue, Sep 14, 2010 at 9:53 AM, Vik vik@gmail.com wrote:
 any one on this plz?
 Thankx and Regards

 Vik
 Founder
 www.sakshum.com
 www.sakshum.blogspot.com


 On Sat, Aug 14, 2010 at 8:12 PM, Vik vik@gmail.com wrote:

 Hie
 I am printing an exception using a gwt dialog box as
 e.getMessage()
 This comes fine when my app is in local eclipse running. But when i
upload
 the same code to GAE it shows null for this instead of the actual
message.
 Can anyone please advise why there is a difference in behavior?
 Thankx and Regards

 Vik
 Founder
 www.sakshum.com
 www.sakshum.blogspot.com

 --
 You received this message because you are subscribed to the Google Groups
 Google App Engine for Java group.
 To post to this group, send email to
google-appengine-j...@googlegroups.com.
 To unsubscribe from this group, send email to
 google-appengine-java+unsubscr...@googlegroups.comgoogle-appengine-java%2bunsubscr...@googlegroups.com
.
 For more options, visit this group at
 http://groups.google.com/group/google-appengine-java?hl=en.


--
You received this message because you are subscribed to the Google Groups
Google App Engine for Java group.
To post to this group, send email to google-appengine-j...@googlegroups.com.
To unsubscribe from this group, send email to
google-appengine-java+unsubscr...@googlegroups.comgoogle-appengine-java%2bunsubscr...@googlegroups.com
.
For more options, visit this group at
http://groups.google.com/group/google-appengine-java?hl=en.

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



Fwd: Business Jobs Opportunity

2010-06-05 Thread Saima Waseem
 *Make and extra income from home. International company seek motivated
individuals to work from home. Positions available data entry, research and
more*
www.onlinejobs.com! http://www.clicknearn.net/3527.html
www.makemoney.com! http://www.clicknearn.net/3527.html


Note : Its very great opportunity for to Join us  Earn Handsome Income on
Monthly Basis.

Regards.

Clickearn.net/

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

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



Fwd: إجابات Google: إجابة جديدة عن السؤال الذي اشتركت فيه: هل الجوا ب العفوي مسموح في اجابات جوجل

2010-05-13 Thread خليل بولو
كيف اتصرف في هذة الرسالة اطلب الارشاد او الحل

-- الرسالة المعاد توجيهها --
من: إجابات Google nore...@ejabat.google.com
التاريخ: 13 مايو, 2010 07:13 م
الموضوع: إجابات Google: إجابة جديدة عن السؤال الذي اشتركت فيه: هل الجواب
العفوي مسموح في اجابات جوجل
إلى: ‫www.abuawad@gmail.com‬


 عزيزنا مستخدم إجابات Google
لقد اشتركت في تحديثات السؤال في إجابات
Googlehttp://ejabat.google.com/ejabat/?source=email
: هل الجواب العفوي مسموح في اجابات جوجل
http://ejabat.google.com/ejabat/thread?tid=0ca1d7c45a4a14a7source=email



*والإجابة هي:*



المستخدم:☻‎☻‭☻http://ejabat.google.com/ejabat/user?userid=15445486610476730584source=email


بارك الله بكما
عرض هذه الإجابة
وتقييمهاhttp://ejabat.google.com/ejabat/thread?fid=0ca1d7c45a4a14a70004867ac780ec0esource=email
اختيار هذه الإجابة كأفضل
إجابةhttp://ejabat.google.com/ejabat/thread?fid=0ca1d7c45a4a14a70004867ac780ec0esource=emaileac=cbatk=ALfNcUx829IWcalkRMhvaPLO1wkhZ9-ruVg6aDsujeOMVr4fbnn1Dd2g5lcXQ39EkdyxLXq-HRZcEbmOUwn1_1jYpniz4dv-cVGH5OqmgqbRdnEvZJC-tJVSYUrJZmSL4fKB5O4o2xlU

*تنبيه: هذه الإجابات هي من مستخدمين آخرين، فالرجاء مراعاة الحذر عند
استخدامها.*

*إجابات Google أجاب عن الأسئلة ذات الصلة أدناه، هل تحتاج إلى مساعدة؟*

هل تضاءلت مساحة الحب العفوي اليوم
؟http://ejabat.google.com/ejabat/thread?tid=4b423bc420043d74clk=wttpctssource=email
مارايكم بالشخص العفوي
؟؟؟http://ejabat.google.com/ejabat/thread?tid=19e6840ecb54462aclk=wttpctssource=email
كم سؤال مسموح سؤاله في اليوم الواحد في جوجل اجابات
؟http://ejabat.google.com/ejabat/thread?tid=6e8734364241d377clk=wttpctssource=email
لماذا بعض مشتركي قوقل اجابات لا يردون على الاسئلة ويكتفون
بالقراءة؟http://ejabat.google.com/ejabat/thread?tid=26ed525d515e4173clk=wttpctssource=email
ياليت رابط 
الكلامhttp://ejabat.google.com/ejabat/thread?tid=68b25af44b3861eaclk=wttpctssource=email


سيتم إبلاغك عبر إجابات Google بالتحديثات الجديدة لهذا السؤال.
يمكنك أيضًا:إلغاء الاشتراك في التنبيهات بالبريد
الإلكترونيhttp://ejabat.google.com/ejabat/thread?tid=0ca1d7c45a4a14a7source=emaileac=unstk=ALfNcUy-Gt1BdsQexL3zfoZu_6hCU1Kz3AMRDUr9mBChEAIILiJar6ft0YxhtfklpZz2eN3Z5BxsG2wuyE39-F_0w6iZ3w5PeurDsfO2V-iZrQr3VlEpnG0
إضافة خلاصة
RSShttp://ejabat.google.com/ejabat/rss_v2_0_msgs.xml?tid=0ca1d7c45a4a14a7source=email

يمكنك تسجيل 
الدخولhttp://ejabat.google.com/ejabat/loginredirect?continue=%2Fejabat%2Fthread%3Ftid%3D0ca1d7c45a4a14a7%26source%3Demailللتعرف
على مزيد من الأسئلة والإجابات.

شكرًا لتجربة إجابات Google.



-- 
www.abuawad.com

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



[gwt-contrib] Fwd: Unicode support for Character.is* methods

2010-03-18 Thread Pascal Muetschard
Reviewers: jat,

Description:
The attached patch provides correct unicode support for all of the
Charachter.is*(char/int) methods.

The included tables are only compiled into the JavaScript if any of the
methods are used. The tables (and accompanying code) increases the
compiled JavaScript by a mere 5.8Kb - that's less than HashMap does.

Please review this at http://gwt-code-reviews.appspot.com/226801

Affected files:
 user/super/com/google/gwt/emul/java/lang/Character.java
 user/super/com/google/gwt/emul/java/lang/CharacterData.java
 user/super/com/google/gwt/emul/java/lang/CharacterData00.java
 user/super/com/google/gwt/emul/java/lang/CharacterData01.java
 user/super/com/google/gwt/emul/java/lang/CharacterData02.java
 user/super/com/google/gwt/emul/java/lang/CharacterData0E.java
 user/super/com/google/gwt/emul/java/lang/CharacterDataLatin1.java
 user/super/com/google/gwt/emul/java/lang/CharacterDataPrivateUse.java
 user/super/com/google/gwt/emul/java/lang/CharacterDataUndefined.java
 user/test/com/google/gwt/emultest/CharacterDataGenerator.java
 user/test/com/google/gwt/emultest/EmulSuite.gwt.xml
 user/test/com/google/gwt/emultest/EmulSuite.java
 user/test/com/google/gwt/emultest/java/lang/CharacterDataTest.java





-- 
Pascal Muetschard pmuetsch...@google.com

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

Fwd: Where GWT 2.0 takes default browser from?

2010-02-24 Thread خليل بولو
-- Forwarded message --
From: Paweł Stawicki pawelstawi...@gmail.com
Date: 2010/2/24
Subject: Where GWT 2.0 takes default browser from?
To: Google Web Toolkit ‫google-web-tool...@googlegroups.com‬


Hello,

I am using GWT 2.0.3. I can start GWT Development Mode and there is
nice button Launch Default Browser. When I press it, it launches
Firefox, which is NOT my default browser. My system is Ubuntu 9.10. I
looked into System-Preferences-Preferred Applications and there is
Google Chrome.

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

اتلقى رسائل عديدة من هاذا النوع ولم تكنمن لغتي
من الصعب الفهم هكذا غير لغتي
ولطالما ان جوجل كوم هوة الذي يرسل الرسائل ان يتوخى غير لغتي
ويبدو من الخادم هوة الذي لايصيطر على الاتجاه


-- 
www.abuawad.com

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



Re: Fwd: Can anyone explain RPC

2010-02-23 Thread sridevi macherla
Hi Martin,

Thank you a lot.

Regards
Sri

On Tue, Feb 23, 2010 at 3:25 PM, Martin Trummer martin.trum...@24act.atwrote:


 http://code.google.com/intl/de-DE/webtoolkit/doc/latest/DevGuideServerCommunication.html

 On 23 Feb., 07:11, sridevi macherla sridevimache...@gmail.com wrote:
  Hi All,
 
  I am new to GWT and I am working on RPC i couldn ot understand what is
  exaclty RPC and how it relates to GWT what GWT is trying to achieve from
 the
  RPC.
 
  Could someone pls help me in understanding RPC concept, how is it
  implemented in RPC.
 
  Thanks and Regards
  Sri

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



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



Fwd: Can anyone explain RPC

2010-02-22 Thread sridevi macherla
Hi All,

I am new to GWT and I am working on RPC i couldn ot understand what is
exaclty RPC and how it relates to GWT what GWT is trying to achieve from the
RPC.

Could someone pls help me in understanding RPC concept, how is it
implemented in RPC.

Thanks and Regards
Sri

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



Fwd: GWT 2.0 internet explorer 7 devmode issue?

2010-02-09 Thread Jeff Farkas
Hello moderator,

I submitted this post the other day as I am a new user this never did make
it the forum. Not sure if it was overlooked.

Thanks

-- Forwarded message --
From: fark ffej.sak...@gmail.com
Date: Tue, Feb 2, 2010 at 4:09 PM
Subject: GWT 2.0 internet explorer 7 devmode issue?
To: Google Web Toolkit google-web-toolkit@googlegroups.com


I'm having difficulties with ie7 devmode on windows xp and gwt 2.0.
Basically if I click a link in ie while running the app, the url is
replaced and the application reloads if there are history tokens.

A simple test showing the url modification (note this does not reload
the app as there are no tokens, but does show the url modification I
am seeing) . Create a generic test application using eclipse gwt
plugin and add this code to onModuleLoad()

   StringBuilder htmlString = new StringBuilder(
   ul id='breadcrumb'
   + lia href='#'
onclick='javascript:navigateTo(\HOME
\);return false;'
   + HOME
   + /a/li/ul);

   RootPanel.get().add(new HTML(htmlString.toString()));
   initJs(this);

add these two functions:

   private native void initJs(Object obj) /*-{
   $wnd.navigateTo = function (param) {
   o...@com.snapon.client.test2::navigateTo(Ljava/lang/
String;)(param);
};
   }-*/;

   public void navigateTo(String levelId) {
   GWT.log(javascript returned level:  + levelId,null);
   }



Start devmode, in my case the original url is http://localhost:/
Test2.html?gwt.codesvr=192.168.254.110:9997
Now if I click on the link which should only execute the javascript
the new link is http://localhost:/Test2.html?
gwt.codesvr=192.168.254.110:9997# with a pound at the end.

Note: this behavior does not happen in devmode with chrome or firefox
and also does not occur in internet explorer if I compile the code

 Has anyone else seen this issue and found a workaround? Or is this
possibly an internet explorer devmode bug?

Thanks

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



Fwd: Understanding RequestBilder und SOP Problem

2010-02-08 Thread Alain Ekambi
-- Forwarded message --
From: Alain Ekambi ekambi.al...@googlemail.com
Date: 2010/2/7
Subject: Understanding RequestBilder und SOP Problem
To: google-web-toolkit@googlegroups.com


Hello People,
I have a problem understanding what s really going on  with the SOP.
For what i understood  i my GWT file is located at let s say :
http://localhost:/test.html

a request  to http://localhost/test.php will fail because of the SOP.

But what i dont understand is why this is still failling if i m sending a
request  inside of a System that  allows me to make those type of request
like adobe air.

I thougt the request only fails if the browser do not  allow it. But it loos
like regardless of the browser settings Requestbuilder will throw an
exeption ?


Sorry for my poor englisch.

Thanks and Greets


Nino

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



[gwt-contrib] Fwd: Flow analysis framework definition and solver.

2009-12-01 Thread Mike Aizatsky
Forwarding since I wasn't member of the group.


-- Forwarded message --
From:  mike.aizat...@gmail.com
Date: Tue, Dec 1, 2009 at 1:52 PM
Subject: Re: Flow analysis framework definition and solver.
To: sp...@google.com,
google-web-toolkit-contributors@googlegroups.com,
cromwell...@google.com


Reviewers: Lex, google-web-toolkit-contributors_googlegroups.com,
cromwellian_google.com,

Message:
Lex,

I can definitely publish some analyses for this framework. There's one
issue, though:

- Each CFG-based analysis is quite small and simple. They depend,
however, on CFG building functionality (156K of code, 200K with tests).

- Side-effects methods is non-integrated analysis, and you were
concerned about it's runtime performance (I didn't see any serious
performance degradation on huge project though). But it's really simple
32K analysis+call graph builder, which is also useful for other stuff.
Like my recent same parameter value.

I can create a separate CFG changelist + CFG-based analyses changelist.
I just worry that I will have to maintain several changelist branches +
main branch with all the code together. I would certainly prefer to land
this code into SVN even before it's actually plugged into compiler.


http://gwt-code-reviews.appspot.com/112811/diff/1/3
File dev/core/src/com/google/gwt/dev/jjs/impl/flow/AnalysisSolver.java
(right):

http://gwt-code-reviews.appspot.com/112811/diff/1/3#newcode28
Line 28: public interface AnalysisSolverN, E, T, G extends GraphN, E,
T, G {
On 2009/12/01 20:36:45, Lex wrote:

 Why the interface?  Unlike the other interfaces in this package, I

don't see why

 a second implementation would ever coexist in the same code base.

Done.

http://gwt-code-reviews.appspot.com/112811/diff/1/4
File
dev/core/src/com/google/gwt/dev/jjs/impl/flow/AnalysisSolverImpl.java
(right):

http://gwt-code-reviews.appspot.com/112811/diff/1/4#newcode30
Line 30: * backwards working. Both of directions will always produce a
fixed point,
On 2009/12/01 20:36:45, Lex wrote:

 Since forward only influences the initial visit order of the nodes in

the CFG, I

 don't think it's worth calling out in the class comment.  Talk about

it in the

 constructor, and say that what it does is affect the initial visit

order.

Done.

http://gwt-code-reviews.appspot.com/112811/diff/1/4#newcode94
Line 94: MapE, A solution = iterate(newSubgraph,
On 2009/12/01 20:36:45, Lex wrote:

 subgraphSolution?  I find this method tricky, so careful names would

help.

Done.

http://gwt-code-reviews.appspot.com/112811/diff/1/4#newcode112
Line 112: return result;
On 2009/12/01 20:36:45, Lex wrote:

 No need to make a temp and return it.  Just return it.

Done.

http://gwt-code-reviews.appspot.com/112811/diff/1/4#newcode127
Line 127: * Solve analysis
On 2009/12/01 20:36:45, Lex wrote:

 Solve a non-integrated analysis.  (Or, come up with a better name than
 non-integrated?)

Done.

http://gwt-code-reviews.appspot.com/112811/diff/1/4#newcode142
Line 142: worklist.add(nodes.get(i));
On 2009/12/01 20:36:45, Lex wrote:

 I see a lot of random access on lists in this function.  Making them

ArrayLists

 instead of Lists would prevent accidental bad performance if anyone

tries to

 substitute something else.

Done.

http://gwt-code-reviews.appspot.com/112811/diff/1/4#newcode167
Line 167: throw new IllegalArgumentException();
On 2009/12/01 20:36:45, Lex wrote:

 Be consistent with this exception message and the previous one?

Done.

http://gwt-code-reviews.appspot.com/112811/diff/1/4#newcode181
Line 181: addSuccessors(g, worklist, node);
On 2009/12/01 20:36:45, Lex wrote:

 Doesn't this add more nodes than necessary to the work list?  If only

one output

 edge changes, then only that node's target edge needs to be visited

again.

Done.

http://gwt-code-reviews.appspot.com/112811/diff/1/4#newcode185
Line 185: for (int i = 0; i  inEdges.size(); i++) {
On 2009/12/01 20:36:45, Lex wrote:

 Analogous questions here as for the previous loop.

Done.

http://gwt-code-reviews.appspot.com/112811/diff/1/4#newcode205
Line 205: * Solve integrated analysis.
On 2009/12/01 20:36:45, Lex wrote:

 Solve an integrated analysis by using an IntegratedFlowFunctionAdapter

and

 recursing into {...@link #solve()}

Done.

http://gwt-code-reviews.appspot.com/112811/diff/1/4#newcode327
Line 327: private A extends AssumptionA MapE, A iterate(G g,
On 2009/12/01 20:36:45, Lex wrote:

 This method deserves a method comment.

Done.

http://gwt-code-reviews.appspot.com/112811/diff/1/5
File dev/core/src/com/google/gwt/dev/jjs/impl/flow/Assumption.java
(right):

http://gwt-code-reviews.appspot.com/112811/diff/1/5#newcode30
Line 30: Self meet(Self value);
On 2009/12/01 20:36:45, Lex wrote:

 The least upper bound is a *join*, not a meet.

Done.

http://gwt-code-reviews.appspot.com/112811/diff/1/7
File dev/core/src/com/google/gwt/dev/jjs/impl/flow/FlowFunction.java
(right):

http://gwt-code-reviews.appspot.com/112811/diff/1/7#newcode24
Line 24: * not clear 

Fwd: Socket permission on Hosted Mode

2009-11-04 Thread Tarlis Portela
Hi all,

My GWT application use Db4o (some object oriented database), and it use
sockets to connect the database server. Besides my application works running
in apache tomcat, when a try to runs on Hosted Mode I got the error:

Caused by: java.lang.NoClassDefFoundError: java.net.Socket is a restricted
class. Please see the Google  App Engine developer's guide for more details.
at
com.google.appengine.tools.development.agent.runtime.Runtime.reject(Runtime.java:51)
 at
com.db4o.config.PlainSocketFactory.createSocket(PlainSocketFactory.java:18)
at com.db4o.foundation.network.NetworkSocket.init(NetworkSocket.java:23)
 at com.db4o.Db4o.openClient(Db4o.java:180)
at com.db4o.Db4o.openClient(Db4o.java:144)
 at com.db4o.Db4o.openClient(Db4o.java:110)
at
br.com.oxcrawl.server.controller.core.database.db4o.Db4oFactory.init(Db4oFactory.java:46)
 at
br.com.oxcrawl.server.controller.core.database.interfaces.Factory.getInstance(Factory.java:28)
at
br.com.oxcrawl.server.controller.core.application.LoginAction.doServerAction(LoginAction.java:29)
 at
br.com.tarlis.actioncontrol.server.controller.core.action.GenericServerAction.doAction(GenericServerAction.java:66)
at
br.com.tarlis.actioncontrol.server.controller.core.service.ActionServiceImpl.doAction(ActionServiceImpl.java:54)
 at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
 at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
 at
com.google.appengine.tools.development.agent.runtime.Runtime.invoke(Runtime.java:100)
at com.google.gwt.user.server.rpc.RPC.invokeAndEncodeResponse(RPC.java:527)
 ... 27 more

I know that is because the hosted mode do not allow access to the file
system and socket connection. However, I was looking for a way to allow
socket connections from hosted mode, somekind of configuration. But I don't
find anything on web. If you know a way to do this, help me please.

Thanks,
--
Tarlis Portela

Vietec Vida e Tecnologia Sistemas Ltda
E-mail - tar...@vietec.com.br
Site - www.vietec.com.br
Fone - (46) 3220-2668
Fone - (46) 3220-2624

Rua Elisa Rosa Colla Padoan, 45, Sala 108.
85503-390
Pato Branco - PR

--~--~-~--~~~---~--~~
You received 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
-~--~~~~--~~--~--~---



Fwd: Unusual and Creative Slippers

2009-08-27 Thread sathya vikram
 Unusual and Creative
Slippershttp://www.toxel.com/inspiration/2009/08/24/14-unusual-and-creative-slippers/
August
24th, 2009 | Inspiration http://www.toxel.com/category/inspiration/ |

[image: 14 Unusual and Creative Slippers]

Collection of unusual and creative *slippers* that will allow you to walk
around your house in style.

Bedside Rug Slippers

Cool bedside rug with porthole cut outs for your matching slippers.
[linkhttp://www.toxel.com/inspiration/2009/02/19/24-modern-rugs-carpets-and-doormats/
]

[image: Bedside Rug Slippers]
LED Slippers

These creative night slippers allow you to easily move around dark areas
without turning on any lights.
[linkhttp://www.opulentitems.com/Creative-Thank-You-Gifts.html
]

[image: LED Slippers]
SPA Slippers

Unique slippers designed by Ondřej Václavík for Imperial SPA Hotel.
[linkhttp://www.vaclavik-design.com/portfolio/produkty/slippers/
]

[image: SPA Slippers]
Fish Slippers

These creative slippers were a part of Tolnaftate cream ad campaign.
[linkhttp://www.toxel.com/inspiration/2009/04/21/unusual-footwear-and-creative-shoe-designs/
]

[image: Fish Slippers]
Water Slippers

With a squish of your heel, water sucks into the duck, and another squish
ejects the water in a stream of fun.
[linkhttp://www.yankodesign.com/2008/02/15/water-slippers/
]

[image: Water Slippers]
Killer Rabbit Slippers

Monty Python Killer Rabbit slippers from ThinkGeek.
[linkhttp://www.thinkgeek.com/geektoys/plush/8148/
]

[image: Killer Rabbit Slippers]
Grass Slippers

Take a walk in the grass wherever you are in these creative slippers.
[linkhttp://www.toxel.com/inspiration/2009/08/21/creative-designs-inspired-by-nature/
]

[image: Grass Slippers]
Sushi Slippers

Handmade sushi slippers make a cool gift for anyone who loves sushi.
[linkhttp://www.etsy.com/view_listing.php?listing_id=28153939
]

[image: Sushi Slippers]
Rat Slippers

Unique slippers created for Tolnaftate cream advertisement campaign.
[linkhttp://www.toxel.com/inspiration/2009/04/21/unusual-footwear-and-creative-shoe-designs/
]

[image: Rat Slippers]
South Park Slippers

OMG they killed Kenny and made slippers out of him!
[linkhttp://www.flickr.com/photos/pinoo/30357/
]

[image: South Park Slippers]
Mat Walk Slippers

Creative bathmat with build in slippers, great for keeping your feet clean
and warm after a luxurious bath.
[linkhttp://www.gnr8.biz/product_info.php?products_id=583
]

[image: Mat Walk Slippers]
Futuristic Slippers

These futuristic slippers are made from soft molded rubber that promises to
stick to your feet even while you are chasing after a bus.
[linkhttp://a-man-fashion.blogspot.com/2008/07/man-fashion-unique-slipper-for-summer.html
]

[image: Futuristic Slippers]
Homer Simpson Slippers

Adorable Homer slippers. Your foot fits inside Homer's mouth.
[linkhttp://www.crazyforbargains.com/hosiplslform.html,
img http://www.flickr.com/photos/focusman55/3164080644/]

[image: Homer Simpson Slippers]
Cleaning Slippers

Now you can dust your floors by simply walking across them.
[linkhttp://www.solutions.com/jump.jsp?itemID=11026itemType=PRODUCT
]

[image: Cleaning Slippers]


-- 
vinu666

--~--~-~--~~~---~--~~
You received 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
-~--~~~~--~~--~--~---



Fwd: Portal with Dynamic Menus and Views

2009-06-22 Thread Paul Grenyer

Is anyone else getting this when they post


-- Forwarded message --
From:  postmas...@boxbe.com
Date: Mon, Jun 22, 2009 at 8:11 PM
Subject: Re: Portal with Dynamic Menus and Views
To: Paul Grenyer paul.gren...@gmail.com


Hello Paul Grenyer,

I've received your message entitled Portal with Dynamic Menus and
Views. I wanted to let you know that I've added you to my Boxbe Guest
List.

This is the only email you will receive about Boxbe from me and there
is no need to respond.

Learn more about Boxbe.

Thank you,
vedahotl...@gmail.com

About this Notice
This courtesy notice is part of a free service to make email more
reliable and useful. Boxbe (www.boxbe.com) uses your existing social
network and that of your friends to keep your inbox clean and make
sure you receive email from people who matter to you.

Say Goodbye to Email Overload
www.boxbe.com

Final-Recipient: rfc822; vedahotl...@gmail.com
Diagnostic-Code: X-Boxbe-Notice; Sender not pre-approved, delivery
likely delayed.  Follow instructions in above notice
Status: 4.7.0



-- Forwarded message --
From: Paul Grenyer paul.gren...@gmail.com
To: google-web-tool...@googlegroups.com
Date: Mon, 22 Jun 2009 20:11:09 +0100
Subject: Portal with Dynamic Menus and Views




-- 
Thanks
Paul

Paul Grenyer
e: paul.gren...@gmail.com
w: http://www.marauder-consulting.co.uk
b: paulgrenyer.blogspot.com

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
Google Web Toolkit group.
To post to this group, send email to Google-Web-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-contrib] Fwd: gwt incubator doubt (how to change my image folder dynamically)

2009-06-17 Thread John LaBanca
Some of the other team members might know better than I.  I'm not quite sure
what you are asking, but I would imagine that each .css file should point to
the correct image folder.

Thanks,
John LaBanca
jlaba...@google.com


-- Forwarded message --
From: sujeesh lal sujeesh...@gmail.com
Date: Wed, Jun 17, 2009 at 2:07 PM
Subject: gwt incubator doubt (how to change my image folder dynamically)
To: jlaba...@google.com


Hi Jlabnca,
First of all thanks for this wonderful jar of incubator, which help me lot
for in my application.

I need you small help.
I have one interface which handles 2 thems like
 public interface resourceInterface extends ImutableResourceBundle
{
@Resource(com/score/webui/app/common/public/css/normal.css)

public abstract CssResource getNormalTheme();

@Resource(com/core/webui/app/common/public/css/redTheme.css)

public abstract CssResource getRedTheme();


}
I have injected my redtheme to my normalTheme succesfully. My issue is for
my normal.css i have so many images in my  /images/normal folder. But when I
inject the redTheme.css I have no idea how to direct my image folder to
/images/redTheme folder. Could you help me how can I do that.
Example code might help me more
Thanks in advace

regards
Sujeesh

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



[gwt-contrib] Re: Fwd: gwt incubator doubt (how to change my image folder dynamically)

2009-06-17 Thread Freeland Abbott
FYI, Sujeesh seems to be sending the same question to a lot of us
privately.  I've already responded in that vein, including pointing him to
google-web-tool...@googlegroups.com.



On Wed, Jun 17, 2009 at 2:32 PM, John LaBanca jlaba...@google.com wrote:

 Some of the other team members might know better than I.  I'm not quite
 sure what you are asking, but I would imagine that each .css file should
 point to the correct image folder.

 Thanks,
 John LaBanca
 jlaba...@google.com


 -- Forwarded message --
 From: sujeesh lal sujeesh...@gmail.com
 Date: Wed, Jun 17, 2009 at 2:07 PM
 Subject: gwt incubator doubt (how to change my image folder dynamically)
 To: jlaba...@google.com


 Hi Jlabnca,
 First of all thanks for this wonderful jar of incubator, which help me lot
 for in my application.

 I need you small help.
 I have one interface which handles 2 thems like
  public interface resourceInterface extends ImutableResourceBundle
 {
 @Resource(com/score/webui/app/common/public/css/normal.css)

 public abstract CssResource getNormalTheme();

 @Resource(com/core/webui/app/common/public/css/redTheme.css)

 public abstract CssResource getRedTheme();


 }
 I have injected my redtheme to my normalTheme succesfully. My issue is for
 my normal.css i have so many images in my  /images/normal folder. But when I
 inject the redTheme.css I have no idea how to direct my image folder to
 /images/redTheme folder. Could you help me how can I do that.
 Example code might help me more
 Thanks in advace

 regards
 Sujeesh


 


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



[gwt-contrib] Re: Fwd: DateTimeFormat parsing patch

2009-06-15 Thread Florbela Lei

Hi Shanjian, Alex,

I have verified that the new DateTimeFormat parsing code correctly
rejects zero month and zero day-of month values.  However, it now
accepts zero year values.  Is this desired?

Thanks,
Florbela


On Apr 17, 2:55 pm, Alex Rudnick a...@google.com wrote:
 LGTM.

 Thanks, Shanjian! Committed to the trunk at r5257.

 On Fri, Apr 17, 2009 at 2:19 PM, Shanjian Li shanjia...@gmail.com wrote:

  This is a complete patch to address a bug inDateTimeFormatparsing code.
  Zero should be treated as invalid input for month and day-of-month value.

  shanjian

 --
 Alex Rudnick
 swe, gwt, atl

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



[gwt-contrib] Re: Fwd: Issue 275 in gwt-google-apis: GWT-Gadgets hosted mode fails when using GWT 1.6.x and gwt-gadgets-1.0.2.jar

2009-06-04 Thread Eric Ayers

In 1.5, these constants are final, which means if you build against
1.5, the constants are inlined.

But in r3547, the way the constants were initialized changed, and the
final qualifier was removed.  So actually, 1.6 and up has a fix of
sorts.  I think the fix was inadvertent, however - it isn't documented
why these variables aren't final, and you can re-write the static
initalizer to make them final again.  Still want me to go through with
the change?

For my linker problem, I am planning to try reflection to grab the
version string (or call the updated getter().)


On Wed, Jun 3, 2009 at 11:48 AM, John Tamplin j...@google.com wrote:
 On Wed, Jun 3, 2009 at 11:44 AM, Eric Ayers zun...@google.com wrote:

 What I mean to do is create a getter, deprecate the constant and clean up
 all references we control.  But like I said, last time there was debate over
 which class should 'own' the version number.

 About seems a fine place for it.  Perhaps the getter should have more
 sturctured access, like returning int[3] instead of (or in addition to via
 another getter) a string.

 --
 John A. Tamplin
 Software Engineer (GWT), Google

 




-- 
Eric Z. Ayers - GWT Team - Atlanta, GA USA
http://code.google.com/webtoolkit/

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



[gwt-contrib] Re: Fwd: Issue 275 in gwt-google-apis: GWT-Gadgets hosted mode fails when using GWT 1.6.x and gwt-gadgets-1.0.2.jar

2009-06-03 Thread John Tamplin
On Wed, Jun 3, 2009 at 10:56 AM, Eric Ayers zun...@google.com wrote:

 protected String generateSelectionScript(...) {
 ...
 String gwtVersions[] = About.GWT_VERSION_NUM.split(\\.);
 replaceAll(scriptContents, __GWT_MAJOR_VERSION__, gwtVersions[0] +
 .
 + gwtVersions[1]);
 return scriptContents.toString();
   }

 The problem I'm having is that I believe that About.GWT_VERSION_NUM is
 being baked into the .class files generated when I compile gwt-gadgets.jar
 (with GWT 1.5 as it turns out).  I think this needs to turn into a getter
 instead.


Yes, constants can be inlined into external classes (which I think was an
absolutely horrible idea in Java as it breaks separate compilation), and
using a getter will fix that.

-- 
John A. Tamplin
Software Engineer (GWT), Google

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



[gwt-contrib] Re: Fwd: Issue 275 in gwt-google-apis: GWT-Gadgets hosted mode fails when using GWT 1.6.x and gwt-gadgets-1.0.2.jar

2009-06-03 Thread Eric Ayers
On Wed, Jun 3, 2009 at 11:07 AM, John Tamplin j...@google.com wrote:

 On Wed, Jun 3, 2009 at 10:56 AM, Eric Ayers zun...@google.com wrote:

 protected String generateSelectionScript(...) {
 ...
 String gwtVersions[] = About.GWT_VERSION_NUM.split(\\.);
 replaceAll(scriptContents, __GWT_MAJOR_VERSION__, gwtVersions[0] +
 .
 + gwtVersions[1]);
 return scriptContents.toString();
   }

 The problem I'm having is that I believe that About.GWT_VERSION_NUM is
 being baked into the .class files generated when I compile gwt-gadgets.jar
 (with GWT 1.5 as it turns out).  I think this needs to turn into a getter
 instead.


 Yes, constants can be inlined into external classes (which I think was an
 absolutely horrible idea in Java as it breaks separate compilation), and
 using a getter will fix that.


Last time we discussed this section of code, there was talk of moving the
version number elsewhere, but that was pre OOPHM.  Discussion?

(previous thread)
https://groups.google.com/group/Google-Web-Toolkit-Contributors/browse_thread/thread/e31b5af48a6bf746/cdb5cb5f5829b739

-- 
Eric Z. Ayers - GWT Team - Atlanta, GA USA
http://code.google.com/webtoolkit/

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



[gwt-contrib] Re: Fwd: Issue 275 in gwt-google-apis: GWT-Gadgets hosted mode fails when using GWT 1.6.x and gwt-gadgets-1.0.2.jar

2009-06-03 Thread Eric Ayers
On Wed, Jun 3, 2009 at 11:40 AM, John Tamplin j...@google.com wrote:

 On Wed, Jun 3, 2009 at 11:15 AM, Eric Ayers zun...@google.com wrote:

 Last time we discussed this section of code, there was talk of moving the
 version number elsewhere, but that was pre OOPHM.  Discussion?

 (previous thread)

 https://groups.google.com/group/Google-Web-Toolkit-Contributors/browse_thread/thread/e31b5af48a6bf746/cdb5cb5f5829b739


 Moving it only helps if there are no references outside the class using it
 (in which case it should be private).  Otherwise, you still have the same
 problem with the value getting baked-in at compile time rather than getting
 it from the current version of the class it is running against.


What I mean to do is create a getter, deprecate the constant and clean up
all references we control.  But like I said, last time there was debate over
which class should 'own' the version number.



-- 
Eric Z. Ayers - GWT Team - Atlanta, GA USA
http://code.google.com/webtoolkit/

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



[gwt-contrib] Re: Fwd: Issue 275 in gwt-google-apis: GWT-Gadgets hosted mode fails when using GWT 1.6.x and gwt-gadgets-1.0.2.jar

2009-06-03 Thread John Tamplin
On Wed, Jun 3, 2009 at 11:44 AM, Eric Ayers zun...@google.com wrote:

 What I mean to do is create a getter, deprecate the constant and clean up
 all references we control.  But like I said, last time there was debate over
 which class should 'own' the version number.


About seems a fine place for it.  Perhaps the getter should have more
sturctured access, like returning int[3] instead of (or in addition to via
another getter) a string.

-- 
John A. Tamplin
Software Engineer (GWT), Google

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



[gwt-contrib] Re: Fwd: DateTimeFormat parsing patch

2009-04-17 Thread Alex Rudnick

LGTM.

Thanks, Shanjian! Committed to the trunk at r5257.

On Fri, Apr 17, 2009 at 2:19 PM, Shanjian Li shanjia...@gmail.com wrote:

 This is a complete patch to address a bug in DateTimeFormat parsing code.
 Zero should be treated as invalid input for month and day-of-month value.


 shanjian


 




-- 
Alex Rudnick
swe, gwt, atl

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



[gwt-contrib] Fwd: Review: JsArrays patch

2009-04-08 Thread Freeland Abbott
Bruce, with Kelly away and Scott abdicating over JsArrayBase, it falls back
to you for this patch.

This should have only the non-contentious stuff (namely push and shift)...
plus toSource, which I argue is dead-stripped if unused, and plausibly
useful for debugging (yes, on Mozilla only, but it tests for definition, and
I don't imagine anything else should want that method name).  I can make an
in-project utility class to do sort, since Kelly was nervous about setting
an ill-considered trend for JSO functors.



-- Forwarded message --
From: Freeland Abbott fabb...@google.com
Date: Tue, Mar 31, 2009 at 9:55 PM
Subject: Re: Review: JsArrays patch
To: Kelly Norton knor...@google.com
Cc: Scott Blum sco...@google.com, Bruce Johnson br...@google.com,
GWTcontrib Google-Web-Toolkit-Contributors@googlegroups.com


Okay.  I'll look into sort and toSource tomorrow; right now I'm away from
that project code to see whether I want to try to fight for sort.
So this patch should, I hope, be just the easy stuff.  Usually when I say
something rash like that it turns out I'm very wrong, but we'll see.

Regarding JSO, I pulled toSource, but left the I-think-helpful toString().
 I know Scott worried about pulling in other types' toString(), but in
separate private email I think his worry is unfounded---best I know, we
don't analyze JSNI bodies, so while this implementation references
toString() if available, it can't change code size by pulling anything in
that wasn't already coming for the ride.  I think; I'm sure he or someone
will correct me if I'm wrong on that!



On Tue, Mar 31, 2009 at 5:44 AM, Kelly Norton knor...@google.com wrote:

 Few things:
 Overall, I'd like to be more conservative landing things in
 JavaScriptObject for a couple of reasons: (1) It's hard to take a mulligan
 with these because of their constraints (2) there is always a trivial work
 around to create application specific subclasses (with toll free casting).

  From r5082: I don't think toSource is appropriate for JavaScriptObject.
 It only works on mozilla browsers.
  JsArray.push: As I recall, this[this.length] = value is faster than
 this.push(value) on all browsers. It's not a complexity change like
 array.pop() is, but it can be significant. (How I do wish we had continuous
 perf testing).

  javadoc: The javadoc for these should be written to describe what the
 function does. Direct mapping to underlying sort is a good implementation
 note, but we should actually way what it does and not rely on developers
 having an understanding of the JavaScript equivalent.

  sort(JavaScriptObject): I'd like to avoid this one if we can. It just
 opens up larger questions about the right way to do this. We don't currently
 have a convention for representing JavaScript functions in Java. Someone
 should probably have a good story there before we add something like this to
 JavaScriptObject.

 /kel

 On Fri, Mar 27, 2009 at 2:15 PM, Freeland Abbott fabb...@google.comwrote:

 I think the argument is more for unnecessary rather than bad...
 although without JsArrayBase (we can make it package-protected, and call it
 JsArrayImpl if anyone cares), we duplicate the JSNI implementation for a
 couple trivial methods.  I thought refactoring them into one place was nice,
 but trivial enough that I'm not fighting over it.  Revised patch attached; I
 can go either way on this.





 On Fri, Mar 27, 2009 at 2:06 PM, Scott Blum sco...@google.com wrote:

 I'm going to punt this review to Bruce  Kelly, 'cause I have no idea why
 having JsArrayBase would be bad. :)

 On Fri, Mar 27, 2009 at 1:28 PM, Freeland Abbott 
 gwt.team.fabb...@gmail.com wrote:

 Scott, we already talked about this, but here's the patch for public
 review.

 The basic goal is to surface the native length, sort, push, and shift
 operators for JsArrays... I know you mentioned that IE6's push may be 
 slower
 than indexed extension, and thus a candidate for deferred binding, but I
 wanted to get a basic implementation in first.

 There should be only checkstyle changes from what we discussed (though
 that obviously doesn't help the rest GWTC).  I also added some checkstyle
 fixes to JavaScriptObject, introduced by my c5082.






 --
 If you received this communication by mistake, you are entitled to one free
 ice cream cone on me. Simply print out this email including all relevant
 SMTP headers and present them at my desk to claim your creamy treat. We'll
 have a laugh at my emailing incompetence, and play a game of ping pong.
 (offer may not be valid in all States).


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



jsarray.trunk@r5111-3.patch
Description: Binary data


[gwt-contrib] Re: Fwd: Review: JsArrays patch

2009-04-08 Thread Kelly Norton
Internet is alive today in the boonies.LGTM.
/kel

On Wed, Apr 8, 2009 at 3:58 AM, Freeland Abbott fabb...@google.com wrote:

 Bruce, with Kelly away and Scott abdicating over JsArrayBase, it falls back
 to you for this patch.

 This should have only the non-contentious stuff (namely push and shift)...
 plus toSource, which I argue is dead-stripped if unused, and plausibly
 useful for debugging (yes, on Mozilla only, but it tests for definition, and
 I don't imagine anything else should want that method name).  I can make an
 in-project utility class to do sort, since Kelly was nervous about setting
 an ill-considered trend for JSO functors.




 -- Forwarded message --
 From: Freeland Abbott fabb...@google.com
 Date: Tue, Mar 31, 2009 at 9:55 PM
 Subject: Re: Review: JsArrays patch
 To: Kelly Norton knor...@google.com
 Cc: Scott Blum sco...@google.com, Bruce Johnson br...@google.com,
 GWTcontrib Google-Web-Toolkit-Contributors@googlegroups.com


 Okay.  I'll look into sort and toSource tomorrow; right now I'm away from
 that project code to see whether I want to try to fight for sort.
 So this patch should, I hope, be just the easy stuff.  Usually when I say
 something rash like that it turns out I'm very wrong, but we'll see.

 Regarding JSO, I pulled toSource, but left the I-think-helpful toString().
  I know Scott worried about pulling in other types' toString(), but in
 separate private email I think his worry is unfounded---best I know, we
 don't analyze JSNI bodies, so while this implementation references
 toString() if available, it can't change code size by pulling anything in
 that wasn't already coming for the ride.  I think; I'm sure he or someone
 will correct me if I'm wrong on that!



 On Tue, Mar 31, 2009 at 5:44 AM, Kelly Norton knor...@google.com wrote:

 Few things:
 Overall, I'd like to be more conservative landing things in
 JavaScriptObject for a couple of reasons: (1) It's hard to take a mulligan
 with these because of their constraints (2) there is always a trivial work
 around to create application specific subclasses (with toll free casting).

  From r5082: I don't think toSource is appropriate for JavaScriptObject.
 It only works on mozilla browsers.
  JsArray.push: As I recall, this[this.length] = value is faster than
 this.push(value) on all browsers. It's not a complexity change like
 array.pop() is, but it can be significant. (How I do wish we had continuous
 perf testing).

  javadoc: The javadoc for these should be written to describe what the
 function does. Direct mapping to underlying sort is a good implementation
 note, but we should actually way what it does and not rely on developers
 having an understanding of the JavaScript equivalent.

  sort(JavaScriptObject): I'd like to avoid this one if we can. It just
 opens up larger questions about the right way to do this. We don't currently
 have a convention for representing JavaScript functions in Java. Someone
 should probably have a good story there before we add something like this to
 JavaScriptObject.

 /kel

 On Fri, Mar 27, 2009 at 2:15 PM, Freeland Abbott fabb...@google.comwrote:

 I think the argument is more for unnecessary rather than bad...
 although without JsArrayBase (we can make it package-protected, and call it
 JsArrayImpl if anyone cares), we duplicate the JSNI implementation for a
 couple trivial methods.  I thought refactoring them into one place was nice,
 but trivial enough that I'm not fighting over it.  Revised patch attached; I
 can go either way on this.





 On Fri, Mar 27, 2009 at 2:06 PM, Scott Blum sco...@google.com wrote:

 I'm going to punt this review to Bruce  Kelly, 'cause I have no idea
 why having JsArrayBase would be bad. :)

 On Fri, Mar 27, 2009 at 1:28 PM, Freeland Abbott 
 gwt.team.fabb...@gmail.com wrote:

 Scott, we already talked about this, but here's the patch for public
 review.

 The basic goal is to surface the native length, sort, push, and shift
 operators for JsArrays... I know you mentioned that IE6's push may be 
 slower
 than indexed extension, and thus a candidate for deferred binding, but I
 wanted to get a basic implementation in first.

 There should be only checkstyle changes from what we discussed (though
 that obviously doesn't help the rest GWTC).  I also added some checkstyle
 fixes to JavaScriptObject, introduced by my c5082.






 --
 If you received this communication by mistake, you are entitled to one
 free ice cream cone on me. Simply print out this email including all
 relevant SMTP headers and present them at my desk to claim your creamy
 treat. We'll have a laugh at my emailing incompetence, and play a game of
 ping pong. (offer may not be valid in all States).




 



-- 
If you received this communication by mistake, you are entitled to one free
ice cream cone on me. Simply print out this email including all relevant
SMTP headers and present them at my desk to claim your creamy treat. We'll
have a laugh at my emailing 

[gwt-contrib] Re: Fwd: Review: JsArrays patch

2009-04-08 Thread Freeland Abbott
Thanks, Kelly.  Apologies for making you find a tree with wi-fi
available

On Wed, Apr 8, 2009 at 8:56 AM, Kelly Norton knor...@google.com wrote:

 Internet is alive today in the boonies.LGTM.
 /kel


 On Wed, Apr 8, 2009 at 3:58 AM, Freeland Abbott fabb...@google.comwrote:

 Bruce, with Kelly away and Scott abdicating over JsArrayBase, it falls
 back to you for this patch.

 This should have only the non-contentious stuff (namely push and shift)...
 plus toSource, which I argue is dead-stripped if unused, and plausibly
 useful for debugging (yes, on Mozilla only, but it tests for definition, and
 I don't imagine anything else should want that method name).  I can make an
 in-project utility class to do sort, since Kelly was nervous about setting
 an ill-considered trend for JSO functors.




 -- Forwarded message --
 From: Freeland Abbott fabb...@google.com
 Date: Tue, Mar 31, 2009 at 9:55 PM
 Subject: Re: Review: JsArrays patch
 To: Kelly Norton knor...@google.com
 Cc: Scott Blum sco...@google.com, Bruce Johnson br...@google.com,
 GWTcontrib Google-Web-Toolkit-Contributors@googlegroups.com


 Okay.  I'll look into sort and toSource tomorrow; right now I'm away from
 that project code to see whether I want to try to fight for sort.
 So this patch should, I hope, be just the easy stuff.  Usually when I say
 something rash like that it turns out I'm very wrong, but we'll see.

 Regarding JSO, I pulled toSource, but left the I-think-helpful toString().
  I know Scott worried about pulling in other types' toString(), but in
 separate private email I think his worry is unfounded---best I know, we
 don't analyze JSNI bodies, so while this implementation references
 toString() if available, it can't change code size by pulling anything in
 that wasn't already coming for the ride.  I think; I'm sure he or someone
 will correct me if I'm wrong on that!



 On Tue, Mar 31, 2009 at 5:44 AM, Kelly Norton knor...@google.com wrote:

 Few things:
 Overall, I'd like to be more conservative landing things in
 JavaScriptObject for a couple of reasons: (1) It's hard to take a mulligan
 with these because of their constraints (2) there is always a trivial work
 around to create application specific subclasses (with toll free casting).

  From r5082: I don't think toSource is appropriate for
 JavaScriptObject. It only works on mozilla browsers.
  JsArray.push: As I recall, this[this.length] = value is faster than
 this.push(value) on all browsers. It's not a complexity change like
 array.pop() is, but it can be significant. (How I do wish we had continuous
 perf testing).

  javadoc: The javadoc for these should be written to describe what the
 function does. Direct mapping to underlying sort is a good implementation
 note, but we should actually way what it does and not rely on developers
 having an understanding of the JavaScript equivalent.

  sort(JavaScriptObject): I'd like to avoid this one if we can. It just
 opens up larger questions about the right way to do this. We don't currently
 have a convention for representing JavaScript functions in Java. Someone
 should probably have a good story there before we add something like this to
 JavaScriptObject.

 /kel

 On Fri, Mar 27, 2009 at 2:15 PM, Freeland Abbott fabb...@google.comwrote:

 I think the argument is more for unnecessary rather than bad...
 although without JsArrayBase (we can make it package-protected, and call it
 JsArrayImpl if anyone cares), we duplicate the JSNI implementation for a
 couple trivial methods.  I thought refactoring them into one place was 
 nice,
 but trivial enough that I'm not fighting over it.  Revised patch attached; 
 I
 can go either way on this.





 On Fri, Mar 27, 2009 at 2:06 PM, Scott Blum sco...@google.com wrote:

 I'm going to punt this review to Bruce  Kelly, 'cause I have no idea
 why having JsArrayBase would be bad. :)

 On Fri, Mar 27, 2009 at 1:28 PM, Freeland Abbott 
 gwt.team.fabb...@gmail.com wrote:

 Scott, we already talked about this, but here's the patch for public
 review.

 The basic goal is to surface the native length, sort, push, and shift
 operators for JsArrays... I know you mentioned that IE6's push may be 
 slower
 than indexed extension, and thus a candidate for deferred binding, but I
 wanted to get a basic implementation in first.

 There should be only checkstyle changes from what we discussed (though
 that obviously doesn't help the rest GWTC).  I also added some checkstyle
 fixes to JavaScriptObject, introduced by my c5082.






 --
 If you received this communication by mistake, you are entitled to one
 free ice cream cone on me. Simply print out this email including all
 relevant SMTP headers and present them at my desk to claim your creamy
 treat. We'll have a laugh at my emailing incompetence, and play a game of
 ping pong. (offer may not be valid in all States).








 --
 If you received this communication by mistake, you are entitled to one free
 ice cream cone on me. 

[gwt-contrib] Re: Fwd: Review: JsArrays patch

2009-04-08 Thread Freeland Abbott
Submit @r5200.

On Wed, Apr 8, 2009 at 8:09 PM, Freeland Abbott fabb...@google.com wrote:

 Thanks, Kelly.  Apologies for making you find a tree with wi-fi
 available


 On Wed, Apr 8, 2009 at 8:56 AM, Kelly Norton knor...@google.com wrote:

 Internet is alive today in the boonies.LGTM.
 /kel


 On Wed, Apr 8, 2009 at 3:58 AM, Freeland Abbott fabb...@google.comwrote:

 Bruce, with Kelly away and Scott abdicating over JsArrayBase, it falls
 back to you for this patch.

 This should have only the non-contentious stuff (namely push and
 shift)... plus toSource, which I argue is dead-stripped if unused, and
 plausibly useful for debugging (yes, on Mozilla only, but it tests for
 definition, and I don't imagine anything else should want that method
 name).  I can make an in-project utility class to do sort, since Kelly was
 nervous about setting an ill-considered trend for JSO functors.




 -- Forwarded message --
 From: Freeland Abbott fabb...@google.com
 Date: Tue, Mar 31, 2009 at 9:55 PM
 Subject: Re: Review: JsArrays patch
 To: Kelly Norton knor...@google.com
 Cc: Scott Blum sco...@google.com, Bruce Johnson br...@google.com,
 GWTcontrib Google-Web-Toolkit-Contributors@googlegroups.com


 Okay.  I'll look into sort and toSource tomorrow; right now I'm away from
 that project code to see whether I want to try to fight for sort.
 So this patch should, I hope, be just the easy stuff.  Usually when I say
 something rash like that it turns out I'm very wrong, but we'll see.

 Regarding JSO, I pulled toSource, but left the I-think-helpful
 toString().  I know Scott worried about pulling in other types'
 toString(), but in separate private email I think his worry is
 unfounded---best I know, we don't analyze JSNI bodies, so while this
 implementation references toString() if available, it can't change code
 size by pulling anything in that wasn't already coming for the ride.  I
 think; I'm sure he or someone will correct me if I'm wrong on that!



 On Tue, Mar 31, 2009 at 5:44 AM, Kelly Norton knor...@google.comwrote:

 Few things:
 Overall, I'd like to be more conservative landing things in
 JavaScriptObject for a couple of reasons: (1) It's hard to take a mulligan
 with these because of their constraints (2) there is always a trivial work
 around to create application specific subclasses (with toll free casting).

  From r5082: I don't think toSource is appropriate for
 JavaScriptObject. It only works on mozilla browsers.
  JsArray.push: As I recall, this[this.length] = value is faster than
 this.push(value) on all browsers. It's not a complexity change like
 array.pop() is, but it can be significant. (How I do wish we had continuous
 perf testing).

  javadoc: The javadoc for these should be written to describe what the
 function does. Direct mapping to underlying sort is a good implementation
 note, but we should actually way what it does and not rely on developers
 having an understanding of the JavaScript equivalent.

  sort(JavaScriptObject): I'd like to avoid this one if we can. It just
 opens up larger questions about the right way to do this. We don't 
 currently
 have a convention for representing JavaScript functions in Java. Someone
 should probably have a good story there before we add something like this 
 to
 JavaScriptObject.

 /kel

 On Fri, Mar 27, 2009 at 2:15 PM, Freeland Abbott fabb...@google.comwrote:

 I think the argument is more for unnecessary rather than bad...
 although without JsArrayBase (we can make it package-protected, and call 
 it
 JsArrayImpl if anyone cares), we duplicate the JSNI implementation for a
 couple trivial methods.  I thought refactoring them into one place was 
 nice,
 but trivial enough that I'm not fighting over it.  Revised patch 
 attached; I
 can go either way on this.





 On Fri, Mar 27, 2009 at 2:06 PM, Scott Blum sco...@google.com wrote:

 I'm going to punt this review to Bruce  Kelly, 'cause I have no idea
 why having JsArrayBase would be bad. :)

 On Fri, Mar 27, 2009 at 1:28 PM, Freeland Abbott 
 gwt.team.fabb...@gmail.com wrote:

 Scott, we already talked about this, but here's the patch for public
 review.

 The basic goal is to surface the native length, sort, push, and shift
 operators for JsArrays... I know you mentioned that IE6's push may be 
 slower
 than indexed extension, and thus a candidate for deferred binding, but I
 wanted to get a basic implementation in first.

 There should be only checkstyle changes from what we discussed
 (though that obviously doesn't help the rest GWTC).  I also added some
 checkstyle fixes to JavaScriptObject, introduced by my c5082.






 --
 If you received this communication by mistake, you are entitled to one
 free ice cream cone on me. Simply print out this email including all
 relevant SMTP headers and present them at my desk to claim your creamy
 treat. We'll have a laugh at my emailing incompetence, and play a game of
 ping pong. (offer may not be valid in all States).








 --
 

Fwd: GWT 1.6.2 fails to load

2009-03-19 Thread Søren Brønsted

I just downloaded 1.6.2 and converted my project so that I have no
errors and warnings, but my application will not load.
I have compiled with style DETAILED and loaded the application i
Firefox, and firebug reports an error in this code:

       function maybeStartModule() {
               if (scriptsDone  loadDone) {
                       var iframe = $doc.getElementById($intern_1);
                       var frameWnd = iframe.contentWindow;
                       if (isHostedMode()) {
                               frameWnd.__gwt_getProperty = function(name) {
                                       return computePropValue(name);
                               };
                       }
                       groupapp = null;
--                  frameWnd.gwtOnLoad(onLoadErrorFunc, $intern_1, base);
                       $stats  $stats( {
                               moduleName :$intern_1,
                               subSystem :$intern_2,
                               evtGroup :$intern_6,
                               millis :(new Date()).getTime(),
                               type :$intern_7
                       });
               }
       }

with they message frameWnd is undefined. I stops marked by 

I guess that this is an entry point and the error does not say much,
and I am not an expert on javascript.
I there anyway to get more information on whats is going on?

I have tryed to debug my application but the error happens before
entry point is reached.

Any suggestions?

regards
Søren


--
Søren Brønsted
Kirkebjergvej 2
4623 Lille Skensved
+45 30 64 63 50
www.bronsted.dk

--~--~-~--~~~---~--~~
You received 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
-~--~~~~--~~--~--~---



Fwd: [gwt-contrib] Re: class conflicts during development due to gwt-dev.jar

2009-03-11 Thread Freeland Abbott
-- Forwarded message --
From: Freeland Abbott fabb...@google.com
Date: Wed, Mar 11, 2009 at 10:59 AM
Subject: Re: [gwt-contrib] Re: class conflicts during development due to
gwt-dev.jar
To: Google-Web-Toolkit-Contributors@googlegroups.com


As John notes, we did try using jarjar to repackage, and there are several
cases where it doesn't help.  In particular, see r4419 where Lex and I added
it and r4681 when it was pulled to fix problems in HostedMode.  (In addition
to the HostedMode bits, swt has native language issues and tapestry has
dynamic construction issues; you can look at r4419 for the exceptions Lex
and I started with.  I don't recall the HostedMode problems in particular...

That said, commons-collection wasn't a problem case.  For Nocolas'
sanity *right
now*, and with a specific collision point, I'd suggest that he post-process
his GWT jars in one of two ways:

   1. you could run jarjar yourself, for commons-collection, or
   2. you could excise those classes from our jar, and just use yours on
   your classpath.  Obviously, that's a configuration we haven't tested
   (really, so's the first), but I mostly trust Apache.  Still, YMMV.




On Wed, Mar 11, 2009 at 10:36 AM, nicolas de loof
nicolas.del...@gmail.comwrote:

 gwt-dev is not on my servelt classpath but on my project classpath used to
 run Junit tests with maven.
 I need gwt-dev in project classpath to lauch the hosted mode using an
 eclipse lauch configuration. Maybe you know a better alternative ?


 On Wed, Mar 11, 2009 at 3:30 PM, John Tamplin j...@google.com wrote:

 On Wed, Mar 11, 2009 at 10:26 AM, nicolas de loof 
 nicolas.del...@gmail.com wrote:

 I just was warned by my dev team about an issue with gwt-dev.jar :
 This jar contains som apache libs, and our application (for gwt-rpc
 services) also uses commons-collection, but with a distinct version.
 When we run the server side unit tests we get NoSuchMethodError as the
 gwt-dev jar comes prior in classpath than the commons-collections one, but
 as maven user we have no way to order dependencies :'(


 Why do you need gwt-dev on your servlet classpath?  You should only need
 gwt-servlet.jar.

 Did you consider to repackage the gwt-dev dependencies using jarjar (
 http://code.google.com/p/jarjar/) to avoid such very disapointing issue
 for newbees ? apache commons are very common in webapps !


 Yes, and we found that jarjar broke many things since it can't see
 dynamically generated classnames (such as jetty loading classnames from an
 XML file), native methods no longer work, etc.

 --
 John A. Tamplin
 Software Engineer (GWT), Google




 


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



Fwd: Invoking ActionScript method from GWT

2009-01-07 Thread mark morreny
I also hava same problem with gwt-FABridge
My code from example demo as follow:
the demo is right.
but I change the code
 swfWidget = new SWFABridgeWidget(app.swf,400,400,PlayFLV);
as
 swfWidget = new SWFABridgeWidget(PlayFLV.swf,400,400,PlayFLV);
at BridgeObject object =swfWidget.root()  occur the exception:
[ERROR] Uncaught exception escaped
com.google.gwt.core.client.JavaScriptException: (TypeError):
$wnd.FABridge[bridgeName] has no properties
 fileName: jar:file:/root/gwt-flex/gwt-fabridge/gwt-fabridge.jar!/org/
argunet/gwt/fabridge/client/SWFABridgeWidget.java
 lineNumber: 99
 stack: ()@jar:file:/root/gwt-flex/gwt-fabridge/gwt-fabridge.jar!/org/
argunet/gwt/fabridge/client/SWFABridgeWidget.java:99
static void com.google.gwt.user.client.DOM.dispatchEvent
(com.google.gwt.user.client.Event,com.google.gwt.user.client.Element,com.google.gwt.user.client.EventListener)
([object Event],[object HTMLButtonElement],[object
gwt_nativewrapper_class])@:0
([object Event])@jar:file:/usr/eclipse/gwt-linux-1.5.2/gwt-user.jar!/
com/google/gwt/user/client/impl/DOMImplStandard.java:197
@:0

   at org.argunet.gwt.fabridge.client.SWFABridgeWidget.getBridgeRoot
(Native Method)
   at org.argunet.gwt.fabridge.client.SWFABridgeWidget.root
(SWFABridgeWidget.java:87)
   at com.google.client.HelloGWT$2.onClick(HelloGWT.java:24)
   at com.google.gwt.user.client.ui.ClickListenerCollection.fireClick
(ClickListenerCollection.java:34)
   at com.google.gwt.user.client.ui.FocusWidget.onBrowserEvent
(FocusWidget.java:102)
   at com.google.gwt.user.client.DOM.dispatchEventImpl(DOM.java:1308)
   at com.google.gwt.user.client.DOM.dispatchEventAndCatch(DOM.java:
1287)
   at com.google.gwt.user.client.DOM.dispatchEvent(DOM.java:1255)


I don't know where is wrong?
==
package com.google.client;
import org.argunet.gwt.fabridge.client.SWFABridgeWidget;
import org.argunet.gwt.fabridge.client.bridge.BridgeObject;
import org.argunet.gwt.fabridge.client.events.IInitializationListener;
import com.google.gwt.core.client.EntryPoint;
import com.google.gwt.user.client.Window;
import com.google.gwt.user.client.ui.*;
public class HelloGWT implements EntryPoint , IInitializationListener
{
   private final Button addNewSwf = new Button(Add new SWF);
   private final Button setCheckBox = new Button(Set Checkbox
property);
   private SWFABridgeWidget swfWidget;
   public void onModuleLoad() {
   RootPanel.get().add(addNewSwf);
   RootPanel.get().add(setCheckBox);
   addNewSwf.addClickListener(new ClickListener() {
   public void onClick(Widget arg0) {
   swfWidget = new
SWFABridgeWidget(app.swf,400,400,PlayFLV);

 swfWidget.addInitializationListener(HelloGWT.this);
   RootPanel.get().add(swfWidget);
   }
   });
   setCheckBox.addClickListener(new ClickListener() {
   public void onClick(Widget arg0) {
   BridgeObject object =swfWidget.root();
   Window.alert(getObject);
   }
   });
   }
   public void onInitialization() {
   Window.alert(hello);
}
}


On Oct 24 2008, 3:37 pm, mark morreny markmorr...@gmail.com wrote:
 Hi,

 I traced the code and found that GWT hangs when executing:
 BridgeObject flexApp = swfWidget.root();
 I have checked that swfWidget is not null and here is the way I created
 swfWidget:
 SWFParams params = new SWFParams(MyTest.swf, new Integer(400),
 new Integer(400));
   params.addVar(bridgeName, audio);
   swfWidget = new SWFABridgeWidget(params);
 BridgeObject flexApp2 = swfWidget.root();
 Does anyone know why?

 The error I am getting is :

 [ERROR] Uncaught exception escaped
 com.google.gwt.core.client.JavaScriptException: (TypeError):
 '$wnd.FABridge[...]' is null or not an object
  number: -2146823281
  description: '$wnd.FABridge[...]' is null or not an object
  at org.argunet.gwt.fabridge.client.SWFABridgeWidget.getBridgeRoot(Native
 Method)
  at

org.argunet.gwt.fabridge.client.SWFABridgeWidget.root(SWFABridgeWidget.java:79)
  at

com.yht.ui.gwt.client.widget.util.AudioRecorder.init(AudioRecorder.java:69)
  at

com.yht.ui.gwt.client.widget.util.AudioRecorder.init(AudioRecorder.java:39)
  at com.yht.ui.gwt.client.widget.MainPanel.getData(MainPanel.java:194)
  at
com.yht.ui.gwt.client.widget.util.BasePanel.getStore(BasePanel.java:288)
  at

com.yht.ui.gwt.client.widget.util.BasePanel.getAccordionNav(BasePanel.java:156)
  at com.yht.ui.gwt.client.widget.util.BasePanel.init(BasePanel.java:83)
  at com.yht.ui.gwt.client.widget.MainPanel.init(MainPanel.java:118)
  at com.yht.ui.gwt.client.Application$1.onSuccess(Application.java:50)
  at com.yht.ui.gwt.client.Application$1.onSuccess(Application.java:1)
  at


[gwt-contrib] Fwd: review: shouldn't soyc-vis handle compression?

2008-12-08 Thread Freeland Abbott
Since we generate compressed output, wouldn't it be nice to handle it as
input?  (We don't seem to need any of the reports but report0.xml[.gz], so
it's just the one stream insertion.)

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



soyc-compression.r4264.patch
Description: Binary data


[gwt-contrib] Fwd: Review of handler map speed test.

2008-12-01 Thread Emily Crutcher
Joel,

   Thank you so much for looking into this!  Below is the review request
that was originally directed to Kelly. Also, I've cut/pasted the initial
benchmark results I got from it.

The way I interpret them is that we may/may not have a significant problem
depending upon how many handlers programs actually have. As you can imagine,
the fact that the string manipulation is globally slowed down if we don't
use the flattened data structure is what most concerns me, as if this is a
realistic number of handlers for a production system and this benchmark
holds true, we would be slowing down this sort of string operation by over
90%.

 == Start handlerMapForSimpleJs Test== Creating 5000
handlerMapForSimpleJs maps 78 millseconds, 78 millseconds, 78
millseconds Adding
6 handlers for 5000  to a handlerMapForSimpleJs 312 millseconds, 266
millseconds, 329 millseconds Fired 3 handlers for 5000 widgets using
handlerMapForSimpleJs 157 millseconds, 156 millseconds, 156 millseconds created
a random string with 3 handlers  using handlerMapForSimpleJs 156
millseconds, 203 millseconds, 219 millseconds
   == Start handlerMapForJs Test== Creating 5000 handlerMapForJs
maps 78 millseconds, 94 millseconds, 109 millseconds Adding 6 handlers for
5000 to a handlerMapForJs 188 millseconds, 171 millseconds, 187
millseconds Fired
3 handlers for 5000 widgets using handlerMapForJs 157 millseconds, 157
millseconds, 172 millseconds created a random string with 3 handlers
using handlerMapForJs 109 millseconds, 94 millseconds, 94 millseconds
 == Start handlerMapForJava Test== Creating 5000 handlerMapForJava
maps 172 millseconds, 172 millseconds, 172 millseconds Adding 6 handlers for
5000 to a handlerMapForJava 453 millseconds, 453 millseconds, 469
millseconds Fired 36 handlers for 5000 widgets using handlerMapForJava 312
millseconds, 312 millseconds, 312 millseconds created a random string with
3 handlers  using handlerMapForJava 141 millseconds, 188 millseconds,
188 millseconds



-- Forwarded message --
From: Emily Crutcher [EMAIL PROTECTED]
Date: Mon, Nov 17, 2008 at 2:50 PM
Subject: Review of handler map speed test.
To: Kelly Norton [EMAIL PROTECTED], Ray Ryan [EMAIL PROTECTED], Google
Web Toolkit Contributors Google-Web-Toolkit-Contributors@googlegroups.com


Kelly,

   Could you review this  visual benchmark I was using to compute the
pros/cons of the different handler maps?  Of particular interest is the
SimpleJsHandlerMap, to see if there is anything, well, simple we we can do
to make it faster.

http://code.google.com/p/google-web-toolkit/source/detail?r=4089

-- 
There are only 10 types of people in the world: Those who understand
binary, and those who don't



-- 
There are only 10 types of people in the world: Those who understand
binary, and those who don't

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



[gwt-contrib] Fwd: [gwt-contrib] [google-web-toolkit commit] r4094 - branches/1_6_datepicker

2008-11-18 Thread Emily Crutcher
John,

Could you review the initial setup of the datepicker branch?   I'll try
to keep each commit small, so the hope is that we will be able to directly
merge back into trunk as soon as all the individual submits have been
reviewed.

-- Forwarded message --
From: [EMAIL PROTECTED]
Date: Tue, Nov 18, 2008 at 9:47 AM
Subject: [gwt-contrib] [google-web-toolkit commit] r4094 -
branches/1_6_datepicker
To: [EMAIL PROTECTED]



Author: [EMAIL PROTECTED]
Date: Tue Nov 18 06:46:29 2008
New Revision: 4094

Added:
   branches/1_6_datepicker/
  - copied from r4093, /releases/1.6/

Log:






-- 
There are only 10 types of people in the world: Those who understand
binary, and those who don't

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



[gwt-contrib] Fwd: [gwt-contrib] [google-web-toolkit commit] r4094 - branches/1_6_datepicker

2008-11-18 Thread Emily Crutcher
Ray,

  re-routing this to you as John is otherwise occupied with chatter. As
you are, I believe, about to get on a plane,  will not continue to send
individual notifications, rather whenever you get to the point you can
review, please let me know, and if any of the commits on the branch are
subsequently superseded, I will mark them with a +1 so you can safely skip
those reviews.

-- Forwarded message --
From: Emily Crutcher [EMAIL PROTECTED]
Date: Tue, Nov 18, 2008 at 10:07 AM
Subject: Fwd: [gwt-contrib] [google-web-toolkit commit] r4094 -
branches/1_6_datepicker
To: John LaBanca [EMAIL PROTECTED], Google Web Toolkit Contributors 
Google-Web-Toolkit-Contributors@googlegroups.com


John,

Could you review the initial setup of the datepicker branch?   I'll try
to keep each commit small, so the hope is that we will be able to directly
merge back into trunk as soon as all the individual submits have been
reviewed.


-- Forwarded message --
From: [EMAIL PROTECTED]
Date: Tue, Nov 18, 2008 at 9:47 AM
Subject: [gwt-contrib] [google-web-toolkit commit] r4094 -
branches/1_6_datepicker
To: [EMAIL PROTECTED]



Author: [EMAIL PROTECTED]
Date: Tue Nov 18 06:46:29 2008
New Revision: 4094

Added:
   branches/1_6_datepicker/
  - copied from r4093, /releases/1.6/

Log:






-- 
There are only 10 types of people in the world: Those who understand
binary, and those who don't



-- 
There are only 10 types of people in the world: Those who understand
binary, and those who don't

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



Re: Fwd: Tree performance

2008-11-12 Thread Michael Vogt
Hi Greg.


TreeItems use up a lot of HTML boxes, so drawing thousands of them
 equates to drawing tens of thousands of HTML boxes. That takes time in
 javascipt.

 I did this test program some time ago to see what the difference was
 between Tree and FastTree - you might be able to use this to your own
 practical limit.


Cool, thanks a lot,
Michael

--~--~-~--~~~---~--~~
You received 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 [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/Google-Web-Toolkit?hl=en
-~--~~~~--~~--~--~---



Re: Fwd: Tree performance

2008-11-11 Thread gregor

Hi Michael,

TreeItems use up a lot of HTML boxes, so drawing thousands of them
equates to drawing tens of thousands of HTML boxes. That takes time in
javascipt.

I did this test program some time ago to see what the difference was
between Tree and FastTree - you might be able to use this to your own
practical limit.

regards
gregor

public class Scratch implements EntryPoint {

private VerticalPanel box = new VerticalPanel();
private ScrollPanel scroller = new ScrollPanel();
private Tree tree = makeTree();
//private FastTree tree = makeFastTree();

public void onModuleLoad() {

scroller.add(tree);
box.add(scroller);
box.setWidth(100%);
scroller.setWidth(100%);

// set border styles to show what's happening
Element treeElem = tree.getElement();
DOM.setStyleAttribute(treeElem,border,2px solid blue);
Element boxElem = box.getElement();
DOM.setStyleAttribute(boxElem,border,2px solid red);
Element scrElem = scroller.getElement();
DOM.setStyleAttribute(scrElem,border,2px solid green);

Window.enableScrolling(false);
Window.setMargin(10px);
RootPanel.get().add(box);
DeferredCommand.addCommand(new Command() {
public void execute() {
onWindowResized(Window.getClientWidth(),
Window.getClientHeight());
}
});
onWindowResized(Window.getClientWidth(),
Window.getClientHeight());
}


private static Tree makeTree()  {

Tree tree = new Tree() {
// fix for incorrect scrolling when selected item
// is out of view
public void setFocus(boolean inFocus) {};
};
for (int i=0; i30; i++) {
TreeItem lev1 = new TreeItem(Level 1:  + (i + 1));
tree.addItem(lev1);
for (int j=0; j3; j++) {
TreeItem lev2 = new TreeItem(Level 2:  + (j + 1));
lev1.addItem(lev2);
for (int k=0; k3; k++) {
TreeItem lev3 = new TreeItem(Level 3:  + (k +
1));
lev2.addItem(lev3);
}
}
}
return tree;
}

/*
private static FastTree makeFastTree()  {

FastTree.addDefaultCSS();

FastTree tree = new FastTree() {
// fix for incorrect scrolling when selected item
// is out of view
public void setFocus(boolean inFocus) {};
};


for (int i=0; i30; i++) {
FastTreeItem lev1 = new FastTreeItem(Level 1:  + (i +
1));
tree.addItem(lev1);
for (int j=0; j30; j++) {
FastTreeItem lev2 = new FastTreeItem(Level 2:  + (j
+ 1));
lev1.addItem(lev2);
for (int k=0; k30; k++) {
FastTreeItem lev3 = new FastTreeItem(Level 3:  +
(k + 1));
lev2.addItem(lev3);
}
}
}
return tree;
}
*/

public void onWindowResized(int width, int height) {
int scrHieght = height - box.getAbsoluteTop() - 12;
if (scrHieght  1) {
scrHieght = 1;
}
scroller.setHeight( + scrHieght);
}

}
}


On Nov 11, 4:03 pm, Michael Vogt [EMAIL PROTECTED] wrote:
 Hi.

 Answer forwarding to the group.

 What I should have mentioned is, that the transport of the data over
 the wire is no problem, since this is an internal application.

 Greetings,
 Michael Vogt

 -- Forwarded message --
 From: trist [EMAIL PROTECTED]
 Date: Tue, Nov 11, 2008 at 15:59
 Subject: Re: Tree performance
 To: Michael Vogt [EMAIL PROTECTED]

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

 On 11 Lis, 15:53, Michael Vogt [EMAIL PROTECTED] wrote:
  Hello all.

  The question I need to find an answer to is, what is the practical
  limit of number of items in a leaf of a tree element. Does somebody
  have experience with this? Is the tree already too slow to use with
  hundred items, or are thousand items usable?

  Is there a tree available, that allows paging the items in a tree element?

  Thanks a lot,
  Michael Vogt
--~--~-~--~~~---~--~~
You received 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 [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/Google-Web-Toolkit?hl=en
-~--~~~~--~~--~--~---



Fwd: Tree performance

2008-11-11 Thread Michael Vogt

Hi.

Answer forwarding to the group.

What I should have mentioned is, that the transport of the data over
the wire is no problem, since this is an internal application.


Greetings,
Michael Vogt


-- Forwarded message --
From: trist [EMAIL PROTECTED]
Date: Tue, Nov 11, 2008 at 15:59
Subject: Re: Tree performance
To: Michael Vogt [EMAIL PROTECTED]


http://google-web-toolkit-incubator.googlecode.com/svn/trunk/demo/FastTree/FastTreeDemo.html

On 11 Lis, 15:53, Michael Vogt [EMAIL PROTECTED] wrote:
 Hello all.

 The question I need to find an answer to is, what is the practical
 limit of number of items in a leaf of a tree element. Does somebody
 have experience with this? Is the tree already too slow to use with
 hundred items, or are thousand items usable?

 Is there a tree available, that allows paging the items in a tree element?

 Thanks a lot,
 Michael Vogt

--~--~-~--~~~---~--~~
You received 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 [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/Google-Web-Toolkit?hl=en
-~--~~~~--~~--~--~---



[gwt-contrib] Fwd: [gwt-google-apis] [EMAIL PROTECTED] commented on revision r959.

2008-10-29 Thread Eric Ayers
Here is a code review I filled out for Daniel's visualization patch,

A word to the wise when reviewing code on code.google.com: If you see your
comment go to a grey box with the save/cancel button still active - your
comment didn't save.

-Eric.

-- Forwarded message --
From: [EMAIL PROTECTED]
Date: Wed, Oct 29, 2008 at 3:20 PM
Subject: [gwt-google-apis] [EMAIL PROTECTED] commented on revision r959.
To: [EMAIL PROTECTED]


[gwt-google-apis] [EMAIL PROTECTED] commented on revision r959.
Details are at http://code.google.com/p/gwt-google-apis/source/detail?r=959

Score: Positive

General Comment:
Thanks for your work to finish out the work on PieChart and Table. The most
important issue is the implementation of DrawOptions setters.  I have some
guidelines in quot;Making Google APIS for GWT betterquot;  that I've been
trying to capture.
http://code.google.com/docreader/#p=gwt-google-apisamp;s=gwt-google-apisamp;t=MakingGALGWTBetterhttp://code.google.com/docreader/#p=gwt-google-apiss=gwt-google-apist=MakingGALGWTBetter

I don't expect you to change all the listeners to handlers in this patch,
but I wanted to make it prominent in your mind. JavaScript API changes that
don't affect JavaScript developers cause havoc on the Java API bindings
(like adding a parameter to a callback interface).

Line-by-line comments:

File:
/branches/reviews/visualization/daniel-galgwt-gviz-options-and-events/visualization/samples/hellovisualization/src/com/google/gwt/visualization/sample/hellovisualization/client/VisualizationDemo.java
(r959)
===

Line 170:   public void onSelect(Visualization? extends
AbstractDrawOptions visualization) {
---
Your work didn't affect this, but I suggest that we need to move away for
the 'Listener' terminology amp; pattern and turn to the 'Handler' pattern.

What this means is that the callback methods get a single event object that
contains all arguments to the callback, (such as the visualization
instance).  In gwt-google-apis, we've moved all of our event handling to
this model.  See the com.google.gwt.maps.client.events package in the
gwt-maps library for examples.

File:
/branches/reviews/visualization/daniel-galgwt-gviz-options-and-events/visualization/visualization/src/com/google/gwt/visualization/client/AbstractDrawOptions.java
(r959)
===

Line 29:   protected final native void setOption(String option, boolean
value) /*-{
---
These methods were intentionally made public so that end users could
manipulate properties that might be added later after the release of the GWT
bindings.

File:
/branches/reviews/visualization/daniel-galgwt-gviz-options-and-events/visualization/visualization/src/com/google/gwt/visualization/client/AbstractVisualizationContainer.java
(r959)
===

Line 89:   public T getVisualization() {
---
LG

File:
/branches/reviews/visualization/daniel-galgwt-gviz-options-and-events/visualization/visualization/src/com/google/gwt/visualization/client/DataView.java
(r959)
===

Line 51:   }
---
doh!


File:
/branches/reviews/visualization/daniel-galgwt-gviz-options-and-events/visualization/visualization/src/com/google/gwt/visualization/client/PieChart.java
(r959)
===

Line 71:   setOption(backgroundColor, color);
---
The DrawOptions class was originally implemented using setOption(), but they
were then intentionally implemented as native methods before for efficiency.
 The GWT compiler will inline the JavaScript so that the wrapper code just
melts away to nothing. To see the effect, run the GWT compiler in pretty
mode (-style PRETTY) and look at the output, comparing the two methods)

 We reserved the setOption() method for end users in case a visualization
gains new features, users can still take advantage of them.

File:
/branches/reviews/visualization/daniel-galgwt-gviz-options-and-events/visualization/visualization/src/com/google/gwt/visualization/client/PieChartWidget.java
(r959)
===

Line 41:   }
---
Removing the delegator methods in favor of getVisualization() seems like a
win.

File:

Fwd: PureMVC

2008-10-26 Thread yunhui song
-- Forwarded message --
From: yunhui song [EMAIL PROTECTED]
Date: Sun, Oct 26, 2008 at 8:26 PM
Subject: Re: PureMVC
To: Google-Web-Toolkit@googlegroups.com


Hi Thomas,

 I've seen some widgets be injected other widgets but not a single

event listener (or I missed something).


It's true that for my project I only injected some widgets on a main panel.
 That's the project specific choice. Because it's more easy to do that.

I'am not very clear your use case now. Let me have a guess for the use case:

1. We have two widgets w1 and w2, both of them would fire Event clickEvent.

2. We need one Event Listener named CommonEventListener, we expect it can be
used to process clickEvent fired from both w1 and w2.

3. We hope the container, that is Gin to inject when system initialize. So
refractor the code like.
W1 w1 = new W1();
w1.addClickEventListener(new CommonEventListener(p1,p2){});

W2 w2 = new W2();
w2.addClickEventListener(new CommonEventListener(p1,p2){});
by:

  CommonEventListener aCommonEventListener =
injector.getCommonEventListener();
  W1 w1 = injector.getW1();
  w1.addClickEventListener(aCommonEventListener);
  W2 w2 = injector.getW2();
  w2.addClickEventListener(aCommonEventListener);

Because polymorphism is not usable in GWT, we can not use W1 or W2's common
interface or base class as CommonEventListener. My suggestion is:

private W1 w1;
private W2 w2;
@inject
public CommonEventListener(W1 w1,W2 w2){
   //w1 and w2 should be created by ginmodule as singleton instance.
   this.w1 = w1;
   this.w2 = w2;
}

public void onClick(Event e){
   if(e.getSource() == w1){
  //w1.update();
   }else if(e.getSource() == w2){
  //w2.update();
   }
}

I don't think it's an perfect solution(you must change the parameter, as you
said, use ListT is same like ). But it should be able to manage the
listener and ui creation by container and unit test could be implemented
easily.

Hope that is not confusing.

Sammi










On Sun, Oct 26, 2008 at 6:50 PM, Thomas Broyer [EMAIL PROTECTED] wrote:



 On 27 oct, 00:09, yunhui song [EMAIL PROTECTED] wrote:
  Hi,
 
Actually, Gin is used to implements Ioc Container. It can bind
 everything
  not only event Listener.
 
Guice or Spring can do that naturally, but because GWT can not support
  Java reflection, such as forClass(className).getInstance. So Gin use
  generic and annotation to do that.

 Sorry, I should have been clearer: I know what Guice (and Gin) and
 Spring are. Just that they cannot AFAIK inject listeners (i.e. call
 some addXListener method, eventually several times on a single
 instance). Of course you can use method injection with a
 setXListeners(ListXListener) method (should be supported by Gin as
 of today) but I wouldn't call it injecting event listeners; or
 inject event sources or event targets but that's not flexible at all
 (why having event listeners in this case, just keep references to
 the injected widgets and call the appropriate methods on them)

I have a open source project to do that.  GinModule and GindInjector
 are
  key players for that.
please check out here, that's a real world project.
 http://openorg.googlecode.com/svn/trunk/magpie

 I've seen some widgets be injected other widgets but not a single
 event listener (or I missed something).
 



-- 
Sammi
http://code.google.com/p/openorg



-- 
Sammi
http://code.google.com/p/openorg

--~--~-~--~~~---~--~~
You received 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 [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/Google-Web-Toolkit?hl=en
-~--~~~~--~~--~--~---



Fwd: Module inheritance problem

2008-10-11 Thread marcelo melo

I'm going nuts with this error 'cause I can't find its source.

I am trying to load a module from a jar into a GWT app, and when
trying to run it I'm getting the error No source code is available
for type br.com.proximati.proxxi.service.client.vo.MenuVO; did you
forget to inherit a required module?

I know it is module related,but I can't find what I am doing wrong!
The app finds and loads my module, but It doesn't find the classes
inside it.

I am running GWTShell with -logLevel and getting the following:

...
  Loading inherited module 'br.com.proximati.proxxi.service.ProxxiClient'
 Module location:
jar:file:/home/marcelo/desenv/projetos/proxxi/lib/proxxiClient.jar!/br/com/proximati/proxxi/service/ProxxiClient.gwt.xml

^
That's my module!
...

Public resources found in...
...
Searching for resources within
file:/home/marcelo/desenv/projetos/proxxi/lib/proxxiClient.jar
   Indexing zip file:
/home/marcelo/desenv/projetos/proxxi/lib/proxxiClient.jar
^
Once again!
...
Translatable source found in...
 Refreshing resources
...
Searching for resources within
file:/home/marcelo/desenv/projetos/proxxi/lib/proxxiClient.jar
   Indexing zip file:
/home/marcelo/desenv/projetos/proxxi/lib/proxxiClient.jar
^
And here it is once more!

This jar has the following structure:
inside: br-com-proximati-proxxi-service

There are 3 packages:
client
entity
model

And the ProxxiClient.gwt.xml which contents are:
module
   source path=client /
/module

 And insider the client there is the package vo with the MenuVO class.

What I am missing???

--~--~-~--~~~---~--~~
You received 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 [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/Google-Web-Toolkit?hl=en
-~--~~~~--~~--~--~---



[gwt-contrib] Fwd: [gwt-contrib] Re: Proposed API Addition - TabBar.setTabEnabled(int, boolean)

2008-09-19 Thread Freeland Abbott
-- Forwarded message --
Date: Fri, Sep 19, 2008 at 11:28 AM
Subject: Re: [gwt-contrib] Re: Proposed API Addition -
TabBar.setTabEnabled(int, boolean)
To: Google-Web-Toolkit-Contributors@googlegroups.com


I think I agree (where would we boot them too, if we had the job?  The other
option is something like an IllegalStateException...), but it means you'll
need a selected-but-disabled visual style.  And are the (displayed) contents
of the selected-but-disabled tab themselves disabled, or is it more of
disabled as soon as you leave?



On Fri, Sep 19, 2008 at 10:09 AM, John LaBanca [EMAIL PROTECTED] wrote:

 I think that disabling the selected tab is a valid state, as is
 programatically selecting a disabled tab.  It should be up to the user to
 decide if the user should be booted off the tab if its disabled.

 Thanks,
 John LaBanca
 [EMAIL PROTECTED]


 On Fri, Sep 19, 2008 at 10:07 AM, Joel Webber [EMAIL PROTECTED] wrote:

 Sounds ok to me. The only caveat I would add is to think carefully about
 how we handle the various states that might come up inadvertently -- for
 example, what happens if you disable the currently-selected tab?


 On Thu, Sep 18, 2008 at 9:51 PM, Emily Crutcher [EMAIL PROTECTED] wrote:

 Seems like a good idea to me.

 On Thu, Sep 18, 2008 at 9:22 PM, John LaBanca [EMAIL PROTECTED]wrote:

 Contributors -

 I propose adding the following method to TabBar:

 public void setTabEnabled(int index, boolean enabled)


 When disabled, a tab will be assigned the additional style
 gwt-TabBarItem-disabled, and the user will not be able to select the tab
 using the mouse or keyboard.  The style themes will be updated to reflect
 the disabled state.

 You can see the proposed patch attached.  Here is the associated issue:
 http://code.google.com/p/google-web-toolkit/issues/detail?id=2527

 Does anyone see any problem with this enhancement?

 Thanks,
 John LaBanca
 [EMAIL PROTECTED]





 --
 There are only 10 types of people in the world: Those who understand
 binary, and those who don't







 


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



[gwt-contrib] Re: Fwd: [gwt-contrib] Re: Proposed API Addition - TabBar.setTabEnabled(int, boolean)

2008-09-19 Thread Freeland Abbott
Well, I don't necessarily think you need a new style, but we may at least
need to be deterministic about which one wins if they're both applied (and
overlap in some setting)... so, if your selected tab has a white background
and your disabled ones have gray with italic text, then selected  disabled
should probably have italic text, but what color is its background?

Maybe either one, it depends is an okay answer for such an odd condition,
but we should explicitly decide that!


On Fri, Sep 19, 2008 at 12:11 PM, John LaBanca [EMAIL PROTECTED] wrote:

 Note that only the tab in the TabBar is disabled, not the contents of the
 TabPanel.  If the user is on a disabled tab, they can still interact with
 the contents of the tab.  The only way this can happen is:
 1. The end user is on a tab which becomes programatically disabled
 2. The app programatically selects a disabled tab

 Since both of these scenarios require a programatic decision, the app is
 responsible for taking the appropriate action of booting the user or not.
 We don't necessarily *need* a disabled-but-selected tab styling as the
 most common styles (changing font color) can be handled without it, but it
 could be helpful in some scenarios.  Anyone have thoughts on this?

 Thanks,
 John LaBanca
 [EMAIL PROTECTED]


 On Fri, Sep 19, 2008 at 11:36 AM, Freeland Abbott 
 [EMAIL PROTECTED] wrote:



 -- Forwarded message --
 Date: Fri, Sep 19, 2008 at 11:28 AM
 Subject: Re: [gwt-contrib] Re: Proposed API Addition -
 TabBar.setTabEnabled(int, boolean)
 To: Google-Web-Toolkit-Contributors@googlegroups.com


 I think I agree (where would we boot them too, if we had the job?  The
 other option is something like an IllegalStateException...), but it means
 you'll need a selected-but-disabled visual style.  And are the (displayed)
 contents of the selected-but-disabled tab themselves disabled, or is it more
 of disabled as soon as you leave?



 On Fri, Sep 19, 2008 at 10:09 AM, John LaBanca [EMAIL PROTECTED]wrote:

 I think that disabling the selected tab is a valid state, as is
 programatically selecting a disabled tab.  It should be up to the user to
 decide if the user should be booted off the tab if its disabled.

 Thanks,
 John LaBanca
 [EMAIL PROTECTED]


 On Fri, Sep 19, 2008 at 10:07 AM, Joel Webber [EMAIL PROTECTED] wrote:

 Sounds ok to me. The only caveat I would add is to think carefully about
 how we handle the various states that might come up inadvertently -- for
 example, what happens if you disable the currently-selected tab?


 On Thu, Sep 18, 2008 at 9:51 PM, Emily Crutcher [EMAIL PROTECTED] wrote:

 Seems like a good idea to me.

 On Thu, Sep 18, 2008 at 9:22 PM, John LaBanca [EMAIL PROTECTED]wrote:

 Contributors -

 I propose adding the following method to TabBar:

 public void setTabEnabled(int index, boolean enabled)


 When disabled, a tab will be assigned the additional style
 gwt-TabBarItem-disabled, and the user will not be able to select the 
 tab
 using the mouse or keyboard.  The style themes will be updated to reflect
 the disabled state.

 You can see the proposed patch attached.  Here is the associated
 issue:
 http://code.google.com/p/google-web-toolkit/issues/detail?id=2527

 Does anyone see any problem with this enhancement?

 Thanks,
 John LaBanca
 [EMAIL PROTECTED]





 --
 There are only 10 types of people in the world: Those who understand
 binary, and those who don't














 


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



[gwt-contrib] Re: Fwd: [gwt-contrib] Re: Proposed API Addition - TabBar.setTabEnabled(int, boolean)

2008-09-19 Thread John LaBanca
You can decide which one styles win (if there is a conflict) in the style
sheet.  Whichever appears last has priority.  The default style themes will
set the cursor to default (as opposed to a pointer) and the font color to
gray, and that takes priority over the selected styles.  The selected styles
will still set the background color of the tab because the disabled style
doesn't override it.

Thanks,
John LaBanca
[EMAIL PROTECTED]


On Fri, Sep 19, 2008 at 12:32 PM, Freeland Abbott 
[EMAIL PROTECTED] wrote:

 Well, I don't necessarily think you need a new style, but we may at least
 need to be deterministic about which one wins if they're both applied (and
 overlap in some setting)... so, if your selected tab has a white background
 and your disabled ones have gray with italic text, then selected  disabled
 should probably have italic text, but what color is its background?

 Maybe either one, it depends is an okay answer for such an odd condition,
 but we should explicitly decide that!



 On Fri, Sep 19, 2008 at 12:11 PM, John LaBanca [EMAIL PROTECTED]wrote:

 Note that only the tab in the TabBar is disabled, not the contents of the
 TabPanel.  If the user is on a disabled tab, they can still interact with
 the contents of the tab.  The only way this can happen is:
 1. The end user is on a tab which becomes programatically disabled
 2. The app programatically selects a disabled tab

 Since both of these scenarios require a programatic decision, the app is
 responsible for taking the appropriate action of booting the user or not.
 We don't necessarily *need* a disabled-but-selected tab styling as the
 most common styles (changing font color) can be handled without it, but it
 could be helpful in some scenarios.  Anyone have thoughts on this?

 Thanks,
 John LaBanca
 [EMAIL PROTECTED]


 On Fri, Sep 19, 2008 at 11:36 AM, Freeland Abbott 
 [EMAIL PROTECTED] wrote:



 -- Forwarded message --
 Date: Fri, Sep 19, 2008 at 11:28 AM
 Subject: Re: [gwt-contrib] Re: Proposed API Addition -
 TabBar.setTabEnabled(int, boolean)
 To: Google-Web-Toolkit-Contributors@googlegroups.com


 I think I agree (where would we boot them too, if we had the job?  The
 other option is something like an IllegalStateException...), but it means
 you'll need a selected-but-disabled visual style.  And are the (displayed)
 contents of the selected-but-disabled tab themselves disabled, or is it more
 of disabled as soon as you leave?



 On Fri, Sep 19, 2008 at 10:09 AM, John LaBanca [EMAIL PROTECTED]wrote:

 I think that disabling the selected tab is a valid state, as is
 programatically selecting a disabled tab.  It should be up to the user to
 decide if the user should be booted off the tab if its disabled.

 Thanks,
 John LaBanca
 [EMAIL PROTECTED]


 On Fri, Sep 19, 2008 at 10:07 AM, Joel Webber [EMAIL PROTECTED] wrote:

 Sounds ok to me. The only caveat I would add is to think carefully
 about how we handle the various states that might come up inadvertently --
 for example, what happens if you disable the currently-selected tab?


 On Thu, Sep 18, 2008 at 9:51 PM, Emily Crutcher [EMAIL PROTECTED]wrote:

 Seems like a good idea to me.

 On Thu, Sep 18, 2008 at 9:22 PM, John LaBanca [EMAIL PROTECTED]wrote:

 Contributors -

 I propose adding the following method to TabBar:

 public void setTabEnabled(int index, boolean enabled)


 When disabled, a tab will be assigned the additional style
 gwt-TabBarItem-disabled, and the user will not be able to select the 
 tab
 using the mouse or keyboard.  The style themes will be updated to 
 reflect
 the disabled state.

 You can see the proposed patch attached.  Here is the associated
 issue:
 http://code.google.com/p/google-web-toolkit/issues/detail?id=2527

 Does anyone see any problem with this enhancement?

 Thanks,
 John LaBanca
 [EMAIL PROTECTED]





 --
 There are only 10 types of people in the world: Those who understand
 binary, and those who don't

















 


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



[gwt-contrib] Fwd: Issue 2607: GWT trunk hosted mode crash

2008-09-02 Thread Eric Ayers
-- Forwarded message --
From: Eric Ayers [EMAIL PROTECTED]
Date: Tue, Sep 2, 2008 at 1:50 PM
Subject: Issue 2607: GWT trunk hosted mode crash
To: John Tamplin [EMAIL PROTECTED],
[EMAIL PROTECTED]


John,
I'm running into a problem where an exception that shows up as Unexpected
Exception in the Development shell (Linux Hosted Mode) results in a hosted
mode browser crash when you select the value to inspect the stack trace.

JsRootedValue::currentContext - context stack empty

You and I have looked at one of these before.  It doesn't affect 1.5.

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

In a thread on the public forum, you mentioned this might be related to
module startup, but my case, the problem is occurring in an event callback,
long after onModuleLoad() is finished.

-Eric.
-- 
Eric Z. Ayers - GWT Team - Atlanta, GA USA
http://code.google.com/webtoolkit/



-- 
Eric Z. Ayers - GWT Team - Atlanta, GA USA
http://code.google.com/webtoolkit/

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