Re: Large MVP applications and GWT.runAsync()

2010-02-08 Thread Joe Cheng
Jarrod, are you using this ProxyPresenter more than once within the same
application (with different presenter type parameters), and found that it
introduced the split points as expected? I originally tried something like
this but found that it would only ever introduce a single split point, no
matter how many times I used it.

I was able to solve the problem using deferred binding and was about to
write a blog post about it, but if your code actually works as desired then
I need to go back and figure out what I was doing wrong.

On Mon, Jan 25, 2010 at 8:16 PM, jarrod jarrod.carl...@gmail.com wrote:

 While building an application for my company, I needed a way to make
 large sections of the application sit behind a split point. After
 organizing my application into modules of related functionality, I
 came up with slick, easy way to make those modules split out
 automatically: by using a proxy presenter.

 My application uses gin and a hand-made MVP framework based loosely
 off of gwt-presenter. Some adaptation may be necessary to fit your
 particular frameworks, but here goes:

 public class ProxyPresenterT extends Presenter implements Presenter
 {

private static class ProxyView implements View {

SimplePanel proxy = new SimplePanel();

ProxyView() {

}

@Override
public Widget asWidget() {
return this.proxy;
}

protected void setView(View view) {
this.proxy.setWidget(view.asWidget());
}

}

private boolean asyncCalled;
private boolean bound;

private HandlerManager bus;
private T impl;
private ProviderT provider;
private QueueCommand queue;
private ProxyView view;

public ProxyPresenter(HandlerManager bus, ProviderT provider) {
this(bus, provider, false);
}

public ProxyPresenter(HandlerManager bus, ProviderT provider,
boolean eager) {
this.bus = bus;
this.provider = provider;
this.queue = new LinkedListCommand();
this.view = new ProxyView();
if (eager) {
ensurePresenter();
}
}

@Override
public void bind() {
this.bound = true;
queue(new Command() {

@Override
public void execute() {
ProxyPresenter.this.impl.bind();
}

});
}

@Override
public View getView() {
return this.view;
}

@Override
public void handleHistory(final HistoryItem item) {
queue(new Command() {

@Override
public void execute() {
ProxyPresenter.this.impl.handleHistory(item);
}

});
}

@Override
public boolean isBound() {
return this.bound;
}

@Override
public void release() {
queue(new Command() {

@Override
public void execute() {
ProxyPresenter.this.impl.release();
}
});
this.bound = false;
}

protected void ensurePresenter() {
if (!this.asyncCalled) {
this.asyncCalled = true;
GWT.runAsync(new RunAsyncCallback() {

@Override
public void onFailure(Throwable reason) {
ProxyPresenter.this.bus
.fireEvent(new ApplicationExceptionEvent
 (reason));
}

@Override
public void onSuccess() {

// get impl instance
ProxyPresenter.this.impl =
 ProxyPresenter.this.provider
.get();

// fill-in proxy view
ProxyPresenter.this.view.setView
 (ProxyPresenter.this.impl
.getView());

// execute any queued commands
while (ProxyPresenter.this.queue.peek() != null) {
Command cmd = ProxyPresenter.this.queue.poll
 ();
cmd.execute();
}

}
});
}
}

protected void queue(Command command) {
ensurePresenter();
if (this.impl != null) {
command.execute();
} else {
this.queue.offer(command);
}
}

T getPresenter() {
return this.impl;
}

 }



 Then, in my gin module, instead of using an explicit bind, I use a
 @Provides method, like so:

@Provides
Presenter getRealPresenter(HandlerManager bus,
ProviderRealPresenter provider) {
return new ProxyPresenterRealPresenter(bus, provider);
}


 The rest is automagic!

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

Re: Problem with Thread in GWT2.0

2010-02-08 Thread Joe Cheng
If you use a timer, your data will be delayed by up to the period of the
timer (e.g. if your timer fires every 5 seconds then there will be a delay
of up to 5 seconds to display your data).

Rather than an infinite while or for loop, you can loop by having the RPC
call's AsyncCallback onSuccess and onFailure methods make the RPC call
again. On the server side, you can make the RPC call block until some data
is ready. (You don't want to block for too long, otherwise the RPC call will
time out--but not too short either, otherwise you will be creating
unnecessary network traffic).

On Sun, Feb 7, 2010 at 12:46 PM, SergeZ comp1...@gmail.com wrote:

 Thanks to your all for answers on my question! I'll try to call the
 run() method ( how can I\ forgot to call it))  ). But I thinking that
 it will not helps me...

 Actually, I have the one concrete task - create some similarity to
 monitoring system. My software must receive data from DataBase and
 represent it without any delays. Server's part of App based on summary
 of Sockets, Rmi technologies. And Client part of app - of course GWT
 GUI. Both of them connects through RPC AsyncCall. (it's just a
 standart GWT's scheme applications )  So, the real question is about
 possibility to create these app.. As I rightly understood, the only
 way I can use to get data from Server Side - is to use RPC call to
 server's method  and I can NOT do this in an infinite loop because It
 will interrupt my app's logic. And also I can NOT use for this
 purposes threads - due to signle-threadness of JavaSript. Am I right
 about that I can just simulate a real-time data receiving through
 using GWT's timer and each time when a timer will expired I'll have to
 make a RPC call to Server Side to getting the data ?

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



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



Re: UiBinder and overflow-x: hidden; overflow-y: hidden

2010-02-08 Thread Thomas Broyer


On Feb 8, 6:08 am, Brett Morgan brett.mor...@gmail.com wrote:
 Guys,

 I'm just kicking the tyres on UiBinder, and I'm curious as to why there are
 wrapper divs with overflow hiding?

That's nothing to do with UiBinder. You're probably rather talking
about the new layout panels: 
http://code.google.com/webtoolkit/doc/latest/DevGuideUiPanels.html#LayoutPanels

 I'm attempting to build ye stock standard looking web pages (think
 http://960.gs/ style), but from within gwt because I'm a java guy.

 Is there a way to turn off the overflow hiding behaviour?

I don't think so, because it'd likely break the layout. I think the
idea is that you put scrollable widgets where you want them.
...or you could probably implement your own layout panel I guess.

-- 
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: Adding new event types (touch etc.)

2010-02-08 Thread Thomas Broyer

On Feb 7, 7:54 pm, msa...@gmail.com msa...@gmail.com wrote:
 On Feb 7, 8:21 pm, Thomas Broyer t.bro...@gmail.com wrote:

  If you want it to do it cleanly, I'd suggest not relying on the
  magic of addDomHandler but rather just register handlers in widgets
  using addHandler and sinking the native handlers yourself (in the
  case of those events, you know you're in WebKit)

 Is there a way to get GWT to deliver new native events to
 Widget.onBrowserEvent(),

Yes, just use
@com.google.gwt.user.client.impl.DOMImplStandard::dispatchEvent as the
handler.

 or do I have register a listener myself in
 JavaScript code?

You'd have to register the listener anyway.

As an example, here's how I did it for drop events in Adobe AIR
(nothing AIR-specific though, could be used in any WebKit-based
browser actually). The code is still based on the pre-1.6 listener
approach, but it's not that hard to make it work the new way:
http://code.google.com/p/gwt-in-the-air/source/browse/trunk/src/net/ltgt/gwt/air/user/client/ui/DropPanel.java
http://code.google.com/p/gwt-in-the-air/source/browse/trunk/src/net/ltgt/gwt/air/user/client/ui/impl/DropPanelImplAIR.java

I'm thinking in starting a Wave about how I think event handling
should be refactored.

-- 
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: UiBinder and overflow-x: hidden; overflow-y: hidden

2010-02-08 Thread Brett Morgan
On Mon, Feb 8, 2010 at 8:02 PM, Thomas Broyer t.bro...@gmail.com wrote:



 On Feb 8, 6:08 am, Brett Morgan brett.mor...@gmail.com wrote:
  Guys,
 
  I'm just kicking the tyres on UiBinder, and I'm curious as to why there
 are
  wrapper divs with overflow hiding?

 That's nothing to do with UiBinder. You're probably rather talking
 about the new layout panels:
 http://code.google.com/webtoolkit/doc/latest/DevGuideUiPanels.html#LayoutPanels


Thank you for the pointer. It makes sense now.


  I'm attempting to build ye stock standard looking web pages (think
  http://960.gs/ style), but from within gwt because I'm a java guy.
 
  Is there a way to turn off the overflow hiding behaviour?

 I don't think so, because it'd likely break the layout. I think the
 idea is that you put scrollable widgets where you want them.
 ...or you could probably implement your own layout panel I guess.


You are spot on the money, I wrapped my UiBinder markup with a
g:ScrollPanel and everything behaves. 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.comgoogle-web-toolkit%2bunsubscr...@googlegroups.com
 .
 For more options, visit this group at
 http://groups.google.com/group/google-web-toolkit?hl=en.




-- 
Brett Morgan http://domesticmouse.livejournal.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: Simple UiBinder question about ui:image resource=....

2010-02-08 Thread cpm
I'm another one finding that the resource={res.myImage} just won't
work.

My findings are that I can have just ui:image field=myImage / in
the file along with an @sprite .logo { gwt-image: myImage; } and as
long as I have an image file called myImage.png in the same package/
directory it'll work.
You don't seem to need a resource= or src= on the ui:image tag at
all - the field attribute is the name of the image it'll look for
unless you add a src attribute. This would explain why emerix was
getting an No com.google.gwt.resources.client.ClientBundle $Source
annotation and no resources found with default extensions  error
with:

ui:image field='logo' resource='../resources/my_logo.png'/ui:image

It's just ignoring the resource attribute and looking for a logo.png
file instead.

The src attribute seems to work like the @Source annotation you would
put in a ResourceBundle, such as:

@Source(myLogo.png)
ImageResource logo();

I would expect this to be the same as:

ui:image field=logo src=myLogo.png /


The same seems to apply then when you try to use ui:image
field=logo resource={res.myLogo} /
The resource attribute is ignored and its still looking for a logo.png
in the current directory and flagging an error that no Source
annotation has been given.
What you need to do to get the resource atrribute to work, I've no
idea, but it would be a neater solution if it did work.



but I got the error :

On Jan 18, 5:12 pm, emerix rafa...@gmail.com wrote:
 Hi,

 I'm also still looking for some documentation on this ui:image tag.
 (and the other tags also : ui:data, ui:attribute, ...)

 Do anyone know how to put absolute path in the src attribute ?
 ui:image field=myImage src=com/mycompany/path/to/myImage.png/
 ui:image
 doesn't work :/

 Using relative path works but I have to change it every time I copy
 the code to another widget :/

 ++emerix

 On Jan 17, 6:05 pm, Nico nicolas.antonia...@gmail.com wrote:

  Thanks emerix for the src= tips. It helped me a lot.

  I have the same problem when I use resource={res.myImage} ...

  I have declared the ui:with field .. targeting the right Resource
  class but I always have an error that says : No
  com.google.gwt.resources.client.ClientBundle$Source annotation and no
  resources found with default extensions

  However, I don't know where to find doc about ui:image tag. Where
  did you find that there was a src or a resource attribute ? directly
  in the source code ?
  Thanks a lot.

  Nicolas

  On 12 jan, 17:24, Chris Ramsdale cramsd...@google.com wrote:

   Do you have the following in your ui.xml file:

   ui:with field='res' type='com.google.gwt.sandbox.client.Resources'/

   ...where 'com.google.gwt.sandbox.client.Resources' is replaced with your
   resources class.

   On Thu, Jan 7, 2010 at 5:24 AM, emerix rafa...@gmail.com wrote:
Hello,

I tried using relative paths for the resource property :
ui:image field='logo' resource='../resources/my_logo.png'/ui:image

but I got the error : No com.google.gwt.resources.client.ClientBundle
$Source annotation and no resources found with default extensions

if I use the src property, everything is ok :
ui:image field='logo' src='../resources/my_logo.png'/ui:image

hope someone find this useful :)

However what I really wanted is using your 2nd solution :
ui:image field='logo' resource='{res.logo}'/ui:image
but when I load the page I also get the error : No
com.google.gwt.resources.client.ClientBundle$Source annotation and no
resources found with default extensions

am I missing something ?

thanks a lot :)

++emerix

On Jan 4, 11:15 pm, Chris Ramsdale cramsd...@google.com wrote:
 One option would be to use relative paths within the ui:image 
 element.
For
 example:

 ui:image field='logo' resource='../resources/my_logo.png'/ui:image

 Another option would be to use ui:with, get a hold of the 
 ClientBundle,
 and reference an image within it.

 public interface Resources extends ClientBundle {
   @Source(com/google/gwt/sandbox/resources/my_logo.png)
   ImageResource logo();

 }

 ui:UiBinder
   ...
   ui:with field='res' 
 type='com.google.gwt.sandbox.client.Resources'/
   ui:image field='logo' resource='{res.logo}'/ui:image
   ...
 /ui:UiBinder

 Underscores within the filename are completely valid (the above 
 examples
 compile and run w/o issue).

 On Thu, Dec 31, 2009 at 3:30 AM, Daniel doubleagen...@gmail.com 
 wrote:
  Here's a valid ui.xml file:

  ?xml version=1.0 encoding=UTF-8?
  !DOCTYPE ui:UiBinder SYSTEM http://dl.google.com/gwt/DTD/
  xhtml.ent

  ui:UiBinder xmlns:ui=urn:ui:com.google.gwt.uibinder
  xmlns:g=urn:import:com.google.gwt.user.client.ui

   ui:style field=IekyStyle
     .anchorWrapper a {
         display: block;
     }

    �...@sprite .left {
         gwt-image: 'left';
     }

    

Re: Problem with Thread in GWT2.0

2010-02-08 Thread Alexander
SergerZ, infinity loop never seems to be a good idea.

You won't ever get realtime behaviour as you can't get out from
client-server paradigm. So only emulate. This timer solution is good.

Btw, maybe you want to look at http://code.google.com/p/rocket-gwt/ server
push technology.

On 8 February 2010 14:39, Joe Cheng j...@joecheng.com wrote:

 If you use a timer, your data will be delayed by up to the period of the
 timer (e.g. if your timer fires every 5 seconds then there will be a delay
 of up to 5 seconds to display your data).

 Rather than an infinite while or for loop, you can loop by having the RPC
 call's AsyncCallback onSuccess and onFailure methods make the RPC call
 again. On the server side, you can make the RPC call block until some data
 is ready. (You don't want to block for too long, otherwise the RPC call will
 time out--but not too short either, otherwise you will be creating
 unnecessary network traffic).


 On Sun, Feb 7, 2010 at 12:46 PM, SergeZ comp1...@gmail.com wrote:

 Thanks to your all for answers on my question! I'll try to call the
 run() method ( how can I\ forgot to call it))  ). But I thinking that
 it will not helps me...

 Actually, I have the one concrete task - create some similarity to
 monitoring system. My software must receive data from DataBase and
 represent it without any delays. Server's part of App based on summary
 of Sockets, Rmi technologies. And Client part of app - of course GWT
 GUI. Both of them connects through RPC AsyncCall. (it's just a
 standart GWT's scheme applications )  So, the real question is about
 possibility to create these app.. As I rightly understood, the only
 way I can use to get data from Server Side - is to use RPC call to
 server's method  and I can NOT do this in an infinite loop because It
 will interrupt my app's logic. And also I can NOT use for this
 purposes threads - due to signle-threadness of JavaSript. Am I right
 about that I can just simulate a real-time data receiving through
 using GWT's timer and each time when a timer will expired I'll have to
 make a RPC call to Server Side to getting the data ?

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


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




-- 
Regards,
Alexander

-- 
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: Java.io , No source code is available in clint side

2010-02-08 Thread Alexander
At client side? At client side everything runs in javascript, not in java.

On 8 February 2010 17:17, prem premn...@gmail.com wrote:

 Hi,

 I tried to read a excel sheet by using Java.io in a GWT project in
 clint side.

 And the same code is working fine with normal java with command
 prompt.

 Can any one suggest the prob?

 and how to solve this problem??

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




-- 
Regards,
Alexander

-- 
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: Init Frame while invisible?

2010-02-08 Thread goolie
Thx Sky!

I thought I had attached it to the DOM but actually had a broken chain
when testing it with isAttached(). I've go it working now.

BR
Oskar

-- 
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: Java.io , No source code is available in clint side

2010-02-08 Thread Lothar Kimmeringer
prem schrieb:

 I tried to read a excel sheet by using Java.io in a GWT project in
 clint side.

If you search the error-message in this group you will find many
threads explaining why this can't work.

 And the same code is working fine with normal java with command
 prompt.
 
 Can any one suggest the prob?

The reason is explained already many times.

 and how to solve this problem??

The solution is to send the excel to the server, let it process
the XLS and send e.g. a CSV or a serialized java-object back to
the client that is used to present the sheet on the client side.


Regards, Lothar

-- 
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: Java.io , No source code is available in clint side

2010-02-08 Thread Alexander
Or find JS library for parsing Excel side (if exist any) and use it as
native code on client side.

On 8 February 2010 17:32, Lothar Kimmeringer j...@kimmeringer.de wrote:

 prem schrieb:

  I tried to read a excel sheet by using Java.io in a GWT project in
  clint side.

 If you search the error-message in this group you will find many
 threads explaining why this can't work.

  And the same code is working fine with normal java with command
  prompt.
 
  Can any one suggest the prob?

 The reason is explained already many times.

  and how to solve this problem??

 The solution is to send the excel to the server, let it process
 the XLS and send e.g. a CSV or a serialized java-object back to
 the client that is used to present the sheet on the client side.


 Regards, Lothar

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




-- 
Regards,
Alexander

-- 
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: upgrade gwt 1.5 to 1.6 help!!

2010-02-08 Thread asle
I tried with the plugin and without the plugin.

When i create a new project, i am not problem. My problem is when i
upgrade my project, because i have a project with gwt 1.5 and i
upgrade to 1.6 and i folowing the steps but i not understand
how switch shell for hosted mode.

Sorry for the writing,  but i am not speak english
Thanks

best regards


On 5 feb, 13:42, Rajeev Dayal rda...@google.com wrote:
 Are you using the Google Plugin for Eclipse?



 On Fri, Feb 5, 2010 at 1:26 AM, Gal Dolber gal.dol...@gmail.com wrote:
  I recommend you to go straight to GWT 2.0. Just update the SDK and find the
  deprecated's in your code.
  The biggest problem you can have is with the ImageBundle, now you have to
  use ClientBundle.
  Also I don't remember if the Listeners - Handlers transition was before of
  after 1.6 ...
  Anyway... you won't regret it
  Best

  2010/2/4 asle asle...@gmail.com

  Hello:

  We have a problem to upgrade gwt , and folowing the steps in

 http://code.google.com/intl/es/webtoolkit/doc/1.6/ReleaseNotes_1_6.ht...
  .
  The first step is ok, but de second step:
  Switch from GWTShell to HostedMode i am not understand how i do,
  because i do not know where  directory is the main class for swich.
  I need you help for indications to change the main class because i
  need folowing the steps for upgrating my project:
  In order to eliminate this warning, change your main class from
  com.google.gwt.dev.GWTShell to com.google.gwt.dev.HostedMode

  When i run the project, indicate this warning:

  WARNING: 'com.google.gwt.dev.GWTShell' is deprecated and will be
  removed in a future release.
  Use 'com.google.gwt.dev.HostedMode' instead.

  Sorry for the writing,  but i am not speak english
  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.comgoogle-web-toolkit%2bunsubs­cr...@googlegroups.com
  .
  For more options, visit this group at
 http://groups.google.com/group/google-web-toolkit?hl=en.

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

 - Mostrar texto de la cita -

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



Who uploads GWT to Maven

2010-02-08 Thread Jan Ehrhardt
Hi,

currently GWT 2.0 is available in Maven's repo1, but GWT 2.0.1 is released
since last week.
So, who does the uploads to the public Maven repo? Is there a POM available,
that is used for uploading? Can I help in any way to speed up the uploading
to Maven?

The best case would be, if new GWT releases were available through Maven
from day one. Anything bringing me closer to this is welcome.

Regards
Jan Ehrhardt

-- 
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: Problem with Thread in GWT2.0

2010-02-08 Thread SergeZ
Can you give a simple example of how to make this looped
asynccallback call ?

On 8 фев, 11:39, Joe Cheng j...@joecheng.com wrote:
 If you use a timer, your data will be delayed by up to the period of the
 timer (e.g. if your timer fires every 5 seconds then there will be a delay
 of up to 5 seconds to display your data).

 Rather than an infinite while or for loop, you can loop by having the RPC
 call's AsyncCallback onSuccess and onFailure methods make the RPC call
 again. On the server side, you can make the RPC call block until some data
 is ready. (You don't want to block for too long, otherwise the RPC call will
 time out--but not too short either, otherwise you will be creating
 unnecessary network traffic).



 On Sun, Feb 7, 2010 at 12:46 PM, SergeZ comp1...@gmail.com wrote:
  Thanks to your all for answers on my question! I'll try to call the
  run() method ( how can I\ forgot to call it))  ). But I thinking that
  it will not helps me...

  Actually, I have the one concrete task - create some similarity to
  monitoring system. My software must receive data from DataBase and
  represent it without any delays. Server's part of App based on summary
  of Sockets, Rmi technologies. And Client part of app - of course GWT
  GUI. Both of them connects through RPC AsyncCall. (it's just a
  standart GWT's scheme applications )  So, the real question is about
  possibility to create these app.. As I rightly understood, the only
  way I can use to get data from Server Side - is to use RPC call to
  server's method  and I can NOT do this in an infinite loop because It
  will interrupt my app's logic. And also I can NOT use for this
  purposes threads - due to signle-threadness of JavaSript. Am I right
  about that I can just simulate a real-time data receiving through
  using GWT's timer and each time when a timer will expired I'll have to
  make a RPC call to Server Side to getting the data ?

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

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



Re: Problem with Thread in GWT2.0

2010-02-08 Thread SergeZ
Thanks for the reference. This feature is very interesting!

On 8 фев, 14:20, Alexander the.malk...@gmail.com wrote:
 SergerZ, infinity loop never seems to be a good idea.

 You won't ever get realtime behaviour as you can't get out from
 client-server paradigm. So only emulate. This timer solution is good.

 Btw, maybe you want to look athttp://code.google.com/p/rocket-gwt/server
 push technology.

 On 8 February 2010 14:39, Joe Cheng j...@joecheng.com wrote:





  If you use a timer, your data will be delayed by up to the period of the
  timer (e.g. if your timer fires every 5 seconds then there will be a delay
  of up to 5 seconds to display your data).

  Rather than an infinite while or for loop, you can loop by having the RPC
  call's AsyncCallback onSuccess and onFailure methods make the RPC call
  again. On the server side, you can make the RPC call block until some data
  is ready. (You don't want to block for too long, otherwise the RPC call will
  time out--but not too short either, otherwise you will be creating
  unnecessary network traffic).

  On Sun, Feb 7, 2010 at 12:46 PM, SergeZ comp1...@gmail.com wrote:

  Thanks to your all for answers on my question! I'll try to call the
  run() method ( how can I\ forgot to call it))  ). But I thinking that
  it will not helps me...

  Actually, I have the one concrete task - create some similarity to
  monitoring system. My software must receive data from DataBase and
  represent it without any delays. Server's part of App based on summary
  of Sockets, Rmi technologies. And Client part of app - of course GWT
  GUI. Both of them connects through RPC AsyncCall. (it's just a
  standart GWT's scheme applications )  So, the real question is about
  possibility to create these app.. As I rightly understood, the only
  way I can use to get data from Server Side - is to use RPC call to
  server's method  and I can NOT do this in an infinite loop because It
  will interrupt my app's logic. And also I can NOT use for this
  purposes threads - due to signle-threadness of JavaSript. Am I right
  about that I can just simulate a real-time data receiving through
  using GWT's timer and each time when a timer will expired I'll have to
  make a RPC call to Server Side to getting the data ?

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

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

 --
 Regards,
 Alexander

-- 
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: server side internationalization

2010-02-08 Thread Lucas de Oliveira
Hi all,
sorry to bring back the post but I'm having problems while trying to use
KtrI18N.
The thing is that I have an Enum class that shouldn't know if the code is
running on the client or server side. A little code:

public enum Status{
 OPEN {
@Override
public String getI18N() {
return labels.statusOpen();
}
 },
 CLOSED {

@Override
public String getI18N() {
return labels.statusClosed();
}
}

 Labels labels = KtrI18N.createConstants(Labels.class);
 public abstract String i18n();
}

So this code should run both in client and server. The problem is: it
doesn't work at the client side. I checked the KtrI18N website and there is
an eclipse plugin to create the supersource trick for you, but I couldn't
make it work. Any ideas?

thanks in advance,
cheers!

-- 
Lucas de Oliveira Arantes

-- 
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: Problem with Thread in GWT2.0

2010-02-08 Thread Tom Schindl
You might want to have something like comet. Take a look at
http://code.google.com/p/gwteventservice/

Tom

On Mon, Feb 8, 2010 at 1:22 PM, SergeZ comp1...@gmail.com wrote:
 Can you give a simple example of how to make this looped
 asynccallback call ?

 On 8 фев, 11:39, Joe Cheng j...@joecheng.com wrote:
 If you use a timer, your data will be delayed by up to the period of the
 timer (e.g. if your timer fires every 5 seconds then there will be a delay
 of up to 5 seconds to display your data).

 Rather than an infinite while or for loop, you can loop by having the RPC
 call's AsyncCallback onSuccess and onFailure methods make the RPC call
 again. On the server side, you can make the RPC call block until some data
 is ready. (You don't want to block for too long, otherwise the RPC call will
 time out--but not too short either, otherwise you will be creating
 unnecessary network traffic).



 On Sun, Feb 7, 2010 at 12:46 PM, SergeZ comp1...@gmail.com wrote:
  Thanks to your all for answers on my question! I'll try to call the
  run() method ( how can I\ forgot to call it))  ). But I thinking that
  it will not helps me...

  Actually, I have the one concrete task - create some similarity to
  monitoring system. My software must receive data from DataBase and
  represent it without any delays. Server's part of App based on summary
  of Sockets, Rmi technologies. And Client part of app - of course GWT
  GUI. Both of them connects through RPC AsyncCall. (it's just a
  standart GWT's scheme applications )  So, the real question is about
  possibility to create these app.. As I rightly understood, the only
  way I can use to get data from Server Side - is to use RPC call to
  server's method  and I can NOT do this in an infinite loop because It
  will interrupt my app's logic. And also I can NOT use for this
  purposes threads - due to signle-threadness of JavaSript. Am I right
  about that I can just simulate a real-time data receiving through
  using GWT's timer and each time when a timer will expired I'll have to
  make a RPC call to Server Side to getting the data ?

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

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



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



Re: Unable to Use GWT Developer Plugin with Firefox 3.6

2010-02-08 Thread makoki
We've got a similar problem under mac. The app that before the plugin
update worked fine now has some problems with DateBox instances, other
browsers plugins seems fine, the application runs fine if compiled and
seen through any browser including FF without plugin, it gets the same
problems if try the compiled app with a FF browser with the plugin.
Oh, we're using FF 3.6 and GWT 2.0

On 3 feb, 14:21, kolstae espenamblekols...@gmail.com wrote:
 I have the exact sameproblem.

 On Feb 2, 4:53 pm, Thad thad.humphr...@gmail.com wrote:

  Yes.  This has been observed and commented on.  I've been usingFirefox3.5.7 
  (on Linux) because of this.

  This morning I was alerted to an update to the GWTplugin, and
  installed it (v.1.0.7511).  However it still does not work withFirefox3.6.  
  When I try using it,Firefox3.6just asks for,
  downloads, and installs thepluginover and over again.

  On Jan 30, 2:39 am, akhil shastri.ak...@gmail.com wrote:

   Dear Team,

   i m using GWT 2.0 with MyEclips6.0, i created an sample project with
   GWT but when i compile and goto browse (FireFox3.6) that it is asking
   that apluginis required , as per give link i download theplugin
   also, but it's showing error that it is not compatible withFireFox3.6

   wating for Help

   regards
   Akhil

-- 
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: Who uploads GWT to Maven

2010-02-08 Thread Ben Harris
It is in there...? Since 5th Feb.
http://repo1.maven.org/maven2/com/google/gwt/gwt-user/

On Feb 8, 8:20 pm, Jan Ehrhardt jan.ehrha...@googlemail.com wrote:
 Hi,

 currently GWT 2.0 is available in Maven's repo1, but GWT 2.0.1 is released
 since last week.
 So, who does the uploads to the public Maven repo? Is there a POM available,
 that is used for uploading? Can I help in any way to speed up the uploading
 to Maven?

 The best case would be, if new GWT releases were available through Maven
 from day one. Anything bringing me closer to this is welcome.

 Regards
 Jan Ehrhardt

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



Understanding RequestBilder und SOP Problem

2010-02-08 Thread Alain Ekambi
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.



RootPanel.get().clear() does not clear the page

2010-02-08 Thread go canal
Hi,
I try to add RootPanel.get().clear() in the callback but it does not clear 
anything. If I use RootPanel.get(nameofcontainer).clear(), then it works - 
that widget is removed.

I am using the default greet example. GWT 2.0.1, Chrome browser. This is how I 
create the widgets: 
RootPanel.get(
RootPanel.get(
RootPanel.get(
RootPanel.get(nameFieldContainer).add(nameField);passwordFieldContainer).add(passwordField);sendButtonContainer).add(sendButton);errorLabelContainer).add(errorLabel);

Did I understand RootPanel.get().clear() correctly - I thought it will 
clear everything on the page
rgds,
canal 


  

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



can not set breakpoint

2010-02-08 Thread canal
hi,
searched the group but still can not make it work - can not set
breakpoint in the client code

i am using Eclipse 3.5, GWT 2.0.1, with plugin. Chrome;

I can not set any breakpoint in the client code - not in the callback,
not in the OnModuleLoad.

Server code is ok.

thanks
canal

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



Re: MVP nested presenters

2010-02-08 Thread Jesse Dowdle
We have discussed this issue at length on our team, as we're building
an application that will eventually grow to be quite large. There are
certainly pros and cons to each approach (nesting presenters vs a flat
lookup at the AppController level).

Nested Pros
Handy place to hook up a hierarchical location change framework
Chain of responsibility for loading data (parents can load data from
an rpc and pass it down to child presenters to ensure state is
maintained)
Easy re-use of groups of presenters, flexibility to mix and match.
Plays well with nested display objects, so if you've got a TabPanel,
each tab can be driven by a separate presenter and the panel itself
can have a presenter to load data common to all tabs.

Nested Cons
Can be more difficult to analyze the layout of the application without
a single class where all presenter relationships are defined
Does not play well with view classes which have components that need
to be driven by multiple presenters. For example, if you have a ui.xml
with two main areas and you want a presenter to handle each, using
nested presenters requires more spaghetti code that just having a
couple of flat ones.
It can be more difficult to write unit tests against parent
presenters, because you have to take into account instantiation and
operation of child presenters... This can impact the complexity of the
mock objects you must create.

Anyway, we've chosen to go with nested presenters, but I would say the
vote on our team for this was split 4/2, so clearly even for us not
everybody is in love with it.

On Feb 5, 5:00 pm, Sydney sydney.henr...@gmail.com wrote:
 I try to implement the best practices discussed in the article Large
 scale application development and MVP. My application is designed
 using several widgets:
 MainContainerWidget: a DockLayoutPanel
 NorthWidget: a widget in the north region of the main container
 CenterWidget: a widget in the center region of the main container.
 This widget is a composite of two widget (TopWidget and BottomWidget)
 SouthWidget: a widget in the south region of the main container.

 1/ I created a Presenter for each widget. The CenterPresenter contains
 a TopPresenter and a BottomPresenter that are instanciated in the
 constructor of CenterPresenter.

     public CenterPresenter(HandlerManager eventBus, Display display) {
       this.eventBus = eventBus;
       this.display = display;
       topPresenter = new TopPresenter(eventBus, new TopWidget());
       bottomPresenter = new BottomPresenter(eventBus, new
 BottomWidget());
     }

     @Override
     public void go(HasWidgets container) {
         bind();
         container.clear();
         container.add(display.asWidget());
     }

     private void bind() {
       topPresenter.bind();
       bottomPresenter.bind();
     }

 So basically when the CenterPresenter is created in the AppController
 class, it would create all its child presenters and call the bind
 methods. Does it seem a good approach or is there a better way?

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



Remote procedure calls in gwt project

2010-02-08 Thread Firas
Hi,

I am trying to study Google web-tool kit and will be thankful for some
help,

while using remote procedure call i found that they were presented in
two ways, one is the demo service when installing a new gwt project
and other that i found in examples,
the one in demo application you have it, the other is this one :

ServletFacadeServiceAsync servletFacadeServiceAsync =
(ServletFacadeServiceAsync) GWT
.create(ServletFacadeService.class);

ServiceDefTarget endpoint = (ServiceDefTarget)
servletFacadeServiceAsync;
endpoint.setServiceEntryPoint(GWT.getModuleBaseURL() + /facade);

i would like to know why this one worked for me in maven project,
while the demo made my life like hill :):):)

i just cant understand why it didn't work with maven project, although
it works perfectly with gwt project,
please help me to understand the deference between them and why it
didn't work with maven.

thanks in advance.

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



Re: How to configure my web.xml

2010-02-08 Thread Manny
I have the same error. there is no help out there and documentation on
these
common errors are TERRIBLE. thanks for posting this

On Jan 10, 8:42 pm, Dave ladjo...@gmail.com wrote:
 I fixed the error. I was unaware that I had to compile the application
 before. I can't recall any literature which tells you to compile
 before running. I felt that by running it as a web app, then the
 requisite compilation would have been done automatically.

 On Jan 10, 1:28 pm, Dave ladjo...@gmail.com wrote:



   When I made the the following changes and I navigate 
  tohttp://localhost:/my_App.html?gwt.codesvr=127.0.1.1:9997#page1. I
  am getting HTTP ERROR: 404 NOT_FOUND RequestURI=/my_app/service1.

  Changes:

  web.xml.
  servlet
      servlet-nameservice1/servlet-name
      servlet-classcom.server.ServiceImpl1/servlet-class
    /servlet
    servlet
      servlet-nameservice2/servlet-name
      servlet-classcom.server.ServiceImpl2/servlet-class
    /servlet

    servlet-mapping
      servlet-nameservice1/servlet-name
      url-pattern/my_app/service1/url-pattern
    /servlet-mapping

    servlet-mapping
      servlet-nameservice2/servlet-name
      url-pattern/my_app/service2/url-pattern
    /servlet-mapping

  My client side service interface is as follows
  @RemoteServiceRelativePath(service1)
  public interface MyService extends RemoteService
  {
      //some function prototype
     //some function prototype

  }

  I am following instruction found 
  at:http://code.google.com/webtoolkit/doc/1.6/tutorial/appengine.html#test.
  What am I doing wrong?

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



Re: Gwt server side in maven

2010-02-08 Thread יוסף נוגידאת
Hello again
 this what i get in debug mode :

html
head
meta http-equiv=Content-Type content=text/html; charset=ISO-8859-1/
titleError 404 NOT_FOUND/title
/head
bodyh2*HTTP ERROR: 404*/h2preNOT_FOUND/pre
pRequestURI=/hp.com.bsrm.
Application/greet/ppismalla href=http://jetty.mortbay.org/;Powered
by Jetty:///a/small/i/pbr/


thank's for helping


On Fri, Feb 5, 2010 at 8:54 AM, Ignat Alexeyenko
ignatalexeye...@gmail.comwrote:

 Hi again,

 So, how do you use maven?
 Which output it gives to you?

 Please post maven log.

 --
 Kind regards,
 Ignat Alexeyenko

 On Thu, Feb 4, 2010 at 2:38 PM, יוסף נוגידאת joseph.p...@gmail.comwrote:

 hello Ignat

 No i do not have any errors


 On Thu, Feb 4, 2010 at 2:31 PM, Ignat Alexeyenko 
 ignatalexeye...@gmail.com wrote:

 Hi

 Do you have any errors during maven work?

 --
 Kind regards,
 Ignat Alexeyenko.

 On Thu, Feb 4, 2010 at 11:13 AM, joe7935 joseph.p...@gmail.com wrote:

 Hello all,
 I try to build a project in maven and gwt with server side.
 so i select to use a gwt-maven-plugin archetype as a maven project .

 here is my app :

 public class Application implements EntryPoint
 {

  public void onModuleLoad()
  {
  final Button button = new Button();
  final Label label = new Label(only for test);


  button.addClickHandler(new ClickHandler()
  {
public void onClick(ClickEvent arg0)
{
GetStringServiceAsync service =
 (GetStringServiceAsync)
 GWT.create(GetStringService.class);
service.getString(1, 2,new
 AsyncCallbackString()
{
public void
 onSuccess(String res)
{

  label.setText(res);
}

public void
 onFailure(Throwable arg0)
{

  label.setText(Error Connection);
}
});
}
});
 RootPanel.get().add(button);
 RootPanel.get().add(label);
  }
 }



 server interface :

 public interface GetStringService extends RemoteService
 {
public String getString(String name, String pass);
 }

 public interface GetStringServiceAsync
 {
void getString(String name,String pass,AsyncCallbackString
 callback );
 }


 server Impi..
 @SuppressWarnings(serial)
 public class GetStringImpl extends RemoteServiceServlet implements
 GetStringService
 {
public String getString(String name, String pass)
{
return Hello every body ...;
}
 }


 POM file :


 ?xml version=1.0 encoding=UTF-8?
 project xmlns=http://maven.apache.org/POM/4.0.0; xmlns:xsi=http://
 www.w3.org/2001/XMLSchema-instance xsi:schemaLocation=http://
 maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd;
  !--
POM generated by gwt-maven-plugin archetype
  --
  modelVersion4.0.0/modelVersion
  groupIdcom.hp.bsrm/groupId
  artifactIdttt/artifactId
  packagingwar/packaging
  version0.0.1-SNAPSHOT/version

  properties

  !-- convenience to define GWT version in one place --
  gwt.version2.0.0/gwt.version

  !--  tell the compiler we can use 1.5 --
  maven.compiler.source1.5/maven.compiler.source
  maven.compiler.target1.5/maven.compiler.target

  /properties

  dependencies

  !--  GWT dependencies (from central repo) --
dependency
  groupIdcom.google.gwt/groupId
  artifactIdgwt-servlet/artifactId
  version${gwt.version}/version
  scoperuntime/scope
/dependency
dependency
  groupIdcom.google.gwt/groupId
  artifactIdgwt-user/artifactId
  version${gwt.version}/version
  scopeprovided/scope
/dependency

!-- test --
dependency
  groupIdjunit/groupId
  artifactIdjunit/artifactId
  version4.7/version
  scopetest/scope
/dependency
  /dependencies

  build
outputDirectorywar/WEB-INF/classes/outputDirectory
plugins
  plugin
groupIdorg.codehaus.mojo/groupId
artifactIdgwt-maven-plugin/artifactId
version1.2/version
executions
  execution
goals
  goalcompile/goal
  goaltest/goal
/goals
  /execution
/executions
configuration
  runTargetcom.hp.bsrm.ttt.Application/Application.html/
 runTarget
/configuration
  /plugin
  !--
  If you want to use the target/web.xml file mergewebxml
 produces,
  tell the war plugin to use it.
  Also, exclude what you want from the final artifact here.
plugin
groupIdorg.apache.maven.plugins/groupId
artifactIdmaven-war-plugin/artifactId
configuration
webXmltarget/web.xml/webXml

Understanding RequestBilder und SOP Problem

2010-02-08 Thread Alain Ekambi
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 Greet

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.



I need SOP disabled in GWT 2.0 built-in web server.

2010-02-08 Thread Tatchan
Hi all,

I have to make http request (but not RPC)  to a service which runs in
a different port on the local host in development mode, which is
fortunately possible with GWT 1.7 and IE 8 (but not with Firefox 3.5 -
bad). But now with GWT 2.0 this convenience has gone. Things got
really complicated and inefficient in terms of development, since I
have to use an external Apache server with proper proxy configuration
to make it work. Stuffs have to be deployed to the server usually -
really bad.
And, to be frank, I still have problems now, and I wish I had my
convenience back. I need a simple way to bypass SOP for locally
development. Could anyone help me please?

Thanks alot,

~Tatchan

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



creating a panel that will refreshes its content automatically from a database.

2010-02-08 Thread Anmol kapoor
i m working on a virtual stock exchange simple game with gwt... i want
to design a panel showing all the stocks the panel should refresh
its content automatically from the database. Please provide your kind
guidance or any tutorial i should refer.

thanks in advance.

Anmol Kapoor

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



Invocation Exception on JUnit TestCase

2010-02-08 Thread Jiyul Lee
I just wrote some rpc service and client module and they works
correctly in both of hosted mode and web mode.

The problem is occurred in User scenario test which is written as
GWTTestCase. Every rpc call throws InvocationException with strange
message likes that:
htmlhead
script language='javascript'
src='org.exria.mobile.sample.login.JUnit.nocache.js'/script
/headbody
iframe src=javascript:'' id='__gwt_historyFrame'
style='position:absolute;width:0;height:0;border:0'/iframe
noscript
  div style=width: 22em; position: absolute; left: 50%; margin-left:
-11em; color: red; background-color: white; border: 1px solid red;
padding: 4px; font-family: sans-serif
Your web browser must have JavaScript enabled
in order for this application to display correctly.
  /div
/noscript
/body/html
at
com.google.gwt.user.client.rpc.impl.RequestCallbackAdapter.onResponseReceived(RequestCallbackAdapter.java:
201)
at
com.google.gwt.http.client.Request.fireOnResponseReceived(Request.java:
287)
at com.google.gwt.http.client.RequestBuilder
$1.onReadyStateChange(RequestBuilder.java:393)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at com.google.gwt.dev.shell.MethodAdaptor.invoke(MethodAdaptor.java:
103)
at com.google.gwt.dev.shell.MethodDispatch.invoke(MethodDispatch.java:
71)
at
com.google.gwt.dev.shell.OophmSessionHandler.invoke(OophmSessionHandler.java:
157)
at
com.google.gwt.dev.shell.BrowserChannel.reactToMessagesWhileWaitingForReturn(BrowserChannel.java:
1713)
at
com.google.gwt.dev.shell.BrowserChannelServer.invokeJavascript(BrowserChannelServer.java:
165)
at
com.google.gwt.dev.shell.ModuleSpaceOOPHM.doInvoke(ModuleSpaceOOPHM.java:
120)
at com.google.gwt.dev.shell.ModuleSpace.invokeNative(ModuleSpace.java:
507)
at
com.google.gwt.dev.shell.ModuleSpace.invokeNativeObject(ModuleSpace.java:
264)
at
com.google.gwt.dev.shell.JavaScriptHost.invokeNativeObject(JavaScriptHost.java:
91)
at com.google.gwt.core.client.impl.Impl.apply(Impl.java)
at com.google.gwt.core.client.impl.Impl.entry0(Impl.java:188)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at com.google.gwt.dev.shell.MethodAdaptor.invoke(MethodAdaptor.java:
103)
at com.google.gwt.dev.shell.MethodDispatch.invoke(MethodDispatch.java:
71)
at
com.google.gwt.dev.shell.OophmSessionHandler.invoke(OophmSessionHandler.java:
157)
at
com.google.gwt.dev.shell.BrowserChannel.reactToMessages(BrowserChannel.java:
1668)
at
com.google.gwt.dev.shell.BrowserChannelServer.processConnection(BrowserChannelServer.java:
401)
at
com.google.gwt.dev.shell.BrowserChannelServer.run(BrowserChannelServer.java:
222)
at java.lang.Thread.run(Unknown Source)

Any Idea?

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



Re: GWT compiler error

2010-02-08 Thread Steve B
You will probably need to be more specific in order to get help.
Are you managing to compile any GWT modules, or is it just this one
module that won't compile?

On Feb 8, 1:27 am, mic mina...@gmail.com wrote:
 I am seeing this error while compiling a module...

 [ERROR] Unexpected
 java.lang.NullPointerException
     at com.google.gwt.dev.javac.JdtCompiler
 $FindTypesInCud.visit(JdtCompiler.java:178)
     at
 org.eclipse.jdt.internal.compiler.ast.TypeDeclaration.traverse(TypeDeclarat 
 ion.java:
 1253)
     at
 org.eclipse.jdt.internal.compiler.ast.QualifiedAllocationExpression.travers 
 e(QualifiedAllocationExpression.java:
 478)
     at
 org.eclipse.jdt.internal.compiler.ast.MessageSend.traverse(MessageSend.java :
 576)
     at
 org.eclipse.jdt.internal.compiler.ast.MethodDeclaration.traverse(MethodDecl 
 aration.java:
 239)
     at
 org.eclipse.jdt.internal.compiler.ast.TypeDeclaration.traverse(TypeDeclarat 
 ion.java:
 1239)
     at
 org.eclipse.jdt.internal.compiler.ast.CompilationUnitDeclaration.traverse(C 
 ompilationUnitDeclaration.java:
 687)
     at com.google.gwt.dev.javac.JdtCompiler
 $CompilerImpl.process(JdtCompiler.java:157)
     at
 org.eclipse.jdt.internal.compiler.Compiler.compile(Compiler.java:444)
     at com.google.gwt.dev.javac.JdtCompiler.doCompile(JdtCompiler.java:
 466)
     at com.google.gwt.dev.javac.CompilationStateBuilder
 $CompileMoreLater.compile(CompilationStateBuilder.java:141)
     at
 com.google.gwt.dev.javac.CompilationStateBuilder.doBuildFrom(CompilationSta 
 teBuilder.java:
 279)
     at
 com.google.gwt.dev.javac.CompilationStateBuilder.buildFrom(CompilationState 
 Builder.java:
 181)
     at
 com.google.gwt.dev.cfg.ModuleDef.getCompilationState(ModuleDef.java:
 280)
     at com.google.gwt.dev.Precompile.precompile(Precompile.java:502)
     at com.google.gwt.dev.Precompile.precompile(Precompile.java:414)
     at com.google.gwt.dev.Compiler.run(Compiler.java:201)
     at com.google.gwt.dev.Compiler$1.run(Compiler.java:152)
     at
 com.google.gwt.dev.CompileTaskRunner.doRun(CompileTaskRunner.java:87)
     at
 com.google.gwt.dev.CompileTaskRunner.runWithAppropriateLogger(CompileTaskRu 
 nner.java:
 81)
     at com.google.gwt.dev.Compiler.main(Compiler.java:159)

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



MVP hierarchy

2010-02-08 Thread bestey
I have a couple questions about the best way to organize my code when
it comes to nested data.

For instance, let's I have a Contact class, to use the common example,
which has a name, an email address and a phone number.

Now to edit this, I can make a ContactEditor, which will have a
ContactEditorView and a ContactEditorPresenter.  The view has three
text fields for each of the three fields, an update button and a
cancel button.  The presenter hooks ups to the HasClickHandlers
exposed by the view and updates the model or cancels depending on
which button is pressed.  Simple enough so far.

Now let's say I want a re-orderable list of editable contacts in one
view.  I want to be able to reuse the existing functionality of my
previously defined ContactEditor (View and Presenter).  Would I create
a ContactListEditorView which has a list of ContactEditorViews and a
ContactListEditorPresenter that has an associated list of
ContactEditorPresenters?

Is that correct in the MVP sense, or am I totally missing something?

Thanks,
Brian

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



Re: GWT + Maven + JBOSS Issue

2010-02-08 Thread regis.dev
Hi,

I had the same issue, and i found the solution.

I was using in dev mode, the eclipse google plugin with also the
m2eclipse (maven plugin), and to generate my war file the maven tool.

When you run the eclipse google plugin, this one generate the gwt
files in  project/war/directory_output  the directory_output is
define in your gwt.xml
module rename-to='directory_output'

But when i was launching the command $ mvn clean package, i never
delete my project/war/directory_output !!!

so dont forget to add in you pom.xml

properties
gwtOutputDirectorywar/gmapsdispobillet/gwtOutputDirectory

/properties

 plugin
artifactIdmaven-clean-plugin/artifactId
version2.4/version
configuration
filesetsfileset
directory${gwtOutputDirectory}/directory
/fileset/filesets
/configuration
/plugin




On 2 fév, 11:50, Kees keesvanbem...@gmail.com wrote:
 Could you share your maven-war-plugin configuration? I can't seem to
 solve this same issue...

 On 28 jan, 09:42, cupakob sira...@gmail.com wrote:

  To solve the problem, we have to cange the config for themaven-war-
  plugin and now works fine.

  On 18 Jan., 10:52, olivier nouguier olivier.nougu...@gmail.com
  wrote:

   How to you run your server ? WTP Launch ?

   On Mon, Jan 18, 2010 at 10:45 AM, Alexander the.malk...@gmail.com wrote:
I meant there is no need to use them in production (e.g. in real server)

2010/1/18 cupakob sira...@gmail.com

i think, the parameter is needed for both - Host and Dev Mode.

On 15 Jan., 17:03, Alexander the.malk...@gmail.com wrote:
 This parameter is only need when you run DevMode, right?

 2010/1/15 cupakob sira...@gmail.com

  hi all,

  i have a project, which useGWTfor the frontend. I can compile and
  run the module withmaven(mvn compile war:explodedgwt:run) and it
  works fine. After that i package (mvn war:exploded package) the 
  app as
  war and deploy it intojboss. When i call

     http://localhost:8080/module-frontend/index.html

  i get follwoing message

     GWTmodule 'XYZ' may need to be (re)compiled

  I found, that the ?gwt.codesvr parameter is missing. I've tried 
  again
  with:

 http://localhost:8080/module-frontend/index.html?gwt.codesvr=172.16.0.
..

  but now i get this error message:

     Plugin failed to connect to hosted mode server at 
  172.16.0.43:9997

  Any suggestions, how to solve the problem?

  --
  You received this message because you are subscribed to the Google
Groups
  Google Web Toolkit group.
  To post to this group, send email to
google-web-tool...@googlegroups.com.
  To unsubscribe from this group, send email to
  google-web-toolkit+unsubscr...@googlegroups.comgoogle-web-toolkit%2bunsubscr...@googlegroups.com
google-web-toolkit%2bunsubscr...@googlegroups.comgoogle-web-toolkit%252bunsubscr...@googlegroups.com

  .
  For more options, visit this group at
 http://groups.google.com/group/google-web-toolkit?hl=en.

 --
 Regards,
 Alexander

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

--
Regards,
Alexander

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

   --
   A coward is incapable of exhibiting love; it is the prerogative of the
   brave.
   --
   Mohandas Gandhi

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



Re: SplitLayoutPanel

2010-02-08 Thread vincent yeung


On Jan 12, 11:33 pm, Stine stinespl...@gmail.com wrote:
 Hello :)

 I am having problems making my panels display the way they should -
 they look almost empty!! :(

 For instance when I have this code...

 public final void onModuleLoad() {
         SplitLayoutPanel p = new SplitLayoutPanel();
         p.addWest(new HTML(navigation), 128);
         p.addNorth(new HTML(list), 384);
         p.add(new HTML(details));
         RootLayoutPanel.get().add(p);

 }

 ... I see the following in my browser...

 navigation                           list

                                           details

 ... which is not very fancy! ;D

 What am I missing?! :/

 Thanks a lot,
 Stine :)

There is a bug that the background color for the splitter is hardcoded
to be white, no matter how you style it the splitter is white (kinda
useless) see http://code.google.com/p/google-web-toolkit/issues/detail?id=4335
for the bug, i had the problem that everytime I tried to colour up the
missing bar it ends up white. might work if you style the splitter
with an image. or use the !important css as stated in the problem

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



Re: GWT + Maven + JBOSS Issue

2010-02-08 Thread regis.dev
Hi i had the same problem,

 i was mixing my generated files from the google eclipse plugin and
the maven gwt plugin.

To fix this problem i add a directory to delete in maven clean plugin

properties
gwtOutputDirectorywar/OUTPUT_DIRECTORY/gwtOutputDirectory
/properties

The OUTPUT_DIRECTORY is defined in your src/main/java/your_package/
Module.gwt.xml


build

plugins

 plugin
artifactIdmaven-clean-plugin/artifactId
version2.4/version
configuration
filesetsfileset

directory${gwtOutputDirectory}/directory
/fileset/filesets
/configuration
/plugin

/plugins
/build

i used this POM 
http://mojo.codehaus.org/gwt-maven-plugin/eclipse/google_plugin.html


On 2 fév, 11:50, Kees keesvanbem...@gmail.com wrote:
 Could you share your maven-war-plugin configuration? I can't seem to
 solve this same issue...

 On 28 jan, 09:42, cupakob sira...@gmail.com wrote:

  To solve the problem, we have to cange the config for themaven-war-
  plugin and now works fine.

  On 18 Jan., 10:52, olivier nouguier olivier.nougu...@gmail.com
  wrote:

   How to you run your server ? WTP Launch ?

   On Mon, Jan 18, 2010 at 10:45 AM, Alexander the.malk...@gmail.com wrote:
I meant there is no need to use them in production (e.g. in real server)

2010/1/18 cupakob sira...@gmail.com

i think, the parameter is needed for both - Host and Dev Mode.

On 15 Jan., 17:03, Alexander the.malk...@gmail.com wrote:
 This parameter is only need when you run DevMode, right?

 2010/1/15 cupakob sira...@gmail.com

  hi all,

  i have a project, which useGWTfor the frontend. I can compile and
  run the module withmaven(mvn compile war:explodedgwt:run) and it
  works fine. After that i package (mvn war:exploded package) the 
  app as
  war and deploy it intojboss. When i call

     http://localhost:8080/module-frontend/index.html

  i get follwoing message

     GWTmodule 'XYZ' may need to be (re)compiled

  I found, that the ?gwt.codesvr parameter is missing. I've tried 
  again
  with:

 http://localhost:8080/module-frontend/index.html?gwt.codesvr=172.16.0.
..

  but now i get this error message:

     Plugin failed to connect to hosted mode server at 
  172.16.0.43:9997

  Any suggestions, how to solve the problem?

  --
  You received this message because you are subscribed to the Google
Groups
  Google Web Toolkit group.
  To post to this group, send email to
google-web-tool...@googlegroups.com.
  To unsubscribe from this group, send email to
  google-web-toolkit+unsubscr...@googlegroups.comgoogle-web-toolkit%2bunsubscr...@googlegroups.com
google-web-toolkit%2bunsubscr...@googlegroups.comgoogle-web-toolkit%252bunsubscr...@googlegroups.com

  .
  For more options, visit this group at
 http://groups.google.com/group/google-web-toolkit?hl=en.

 --
 Regards,
 Alexander

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

--
Regards,
Alexander

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

   --
   A coward is incapable of exhibiting love; it is the prerogative of the
   brave.
   --
   Mohandas Gandhi

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



Uploading image via RPC to use in TreeItem

2010-02-08 Thread tdk
Folks'es,

I have the following situation with images (and none of the
discussions I found seemed appropriate):

+ I have a GUI that shows a tree with tree items
+ each tree item has an associated image, depending on its type
+ the tree data incl images is loaded via RPC
+ the servlet runs on a middle-tier and gets its data from a back-end
server via a defined API
+ all data, incl images, comes from the back-end server and is to be
sent to the GUI

what is the best way to do this and
what do I need to pass the image to the TreeItem

Thomas

PS: I'm an absolute newbie to GWT and RPC, fairly new to web apps, but
I know my Swing inside-out...

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



GWT with hibernate...

2010-02-08 Thread Nenad
Hi,
I am new in GWT and I like this concept, so I've tried to create GWT
application with hibernate support. I have a problem with Object
mapping.
This is my persistence.properties file (it is in src folder of my
project):
hibernate.connection.driver_class = com.mysql.jdbc.Driver
hibernate.connection.url = jdbc:mysql://localhost:3306/gwt_web_shop_db
hibernate.connection.username = root
hibernate.connection.password = somepass
hibernate.c3p0.min_size=5
hibernate.c3p0.max_size=20
hibernate.c3p0.timeout=1800
hibernate.c3p0.max_statements=50
hibernate.dialect = org.hibernate.dialect.MySQLDialect
hibernate.connection.pool_size = 4
hibernate.show_sql = true
hibernate.hbm2ddl.auto = create
hibernate.archive.autodetection = class

When I run application (in Eclipse) everything goes ok with this code:
public UserServiceImpl(){
EntityManagerFactory emf =
Persistence.createEntityManagerFactory();
em = emf.createEntityManager();
}
,but when I try something like this:

Query q = em.createQuery(select u from User where u.username
= :username);
q.setParameter(username, username);
ListUser res = q.getResultList();

I get this Exception: java.lang.IllegalArgumentException:
org.hibernate.hql.ast.QuerySyntaxException: User is not mapped [select
u from User where u.username = :username]

Here is my User.java class:

package gwtWebshop.client.entities;

import java.io.Serializable;

import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.Table;

@Entity(name=User)
@Table(name=users)
public class User implements Serializable{
/**
 *
 */
private static final long serialVersionUID = 1L;
private int id;
private String username;
public User() {
}

@Id
@GeneratedValue(strategy = GenerationType.IDENTITY)
public int getId() {
return id;
}
public String getUsername() {
return username;
}
public void setId(int id) {
this.id = id;
}
public void setUsername(String username) {
this.username = username;
}
}

I concluded that the mapping is not done automatically based on the
annotation, but I do not know how to change that.

Please help me and tell me the right way to do this.
Thank you.

Regards,
Nenad

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



onHistoryChanged() not being called on hitting the Back Button (or even calling History.back())

2010-02-08 Thread AM
Hi,
I am running into this weird issue where the onHistoryChanged() isn't
being called when I hit the browser's back button or even if I call
History.back(). I am testing this in the hosted mode (even running it
in firefox yields me the same result). The strange thing is, if I call
History.back() thrice - looks like it calls onHistoryChanged() on the
third request - it is quite confusing and I was hoping if someone
could shed some light on this issue that I am running into.

I am using GWT 1.5 and to demonstrate my case, I'll use the example in
the GWT-1.5 tutorial (http://preview.tinyurl.com/6grjh2)

// Excluding imports for brevity

// Entry point classes define codeonModuleLoad()/code.
public class BrowserHistoryExample implements EntryPoint {

  TabPanel tabPanel;

  public void onModuleLoad() {

tabPanel = new TabPanel();

int tabIndex = 0;

// A Ext-GWT ContentPanel
(com.extjs.gxt.ui.client.widget.ContentPanel)
ContentPanel cp = new ContentPanel();
cp.addText(Page1);
tabPanel.add(cp, Page1);

cp = new ContentPanel();
cp.addText(Page2);
tabPanel.add(cp, Page2);

Button backButton = new Button(Back);
backButton.addClickListener(new ClickListener () {

public void onClick(Widget arg0) {
System.out.println(Going back now ...);

History.back();

// Commenting this for now ...
// but on un-commenting, the third call to
History.back() seems to invoke onHistoryChanged()
// History.back();
// History.back();
}
});
cp = new ContentPanel();
cp.addText(Page3);
cp.add(backButton);
tabPanel.add(cp, Page3);


tabPanel.addTabListener(new TabListener() {

  public boolean onBeforeTabSelected(SourcesTabEvents sender, int
tabIndex) {
return true;
  }

  public void onTabSelected(SourcesTabEvents sender, int tabIndex)
{
  // Push an item onto the history stack
  System.out.println(Pushing tabIndex:  + tabIndex +  on the
stack);
  History.newItem(page + tabIndex);
  }
});

History.addHistoryListener(new HistoryListener() {

  public void onHistoryChanged(String historyToken) {

  System.out.println(Got token:  + historyToken);

// Parse the history token
try {
  if (historyToken.substring(0, 4).equals(page)) {
String tabIndexToken = historyToken.substring(4, 5);
int tabIndex = Integer.parseInt(tabIndexToken);
// Select the specified tab panel
tabPanel.selectTab(tabIndex);
  } else {
tabPanel.selectTab(0);
  }

} catch (IndexOutOfBoundsException e) {
  tabPanel.selectTab(0);
}
  }
});

tabPanel.selectTab(0);
RootPanel.get().add(tabPanel);
  }
}

So the thing is, when I navigate from Page1 tab to Page2 tab to Page3
tab - and then when I hit the back button (defined above, which
simply calls History.back()) - nothing really happens for the first 2
times I hit the button. Only when I hit it the third time (or
alternatively call History.back() thrice in the buttonClick event) -
is the onHistoryChanged() method invoked.

Again, it would be great if someone could help me figure out whats
going on?

Thanks!

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



Re: SWFObject wrappers

2010-02-08 Thread Chris.Pollard
Hi

Flash and GWT is an area I've had great fun with...

Whilst incorporating Flash into parts of our product, we've not found
it to be a simple exercise :(
Alas our EmNOC product has to cover browsers of all ages.

I'm unable to pass on the wrapper I have as it's very product
specific, but here's some of the issues I created it to cover.

So I used SWFObject, and around that my own JS class. This wrapper
is then exercised by a GWT Flash wrapper class.
This handles:
- the possible delay waiting for Flash to load whilst the GWT is
already up and running
- simplifies the interface between GWT and the Flash components used
- handles case where Flash Player is not available
- within our EmNOC product, Flash is placed within a Deck and we also
have a few tabs per page. With non-IE browsers, the Flash content gets
unloaded when hidden and this causes state loss for the view which had
to be handled so state could be reasserted when the Flash content was
viewed again


Chris

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



Re: creating a panel that will refreshes its content automatically from a database.

2010-02-08 Thread mariyan nenchev
The simplest way is to use polling with gwt timer:
Timer refresher = new Timer() {

public void run() {
 reloadData(); // this must call your rpc that gets the data from db
 }
};

On Sun, Feb 7, 2010 at 2:07 AM, Anmol kapoor anmolkapoorm...@gmail.comwrote:

 i m working on a virtual stock exchange simple game with gwt... i want
 to design a panel showing all the stocks the panel should refresh
 its content automatically from the database. Please provide your kind
 guidance or any tutorial i should refer.

 thanks in advance.

 Anmol Kapoor

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



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



Re: creating a panel that will refreshes its content automatically from a database.

2010-02-08 Thread mariyan nenchev
And you use it :
refresher.scheduleRepeating(1);// every 10 seconds

On Mon, Feb 8, 2010 at 4:15 PM, mariyan nenchev
nenchev.mari...@gmail.comwrote:

 The simplest way is to use polling with gwt timer:
 Timer refresher = new Timer() {

 public void run() {
  reloadData(); // this must call your rpc that gets the data from
 db
  }
 };


 On Sun, Feb 7, 2010 at 2:07 AM, Anmol kapoor anmolkapoorm...@gmail.comwrote:

 i m working on a virtual stock exchange simple game with gwt... i want
 to design a panel showing all the stocks the panel should refresh
 its content automatically from the database. Please provide your kind
 guidance or any tutorial i should refer.

 thanks in advance.

 Anmol Kapoor

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




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



Re: Who uploads GWT to Maven

2010-02-08 Thread Jan Ehrhardt
Oh, I looked at http://mvnrepository.com but it seems not to be up to date.

Regards
Jan Ehrhardt

On Mon, Feb 8, 2010 at 2:30 PM, Ben Harris bharri...@gmail.com wrote:

 It is in there...? Since 5th Feb.
 http://repo1.maven.org/maven2/com/google/gwt/gwt-user/

 On Feb 8, 8:20 pm, Jan Ehrhardt jan.ehrha...@googlemail.com wrote:
  Hi,
 
  currently GWT 2.0 is available in Maven's repo1, but GWT 2.0.1 is
 released
  since last week.
  So, who does the uploads to the public Maven repo? Is there a POM
 available,
  that is used for uploading? Can I help in any way to speed up the
 uploading
  to Maven?
 
  The best case would be, if new GWT releases were available through Maven
  from day one. Anything bringing me closer to this is welcome.
 
  Regards
  Jan Ehrhardt

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



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



Re: I need SOP disabled in GWT 2.0 built-in web server.

2010-02-08 Thread RPB

This works for me in GWT 2.0:
-Open 'Debug configurations' in eclipse
-Uncheck 'Run built-in server'
-Set the port number to your localhost port
-Run

Good luck,
Rob

On Feb 7, 4:51 am, Tatchan tatcha...@gmail.com wrote:
 Hi all,

 I have to make http request (but not RPC)  to a service which runs in
 a different port on the local host in development mode, which is
 fortunately possible with GWT 1.7 and IE 8 (but not with Firefox 3.5 -
 bad). But now with GWT 2.0 this convenience has gone. Things got
 really complicated and inefficient in terms of development, since I
 have to use an external Apache server with proper proxy configuration
 to make it work. Stuffs have to be deployed to the server usually -
 really bad.
 And, to be frank, I still have problems now, and I wish I had my
 convenience back. I need a simple way to bypass SOP for locally
 development. Could anyone help me please?

 Thanks alot,

 ~Tatchan

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



Re: GWT with hibernate...

2010-02-08 Thread John Ivens
Not sure I've seen all the mistakes, but shouldn't it be
from User u where u.snarfle = blarg

Looks like the class is correctly annotated.
I use hbm files and in that case you need to tell hibernate which classes
are mapped to which hbm files in the hibernate.cfg.xml file.
You may need to do the equivalent when you annotate classes, but I am not
sure how.

On Sun, Feb 7, 2010 at 6:02 PM, Nenad nnikolic1...@gmail.com wrote:

 Hi,
 I am new in GWT and I like this concept, so I've tried to create GWT
 application with hibernate support. I have a problem with Object
 mapping.
 This is my persistence.properties file (it is in src folder of my
 project):
 hibernate.connection.driver_class = com.mysql.jdbc.Driver
 hibernate.connection.url = jdbc:mysql://localhost:3306/gwt_web_shop_db
 hibernate.connection.username = root
 hibernate.connection.password = somepass
 hibernate.c3p0.min_size=5
 hibernate.c3p0.max_size=20
 hibernate.c3p0.timeout=1800
 hibernate.c3p0.max_statements=50
 hibernate.dialect = org.hibernate.dialect.MySQLDialect
 hibernate.connection.pool_size = 4
 hibernate.show_sql = true
 hibernate.hbm2ddl.auto = create
 hibernate.archive.autodetection = class

 When I run application (in Eclipse) everything goes ok with this code:
 public UserServiceImpl(){
EntityManagerFactory emf =
 Persistence.createEntityManagerFactory();
em = emf.createEntityManager();
 }
 ,but when I try something like this:

 Query q = em.createQuery(select u from User where u.username
 = :username);
 q.setParameter(username, username);
 ListUser res = q.getResultList();

 I get this Exception: java.lang.IllegalArgumentException:
 org.hibernate.hql.ast.QuerySyntaxException: User is not mapped [select
 u from User where u.username = :username]

 Here is my User.java class:

 package gwtWebshop.client.entities;

 import java.io.Serializable;

 import javax.persistence.Entity;
 import javax.persistence.GeneratedValue;
 import javax.persistence.GenerationType;
 import javax.persistence.Id;
 import javax.persistence.Table;

 @Entity(name=User)
 @Table(name=users)
 public class User implements Serializable{
/**
 *
 */
private static final long serialVersionUID = 1L;
private int id;
private String username;
public User() {
}

@Id
@GeneratedValue(strategy = GenerationType.IDENTITY)
public int getId() {
return id;
}
public String getUsername() {
return username;
}
public void setId(int id) {
this.id = id;
}
public void setUsername(String username) {
this.username = username;
}
 }

 I concluded that the mapping is not done automatically based on the
 annotation, but I do not know how to change that.

 Please help me and tell me the right way to do this.
 Thank you.

 Regards,
 Nenad

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



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



Re: can not set breakpoint

2010-02-08 Thread Aladdin
I'm not sure if this is the correct answer, but I never was able to
set a break point inside anonymous classes , so just in eclipse try to
make them inner class or something ... (ask eclipse to refactor
that)

Aladdin
On Feb 8, 4:05 am, canal goca...@yahoo.com wrote:
 hi,
 searched the group but still can not make it work - can not set
 breakpoint in the client code

 i am using Eclipse 3.5, GWT 2.0.1, with plugin. Chrome;

 I can not set any breakpoint in the client code - not in the callback,
 not in the OnModuleLoad.

 Server code is ok.

 thanks
 canal

-- 
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: problems running application in development mode using -noserver switch and cache.html/nocache.js files not served from the webapp root

2010-02-08 Thread jdw
Hey Dan,

I'm seeing something similar.  I don't know if this is your case but
this is what I've discovered.  If the url you specify with the -
startupUrl does NOT point to a page that uses GWT, the FF tab is
never seen in the development mode window.  Even if you browse to a
page that uses GWT, you will not see the FF tab and you cannot debug
the client-side code.  If the -startupUrl points to a page that uses
GWT then everything works fine.  I created a post on this problem a
few weeks ago and I have not seen a response.  If you figure something
out please post your solution.

Thanks,
- Jay

On Feb 7, 12:52 pm, mooreds moor...@gmail.com wrote:
 Hi folks,

 I'm trying to get GWT 2.0.1 development mode working with the -
 noserver option.  The main issue is that while running in development
 mode, any changes I make in the GWT java classes are not reflected
 when I refresh the browser.

 This is a bit of a nonstandard setup, so let me outline it a bit.

 We have a number of apps that depend on some other cvs modules:

 * gwtapp1
 * gwtapp2
 * gwtlib1
 * gwtlib2

 All of these depend on code running on the server (json files, RPC)
 and I couldn't figure out how to get them working with the built in
 Jetty server.  (For one thing, I couldn't figure out how to have the
 different projects all compile into one WEB-INF/classes directory.)

 gwtapp1 compiles the GWT into the root directory, and works just fine.

 gwtapp2 compiles the GWT into /static/gwt/  One other difference that
 may be relevant is that gwtapp2 uses the cross site linker.  However,
 removing that line from the .gwt.xml file didn't seem to make a
 difference in the behavior.  Another difference is the directory that
 gwtapp2 compiles into actually has 3 different modules in it (but I'm
 not trying to touch any of the other modules).

 It works fine in 'production' mode, when built via ant.  But it
 doesn't work in development mode.

 Here's the arguments I'm using for the eclipse launcher:

 -noserver -startupUrlhttp://localhost:8080/HomePage.do
 com.foo.gwtapp2 (I've tried different URLs, including a static html
 page)

 The GWT development mode window pops up just fine, but I never see the
 'FF' tab pop up when I click 'launch default browser'.  I do see this
 url in the browser window:  
 http://localhost:8080/HomePage.do?gwt.codesvr=192.168.3.103:9997

 I see no messages in the development mode window.  However, when I
 turn the logLevel up to DEBUG (-logLevel DEBUG) I see the 'Loading
 Modules' line.  When I am working with gwtapp1 (which works) I also
 see a 'Connection received from xxx.xxx.xxx.xxx' message.

 Before the 'Connection recieved', I see the following TRACE messages
 when running either app:

     00:00:02.078  [TRACE] Invoking Linker RPC policy file manifest
     00:00:02.078  [TRACE] Invoking Linker Standard
       00:00:02.094  [DEBUG] Attempting to optimize JS
     00:00:02.141  [TRACE] Invoking Linker Export CompilationResult
 symbol maps
     00:00:02.141  [TRACE] Invoking Linker Emit compile report
 artifacts
     00:00:02.141  [TRACE] Linking compilation into C:\eclipse-workspace
 \account\war\com.foo.gwtapp[12]

 I imagine that the Connection is the issue, but am not quite sure how
 to debug it.

 I've installed the Google FF plugin, and am using FF 3.6.  This is an
 old project so it was not created with the google eclipse plugin.
 Running on eclipse 3.4.2 on Windows XP, if that matters.

 I've reviewed this 
 FAQ:http://code.google.com/webtoolkit/doc/latest/FAQ_DebuggingAndCompilin...

 and made sure that I have all the .rpc files in the /static/gwt
 directory.  This directory is browser accessible (ie, when I put a
 file here:http://localhost:8080/static/gwt/a.txt, I can read it with
 my browser).

 I also played around with the -codeServerPort argument, but that
 didn't seem to make any difference.  In the thought that it was
 perhaps a urlrewrite issue (gwtapp2 does some url rewriting) I put a
 static html file in the /static/gwt directory, but that still didn't
 lead to a Connection being made.

 I have done some searching on the web and in the GWT google group, but
 haven't found much else.  I also didn't find anything when searching
 through the bug list.

 What am I missing?  Can anyone give me further places I should look or
 ideas?

 Thanks,
 Dan

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



Re: GWT with hibernate...

2010-02-08 Thread Bruno Pinto A. de Oliveira
hey Nenad,

I use hibernate 3.0 with GWT 2.0 without problem. comparing your exemple
with mine I don't use Hibernate Annotation I'm using xml configuration. I
did 2 Eclipse project. first is my business tier where i did hibernate
enginer and my persists classes. and second project is gtw project.

then i make a package of first project and save file.jar in
gwt-web-project\war\web-inf\lib

i just do access on hibernate engine in sever side.

it is working very well.

I hope it is can help you.

Regards
Bruno


On Mon, Feb 8, 2010 at 1:07 PM, John Ivens john.wagner.iv...@gmail.comwrote:

 Not sure I've seen all the mistakes, but shouldn't it be
 from User u where u.snarfle = blarg

 Looks like the class is correctly annotated.
 I use hbm files and in that case you need to tell hibernate which classes
 are mapped to which hbm files in the hibernate.cfg.xml file.
 You may need to do the equivalent when you annotate classes, but I am not
 sure how.

 On Sun, Feb 7, 2010 at 6:02 PM, Nenad nnikolic1...@gmail.com wrote:

 Hi,
 I am new in GWT and I like this concept, so I've tried to create GWT
 application with hibernate support. I have a problem with Object
 mapping.
 This is my persistence.properties file (it is in src folder of my
 project):
 hibernate.connection.driver_class = com.mysql.jdbc.Driver
 hibernate.connection.url = jdbc:mysql://localhost:3306/gwt_web_shop_db
 hibernate.connection.username = root
 hibernate.connection.password = somepass
 hibernate.c3p0.min_size=5
 hibernate.c3p0.max_size=20
 hibernate.c3p0.timeout=1800
 hibernate.c3p0.max_statements=50
 hibernate.dialect = org.hibernate.dialect.MySQLDialect
 hibernate.connection.pool_size = 4
 hibernate.show_sql = true
 hibernate.hbm2ddl.auto = create
 hibernate.archive.autodetection = class

 When I run application (in Eclipse) everything goes ok with this code:
 public UserServiceImpl(){
EntityManagerFactory emf =
 Persistence.createEntityManagerFactory();
em = emf.createEntityManager();
 }
 ,but when I try something like this:

 Query q = em.createQuery(select u from User where u.username
 = :username);
 q.setParameter(username, username);
 ListUser res = q.getResultList();

 I get this Exception: java.lang.IllegalArgumentException:
 org.hibernate.hql.ast.QuerySyntaxException: User is not mapped [select
 u from User where u.username = :username]

 Here is my User.java class:

 package gwtWebshop.client.entities;

 import java.io.Serializable;

 import javax.persistence.Entity;
 import javax.persistence.GeneratedValue;
 import javax.persistence.GenerationType;
 import javax.persistence.Id;
 import javax.persistence.Table;

 @Entity(name=User)
 @Table(name=users)
 public class User implements Serializable{
/**
 *
 */
private static final long serialVersionUID = 1L;
private int id;
private String username;
public User() {
}

@Id
@GeneratedValue(strategy = GenerationType.IDENTITY)
public int getId() {
return id;
}
public String getUsername() {
return username;
}
public void setId(int id) {
this.id = id;
}
public void setUsername(String username) {
this.username = username;
}
 }

 I concluded that the mapping is not done automatically based on the
 annotation, but I do not know how to change that.

 Please help me and tell me the right way to do this.
 Thank you.

 Regards,
 Nenad

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


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


-- 
You received this message because you are 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: can not set breakpoint

2010-02-08 Thread Jason Parekh
Hi Canal,

What version of Java are you running?
Could you try on a simple project (perhaps the default app created by the
wizard)?
I'm assuming the breakpoints do not show the checkmark on top of them (when
the debugger is connected)?

jason

On Sun, Feb 7, 2010 at 8:05 PM, canal goca...@yahoo.com wrote:

 hi,
 searched the group but still can not make it work - can not set
 breakpoint in the client code

 i am using Eclipse 3.5, GWT 2.0.1, with plugin. Chrome;

 I can not set any breakpoint in the client code - not in the callback,
 not in the OnModuleLoad.

 Server code is ok.

 thanks
 canal

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



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



Re: Understanding RequestBilder und SOP Problem

2010-02-08 Thread Thomas Broyer


On Feb 7, 12:35 pm, Alain Ekambi ekambi.al...@googlemail.com wrote:
 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  tohttp://localhost/test.phpwill 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 can only confirm you that a RequestBuilder in the application
sandbox in an Adobe AIR application can make requests to any server
without hitting the SOP.
Outside the application sandbox though, Adobe AIR behaves like a
browser.

-- 
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: Client Bundle and Image Internationalization

2010-02-08 Thread Christian Goudreau
There's an example of what I have :

Inside the client bundle :

ImageResource example();

and in my directory I have : exemple.png
exemple_fr_CA.png
exemple_en_CA.png

and when I set the local to fr_CA, I have exemple.png instead...

On Sun, Feb 7, 2010 at 10:20 PM, Christian Goudreau 
goudreau.christ...@gmail.com wrote:

 I know how to implements localizable images with Image bundle, but how does
 it works with Client Bundle ? I found nothing about that in the
 documentation and I was wondering what was the best way to acheive this with
 Gwt 2.0.

 Thx

 Christian


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



Re: How to resubmit RPC after session timeout/login

2010-02-08 Thread Jamie
Can you give me an example on how I'd be able to resubmit an RPC with
Ray's command pattern approach?

On Feb 6, 5:50 am, Thomas Broyer t.bro...@gmail.com wrote:
 On Feb 5, 10:24 pm, Jamie jsgreenb...@gmail.com wrote:





  Hi everybody.  I'm trying to extend AsyncCallback to always have the
  same behavior onFailure.  I can successfully catch the session timeout
  exception that I'm looking for, open a login dialog, and have the user
  login.  What I want to do after that is done is to resubmit the
  original RPC call that caused the onfailure.  Here's what I have so
  far:

  code
  public abstract class MyAsyncCallbackT implements AsyncCallbackT {

          public final void onFailure(Throwable caught) {
                  if(caught instanceof StatusCodeException 
  ((StatusCodeException)caught).getStatusCode() == 401) {
                          final LoginDialog login = new LoginDialog();
                          login.addLoginDialogListener(new 
  LoginDialogListener() {
                                  public void loginSuccess() {
                                          login.hide();
                                          //RESUBMIT THE ORIGINAL RPC HERE
                                  }
                          });
                  } else {
                          Window.alert(An error has occurred.  Contact your 
  system
  administrator.);
                  }
          }

          public final void onSuccess(T result) {
                  uponSuccess(result);
          }

          public abstract void uponSuccess(T result);

  }

  /code

  Does anybody know how I can capture the original RPC before it is sent
  so I can resubmit it?

 I suppose Ray Ryan's proposal to use a command pattern for your RPC
 calls [1] would help you in solving it.

 [1]http://code.google.com/events/io/2009/sessions/GoogleWebToolkitBestPr...

-- 
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: problems running application in development mode using -noserver switch and cache.html/nocache.js files not served from the webapp root

2010-02-08 Thread mooreds
Hi Jay,

I think my problem is a bit different, since I explicitly point to a
page with the GWT nocache.js call in it, and still don't connect.

However, moving the GWT up a directory, from /static/gwt to /static,
seemed to enable me to use hosted/development mode.

Thanks,
Dan

On Feb 8, 8:23 am, jdw jwootto...@gmail.com wrote:
 Hey Dan,

 I'm seeing something similar.  I don't know if this is your case but
 this is what I've discovered.  If the url you specify with the -
 startupUrl does NOT point to a page that uses GWT, the FF tab is
 never seen in the development mode window.  Even if you browse to a
 page that uses GWT, you will not see the FF tab and you cannot debug
 the client-side code.  If the -startupUrl points to a page that uses
 GWT then everything works fine.  I created a post on this problem a
 few weeks ago and I have not seen a response.  If you figure something
 out please post your solution.

 Thanks,
 - Jay

 On Feb 7, 12:52 pm, mooreds moor...@gmail.com wrote:

  Hi folks,

  I'm trying to get GWT 2.0.1 development mode working with the -
  noserver option.  The main issue is that while running in development
  mode, any changes I make in the GWT java classes are not reflected
  when I refresh the browser.

  This is a bit of a nonstandard setup, so let me outline it a bit.

  We have a number of apps that depend on some other cvs modules:

  * gwtapp1
  * gwtapp2
  * gwtlib1
  * gwtlib2

  All of these depend on code running on the server (json files, RPC)
  and I couldn't figure out how to get them working with the built in
  Jetty server.  (For one thing, I couldn't figure out how to have the
  different projects all compile into one WEB-INF/classes directory.)

  gwtapp1 compiles the GWT into the root directory, and works just fine.

  gwtapp2 compiles the GWT into /static/gwt/  One other difference that
  may be relevant is that gwtapp2 uses the cross site linker.  However,
  removing that line from the .gwt.xml file didn't seem to make a
  difference in the behavior.  Another difference is the directory that
  gwtapp2 compiles into actually has 3 different modules in it (but I'm
  not trying to touch any of the other modules).

  It works fine in 'production' mode, when built via ant.  But it
  doesn't work in development mode.

  Here's the arguments I'm using for the eclipse launcher:

  -noserver -startupUrlhttp://localhost:8080/HomePage.do
  com.foo.gwtapp2 (I've tried different URLs, including a static html
  page)

  The GWT development mode window pops up just fine, but I never see the
  'FF' tab pop up when I click 'launch default browser'.  I do see this
  url in the browser window:  
  http://localhost:8080/HomePage.do?gwt.codesvr=192.168.3.103:9997

  I see no messages in the development mode window.  However, when I
  turn the logLevel up to DEBUG (-logLevel DEBUG) I see the 'Loading
  Modules' line.  When I am working with gwtapp1 (which works) I also
  see a 'Connection received from xxx.xxx.xxx.xxx' message.

  Before the 'Connection recieved', I see the following TRACE messages
  when running either app:

      00:00:02.078  [TRACE] Invoking Linker RPC policy file manifest
      00:00:02.078  [TRACE] Invoking Linker Standard
        00:00:02.094  [DEBUG] Attempting to optimize JS
      00:00:02.141  [TRACE] Invoking Linker Export CompilationResult
  symbol maps
      00:00:02.141  [TRACE] Invoking Linker Emit compile report
  artifacts
      00:00:02.141  [TRACE] Linking compilation into C:\eclipse-workspace
  \account\war\com.foo.gwtapp[12]

  I imagine that the Connection is the issue, but am not quite sure how
  to debug it.

  I've installed the Google FF plugin, and am using FF 3.6.  This is an
  old project so it was not created with the google eclipse plugin.
  Running on eclipse 3.4.2 on Windows XP, if that matters.

  I've reviewed this 
  FAQ:http://code.google.com/webtoolkit/doc/latest/FAQ_DebuggingAndCompilin...

  and made sure that I have all the .rpc files in the /static/gwt
  directory.  This directory is browser accessible (ie, when I put a
  file here:http://localhost:8080/static/gwt/a.txt, I can read it with
  my browser).

  I also played around with the -codeServerPort argument, but that
  didn't seem to make any difference.  In the thought that it was
  perhaps a urlrewrite issue (gwtapp2 does some url rewriting) I put a
  static html file in the /static/gwt directory, but that still didn't
  lead to a Connection being made.

  I have done some searching on the web and in the GWT google group, but
  haven't found much else.  I also didn't find anything when searching
  through the bug list.

  What am I missing?  Can anyone give me further places I should look or
  ideas?

  Thanks,
  Dan

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

Re: onHistoryChanged() not being called on hitting the Back Button (or even calling History.back())

2010-02-08 Thread obesga
Quick response: in GWT2.0, use

History.addValueChangeHandler(ValueChangeHandlerjava.lang.String
handler)

that is not deprecated

Try use
History.newItem(page + tabIndex,false);

to avoid firing event, this may be the cause

Hope that helps

Oscar

On Feb 7, 9:19 am, AM musicophil...@gmail.com wrote:
 Hi,
 I am running into this weird issue where the onHistoryChanged() isn't
 being called when I hit the browser's back button or even if I call
 History.back(). I am testing this in the hosted mode (even running it
 in firefox yields me the same result). The strange thing is, if I call
 History.back() thrice - looks like it calls onHistoryChanged() on the
 third request - it is quite confusing and I was hoping if someone
 could shed some light on this issue that I am running into.

 I am using GWT 1.5 and to demonstrate my case, I'll use the example in
 the GWT-1.5 tutorial (http://preview.tinyurl.com/6grjh2)

 // Excluding imports for brevity

 // Entry point classes define codeonModuleLoad()/code.
 public class BrowserHistoryExample implements EntryPoint {

   TabPanel tabPanel;

   public void onModuleLoad() {

     tabPanel = new TabPanel();

     int tabIndex = 0;

     // A Ext-GWT ContentPanel
 (com.extjs.gxt.ui.client.widget.ContentPanel)
     ContentPanel cp = new ContentPanel();
     cp.addText(Page1);
     tabPanel.add(cp, Page1);

     cp = new ContentPanel();
     cp.addText(Page2);
     tabPanel.add(cp, Page2);

     Button backButton = new Button(Back);
     backButton.addClickListener(new ClickListener () {

                 public void onClick(Widget arg0) {
                     System.out.println(Going back now ...);

                     History.back();

                     // Commenting this for now ...
                     // but on un-commenting, the third call to
 History.back() seems to invoke onHistoryChanged()
                     // History.back();
                     // History.back();
                 }
     });
     cp = new ContentPanel();
     cp.addText(Page3);
     cp.add(backButton);
     tabPanel.add(cp, Page3);

     tabPanel.addTabListener(new TabListener() {

       public boolean onBeforeTabSelected(SourcesTabEvents sender, int
 tabIndex) {
         return true;
       }

       public void onTabSelected(SourcesTabEvents sender, int tabIndex)
 {
           // Push an item onto the history stack
           System.out.println(Pushing tabIndex:  + tabIndex +  on the
 stack);
           History.newItem(page + tabIndex);
       }
     });

     History.addHistoryListener(new HistoryListener() {

       public void onHistoryChanged(String historyToken) {

           System.out.println(Got token:  + historyToken);

         // Parse the history token
         try {
           if (historyToken.substring(0, 4).equals(page)) {
             String tabIndexToken = historyToken.substring(4, 5);
             int tabIndex = Integer.parseInt(tabIndexToken);
             // Select the specified tab panel
             tabPanel.selectTab(tabIndex);
           } else {
             tabPanel.selectTab(0);
           }

         } catch (IndexOutOfBoundsException e) {
           tabPanel.selectTab(0);
         }
       }
     });

     tabPanel.selectTab(0);
     RootPanel.get().add(tabPanel);
   }

 }

 So the thing is, when I navigate from Page1 tab to Page2 tab to Page3
 tab - and then when I hit the back button (defined above, which
 simply calls History.back()) - nothing really happens for the first 2
 times I hit the button. Only when I hit it the third time (or
 alternatively call History.back() thrice in the buttonClick event) -
 is the onHistoryChanged() method invoked.

 Again, it would be great if someone could help me figure out whats
 going on?

 Thanks!

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



Re: Remote procedure calls in gwt project

2010-02-08 Thread obesga
Really the first, but don't forget to use the annotation

@RemoteServiceRelativePath(servletFacadeService)
public interface ServletFacadeService

On Feb 7, 9:22 pm, Firas firas.ism...@gmail.com wrote:
 Hi,

 I am trying to study Google web-tool kit and will be thankful for some
 help,

 while using remote procedure call i found that they were presented in
 two ways, one is the demo service when installing a new gwt project
 and other that i found in examples,
 the one in demo application you have it, the other is this one :

 ServletFacadeServiceAsync servletFacadeServiceAsync =
 (ServletFacadeServiceAsync) GWT
         .create(ServletFacadeService.class);

 ServiceDefTarget endpoint = (ServiceDefTarget)
 servletFacadeServiceAsync;
 endpoint.setServiceEntryPoint(GWT.getModuleBaseURL() + /facade);

 i would like to know why this one worked for me in maven project,
 while the demo made my life like hill :):):)

 i just cant understand why it didn't work with maven project, although
 it works perfectly with gwt project,
 please help me to understand the deference between them and why it
 didn't work with maven.

 thanks in advance.

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



Re: How to resubmit RPC after session timeout/login

2010-02-08 Thread Thomas Broyer


On 8 fév, 18:15, Jamie jsgreenb...@gmail.com wrote:
 Can you give me an example on how I'd be able to resubmit an RPC with
 Ray's command pattern approach?

I cannot give you a working example, but you'd likely queue all issued
commands and only dequeue them onSuccess. When you think you have to
resubmit your commands, you just have to go through the queue. This is
because the command is self descriptive: it contains all the
necessary information that's needed.

Ray explained that this same pattern also allows you to easily undo
commands (easily on the client side, of course) and to batch commands
to limit the number of requests sent to the server; not to mention
offline mode (you'd save commands in a localStorage or similar offline
storage so they can be submitted when you go back online)

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



Re: GWT 2.0.1 out but Eclipse says There is nothing to update

2010-02-08 Thread Chris Lercher
On Feb 5, 4:41 pm, Rajeev Dayal rda...@google.com wrote:
 Actually, the problem is that when we release a new SDK, the feature id
 changes,

I'm curious: Why do you change it? If I understand it correctly,
Eclipse features shouldn't contain the version number as a part of
their feature id. The feature.xml offers a separate 'version'
attribute.

-- 
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: problems running application in development mode using -noserver switch and cache.html/nocache.js files not served from the webapp root

2010-02-08 Thread mooreds
Another issue I ran into was using the XS linker causes development
mode to stop working.  Apparently this is a known issue:

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

On Feb 8, 10:26 am, mooreds moor...@gmail.com wrote:
 Hi Jay,

 I think my problem is a bit different, since I explicitly point to a
 page with the GWT nocache.js call in it, and still don't connect.

 However, moving the GWT up a directory, from /static/gwt to /static,
 seemed to enable me to use hosted/development mode.

 Thanks,
 Dan

 On Feb 8, 8:23 am, jdw jwootto...@gmail.com wrote:

  Hey Dan,

  I'm seeing something similar.  I don't know if this is your case but
  this is what I've discovered.  If the url you specify with the -
  startupUrl does NOT point to a page that uses GWT, the FF tab is
  never seen in the development mode window.  Even if you browse to a
  page that uses GWT, you will not see the FF tab and you cannot debug
  the client-side code.  If the -startupUrl points to a page that uses
  GWT then everything works fine.  I created a post on this problem a
  few weeks ago and I have not seen a response.  If you figure something
  out please post your solution.

  Thanks,
  - Jay

  On Feb 7, 12:52 pm, mooreds moor...@gmail.com wrote:

   Hi folks,

   I'm trying to get GWT 2.0.1 development mode working with the -
   noserver option.  The main issue is that while running in development
   mode, any changes I make in the GWT java classes are not reflected
   when I refresh the browser.

   This is a bit of a nonstandard setup, so let me outline it a bit.

   We have a number of apps that depend on some other cvs modules:

   * gwtapp1
   * gwtapp2
   * gwtlib1
   * gwtlib2

   All of these depend on code running on the server (json files, RPC)
   and I couldn't figure out how to get them working with the built in
   Jetty server.  (For one thing, I couldn't figure out how to have the
   different projects all compile into one WEB-INF/classes directory.)

   gwtapp1 compiles the GWT into the root directory, and works just fine.

   gwtapp2 compiles the GWT into /static/gwt/  One other difference that
   may be relevant is that gwtapp2 uses the cross site linker.  However,
   removing that line from the .gwt.xml file didn't seem to make a
   difference in the behavior.  Another difference is the directory that
   gwtapp2 compiles into actually has 3 different modules in it (but I'm
   not trying to touch any of the other modules).

   It works fine in 'production' mode, when built via ant.  But it
   doesn't work in development mode.

   Here's the arguments I'm using for the eclipse launcher:

   -noserver -startupUrlhttp://localhost:8080/HomePage.do
   com.foo.gwtapp2 (I've tried different URLs, including a static html
   page)

   The GWT development mode window pops up just fine, but I never see the
   'FF' tab pop up when I click 'launch default browser'.  I do see this
   url in the browser window:  
   http://localhost:8080/HomePage.do?gwt.codesvr=192.168.3.103:9997

   I see no messages in the development mode window.  However, when I
   turn the logLevel up to DEBUG (-logLevel DEBUG) I see the 'Loading
   Modules' line.  When I am working with gwtapp1 (which works) I also
   see a 'Connection received from xxx.xxx.xxx.xxx' message.

   Before the 'Connection recieved', I see the following TRACE messages
   when running either app:

       00:00:02.078  [TRACE] Invoking Linker RPC policy file manifest
       00:00:02.078  [TRACE] Invoking Linker Standard
         00:00:02.094  [DEBUG] Attempting to optimize JS
       00:00:02.141  [TRACE] Invoking Linker Export CompilationResult
   symbol maps
       00:00:02.141  [TRACE] Invoking Linker Emit compile report
   artifacts
       00:00:02.141  [TRACE] Linking compilation into C:\eclipse-workspace
   \account\war\com.foo.gwtapp[12]

   I imagine that the Connection is the issue, but am not quite sure how
   to debug it.

   I've installed the Google FF plugin, and am using FF 3.6.  This is an
   old project so it was not created with the google eclipse plugin.
   Running on eclipse 3.4.2 on Windows XP, if that matters.

   I've reviewed this 
   FAQ:http://code.google.com/webtoolkit/doc/latest/FAQ_DebuggingAndCompilin...

   and made sure that I have all the .rpc files in the /static/gwt
   directory.  This directory is browser accessible (ie, when I put a
   file here:http://localhost:8080/static/gwt/a.txt, I can read it with
   my browser).

   I also played around with the -codeServerPort argument, but that
   didn't seem to make any difference.  In the thought that it was
   perhaps a urlrewrite issue (gwtapp2 does some url rewriting) I put a
   static html file in the /static/gwt directory, but that still didn't
   lead to a Connection being made.

   I have done some searching on the web and in the GWT google group, but
   haven't found much else.  I also didn't find anything when searching
   through the bug list.

   What am I 

Re: onHistoryChanged() not being called on hitting the Back Button (or even calling History.back())

2010-02-08 Thread AM
Hi Obsega - my company has bought the licenses for Ext-GWT 1.0 - which
is not compatible with GWT2.0. To upgrade to GWT2.0, we'd have to
upgrade our ExtGWT licenses to ExtGWT3.0 - and since I am the only one
using this toolkit now and need this upgrade only for the History
functionality, I am not very optimistic if we'd be upgrading the
ExtGWT licenses :-(

I know its annoying to ask questions about an older version - but I
have no other option in this case. Anyone .. any clues what might be
going on??

Thanks!

On Feb 8, 9:39 am, obesga obe...@gmail.com wrote:
 Quick response: in GWT2.0, use

 History.addValueChangeHandler(ValueChangeHandlerjava.lang.String
 handler)

 that is not deprecated

 Try use
 History.newItem(page + tabIndex,false);

 to avoid firing event, this may be the cause

 Hope that helps

 Oscar

 On Feb 7, 9:19 am, AM musicophil...@gmail.com wrote:

  Hi,
  I am running into this weird issue where the onHistoryChanged() isn't
  being called when I hit the browser's back button or even if I call
  History.back(). I am testing this in the hosted mode (even running it
  in firefox yields me the same result). The strange thing is, if I call
  History.back() thrice - looks like it calls onHistoryChanged() on the
  third request - it is quite confusing and I was hoping if someone
  could shed some light on this issue that I am running into.

  I am using GWT 1.5 and to demonstrate my case, I'll use the example in
  the GWT-1.5 tutorial (http://preview.tinyurl.com/6grjh2)

  // Excluding imports for brevity

  // Entry point classes define codeonModuleLoad()/code.
  public class BrowserHistoryExample implements EntryPoint {

    TabPanel tabPanel;

    public void onModuleLoad() {

      tabPanel = new TabPanel();

      int tabIndex = 0;

      // A Ext-GWT ContentPanel
  (com.extjs.gxt.ui.client.widget.ContentPanel)
      ContentPanel cp = new ContentPanel();
      cp.addText(Page1);
      tabPanel.add(cp, Page1);

      cp = new ContentPanel();
      cp.addText(Page2);
      tabPanel.add(cp, Page2);

      Button backButton = new Button(Back);
      backButton.addClickListener(new ClickListener () {

                  public void onClick(Widget arg0) {
                      System.out.println(Going back now ...);

                      History.back();

                      // Commenting this for now ...
                      // but on un-commenting, the third call to
  History.back() seems to invoke onHistoryChanged()
                      // History.back();
                      // History.back();
                  }
      });
      cp = new ContentPanel();
      cp.addText(Page3);
      cp.add(backButton);
      tabPanel.add(cp, Page3);

      tabPanel.addTabListener(new TabListener() {

        public boolean onBeforeTabSelected(SourcesTabEvents sender, int
  tabIndex) {
          return true;
        }

        public void onTabSelected(SourcesTabEvents sender, int tabIndex)
  {
            // Push an item onto the history stack
            System.out.println(Pushing tabIndex:  + tabIndex +  on the
  stack);
            History.newItem(page + tabIndex);
        }
      });

      History.addHistoryListener(new HistoryListener() {

        public void onHistoryChanged(String historyToken) {

            System.out.println(Got token:  + historyToken);

          // Parse the history token
          try {
            if (historyToken.substring(0, 4).equals(page)) {
              String tabIndexToken = historyToken.substring(4, 5);
              int tabIndex = Integer.parseInt(tabIndexToken);
              // Select the specified tab panel
              tabPanel.selectTab(tabIndex);
            } else {
              tabPanel.selectTab(0);
            }

          } catch (IndexOutOfBoundsException e) {
            tabPanel.selectTab(0);
          }
        }
      });

      tabPanel.selectTab(0);
      RootPanel.get().add(tabPanel);
    }

  }

  So the thing is, when I navigate from Page1 tab to Page2 tab to Page3
  tab - and then when I hit the back button (defined above, which
  simply calls History.back()) - nothing really happens for the first 2
  times I hit the button. Only when I hit it the third time (or
  alternatively call History.back() thrice in the buttonClick event) -
  is the onHistoryChanged() method invoked.

  Again, it would be great if someone could help me figure out whats
  going on?

  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.



Error loading my app

2010-02-08 Thread BR
I get this while loading my app. Anyone knows what it might be caused
by? This is GWT 2.0, on MacOS X Snow Leopard, in OOPHM:

00:04:00.123 [ERROR] Uncaught exception escaped
com.google.gwt.core.client.JavaScriptException: (NS_ERROR_FAILURE):
Component returned failure code: 0x80004005 (NS_ERROR_FAILURE)
[nsIDOMHTMLSelectElement.selectedIndex]  QueryInterface: function
QueryInterface() { [native code] }  result: 2147500037  filename:
http://test.taskdock.com:  lineNumber: 62  columnNumber: 0  inner:
null  data: null  initialize: function initialize() { [native
code] } at
com.google.gwt.dev.shell.BrowserChannelServer.invokeJavascript(BrowserChannelServer.java:
195)at
com.google.gwt.dev.shell.ModuleSpaceOOPHM.doInvoke(ModuleSpaceOOPHM.java:
120)at
com.google.gwt.dev.shell.ModuleSpace.invokeNative(ModuleSpace.java:
507)at
com.google.gwt.dev.shell.ModuleSpace.invokeNativeObject(ModuleSpace.java:
264)at
com.google.gwt.dev.shell.JavaScriptHost.invokeNativeObject(JavaScriptHost.java:
91) at com.google.gwt.core.client.impl.Impl.apply(Impl.java)at
com.google.gwt.core.client.impl.Impl.entry0(Impl.java:188)  at
sun.reflect.GeneratedMethodAccessor52.invoke(Unknown Source)at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:
25) at java.lang.reflect.Method.invoke(Method.java:585) at
com.google.gwt.dev.shell.MethodAdaptor.invoke(MethodAdaptor.java:103)
at com.google.gwt.dev.shell.MethodDispatch.invoke(MethodDispatch.java:
71) at
com.google.gwt.dev.shell.OophmSessionHandler.invoke(OophmSessionHandler.java:
157)at
com.google.gwt.dev.shell.BrowserChannel.reactToMessages(BrowserChannel.java:
1668)   at
com.google.gwt.dev.shell.BrowserChannelServer.processConnection(BrowserChannelServer.java:
401)at
com.google.gwt.dev.shell.BrowserChannelServer.run(BrowserChannelServer.java:
222)at java.lang.Thread.run(Thread.java:613)

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



Re: MVP nested presenters

2010-02-08 Thread Sydney
Thanks for your insight. I was wondering how the flat lookup approach
would work. When the application starts the MainContainerPresenter
would be created and the go method would be called with a
RootLayoutPanel as a parameter. What I don't see is where the other
presenters would be created, and how to wire up everything together.
Also another topic I am experiencing problems is how to implement view
transition. For instance a click on a button can modify part of the
UI. I was thinking about using custom events (using the event bus)
that presenters would listen to.

On Feb 7, 12:17 pm, Jesse Dowdle dowdl...@gmail.com wrote:
 We have discussed this issue at length on our team, as we're building
 an application that will eventually grow to be quite large. There are
 certainly pros and cons to each approach (nesting presenters vs a flat
 lookup at the AppController level).

 Nested Pros
 Handy place to hook up a hierarchical location change framework
 Chain of responsibility for loading data (parents can load data from
 an rpc and pass it down to child presenters to ensure state is
 maintained)
 Easy re-use of groups of presenters, flexibility to mix and match.
 Plays well with nested display objects, so if you've got a TabPanel,
 each tab can be driven by a separate presenter and the panel itself
 can have a presenter to load data common to all tabs.

 Nested Cons
 Can be more difficult to analyze the layout of the application without
 a single class where all presenter relationships are defined
 Does not play well with view classes which have components that need
 to be driven by multiple presenters. For example, if you have a ui.xml
 with two main areas and you want a presenter to handle each, using
 nested presenters requires more spaghetti code that just having a
 couple of flat ones.
 It can be more difficult to write unit tests against parent
 presenters, because you have to take into account instantiation and
 operation of child presenters... This can impact the complexity of the
 mock objects you must create.

 Anyway, we've chosen to go with nested presenters, but I would say the
 vote on our team for this was split 4/2, so clearly even for us not
 everybody is in love with it.

 On Feb 5, 5:00 pm, Sydney sydney.henr...@gmail.com wrote:



  I try to implement the best practices discussed in the article Large
  scale application development and MVP. My application is designed
  using several widgets:
  MainContainerWidget: a DockLayoutPanel
  NorthWidget: a widget in the north region of the main container
  CenterWidget: a widget in the center region of the main container.
  This widget is a composite of two widget (TopWidget and BottomWidget)
  SouthWidget: a widget in the south region of the main container.

  1/ I created a Presenter for each widget. The CenterPresenter contains
  a TopPresenter and a BottomPresenter that are instanciated in the
  constructor of CenterPresenter.

      public CenterPresenter(HandlerManager eventBus, Display display) {
        this.eventBus = eventBus;
        this.display = display;
        topPresenter = new TopPresenter(eventBus, new TopWidget());
        bottomPresenter = new BottomPresenter(eventBus, new
  BottomWidget());
      }

      @Override
      public void go(HasWidgets container) {
          bind();
          container.clear();
          container.add(display.asWidget());
      }

      private void bind() {
        topPresenter.bind();
        bottomPresenter.bind();
      }

  So basically when the CenterPresenter is created in the AppController
  class, it would create all its child presenters and call the bind
  methods. Does it seem a good approach or is there a better way?

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



Using RequestBuilder to request from local file system

2010-02-08 Thread vanfleet
Hi, I'm trying to use RequestBuilder to pull html files off my local
system and I'm getting the ...file.html is invalid or violates the
same-origin security restriction error in IE 7, but in Firefox 3.5.7
it works fine. When I setup the call I'm using:

  String url=GWT.getHostPageBaseURL() + file.html;
  RequestBuilder builder = new RequestBuilder(RequestBuilder.GET,url);

Since I'm not working off a server the url looks something like:

  file:///D:/some/dir/MyGWTApp/file.html

Since the file I'm trying to get is in the same space as the GWT
application I don't understand why it would be violating the same-
origin security restriction. I know that Ajax can do this, I've done
it before using Dojo.

My problem here is that I have a requirement that documentation be
shipped to customers on a CD rather than being accessed on the web.
What can I do to fix this, any help would be greatly appreciated.

Thanks,
David

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



Re: MVP nested presenters

2010-02-08 Thread Joe Cheng
On my project I used Gin to wire up nested presenters/views, it is very
nice. I wouldn't dream of doing large-scale MVP now without dependency
injection--it really takes a lot of tedious wiring code out. This book
helped a lot for me:
http://www.amazon.com/Dependency-Injection-Dhanji-R-Prasanna/dp/193398855X

On Mon, Feb 8, 2010 at 10:55 AM, Sydney sydney.henr...@gmail.com wrote:

 Thanks for your insight. I was wondering how the flat lookup approach
 would work. When the application starts the MainContainerPresenter
 would be created and the go method would be called with a
 RootLayoutPanel as a parameter. What I don't see is where the other
 presenters would be created, and how to wire up everything together.
 Also another topic I am experiencing problems is how to implement view
 transition. For instance a click on a button can modify part of the
 UI. I was thinking about using custom events (using the event bus)
 that presenters would listen to.

 On Feb 7, 12:17 pm, Jesse Dowdle dowdl...@gmail.com wrote:
  We have discussed this issue at length on our team, as we're building
  an application that will eventually grow to be quite large. There are
  certainly pros and cons to each approach (nesting presenters vs a flat
  lookup at the AppController level).
 
  Nested Pros
  Handy place to hook up a hierarchical location change framework
  Chain of responsibility for loading data (parents can load data from
  an rpc and pass it down to child presenters to ensure state is
  maintained)
  Easy re-use of groups of presenters, flexibility to mix and match.
  Plays well with nested display objects, so if you've got a TabPanel,
  each tab can be driven by a separate presenter and the panel itself
  can have a presenter to load data common to all tabs.
 
  Nested Cons
  Can be more difficult to analyze the layout of the application without
  a single class where all presenter relationships are defined
  Does not play well with view classes which have components that need
  to be driven by multiple presenters. For example, if you have a ui.xml
  with two main areas and you want a presenter to handle each, using
  nested presenters requires more spaghetti code that just having a
  couple of flat ones.
  It can be more difficult to write unit tests against parent
  presenters, because you have to take into account instantiation and
  operation of child presenters... This can impact the complexity of the
  mock objects you must create.
 
  Anyway, we've chosen to go with nested presenters, but I would say the
  vote on our team for this was split 4/2, so clearly even for us not
  everybody is in love with it.
 
  On Feb 5, 5:00 pm, Sydney sydney.henr...@gmail.com wrote:
 
 
 
   I try to implement the best practices discussed in the article Large
   scale application development and MVP. My application is designed
   using several widgets:
   MainContainerWidget: a DockLayoutPanel
   NorthWidget: a widget in the north region of the main container
   CenterWidget: a widget in the center region of the main container.
   This widget is a composite of two widget (TopWidget and BottomWidget)
   SouthWidget: a widget in the south region of the main container.
 
   1/ I created a Presenter for each widget. The CenterPresenter contains
   a TopPresenter and a BottomPresenter that are instanciated in the
   constructor of CenterPresenter.
 
   public CenterPresenter(HandlerManager eventBus, Display display) {
 this.eventBus = eventBus;
 this.display = display;
 topPresenter = new TopPresenter(eventBus, new TopWidget());
 bottomPresenter = new BottomPresenter(eventBus, new
   BottomWidget());
   }
 
   @Override
   public void go(HasWidgets container) {
   bind();
   container.clear();
   container.add(display.asWidget());
   }
 
   private void bind() {
 topPresenter.bind();
 bottomPresenter.bind();
   }
 
   So basically when the CenterPresenter is created in the AppController
   class, it would create all its child presenters and call the bind
   methods. Does it seem a good approach or is there a better way?

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



Authenticate before loading the application

2010-02-08 Thread Simon
I would like to authenticate the user before sending him all the GWT
javascript.

I mean, I rely on Google UserService, which I filter with my own
database of users.
If the user is logged on Google, I want my app to get the user's info
from UserService, then load the app if the user is granted, or
redirect him if he is not.

To do that I think about moving the welcome page with the application
javascript into a servlet, and to do the authentication there.

Is it ok for GWT / do you have any better solution to do that ?

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



service implementation for GWT best practice

2010-02-08 Thread bhomass
On Ray Ryan's presentation, there is no sample code for implementation
of the ContactsService.

The code structure would look something like

public class ContactsServiceImpl implements RTSService {

@Override
public T extends Response T execute(ActionT action) {
// TODO Auto-generated method stub
return null;
}

}

I am wondering how do you use one execute to implement server side
functions for all the possible actions? do you use a factory method to
identify the action class and send the request off to different
utility classes to process?

-- 
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: Exceptions in Event Handlers(inner classes) are not shown by Dev Mode Panel in Eclipse!

2010-02-08 Thread J-Pro
Thanks, Sanjiv Jivan, due to your post in SmartGWT forum, I'm now able
to see those exceptions!

For those who is interested in it too, here is Sanjiv's quote about
how to solve it:
--
I've just checked in a bunch of code changes that incorporates proper
exception handling of uncaught exceptions. Please pick up the latest
build from SVN or nightly build (see FAQ sticky).

Note that while the change is backward compatible with GWT versions
lower than 2.0, you'll only be able to see the benefits of this
improved exception handling with GWT 2.0 and above.

If you want custom handling of uncaught exceptions you can register
your own UncaughtExceptionHandler with
GWT.setUncaughtExceptionHandler(..). Otherwise a default one is
already setup that displays the details of the error as an alert when
running in Dev Mode as well as the entire stack trace display in the
Dev. Console.

This is a significant improvement that I'm really happy about. Please
try out the latest build and let me know if you have any issues or are
seeing cases where exceptions are not captured.
--

Thank you very much again, Sanjiv, you've helped a lot!


On Feb 7, 2:03 am, Sanjiv Jivan sanjiv.ji...@gmail.com wrote:
 J-Pro,
 I've got some suggestions from John Tamplin on this and will be
 incorporating them in SmartGWT in a few days so this should be resolved
 soon. I see you've posted on the SmartGWT forum as well. I'll follow up with
 you on that thread.

 Thanks,
 Sanjiv

 On Fri, Feb 5, 2010 at 10:06 AM, Joel Webber j...@google.com wrote:
  This may be a problem with SmartGWT. I'm not familiar with the details of
  how they deal with wrapping events from the native SmartClient widgets, but
  if they fail to properly punt exceptions to the UncaughtExceptionHandler,
  dev mode will eat the exceptions.

  On Thu, Feb 4, 2010 at 12:58 PM, J-Pro jpro@gmail.com wrote:

  Good afternoon, dear GWT group members!

  I've noticed that if I create an event handler, for example

  ButtonItem btnSubmit = new ButtonItem();
  btnSubmit.addClickHandler(new
  com.smartgwt.client.widgets.form.fields.events.ClickHandler()
  {
    �...@override
     public void
  onClick(com.smartgwt.client.widgets.form.fields.events.ClickEvent
  event)
     {
       int i = 5/0;
     }
  });

  I can't see the problem in the Development Mode Panel in the Eclipse.
  The last record there is Module has been loaded. The application
  itself behaves just as if nothing happened. You can try it by
  yourself.

  But if only I put int i = 5/0; after ButtonItem declaration, i.e.
  not in inner class, the exception will be described in Development
  Mode Panel.

  Having this, it's very hard to catch errors... Can you advise anything
  to me? Or is it a bug?

  I use Eclipse 3.5 SR1, Google Plugin 1.2.0, GWT Toolkit SDK 2.0.1,
  smartgwt 2.0, latest Firefox and Windows 7 x64 Ultimate.

  Thank you very much in advance!

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

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

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



Re: Maven users survey

2010-02-08 Thread olivier nouguier
Hi Keith,
 Great great !!!
 In fact currently it may works but it is need some twix in the WTP metadata
project file. BTW it a very comfortable environment, where it is easy and
efficient to test general integration (WEB1 + WEB2). Very efficient, because
you can choose or not to debug client/server part, so it can (re)start very
quickly.
 The only small issue I have is that I have to add the extra gwt.codesvr
parameter to use the dev mode, will it be still the case with GEP 1.3 or
could we activate/force the usage of dev mode without altering the url ?

Many many thx for GWT.
Best regards,
Olivier

On Fri, Feb 5, 2010 at 4:22 PM, Keith Platfoot kplatf...@google.com wrote:

 Hi Olivier,

 GPE 1.3 should be compatible with WTP/Eclipse EE.  For example, you'll be
 able to easily add GWT and/or App Engine to an existing Dynamic Web Project,
 and then debug the application using the GPE Web Application launch
 configurations.  For GWT projects that have a separate backend (e.g. an
 existing Tomcat or Jetty instance), you will be able to launch your GWT
 font-end in the existing server, so you can debug both client-side code and
 server-side code simultaneously.  If you change your GWT code during a
 debugging session, you can refresh to get the updates immediately, and of
 course do the same for server-side code and static resources changes as well
 (if your server adapter supports it).

 Keith

 On Fri, Feb 5, 2010 at 3:17 AM, olivier nouguier 
 olivier.nougu...@gmail.com wrote:

 Thx a lot for all this, it will clearly simplify GWT with Maven, but did
 you plan to add some WTP support in the next GEP release ?


 On Thu, Feb 4, 2010 at 8:33 PM, Keith Platfoot kplatf...@google.comwrote:

 Yes, I've been meaning to reply back to this thread.  Thanks for
 reminding me, Brian! :-)

 Our plans for the next release of the Google Plugin for Eclipse (1.3)
 include 4 changes designed to make integration with Maven and J2EE projects
 easier:

1. The WAR directory can now be configured to be *any*project-relative 
 path (e.g.
src/main/webapp if you're using Maven).  You'll also be able to
specify whether that directory is source-only (typical Maven/J2EE 
 scenario),
or whether it should also function as the WAR output directory from 
 which to
run/debug or deploy to App Engine.  If your WAR directory is input *
and* output (which will remain the default for new Web App projects),
the plugin will manage synchronizing the contents of WEB-INF/lib
WEB-INF/classes with your project's build path and compiled output.
 Otherwise, we'll leave your WAR source directory alone and you'll need 
 to
specify your WAR output location when launching, deploying, etc (the 
 plugin
will remember the location once you set it the first time).
2. The Web App launch configuration UI is being redesigned to allow
you to see, and if necessary change, *any* of the launch arguments.
 Previously, we were waiting until launch time to set many of these
arguments based on heuristics that were invisible and inaccessible to 
 you.
 Now you'll be in full control of how your projects get launched.  Also,
we're adding the capability to automatically migrate your launch
configurations when necessary, for example, updating the -javaagent flag
when changing App Engine SDKs.
3. GWT/App Engine projects will no longer require our SDK library on
the classpath.  This means Maven users will be able to pull in JAR files
from their M2 repository as they're accustomed to and the plugin won't 
 mind
a bit.
4. The severity of any problem marker generated by the plugin will be
fully customizable via an Errors/Warnings preference page (similar to the
Java Errors/Warnings page), letting you specify either Error, Warning, or
Ignore.

 We'll also be including a few smaller features and bug fixes as well.

 What does everyone think about the 4 changes outlined above?  We've been
 testing the plugin against various Maven and J2EE configurations to try to
 ensure that we've eliminated the most critical roadblocks.  However, we're
 very interested in also having you folks take it for a spin before the
 official release date (slated for next month).  We're not quite ready yet,
 but stay tuned for a 1.3 preview build to be made available hopefully in a
 few weeks.  We'll distribute it as a zip file for dropin 
 installationhttp://code.google.com/eclipse/docs/install-from-zip.html so
 it will come with the standard warnings and caveats (use with a clean
 Eclipse install and workspace, use at your risk, etc.).  However, it will
 hopefully give you a chance to give us any last-minute feedback about our
 changes before the final release.

 Thanks,

 Keith

 On Thu, Feb 4, 2010 at 12:55 PM, bkbonner brian.bon...@paraware.comwrote:

 Keith, are you going to give the folks who replied to your message
 some sort of thoughts on what you're going to implement and hopefully
 let us try 

Re: Client Bundle and Image Internationalization

2010-02-08 Thread Christian Goudreau
Ok... it's working in dev mode, I don't know why it didnt when going live,
I'll do some more test and come back later

On Mon, Feb 8, 2010 at 12:02 PM, Christian Goudreau 
goudreau.christ...@gmail.com wrote:

 There's an example of what I have :

 Inside the client bundle :

 ImageResource example();

 and in my directory I have : exemple.png
 exemple_fr_CA.png
 exemple_en_CA.png

 and when I set the local to fr_CA, I have exemple.png instead...

 On Sun, Feb 7, 2010 at 10:20 PM, Christian Goudreau 
 goudreau.christ...@gmail.com wrote:

 I know how to implements localizable images with Image bundle, but how
 does it works with Client Bundle ? I found nothing about that in the
 documentation and I was wondering what was the best way to acheive this with
 Gwt 2.0.

 Thx

 Christian




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



struts integration problem

2010-02-08 Thread crojay78
Hi,

I was able to put my client code stuff of my gwt-app into my existing
Struts 1.2.x . So far so good, but now I am stuck on the integration
of my rpc-services into my struts app. I created a jar file of the
server class files and put it into my struts app also i configured the
servlet in the web.xml. I can call the configured url pattern of the
servlet and it will not produce an error in the logs so i guess its
valid configured. My problem is that my gwt client area of the struts
app does not use the rpc's, normally it should load user properties
from the databaseDid I miss an additionally configuration which is
necessary so that the gwt stuff works together?

Hope somebody can help me!

Best Regards

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



Bug in Browsers that's Not in Hosted Mode

2010-02-08 Thread Geoffrey Wiseman
I'm just encountering my first piece of code that works fine in hosted
mode (GWT 1.7.1) but totally fails on every browser I try it in.  I
guess that means I'm going to have to debug the Javascript that I
didn't write, since I can't debug in hosted mode.  If someone's been
through this already and wants to pass on any tips, I'm all ears.  Are
there common reasons why this might happen?  Known Issues?

Just looking for general feedback, although I'm happy to return with
more information once I've tracked down the problem.

-- 
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: Authenticate before loading the application

2010-02-08 Thread Youngster
Did you have a look at this page:
http://code.google.com/appengine/docs/java/config/webxml.html#Security_and_Authentication
?

-- 
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: Authenticate before loading the application

2010-02-08 Thread Simon
Yes that is the basics of app engine security. I use it to get the
Google account of the user.

This is the first step of the login: Google authentication.
Second step I want to validate the Google account against my own set
of users,
Last step I want to send to the user the whole javascript app.

On 8 fév, 23:04, Youngster aecdej...@gmail.com wrote:
 Did you have a look at this 
 page:http://code.google.com/appengine/docs/java/config/webxml.html#Securit...
 ?

-- 
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: Bug in Browsers that's Not in Hosted Mode

2010-02-08 Thread Geoffrey Wiseman
On Feb 8, 5:04 pm, Geoffrey Wiseman geoffrey.wise...@gmail.com
wrote:
 Just looking for general feedback, although I'm happy to return with
 more information once I've tracked down the problem.

Ah, this is less surprising than I anticipated; I think it boils down
to a regular expression issue, which is definitely a source of known
surprises between hosted mode and browsers.

-- 
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: Adding new event types (touch etc.)

2010-02-08 Thread Thomas Broyer


On 8 fév, 10:17, Thomas Broyer wrote:

 I'm thinking in starting a Wave about how I think event handling
 should be refactored.

Done: https://wave.google.com/wave/#restored:wave:googlewave.com!w%252Bux7zL81XA

Still To Be Continued, and I'll try to work on a patch later on if I
find some time.

-- 
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: Authenticate before loading the application

2010-02-08 Thread Thomas Broyer


On 8 fév, 23:26, Simon sp.ma...@gmail.com wrote:
 Yes that is the basics of app engine security. I use it to get the
 Google account of the user.

 This is the first step of the login: Google authentication.
 Second step I want to validate the Google account against my own set
 of users,
 Last step I want to send to the user the whole javascript app.

You could use a servlet filter to let users in to the app or redirect
them out; or use a servlet or JSP as the host page for the app.

-- 
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: can not set breakpoint

2010-02-08 Thread go canal
I have upgraded JDK to 1.6u18. tried the default project greetService, still 
the same.
 rgds,
canal





From: Jason Parekh jasonpar...@gmail.com
To: google-web-toolkit@googlegroups.com
Sent: Mon, February 8, 2010 11:34:43 PM
Subject: Re: can not set breakpoint

Hi Canal,

What version of Java are you running?
Could you try on a simple project (perhaps the default app created by the 
wizard)?
I'm assuming the breakpoints do not show the checkmark on top of them (when the 
debugger is connected)?

jason


On Sun, Feb 7, 2010 at 8:05 PM, canal goca...@yahoo.com wrote:


hi,
searched the group but still can not make it work - can not set
breakpoint in the client code

i am using Eclipse 3.5, GWT 2.0.1, with plugin. Chrome;

I can not set any breakpoint in the client code - not in the callback,
not in the OnModuleLoad.

Server code is ok.

thanks
canal


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



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



  

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



RootPanel.get().clear does not clear anything

2010-02-08 Thread go canal
[sorry if this is duplicated]

Trying to use RootPanel.get().clear(); but it does not clear anything from the 
page. Here is the HTML file:

  body

!-- OPTIONAL: include this if you want history support --
iframe src=javascript:'' id=__gwt_historyFrame tabIndex='-1' 
style=position:absolute;width:0;height:0;border:0/iframe

!-- RECOMMENDED if your web app will not function without JavaScript 
enabled --
noscript
  div style=width: 22em; position: absolute; left: 50%; margin-left: 
-11em; color: red; background-color: white; border: 1px solid red; padding: 
4px; font-family: sans-serif
Your web browser must have JavaScript enabled
in order for this application to display correctly.
  /div
/noscript

h1/h1

table align=center id=content
  tr style=vertical-align:bottom;
tdimg src=images/logo.png/br/
/td
td style=font-weight: 700; font-size: 1.3em;Login/td
  /tr
  tr
td style=vertical-align: top; color: gray; font-style:italic;bring 
certainty to the uncertainty/td
tddiv id=loginWidget/div/td
  /tr
  tr
td colspan=2
  div style=color: gray; font-style:italic; font-size:0.8em; 
border-top:1px gray solid;metaverse© Copyright 2009-2010/div
/td  
  /tr
  tr
td/td
td style=color:red; id=errorLabelContainer/td
  /tr
/table

  /body

I am expecting that everything in the body will be removed.

rgds,
canal



  

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



Re: I need SOP disabled in GWT 2.0 built-in web server.

2010-02-08 Thread Tatchan
Hi Rob,

Thanks for the tip. I guess it's the same as the -noserver  -
startupUrl isn't it? Anyway, I got an external Apache HTTP server
working.
What I'm saying is that it would be lovely if we have an option to
disable SOP with the built-in web server at least with the localhost
in development mode. That might be easier for some one who have to
work with external legacy services. Furthermore, I feel that debugging
with the built-in web server is more reliable (e.g., changes in code
are usually applied when refreshing the browser, break-points are
usually hit :)

On Feb 8, 9:32 pm, RPB robbol...@gmail.com wrote:
 This works for me in GWT 2.0:
 -Open 'Debug configurations' in eclipse
 -Uncheck 'Run built-in server'
 -Set the port number to your localhost port
 -Run

 Good luck,
 Rob

 On Feb 7, 4:51 am, Tatchan tatcha...@gmail.com wrote:

  Hi all,

  I have to make http request (but not RPC)  to a service which runs in
  a different port on the local host in development mode, which is
  fortunately possible with GWT 1.7 and IE 8 (but not with Firefox 3.5 -
  bad). But now with GWT 2.0 this convenience has gone. Things got
  really complicated and inefficient in terms of development, since I
  have to use an external Apache server with proper proxy configuration
  to make it work. Stuffs have to be deployed to the server usually -
  really bad.
  And, to be frank, I still have problems now, and I wish I had my
  convenience back. I need a simple way to bypass SOP for locally
  development. Could anyone help me please?

  Thanks alot,

  ~Tatchan

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



SuggestBox and HasBlurHandlers

2010-02-08 Thread bestey
Just wondering if there is an easy way to know when focus is lost from
a SuggestBox?
It doesn't implement HasFocusHandlers and HasBlurHandlers but it does
have HasFocus!
Any advice would be appreciated.

Thanks,
Brian

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



Re: MVP nested presenters

2010-02-08 Thread Sydney
For now I don't want to bring Gin or Guice into play because I want to
understand MVP. Then I will put DI to simplify things. Let's say I
have  a basic UI with a north region and a center region of a
DockLayoutPanel. The north region contains a button, when clicking
that button, the center region is updated. I defined the button and
the main layout by using UIBinder.

g:FlowPanel
g:Button ui:field=clickMeButton /
/g:FlowPanel

public class SimpleButtonWidget extends Composite implements
SimpleButtonPresenter.Display {

private static SimpleButtonWidgetUiBinder uiBinder =
GWT.create(SimpleButtonWidgetUiBinder.class);

interface SimpleButtonWidgetUiBinder extends
UiBinderWidget, SimpleButtonWidget {
}

@UiField
Button clickMeButton;

public SimpleButtonWidget() {
initWidget(uiBinder.createAndBindUi(this));
}

@Override
public Widget asWidget() {
return this;
}

@Override
public HasClickHandlers getButton() {
return clickMeButton;
}

}

g:DockLayoutPanelg:north size=45c:SimpleButtonWidget
ui:field=simpleButton//g:north
/g:DockLayoutPanel

public class MainAppContainer extends Composite implements
MainAppContainerPresenter.Display {

private static MainAppContainerUiBinder uiBinder =
GWT.create(MainAppContainerUiBinder.class);

interface MainAppContainerUiBinder extends
UiBinderWidget, MainAppContainer {
}

@UiField
SimpleButtonWidget simpleButton;

public MainAppContainer() {
initWidget(uiBinder.createAndBindUi(this));
}

@Override
public Widget asWidget() {
return this;
}

}

Now the presenters:

public class SimpleButtonPresenter implements Presenter {

public interface Display {
HasClickHandlers getButton();

Widget asWidget();
}

private final HandlerManager eventBus;
private final Display display;

public SimpleButtonPresenter(HandlerManager eventBus, Display
view) {
this.eventBus = eventBus;
this.display = view;
}

@Override
public void go(HasWidgets container) {
bind();
container.clear();
container.add(display.asWidget());
}

public void bind() {
System.out.println(display.getButton().addClickHandler(
new ClickHandler() {

@Override
public void onClick(ClickEvent event) {
System.out.println(Click);
}

}));
System.out.println(Click Registered);
}

}

public class MainAppContainerPresenter implements Presenter {

public interface Display {
Widget asWidget();
}

private final HandlerManager eventBus;
private final Display display;

private final SimpleButtonPresenter simpleButtonPresenter;

public MainAppContainerPresenter(HandlerManager eventBus, Display
view) {
this.eventBus = eventBus;
this.display = view;
simpleButtonPresenter = new SimpleButtonPresenter(eventBus,
new SimpleButtonWidget());
}

@Override
public void go(HasWidgets container) {
bind();
container.clear();
container.add(display.asWidget());
}

public void bind() {
simpleButtonPresenter.bind();
}
}

The App Controller:
presenter = new MainAppContainerPresenter(eventBus, new
MainAppContainer());
presenter.go(container);

When the MainAppContainerPresenter is created, a MainAppContainer is
passed which also creates a SimpleButtonWidget. Now inside the
constructor of MainAppContainerPresenter, I create a
SimpleButtonPresenter along with a SimpleButtonWidget. I am sure I am
doing something wrong because I guess I should only create one
SimpleButtonWidget and it should be linked to the
SimpleButtonPresenter.

When I click on the button I want to update the center region of the
DockLayoutPanel. In the click handler I will fire a custom event using
the event bus. Who should listen to that event, the presenter that
will have to update its content, in that case
MainAppContainerPresenter? In the presenter which captures that event,
how do I get a hold of a specific region of the DockLayoutPanel in the
Display interface?

I am sorry to ask so much questions but I struggle with the MVP
pattern.

On Feb 8, 2:28 pm, Joe Cheng j...@joecheng.com wrote:
 On my project I used Gin to wire up nested presenters/views, it is very
 nice. I wouldn't dream of doing large-scale MVP now without dependency
 injection--it really takes a lot of tedious wiring code out. This book
 helped a lot for 
 me:http://www.amazon.com/Dependency-Injection-Dhanji-R-Prasanna/dp/19339...



 On Mon, Feb 8, 2010 at 10:55 AM, Sydney sydney.henr...@gmail.com wrote:
  Thanks for your insight. I was wondering how the flat lookup approach
  would work. When the application starts the MainContainerPresenter
  would be created and the go method would be called 

Any Google Wave developers in this group?

2010-02-08 Thread Jonas Huckestein
Hi guys,

I was wondering if there were enough wave developers around here that
use gwt so that we could start our own group. I feel that in both the
Wave API group and in this one messages on that subject tend to go
unnoticed.

Anybody interested?

I am about to publish my own mock implementation of the Wave API for
GWT that I made to locally test my gadgets, but I guess I might not be
the only one.

Cheers,
Jonas
--
Jonas Huckestein

http://thezukunft.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: Authenticate before loading the application

2010-02-08 Thread Akash Gupta
http://code.google.com/p/google-web-toolkit/wiki/CodeSplitting

You could use code-splitting for the purpose. If user is authenticated then
send him js code.. else don't.



On Tue, Feb 9, 2010 at 5:08 AM, Thomas Broyer t.bro...@gmail.com wrote:



 On 8 fév, 23:26, Simon sp.ma...@gmail.com wrote:
  Yes that is the basics of app engine security. I use it to get the
  Google account of the user.
 
  This is the first step of the login: Google authentication.
  Second step I want to validate the Google account against my own set
  of users,
  Last step I want to send to the user the whole javascript app.

 You could use a servlet filter to let users in to the app or redirect
 them out; or use a servlet or JSP as the host page for the app.

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



jQuery

2010-02-08 Thread muhannad nasser
Dear all;

can u please tell me how to use jQuery in GWT... do i need to add something
to xml files. and how to call the jQuery functions

thanks

-- 
~~~With Regards~~~
Muhannad Dar-Nasser
~~Computer Systems Engineering~~

-- 
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-ckeditor v0.3 release

2010-02-08 Thread Damien Picard
Hi,

I'm pleased to announce the v0.3 release of gwt-ckeditor :
v0.3

Changes

   - Fixing issues on multiple custom toolbar and attach/detach editor
   - Adding entities and enter mode support


Many thanks to codex69 for its reviews. (font_names and font_sizes lists
will be added soon).

-- 
Damien Picard
Open Source BPM : http://code.google.com/p/osbpm

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



[gwt-contrib] Re: RR : Record selected annotations in Java AST

2010-02-08 Thread bobv


http://gwt-code-reviews.appspot.com/134810/diff/4001/4003
File dev/core/src/com/google/gwt/dev/jjs/ast/JAnnotation.java (right):

http://gwt-code-reviews.appspot.com/134810/diff/4001/4003#newcode40
Line 40: public static class PropertyT extends JNode 
JAnnotationArgument extends
The templated formulation allows the .of() method to reduce the amount
of tedious casting necessary when extracting data from the Property.

http://gwt-code-reviews.appspot.com/134810/diff/4001/4003#newcode72
Line 72: public ListT getValues() {
@interface Foo { String[] value(); }

// Equivalent source
@foo(bar)
@foo({bar})

The list of values could be held in a JNewArray (although it's not
really an allocation), but that's one more layer to unwrap in order to
access the data.  I don't see what adding an extra wrapper type to the
mix buys.

http://gwt-code-reviews.appspot.com/134810/diff/4001/4014
File dev/core/src/com/google/gwt/dev/jjs/ast/JProgram.java (right):

http://gwt-code-reviews.appspot.com/134810/diff/4001/4014#newcode91
Line 91: Arrays.asList(com.google.gwt.dev.jjs, test));
Ok, I'll change the test code to add the packages to this field.

http://gwt-code-reviews.appspot.com/134810

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


[gwt-contrib] Re: GWT 2.0.1 breaks incubator 2.0 ... is a new release emminent ?

2010-02-08 Thread jim n
can you name it 2010x please?



On Feb 4, 8:19 am, Ray Ryan rj...@google.com wrote:
 And the jar is posted. All better?



 On Thu, Feb 4, 2010 at 7:15 AM, Ray Ryan rj...@google.com wrote:
  Sorry, we'll get a 2.0.1 incubator jar up today.

  On Thu, Feb 4, 2010 at 7:04 AM, stuckagain david.no...@gmail.com wrote:

  Hi,

  The changes to CurrencyData and CurrencyList as described in the
  release note of GWT 2.0.1 has impact on the current GWT incubator
  CurrencyWidget. Is there a new release planned ? It seems to be fixed
  in the trunk of incubator.

  This is the compilation error.

   [ERROR] Errors in 'jar:file:/W:/rlsCOTS/gwtincubator/JAVA/lib/gwt-
  incubator.jar!/com/google/gwt/widgetideas/client/CurrencyWidget.java'
      [java]          [ERROR] Line 46: The import
  com.google.gwt.i18n.client.impl.CurrencyData cannot be resolved
      [java]          [ERROR] Line 47: The import
  com.google.gwt.i18n.client.impl.CurrencyList cannot be resolved
      [java]          [ERROR] Line 107: CurrencyData cannot be resolved
  to a type
      [java]          [ERROR] Line 122: CurrencyData cannot be resolved
  to a type
      [java]          [ERROR] Line 122: CurrencyList cannot be resolved
      [java]          [ERROR] Line 123: CurrencyData cannot be resolved
  to a type
      [java]          [ERROR] Line 124: CurrencyData cannot be resolved
  to a type
      [java]          [ERROR] Line 181: CurrencyData cannot be resolved
  to a type

  David

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

  --
  I wish this were a Wave

 --
 I wish this were a Wave

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


[gwt-contrib] concurrent design

2010-02-08 Thread gustav trede
Hello,

I have noticed that concurrency can be improved at many places in the
code.
A few simple examples:

Concurrenthashmap would be good replacement for :
serializationPolicyCache in RemoteServiceServlet
serviceToImplementedInterfacesMap in both the RPC classes

sHttpDateFormat  in HttpHeaders could be threadlocal instead of static
synchronized.

There are many more both simple, and more complex situations that
could become more concurrent too, but it requires more then a 5-10
seconds look like these examples did.

Is there is any interest of concurrency related patches ?.


Could somebody please explain why the threadlocals in
AbstractRemoteServiceServlet must be synchronized ?.

regards
  gustav trede

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


[gwt-contrib] Create or alter a module programmatically

2010-02-08 Thread Luiz Mineo
Hi there.

I'm dedicating some of my time to develop a small framework, to help
me create and maintain big GWT apps. I'm already doing some really
useful things with generators, but one of my objectives is offer the
option to create a lot of modules, without the need to maintain a lot
of *.gwt.xml files, and let the developer choose what modules will go
to the final build, and what won't. For now, I'm trying to achieve
this with an standalone app that is executed before the compiler or
devmode, but I'm looking for a better solution.

Is there any way to create or alter a module (like adding new source
paths) during compile time, using something like generators? Also, is
it possible to retrieve informations about the current module (name,
path...) in a generator? From what I could get from the GWT source,
it's not possible, but any idea would be appreciated =]

Thanks,

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


Re: [gwt-contrib] Re: GWT 2.0.1 breaks incubator 2.0 ... is a new release emminent ?

2010-02-08 Thread John LaBanca
Wow, 2010 already.  Fixed.

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


On Sat, Feb 6, 2010 at 8:52 AM, jim n northrup.ja...@gmail.com wrote:

 can you name it 2010x please?



 On Feb 4, 8:19 am, Ray Ryan rj...@google.com wrote:
  And the jar is posted. All better?
 
 
 
  On Thu, Feb 4, 2010 at 7:15 AM, Ray Ryan rj...@google.com wrote:
   Sorry, we'll get a 2.0.1 incubator jar up today.
 
   On Thu, Feb 4, 2010 at 7:04 AM, stuckagain david.no...@gmail.com
 wrote:
 
   Hi,
 
   The changes to CurrencyData and CurrencyList as described in the
   release note of GWT 2.0.1 has impact on the current GWT incubator
   CurrencyWidget. Is there a new release planned ? It seems to be fixed
   in the trunk of incubator.
 
   This is the compilation error.
 
[ERROR] Errors in 'jar:file:/W:/rlsCOTS/gwtincubator/JAVA/lib/gwt-
   incubator.jar!/com/google/gwt/widgetideas/client/CurrencyWidget.java'
   [java]  [ERROR] Line 46: The import
   com.google.gwt.i18n.client.impl.CurrencyData cannot be resolved
   [java]  [ERROR] Line 47: The import
   com.google.gwt.i18n.client.impl.CurrencyList cannot be resolved
   [java]  [ERROR] Line 107: CurrencyData cannot be resolved
   to a type
   [java]  [ERROR] Line 122: CurrencyData cannot be resolved
   to a type
   [java]  [ERROR] Line 122: CurrencyList cannot be resolved
   [java]  [ERROR] Line 123: CurrencyData cannot be resolved
   to a type
   [java]  [ERROR] Line 124: CurrencyData cannot be resolved
   to a type
   [java]  [ERROR] Line 181: CurrencyData cannot be resolved
   to a type
 
   David
 
   --
  http://groups.google.com/group/Google-Web-Toolkit-Contributors
 
   --
   I wish this were a Wave
 
  --
  I wish this were a Wave

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


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

[gwt-contrib] Re: RR : Record selected annotations in Java AST

2010-02-08 Thread scottb


http://gwt-code-reviews.appspot.com/134810/diff/4001/4003
File dev/core/src/com/google/gwt/dev/jjs/ast/JAnnotation.java (right):

http://gwt-code-reviews.appspot.com/134810/diff/4001/4003#newcode40
Line 40: public static class PropertyT extends JNode 
JAnnotationArgument extends
I guess I kind of see that, but it seems like a lot of unnecessarily
complication for almost no benefit.  Just looking through the patch, it
seems like I was looking at a whole lot more of ? that I could see
instances where we made a cast implicit rather than explicit.

http://gwt-code-reviews.appspot.com/134810/diff/4001/4003#newcode72
Line 72: public ListT getValues() {
It's more consistent with the rest of the AST, and has the useful
feature that the property value JAnnotationArgument's JType is
definitely compatible with the declared property JType.

http://gwt-code-reviews.appspot.com/134810

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


[gwt-contrib] Re: Constant analysis.

2010-02-08 Thread spoon


http://gwt-code-reviews.appspot.com/130812/diff/1/2
File
dev/core/src/com/google/gwt/dev/jjs/impl/gflow/constants/AssumptionDeducer.java
(right):

http://gwt-code-reviews.appspot.com/130812/diff/1/2#newcode135
Line 135: // Only last expression can be reverse engineered.
Either htis comment is innacurate or I don't understand what's going on.
 I believe what's going on is that, from the point of view of a CFG, the
only operation under consideration is the passing of the result of the
last expression to being the result of the multi-expression.  All the
other evaluation steps are represented as separate CFG nodes, and those
nodes' effects on the assumptions will already be presented in the
assumptions list.

If that's what's going on, then please update the comment.

http://gwt-code-reviews.appspot.com/130812/diff/1/2#newcode154
Line 154: private boolean isDeduciveEqValue(JExpression e) {
This method seems to mean, would two expressions equal to e be
substitutable for each other.  If that's what it means, please update
the name and comment.  Can deduce something is awfully vague.

http://gwt-code-reviews.appspot.com/130812/diff/1/4
File
dev/core/src/com/google/gwt/dev/jjs/impl/gflow/constants/ConstantsAnalysis.java
(right):

http://gwt-code-reviews.appspot.com/130812/diff/1/4#newcode30
Line 30: * As of now supports only locals  parameters.
Document that it also does constant folding.

http://gwt-code-reviews.appspot.com/130812/diff/1/5
File
dev/core/src/com/google/gwt/dev/jjs/impl/gflow/constants/ConstantsAssumption.java
(right):

http://gwt-code-reviews.appspot.com/130812/diff/1/5#newcode35
Line 35: public static class CopyOnWrite {
It took me a long time to figure out that this class is a builder that
is initialized with a previous instance of the class.

That's a good pattern, but the name makes it obscure.  Please rename it
to something with something including builder or updater or the
like.

http://gwt-code-reviews.appspot.com/130812/diff/1/5#newcode154
Line 154: values.put(variable, literal);
Given that there is a builder for the class, it would seem better to
make mutators like this be private.  Then, the public API of the class
would be immutable.

Likewise for the assumption/CopyOnWrite pairs for all the other
optimizers.

http://gwt-code-reviews.appspot.com/130812/diff/1/5#newcode185
Line 185: private boolean equal(Object o1, Object o2) {
This ends up compalir JValueLiteral AST nodes rather than the
represented literals.

Perhaps change the argument types to JValueLiteral, and compare the
underlying literals?  Be careful with floats; for safety's sake we might
start with only treating them as equal if their underlying bits are the
same.

http://gwt-code-reviews.appspot.com/130812

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


[gwt-contrib] Re: Make HandlerManager survive exceptions

2010-02-08 Thread Ray Ryan
On Mon, Feb 8, 2010 at 7:53 AM, phopk...@google.com wrote:

 On 2010/02/03 20:16:51, Ray Ryan wrote:

 Is there any reason to limit this to RuntimeException rather than

 Exception?

 Not particularly; I did RuntimeException because #dispatch doesn't throw
 any checked exceptions. Could change to Exception for clarity.


  I think it would be better to capture all exceptions thrown during

 event

 dispatch and then re-throw them in an umbrella exception. This way it

 will reach

 the app's UncaughtExceptionHandler through the usual mechanisms

 without the

 developer having to think about it.


  We do something similar when attaching and detaching Widgets, see
 AttachDetachException. Don't mind its Command stuff, all you need to

 imitate in,

 say, EventDispatchException are


  AttachDetachException(SetThrowable causes)
 public SetThrowable getCauses()


  Really the thing to do is refactor out a common superclass, perhaps
 UmbrellaException


 Ok, I could change to that. Some questions, though:

  - Is there a worry that this changes the current behavior, such that if
 anyone was relying on an early handler throwing that it would stop
 subsequent handlers?


Perhaps, but it's so much more likely that people are having mysterious
failures that I'm comfortable with the change. We've made similar fixes
recently in our core widgets, and the results have only been good.


  - Should HandlerManager still have an UncaughtExceptionHandler? In my
 app I'd like to be able to have a HandlerManager that won't re-throw
 exceptions, so that I can send Events out and still know that,
 regardless of how they're handled, my original function will continue.


Won't that be the case with the flow I've described? All events will fire,
and kick off whatever it is that they kick off, and then the collected
exceptions will be re-thrown. In most apps, I figure this will reach the
default UCE and put up a red banner or whatever. What would this break in
your app?


 I could subclass HandlerManager and override its fireEvent method to
 wrap it in a try/catch, but I'm worried that with that strategy the
 event.kill() and event.setSource() calls at the very end wouldn't get
 called if a handler threw (unless I suppose HandlerManager saved its
 umbrella exception to throw after those lines are executed).


Exactly, that's the intent. Protect the full event dispatch cycle, and then
throw up.



  http://gwt-code-reviews.appspot.com/136805/diff/1/2
 File svn/user/src/com/google/gwt/event/shared/HandlerManager.java

 (right):

  http://gwt-code-reviews.appspot.com/136805/diff/1/2#newcode64
 Line 64: } catch (RuntimeException e) {
 Why limit to RuntimeException and not plain old Exception?




 http://gwt-code-reviews.appspot.com/136805




-- 
I wish this were a Wave

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

Re: [gwt-contrib] Re: TextBoxBase to implement HasDirection instead of its children

2010-02-08 Thread Ray Ryan
Sounds exciting. Looking forward to your patches.

On Sun, Feb 7, 2010 at 11:53 PM, Tomer Greenberg tomer...@google.comwrote:

 I'm working on a new class named AutoDirHandler, which is supposed to
 listen on keypress events and adjust the directionality of the TA / TB as
 you type. The AutoDirHandler is a private member of the TA / TB, which also
 supply methods to enable / disable it.


 On Thu, Feb 4, 2010 at 8:12 PM, Ray Ryan rj...@google.com wrote:

 I more wanted to hear an elaboration on I'm going to add some BiDi
 functionality to TextBox and TextArea.

 But given that Both of TA and TB implement the interface, refactoring the
 copy/paste implementation sounds good to me.

 On Wed, Feb 3, 2010 at 4:01 AM, tomerigo tomer...@google.com wrote:

 I want TextBoxBase to implement HasDirection, which means moving the
 implementation of setDirection and getDirection from TextBox /
 TextArea to TextBoxBase.

 On 2 פברואר, 23:00, Ray Ryan rj...@google.com wrote:
  Extending TextBoxBase sounds perfectly reasonable, but what exactly are
 you
  proposing to implement there?
 
  On Tue, Feb 2, 2010 at 10:58 AM, Tomer Greenberg tomer...@google.com
 wrote:
 
 
 
   Hello gwters,
 
   I'm going to add some BiDi functionality to TextBox and TextArea.
 Given
   that their parent, TextBoxBase, doesn't implement HasDirection, this
 has to
   be done (in an identical manner) for TextBox and TextArea separately.
 But
   then, why won't TextBoxBase implement HasDirection instead of its
 children?
   This way we could save a lot of code duplication, and it's also
 reasonable -
   if it has text, it also has direction.
 
   Any objections?
 
   Thanks
 
   Tomer
 
--
  http://groups.google.com/group/Google-Web-Toolkit-Contributors
 
  --
  I wish this were a Wave

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




 --
 I wish this were a Wave

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


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




-- 
I wish this were a Wave

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

[gwt-contrib] [google-web-toolkit] r7533 committed - Adding branch-info.txt.

2010-02-08 Thread codesite-noreply

Revision: 7533
Author: sp...@google.com
Date: Mon Feb  8 09:07:00 2010
Log: Adding branch-info.txt.

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

Added:
 /branches/gflow/branch-info.txt

===
--- /dev/null
+++ /branches/gflow/branch-info.txt Mon Feb  8 09:07:00 2010
@@ -0,0 +1,4 @@
+This branch is for polishing up a CFG-based optimization suite.
+
+
+It was branched from trunk at r7530.

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


[gwt-contrib] Re: RR : Record selected annotations in Java AST

2010-02-08 Thread bobv

Scott,

  Here's an updated patch that removes the parameterizations.  Per our
IM conversation, a JNewArray is inappropriate because Java annotations
are restricted to single-dimension arrays.

http://gwt-code-reviews.appspot.com/134810

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


[gwt-contrib] Re: RR : Record selected annotations in Java AST

2010-02-08 Thread scottb

LVGTM

http://gwt-code-reviews.appspot.com/134810

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


[gwt-contrib] Two BiDi support classes

2010-02-08 Thread tomerigo

Reviewers: ,

Description:
BidiUtils - utility functions for performing common BiDi tests on
strings, such as direction estimation.

BidiFormatter - utility class for formatting text for display in a
potentially opposite-direction context without garbling.

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

Affected files:
  user/src/com/google/gwt/i18n/I18N.gwt.xml
  user/src/com/google/gwt/i18n/shared/BidiFormatter.java
  user/src/com/google/gwt/i18n/shared/BidiUtils.java
  user/test/com/google/gwt/i18n/I18NSuite.java
  user/test/com/google/gwt/i18n/I18NTest_shared.gwt.xml
  user/test/com/google/gwt/i18n/shared/BidiFormatterTest.java
  user/test/com/google/gwt/i18n/shared/BidiUtilsTest.java
  user/test/com/google/gwt/i18n/shared/GwtBidiUtilsTest.java


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


[gwt-contrib] [google-web-toolkit] r7536 committed - Revert of 7535, which wrongly had trunk/trunk

2010-02-08 Thread codesite-noreply

Revision: 7536
Author: gwt.mirror...@gmail.com
Date: Mon Feb  8 13:54:28 2010
Log: Revert of 7535, which wrongly had trunk/trunk
http://code.google.com/p/google-web-toolkit/source/detail?r=7536

Deleted:
 /trunk/trunk

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


[gwt-contrib] Re: Two BiDi support classes

2010-02-08 Thread jat

There was a problem with the patch upload -- the modified files didn't
show up, perhaps they don't match svn trunk.

I assume I18N pulls in client/shared, and inherits RegExp.  The one
concern I have is that means that RegExp gets pulled in by User, and
that code will wind up always being used if widgets automatically use
BidiUtils (which I understand is the ultimate goal).  Will that code be
structured such that all of this can be dead-stripped if it isn't
needed?


http://gwt-code-reviews.appspot.com/140809

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


[gwt-contrib] Re: Adding new event types (touch etc.)

2010-02-08 Thread Thomas Broyer


On 8 fév, 10:17, Thomas Broyer wrote:

 I'm thinking in starting a Wave about how I think event handling
 should be refactored.

Done: https://wave.google.com/wave/#restored:wave:googlewave.com!w%252Bux7zL81XA

Still To Be Continued, and I'll try to work on a patch later on if I
find some time.

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


  1   2   >