Re: Passing an argument to a View using Activities and Places

2011-10-06 Thread Alisson Prestes
Here's an example from "GWT Development with Activities and Places" tutorial
(
http://code.google.com/webtoolkit/doc/latest/DevGuideMvpActivitiesAndPlaces.html
)

public class HelloPlace extends Place {

private String helloName;

public HelloPlace(String token) {

this.helloName = token;
}

public String getHelloName() {

return helloName;
}

public static class Tokenizer implements PlaceTokenizer {

@Override
public String getToken(HelloPlace place) {

return place.getHelloName();
}

@Override
public HelloPlace getPlace(String token) {

return new HelloPlace(token);

}
}
}

As you correctly guessed, in the constructor you call the "get..." method
and stores it in an attribute, just like you did with the clientFactory.
Then you can check if this attribute is not null in the start method and
call the appropriated method of the view.

Alisson Prestes
www.google.com/profiles/javalisson



On Thu, Oct 6, 2011 at 3:00 PM, Mike Dee  wrote:

> FooActivity.start() looks like this.  Note that while it can get
> FooView from the clientfactory, it has no notion of FooPlace, which is
> where the argument (fooid) is stored.
>
> @Override
> public void start( AcceptsOneWidget containerWidget, EventBus
> eventBus )
> {
>  FooView view = clientFactory.getFooView();
>  view.setPresenter( this );
>  containerWidget.setWidget( view.asWidget() );
> }
>
> I guess the call to view.setName() could be made in FooActivity's
> constructor, where a FooPlace is passed in.
>
> public FooActivity( FooPlace place, ClientFactory clientFactory )
> {
>  this.clientFactory = clientFactory;
> }
>
> But I don't know how to get the argument (token) out of FooPlace.
>
>
> On Oct 6, 10:51 am, Alisson Prestes  wrote:
> > Yes, I think this will work.
> >
> > Alisson Presteswww.google.com/profiles/javalisson
> >
> >
> >
> >
> >
> >
> >
> > On Thu, Oct 6, 2011 at 2:48 PM, Mike Dee  wrote:
> > > Would the call to set the arg in the view go in FooActivity.start()?
> >
> > > On Oct 6, 10:46 am, Mike Dee  wrote:
> > > > So, should I put code in FooActivity?  I am not sure if the
> > > > boilerplate code generated by the activity should have done that or
> > > > not.
> >
> > > > On Oct 6, 10:44 am, Alisson Prestes  wrote:
> >
> > > > > The FooActivity extracts the arguments from the FooPlace. Then it
> calls
> > > the
> > > > > right method in the FooView. Place and View do not interact with
> each
> > > other
> > > > > directly.
> >
> > > > > Alisson Presteswww.google.com/profiles/javalisson
> >
> > > > > On Thu, Oct 6, 2011 at 2:17 PM, Mike Dee 
> > > wrote:
> > > > > > I'm using Activities and Place and can't figure this out.  I've
> been
> > > > > > looking at samples but don't see it in there. I think I'm missing
> > > > > > something.
> >
> > > > > > I have a button in one place that, when clicked, will trigger a
> new
> > > > > > activity and place (along with a new view).  The code for that
> button
> > > > > > simply looks like this:
> >
> > > > > > listener.goTo( new FooPlace( fooid ) );
> >
> > > > > > The above code is in the button handler of BarViewImpl (view
> > > > > > implementation for a separate place/activity).
> >
> > > > > > This above line works in that it goes to FooPlace and the URL
> shows
> > > > > > the parameter (123456):
> >
> > > > > > MyApp.html?gwt.codesvr=127.0.0.1:9997#FooPlace:123456
> >
> > > > > > But fooid doesn't make it to FooView.  How does the FooPlace or
> > > > > > FooActivity pass the fooid to FooView?
> >
> > > > > > --
> > > > > > You received this message because you are subscribed to the
> Google
> > > Groups
> > > > > > "Google Web Toolkit" group.
> > > > > > To post to this group, send email to
> > > google-web-toolkit@googlegroups.com.
> > > > > > To unsubscribe from this group, send email to
> > > > > > google-web-toolkit+unsubscr...@googlegroups.com.
> > > > > > For more options, visit this group at
> > > > > >http://groups.google.com/group/google-web-toolkit?hl=en.
> >
> > > --
> > >

Re: Passing an argument to a View using Activities and Places

2011-10-06 Thread Alisson Prestes
Yes, I think this will work.


Alisson Prestes
www.google.com/profiles/javalisson



On Thu, Oct 6, 2011 at 2:48 PM, Mike Dee  wrote:

> Would the call to set the arg in the view go in FooActivity.start()?
>
> On Oct 6, 10:46 am, Mike Dee  wrote:
> > So, should I put code in FooActivity?  I am not sure if the
> > boilerplate code generated by the activity should have done that or
> > not.
> >
> > On Oct 6, 10:44 am, Alisson Prestes  wrote:
> >
> >
> >
> >
> >
> >
> >
> > > The FooActivity extracts the arguments from the FooPlace. Then it calls
> the
> > > right method in the FooView. Place and View do not interact with each
> other
> > > directly.
> >
> > > Alisson Presteswww.google.com/profiles/javalisson
> >
> > > On Thu, Oct 6, 2011 at 2:17 PM, Mike Dee 
> wrote:
> > > > I'm using Activities and Place and can't figure this out.  I've been
> > > > looking at samples but don't see it in there. I think I'm missing
> > > > something.
> >
> > > > I have a button in one place that, when clicked, will trigger a new
> > > > activity and place (along with a new view).  The code for that button
> > > > simply looks like this:
> >
> > > > listener.goTo( new FooPlace( fooid ) );
> >
> > > > The above code is in the button handler of BarViewImpl (view
> > > > implementation for a separate place/activity).
> >
> > > > This above line works in that it goes to FooPlace and the URL shows
> > > > the parameter (123456):
> >
> > > > MyApp.html?gwt.codesvr=127.0.0.1:9997#FooPlace:123456
> >
> > > > But fooid doesn't make it to FooView.  How does the FooPlace or
> > > > FooActivity pass the fooid to FooView?
> >
> > > > --
> > > > You received this message because you are subscribed to the Google
> Groups
> > > > "Google Web Toolkit" group.
> > > > To post to this group, send email to
> google-web-toolkit@googlegroups.com.
> > > > To unsubscribe from this group, send email to
> > > > google-web-toolkit+unsubscr...@googlegroups.com.
> > > > For more options, visit this group at
> > > >http://groups.google.com/group/google-web-toolkit?hl=en.
>
> --
> You received this message because you are subscribed to the Google Groups
> "Google Web Toolkit" group.
> To post to this group, send email to google-web-toolkit@googlegroups.com.
> To unsubscribe from this group, send email to
> google-web-toolkit+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/google-web-toolkit?hl=en.
>
>

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



Re: Passing an argument to a View using Activities and Places

2011-10-06 Thread Alisson Prestes
The FooActivity extracts the arguments from the FooPlace. Then it calls the
right method in the FooView. Place and View do not interact with each other
directly.

Alisson Prestes
www.google.com/profiles/javalisson



On Thu, Oct 6, 2011 at 2:17 PM, Mike Dee  wrote:

> I'm using Activities and Place and can't figure this out.  I've been
> looking at samples but don't see it in there. I think I'm missing
> something.
>
> I have a button in one place that, when clicked, will trigger a new
> activity and place (along with a new view).  The code for that button
> simply looks like this:
>
> listener.goTo( new FooPlace( fooid ) );
>
> The above code is in the button handler of BarViewImpl (view
> implementation for a separate place/activity).
>
> This above line works in that it goes to FooPlace and the URL shows
> the parameter (123456):
>
> MyApp.html?gwt.codesvr=127.0.0.1:9997#FooPlace:123456
>
> But fooid doesn't make it to FooView.  How does the FooPlace or
> FooActivity pass the fooid to FooView?
>
> --
> You received this message because you are subscribed to the Google Groups
> "Google Web Toolkit" group.
> To post to this group, send email to google-web-toolkit@googlegroups.com.
> To unsubscribe from this group, send email to
> google-web-toolkit+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/google-web-toolkit?hl=en.
>
>

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



Re: UiBinder

2011-09-26 Thread Alisson Prestes
You're not using the xml namespace prefix.




http://code.google.com/webtoolkit/doc/latest/DevGuideUiBinder.html#Simple_binding



Alisson Prestes
www.google.com/profiles/javalisson



On Mon, Sep 26, 2011 at 12:27 PM, Daniel Gerep wrote:

> Hi fellas,
>
> I have a ui.xml file:
>
> http://dl.google.com/gwt/DTD/xhtml.ent";>
>  xmlns:g="urn:import:com.google.gwt.user.client.ui">
> 
>  .important {
> font-weight: bold;
> }
>  
> 
> 
>  Texto
> Imagem
> 
>  
> 
>  
> 
>  
> 
>
> I'm trying to use HTMl instead of GWT components. I have this code on Java
> class
>
> @UiField
> Button button;
> String firstName = "undefined";
>  @UiField
> Image image;
>   public SampleBinderWidget(String firstName) {
>  initWidget(uiBinder.createAndBindUi(this));
> button.setText(firstName);
>  this.firstName = firstName;
>  }
>  @UiHandler("button")
>  void onClick(ClickEvent e) {
> Window.alert("Hello: "+this.firstName);
>  image.setUrl("http://www.google.com/intl/en_ALL/images/logo.gif";);
> }
>
> When I run the code I get a error: Field 'button' does not have an
> 'addClickHandler' method associated, isn't the onClick() for that?
>
> How do I fix this?
>
> Thanks in advance for any help.
>
> --
> *Att*
> *Daniel Gerep*
>
>  --
> You received this message because you are subscribed to the Google Groups
> "Google Web Toolkit" group.
> To post to this group, send email to google-web-toolkit@googlegroups.com.
> To unsubscribe from this group, send email to
> google-web-toolkit+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/google-web-toolkit?hl=en.
>

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



Re: HTML

2011-09-22 Thread Alisson Prestes
You can divide your app into Activities (each Use Case may be an Activity)
and Views (each screen that the user will interact with is a view), then use
them in appropriate time. Check this out:
http://code.google.com/webtoolkit/doc/latest/DevGuideMvpActivitiesAndPlaces.html.


You can also create custom widgets to be reused within your Views
http://code.google.com/webtoolkit/doc/latest/DevGuideUiCustomWidgets.html#composite
.

Concerning the size of the generated code, you can do some code splitting.
It can lessen the need for large downloads when the app is started
http://code.google.com/webtoolkit/doc/latest/DevGuideCodeSplitting.html



Alisson Prestes
www.google.com/profiles/javalisson



On Thu, Sep 22, 2011 at 8:36 AM, Daniel Gerep wrote:

> Hi fellas,
>
> I'm new to GWT and I'm liking it a loot but there is a doubt;
>
> I know that GWT only work with one HTML but all my code, my actions will be
> in the Project.java file? It will be a enormous file with thousands of
> lines. Is it possible to separate things?
>
> Thanks in advance.
>
> --
> *Att*
> *Daniel Gerep*
>
>  --
> You received this message because you are subscribed to the Google Groups
> "Google Web Toolkit" group.
> To post to this group, send email to google-web-toolkit@googlegroups.com.
> To unsubscribe from this group, send email to
> google-web-toolkit+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/google-web-toolkit?hl=en.
>

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



Re: Error with Quartz

2011-09-21 Thread Alisson Prestes
I've never used Quartz, but it seems that your exception is not related to
GWT. Isn't Quartz used on the server-side? So why is this error coming to
the client-side? If you're using it in a service, try to handle the error
before it comes to the client. The same error occurs when you use Quartz
from another place, i.e., from another app that does not use GWT?

Alisson Prestes
www.google.com/profiles/javalisson



On Wed, Sep 21, 2011 at 9:16 AM, andre_guitar7  wrote:

> I'm trying to work GWT with Quartz, but gives an error:
>
> "Caused by: java.security.AccessControlException: access denied
> (java.lang.RuntimePermission modifyThreadGroup)"
>
> What can this be?
>
> --
>
> Pessoal, estou tentando fazer o Quartz funcionar com GWT, mas ao
> executar aparece o erro:
>
> "Caused by: java.security.AccessControlException: access denied
> (java.lang.RuntimePermission modifyThreadGroup)"
>
> Que pode ser isso?
>
> Obrigado!
>
> --
> You received this message because you are subscribed to the Google Groups
> "Google Web Toolkit" group.
> To post to this group, send email to google-web-toolkit@googlegroups.com.
> To unsubscribe from this group, send email to
> google-web-toolkit+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/google-web-toolkit?hl=en.
>
>

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



Re: What about non Javascript sites?

2011-09-08 Thread Alisson Prestes
I heard (and someone here could confirm it or not) that Closure Templates,
another tool developed by Google, has the ability to generate the same page
either in server side or client side. Does anybody know if it is possible to
integrate it with GWT?

Alisson Prestes
www.google.com/profiles/javalisson



On Wed, Sep 7, 2011 at 12:22 PM, karim duran  wrote:

> Hi Raks & Alexandre,
>
> Absolutely. It is even recommended to have a standard behavior if
> javascript is disabled (which is rare these days).
> To do this, create web pages with a traditional business logic. They will
> be displayed without javascript  enabled.
> If javascript is on, it must dynamically replace the contents of pages.
> Many companies have this problem. But it requires more work to deal
> with
>
> Another way is to display a friendly message to the user. :
> "JavaScript should be enabled on your browser in order to this application
> to run normally" or something like that.
>
> I hope it helps.
>
> Regards.
>
> Karim Duran.
>
>
> 2011/9/7 Alexandre Dupriez 
>
>> Hello,
>>
>> Could you please tell us more about the tier application you would
>> have to maintain? Which technology is used, if not Javascript?
>>
>> On 6 sep, 15:43, raks  wrote:
>> > Hi,
>> >
>> > I am very taken with GWT and I believe will make maintaining my
>> company's
>> > site easier.
>> >
>> > However, they say they need to maintain a non JavaScript version of the
>> > site.
>> >
>> > Any ideas how we can do this? Would it have to be a seperate site? Can
>> the
>> > app be partitioned in some way?
>> >
>> > Thanks
>> >
>> > Raks
>>
>> --
>> You received this message because you are subscribed to the Google Groups
>> "Google Web Toolkit" group.
>> To post to this group, send email to google-web-toolkit@googlegroups.com.
>> To unsubscribe from this group, send email to
>> google-web-toolkit+unsubscr...@googlegroups.com.
>> For more options, visit this group at
>> http://groups.google.com/group/google-web-toolkit?hl=en.
>>
>>
>  --
> You received this message because you are subscribed to the Google Groups
> "Google Web Toolkit" group.
> To post to this group, send email to google-web-toolkit@googlegroups.com.
> To unsubscribe from this group, send email to
> google-web-toolkit+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/google-web-toolkit?hl=en.
>

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



GDDBR11

2011-09-01 Thread Alisson Prestes
Hi,

Is anybody from this list coming to Google Developer Day Brazil this year?

Alisson Prestes
www.google.com/profiles/javalisson

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



Re: Does GWT has any framework or class or something for accessibility (especially for client side )

2011-08-02 Thread Alisson Prestes
ARIA Roles?

Alisson Prestes
www.google.com/profiles/javalisson



On Tue, Aug 2, 2011 at 4:28 PM, Ben Munge  wrote:

> I'm not sure what you mean exactly. Accessibility is driven much more
> by the content and construction of your pages. A framework cannot make
> assumptions about accessibility because it doesn't know what your site
> is trying to express. If you follow the UI Binder approach, just
> construct your elements in the most accessible way that fits your site
> (tab indexing, alt comments, descriptive links, etc).
>
> On Aug 2, 12:38 am, mmb  wrote:
> > Hi Everyone ,
> > I just started learning GWT  ,is there any kind of framework or API's
> > for client side accessibility for GWT,i know there is a library for
> > provider side i.e com.google...ui.accessibility,but i want framework
> > or class at the client side
> > thanks in advance for those who reply..
>
> --
> You received this message because you are subscribed to the Google Groups
> "Google Web Toolkit" group.
> To post to this group, send email to google-web-toolkit@googlegroups.com.
> To unsubscribe from this group, send email to
> google-web-toolkit+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/google-web-toolkit?hl=en.
>
>

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



Re: Lots of DIVs

2011-07-29 Thread Alisson Prestes
Very smart :)

Alisson Prestes
www.google.com/profiles/javalisson



On Thu, Jul 28, 2011 at 4:30 PM, Thomas Broyer  wrote:

> First, as soon as you use a layout panel, it adds a div to the document's
> body, using it as a ruler to measure centimeters in pixels (this is the very
> first div here, moved out of view using top:-20cm).
> Then, each layout panel is a div, containing another ruler to measure EMs
> and EXs (it has to be repeated for each panel because it depends on the
> font-size applied locally or inherited).
> Then, each child of layout panel lives in its own div (I don't remember the
> rationale for this, but it had to be done so it works in all browsers and
> allows some kinds of styling –borders and margins–).
>
> So here, you have the CM rule, followed by the RootLayoutPanel, containing
> its own ruler and a child. That child in turns is a layout panel, with its
> own ruler and a single child.
>
> --
> You received this message because you are subscribed to the Google Groups
> "Google Web Toolkit" group.
> To view this discussion on the web visit
> https://groups.google.com/d/msg/google-web-toolkit/-/cUsZ2VaB3m4J.
>
> To post to this group, send email to google-web-toolkit@googlegroups.com.
> To unsubscribe from this group, send email to
> google-web-toolkit+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/google-web-toolkit?hl=en.
>

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



Re: Declar~ á´â´â´ .´´ e an array of panels in UiBindera

2011-07-25 Thread Alisson Prestes
I'm sorry, my smartphone was in my pocket and I accidentally sent this
nonsense message to the group :$

Alisson Prestes
www.google.com/profiles/javalisson



On Mon, Jul 25, 2011 at 9:50 AM, Alisson Prestes wrote:

> On 7/25/11, Alexander Orlov  wrote:
> > On Jul 25, 12:09 pm, Tomasz Gawel  wrote:
> >> List slots;
> >> @UiField FlowPanel slotTargetPanel;
> >>
> >> @UiFactory FocusPanel void addSlot() {
> >
> > I suppose this should be
> >  @UiFactory FocusPanel addSlot() {
> >
> >>FocusPanel slot = new FocusPanel();
> >>slots.add(slot);
> > Here I get:
> > ERROR: Failed to create an instance of
> > 'dp.verp.planer.client.ResourceDefiner' via deferred binding .
> > java.lang.NullPointerException: null
> >
> > Didn't know about @UiFactory. This annotation could be very useful in
> > many other cases...
> >
> > -Alex
> >
> > --
> > You received this message because you are subscribed to the Google Groups
> > "Google Web Toolkit" group.
> > To post to this group, send email to google-web-toolkit@googlegroups.com
> .
> > To unsubscribe from this group, send email to
> > google-web-toolkit+unsubscr...@googlegroups.com.
> > For more options, visit this group at
> > http://groups.google.com/group/google-web-toolkit?hl=en.
> >
> >
>
>
> --
> Alisson Prestes
> www.google.com/profiles/javalisson
>

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



Re: Declar~á´â´â´ .´´ e an array of panels in UiBindera

2011-07-25 Thread Alisson Prestes
On 7/25/11, Alexander Orlov  wrote:
> On Jul 25, 12:09 pm, Tomasz Gawel  wrote:
>> List slots;
>> @UiField FlowPanel slotTargetPanel;
>>
>> @UiFactory FocusPanel void addSlot() {
>
> I suppose this should be
>  @UiFactory FocusPanel addSlot() {
>
>>    FocusPanel slot = new FocusPanel();
>>    slots.add(slot);
> Here I get:
> ERROR: Failed to create an instance of
> 'dp.verp.planer.client.ResourceDefiner' via deferred binding .
> java.lang.NullPointerException: null
>
> Didn't know about @UiFactory. This annotation could be very useful in
> many other cases...
>
> -Alex
>
> --
> You received this message because you are subscribed to the Google Groups
> "Google Web Toolkit" group.
> To post to this group, send email to google-web-toolkit@googlegroups.com.
> To unsubscribe from this group, send email to
> google-web-toolkit+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/google-web-toolkit?hl=en.
>
>


-- 
Alisson Prestes
www.google.com/profiles/javalisson

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



Re: Request Builder

2011-07-03 Thread Alisson Prestes
Your question is very broad. I can only suggest you some official
tutorials:

   1. You can read the tutorial that will teach you how to communicate with
   the server here:
   http://code.google.com/webtoolkit/doc/latest/DevGuideServerCommunication.html
   2. This other tutorial will teach you how to create UI using GWT:
   http://code.google.com/webtoolkit/doc/latest/tutorial/gettingstarted.html
   3. The image you need to create probably can be created using the Google
   Chart Tools API:
   http://code.google.com/p/gwt-google-apis/wiki/VisualizationGettingStarted
   4. Depending on the size of your application, you may wish to use
   Activities and Places to keep everything organized:
   
http://code.google.com/webtoolkit/doc/latest/DevGuideMvpActivitiesAndPlaces.html

If your question is about a more specific topic, please supply more details.


Alisson Prestes
www.google.com/profiles/javalisson



On Sun, Jul 3, 2011 at 12:05 AM, sanjay kanwar wrote:

> Hi There,
>
> I have a task in which i hav to use Request Builder and JSON to fetch the
> data frm the php server and show it in the screen in the form of image
> representating tht data. I am new to jst a recent graduate and new to this
> technology any help about how to proceed  would be very helpful.
>
>
> Thanks in Advance
> Sanjay Kanwar
>
> --
> You received this message because you are subscribed to the Google Groups
> "Google Web Toolkit" group.
> To post to this group, send email to google-web-toolkit@googlegroups.com.
> To unsubscribe from this group, send email to
> google-web-toolkit+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/google-web-toolkit?hl=en.
>

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



Re: Annoncing GWT Brasil

2011-07-01 Thread Alisson Prestes
Thanks, we will be there! :)

Alisson Prestes
www.google.com/profiles/javalisson



On Fri, Jul 1, 2011 at 4:06 PM, Magno Machado  wrote:

> I founded a forum dedicated for brazilian GWT developers, and would like to
> invite any one here who speak portuguese to participate
>
> www.gwtbr.com
>
> --
> Magno Machado Paulo
> http://blog.magnomachado.com.br
> http://code.google.com/p/emballo/
>
> --
> You received this message because you are subscribed to the Google Groups
> "Google Web Toolkit" group.
> To post to this group, send email to google-web-toolkit@googlegroups.com.
> To unsubscribe from this group, send email to
> google-web-toolkit+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/google-web-toolkit?hl=en.
>

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



Re: .setVisible(true); // I can't see what I am missing

2011-06-27 Thread Alisson Prestes
The CSS attribute that you must declare is "display" instead of visibility.
This is the attribute that the setVisible method affects.

#ButtonContainer
{
display: none;
}

Alisson Prestes
www.google.com/profiles/javalisson



On Mon, Jun 27, 2011 at 9:55 PM, RRRaney  wrote:

> Hello,
>
> I would like to figure out how to build my entire container before I show
> it.
> I have this example to help explain and work with.
> This builds the container as I would like (if I remove the
> visibility:hidden).
> With the example as is it never shows the ButtonContainer, just sits
> there as blank page.
> I can't see what it is that I am missing.
>
> My.html
> ---
> 
>   id= "ButtonContainer">
> 
> 
> 
> 
>
> My.css
> --
> .Container
> {
> outline:#C0C0C0 inset thin;
> }
> #ButtonContainer
> {
> visibility: hidden;
> }
> My.java
> ---
> public class SmartPage implements EntryPoint
> {
> public void onModuleLoad()
> {
> HLayout Buttons = new HLayout();
> Buttons.setMembersMargin(15);
> IButton ButtonOne = new IButton("Button One");
> IButton ButtonTwo = new IButton("Button Two");
> Buttons.addMember(ButtonTwo);
> Buttons.addMember(ButtonOne);
> VLayout ButtonLayout = new VLayout();
> ButtonLayout.addMember(Buttons);
> ButtonLayout.setHeight(ButtonOne.getHeight());
> RootPanel.get("Buttons").add(ButtonLayout);
> ButtonLayout.draw();
> RootPanel.get("ButtonContainer").setVisible(true);
> }
> }
> Thanks,
>
> Raney
>
> --
> You received this message because you are subscribed to the Google Groups
> "Google Web Toolkit" group.
> To view this discussion on the web visit
> https://groups.google.com/d/msg/google-web-toolkit/-/TA2_kmOKOFUJ.
> To post to this group, send email to google-web-toolkit@googlegroups.com.
> To unsubscribe from this group, send email to
> google-web-toolkit+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/google-web-toolkit?hl=en.
>

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



Re: Maintaining application state

2011-06-10 Thread Alisson Prestes
I am storing the information in the Client Factory.

Alisson Prestes
www.google.com/profiles/javalisson



On Fri, Jun 10, 2011 at 4:00 PM, Ashton Thomas  wrote:

> I do something kinda similar. I make the assumption that a Place
> object should store all the state/data for the particular place. I
> then have something called a ContextWatcher which controls any
> application wide state or data. I use a static Cache class to actually
> store any data.
>
> The impl also makes it very easy to rebuild application state from a
> refresh or bookmark
>
> Everything is controlled by a PlaceChangeEvent. So, on a PCE the new
> Activity (ActivityMapper calles setPlace(NewPlace) - which makes the
> start() method somewhat irrelevant but allows the same place to be
> called consecutively and have new params for each place)  and
> ContextWatcher (implements PCE.Handler) so both have a reference to
> the new Place. The Activity adds an a callback to the place
> (addOnValidCallback - other objects which need to know when the Place
> and AppWide info is valid) and the ContextWatcher adds a callback to
> the place for onContextCheck (basically the place will make sure it
> has the necessary data it needs then hands control over to the
> ContextWatcher. The ContextWatcher does its thing and then calls
> place.startOnValidCallbacks. The place will then go through all
> callbacks that need to know everything is valid (The activity and any
> other object that have been put on hold)
>
> The method has been working extremely well for keeping Application
> State, Place specific data, Refresh, Bookmark, Caching etc
>
> It does add some custom complexity to the mix and slightly changes the
> way an activity is started but has proved well worth it.
>
> on a PCE the place will take the String token given to its constructor
> and then check to make sure the Client Cache has all the necessary
> data (retrieving it when needed).
>
>
> On Jun 10, 2:08 pm, Ben Imp  wrote:
> > The bundle is presenter-agnostic.  It only contains application-wide
> state
> > and control objects.
> >
> > I do have two classes of presenters in my application, however.  Those
> that
> > get passed the ApplicationBundle are page presenters, and control the
> whole
> > screen (or at least the central content portion of it anyway).  They are
> > created in response to navigation events.  These, in turn, may create
> > component presenters and pass them specific bits of information, like an
> > instance of their view that was retrieved from somewhere in the main page
> > view interface, or a specific implementation of their model interface
> that
> > will play well with the rest of the page.
> >
> > Something like this:
> >
> > public XxxPagePresenter(ApplicationBundle bundle, XxxPageView view) {
> > this.bundle = bundle;
> > this.view = view;
> > this.model = new XxxPageModelImpl();
> > this.yyyComponentPresenter1 = new
> > YyyComponentPresenter(model.getYyyComponentModel(),
> > view.getYyyComponentView());
> > ...
> >
> > }
> >
> > -Ben
>
> --
> You received this message because you are subscribed to the Google Groups
> "Google Web Toolkit" group.
> To post to this group, send email to google-web-toolkit@googlegroups.com.
> To unsubscribe from this group, send email to
> google-web-toolkit+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/google-web-toolkit?hl=en.
>
>

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



Re: MVP pattern uncaught exception

2011-05-24 Thread Alisson Prestes
You must find the "caused by" on the stack trace:

Caused by: java.lang.NullPointerException: null

 at 
com.rourevell.booking.client.ui.ControlPanelViewImpl.(ControlPanelViewImpl.java:80)

 at 
com.rourevell.booking.client.service.impl.ClientFactoryImpl.getControlPanelView(ClientFactoryImpl.java:37)

 at 
com.rourevell.booking.client.activity.ControlPanelActivity.start(ControlPanelActivity.java:21)
...

It seems that you tried to acess a variable without checking if it's null
and got this error. Did you initialize the variable?

Alisson Prestes
www.google.com/profiles/javalisson



On Tue, May 24, 2011 at 5:36 AM, Jordi Planadecursach
wrote:

> Hello guys,
>
> I have an exception in the following code using the MVP pattern. I'm
> just iniciaiting myself to the GWT world and I would need some help.
>
> Call:
>
> public class LoginActivity extends AbstractActivity implements
> LoginView.Presenter {
>private ClientFactory clientFactory;
>[...]
>public void goToControlPanel() {
>clientFactory.getPlaceController().goTo(new
> ControlPanelPlace("controlPanelPlace"));
>}
>
> Stack trace:
>
> 10:26:01.019 [ERROR] [rourevell_booking] Uncaught exception escaped
> com.google.gwt.event.shared.UmbrellaException: One or more exceptions
> caught, see full set in UmbrellaException#getCauses
>at
> com.google.gwt.event.shared.EventBus.castFireEvent(EventBus.java:70)
>at
> com.google.gwt.event.shared.SimpleEventBus.fireEvent(SimpleEventBus.java:
> 57)
>at
> com.google.gwt.place.shared.PlaceController.goTo(PlaceController.java:
> 136)
>at
>
> com.rourevell.booking.client.activity.LoginActivity.goToControlPanel(LoginActivity.java:
> 29)
>at com.rourevell.booking.client.ui.LoginViewImpl
> $1$1.onSuccess(LoginViewImpl.java:61)
>at com.rourevell.booking.client.ui.LoginViewImpl
> $1$1.onSuccess(LoginViewImpl.java:1)
>at
>
> com.google.gwt.user.client.rpc.impl.RequestCallbackAdapter.onResponseReceived(RequestCallbackAdapter.java:
> 232)
>at
> com.google.gwt.http.client.Request.fireOnResponseReceived(Request.java:
> 287)
>at com.google.gwt.http.client.RequestBuilder
> $1.onReadyStateChange(RequestBuilder.java:395)
>at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>at
> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:
> 39)
>at
>
> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:
> 25)
>at java.lang.reflect.Method.invoke(Method.java:597)
>at
> com.google.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:
> 167)
>at
>
> com.google.gwt.dev.shell.BrowserChannelServer.reactToMessagesWhileWaitingForReturn(BrowserChannelServer.java:
> 326)
>at
>
> com.google.gwt.dev.shell.BrowserChannelServer.invokeJavascript(BrowserChannelServer.java:
> 207)
>at
> com.google.gwt.dev.shell.ModuleSpaceOOPHM.doInvoke(ModuleSpaceOOPHM.java:
> 132)
>at
> com.google.gwt.dev.shell.ModuleSpace.invokeNative(ModuleSpace.java:
> 561)
>at
> com.google.gwt.dev.shell.ModuleSpace.invokeNativeObject(ModuleSpace.java:
> 269)
>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:214)
>at sun.reflect.GeneratedMethodAccessor20.invoke(Unknown Source)
>at
>
> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:
> 25)
>at java.lang.reflect.Method.invoke(Method.java:597)
>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:
> 167)
>at
>
> com.google.gwt.dev.shell.BrowserChannelServer.reactToMessages(BrowserChannelServer.java:
> 281)
>at
>
> com.google.gwt.dev.shell.BrowserChannelServer.processConnection(BrowserChannelServer.java:
> 531)
>at
>
> com.google.gwt.dev.shell.BrowserChannelServer.run(BrowserChannelServer.java:
> 352)
>at java.lang.Thread.run(Thread.java:619)
> Caused by: com.google.gwt.event.shared.UmbrellaException: One or more
> exceptions caught, see full set in UmbrellaException#getCauses
>at
>
> com.google.gwt.activity.shared.ActivityManager.onPlaceChange(ActivityMa

Re: GWT and Developing UI

2011-05-23 Thread Alisson Prestes
For "1" and "2" I would use a FlowPanel and some CSS.

Alisson Prestes
www.google.com/profiles/javalisson



On Mon, May 23, 2011 at 4:49 PM, Ash  wrote:

> Some insights would  be definitely helpful.
>
>
> On May 22, 12:28 am, Ash  wrote:
> > We have a application that we have coded using GWT, Java, JDO, JPA.
> > We have almost written our code for crud logic and its time to look at
> > the development of UI. I am new to gwt and trying to explore some
> > options for developing UI using gwt.
> >
> > I am little lost and would like to know whats the best way to go with
> > when developing UI with GWT.
> > I am using UiBinder but would like to know the following:
> >
> > 1) How to autosize custom widgets. Make panels expand or decrease in
> > size when custom widgets with dynamic content are placed inside
> > panels.
> > 2) What strategies to use for overall placing of widgets and elements
> > that work in all major browsers.
> > 3) Any other tips for developing a great looking UI using gwt is
> > really appreciated.
> >
> > Thanks,
> > Ash
>
> --
> You received this message because you are subscribed to the Google Groups
> "Google Web Toolkit" group.
> To post to this group, send email to google-web-toolkit@googlegroups.com.
> To unsubscribe from this group, send email to
> google-web-toolkit+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/google-web-toolkit?hl=en.
>
>

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



Re: How to learn use GWT

2011-05-20 Thread Alisson Prestes
I highly recommend the tutorials on the official website, they're very
good.

When you know the basics (how to create simple UI and how to communicate
with a server) it's time to learn MVP model. I recommend "Model View
Presenter - A Short Presentation" (
http://www.youtube.com/watch?v=oiNfPjV72lg) and as Ryan said before, "Google
I/O 2009 - Best Practices for Architecting GWT App" (
http://www.youtube.com/watch?v=PDuhR18-EdM). and "Google I/O 2010 -
Architecting GWT apps" (http://www.youtube.com/watch?v=M5x6E6ze1x8).

Alisson Prestes
www.google.com/profiles/javalisson

On Fri, May 20, 2011 at 6:20 AM, Yannis BRES  wrote:

> Hi !
>
> Just in case you can read French (or for other people who will read
> this post), the "Programmation GWT 2 : Développer des applications RIA
> et Ajax avec Google Web Toolkit" book by Sami Jabber
> (
> http://www.amazon.fr/Programmation-GWT-D%C3%A9velopper-applications-Toolkit/dp/2212125690/
> )
> remains, IMHO as AFAICT ;-), the most complete book that focuses on
> GWT (and, e.g. not on GAE).  However, this book is more than 6 month
> old ;-) => only GWT 2.0 !
> A bit more updated (circa GWT 2.1) and in English but less focused on
> GWT only, I'd recommend "Google App Engine Java and GWT Application
> Development", by Daniel Guermeur and Amy Unruh
> (
> https://www.packtpub.com/google-app-engine-java-and-gwt-application-development/book
> ).
>  Some of the apparently GAE specific chapters actually talk about more
> generic frameworks (JDO & co) that GAE implements.
> Each of these books quite nicely complement all the documentation your
> can already get from the official site.
>
> Best regards,
>   Yannis
>
> --
> You received this message because you are subscribed to the Google Groups
> "Google Web Toolkit" group.
> To post to this group, send email to google-web-toolkit@googlegroups.com.
> To unsubscribe from this group, send email to
> google-web-toolkit+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/google-web-toolkit?hl=en.
>
>

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



Re: Creating a Dialog Box that Returns Data to its Caller

2011-05-14 Thread Alisson Prestes
You could pass a output variable as an argument to your custom widget and
let the variable be set whenever it's necessary.

The other approach is, just as you said, to create a custom event that would
carry the information and add a method to MyDialogCompositeClass  that takes
as the parameter a custom event handler that handles this custom event.
Inside the event handler, set the data from the event to your variable.

Creating the custom event and the custom event handler takes some effort,
but I think it's worth the effort.


Alisson Prestes
www.google.com/profiles/javalisson



On Fri, May 13, 2011 at 4:43 PM, Murray  wrote:

> I am struggle with this...
>
> I would like to create a dialogbox or popupanel via UiBinder that
> requires the
> user to enter first name and phone number (i.e.  ui:field='fname' ).
>
> From some "main" form, this dialog will be launched...
>
> @UiField MyDialogCompositeClass  mydialogorpopuppnael;
>
>
> dialogdata = mydialogorpopuppnael.show();
>
> where dialogdata is a structure that contains the items from the
> dialogbox.
>
> I know this is not  the way but rather I would need to pass an
> eventhandler etc..
>
> does anyone have an example of this out there?
>
> --
> You received this message because you are subscribed to the Google Groups
> "Google Web Toolkit" group.
> To post to this group, send email to google-web-toolkit@googlegroups.com.
> To unsubscribe from this group, send email to
> google-web-toolkit+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/google-web-toolkit?hl=en.
>
>

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



Re: Where to store global (application) variables?

2011-05-04 Thread Alisson Prestes
I use ClientFactory for storing data about the user, but it's not sensitive
data. If your data is sensitive, I don't if this is the best option.

Alisson Prestes
www.google.com/profiles/javalisson



On Wed, May 4, 2011 at 7:28 PM, Brandon Donnelson
wrote:

> I make a widget and send it to all my other widgets through the
> contructors. I call that widget ClientPersistence class.
>
> brandon donnelson
> http://gwt-examples.googlecodecom
>
> --
> You received this message because you are subscribed to the Google Groups
> "Google Web Toolkit" group.
> To post to this group, send email to google-web-toolkit@googlegroups.com.
> To unsubscribe from this group, send email to
> google-web-toolkit+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/google-web-toolkit?hl=en.
>

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



Re: GWT - Capture values of dynamically created components

2011-05-02 Thread Alisson Prestes
You can

   - use a simple ArrayList to store the values and
   - other ArrayList to store the widgets
   - create a function to update the values in the values ArrayList, that
   receives a integer that represents the position you're altering
   - create a click handler for each hyperlink with a class attribute called
   "index". Each hyperlink will have a single index and this is the way it will
   tell your application which of the groups has been altered

I think this is simple to implement and will solve your problem.

Alisson Prestes
www.google.com/profiles/javalisson



On Mon, May 2, 2011 at 10:43 AM, Bhavin  wrote:

> Hi,
>
> I have a GWT page with 2 text boxes, 1 hyperlink and 1 button
> initially (on page load).
> When I click on the hyperlink, I add another text box (dynamically
> without refreshing the page).
>
> Now when I click the button, I need to capture the values that lie in
> all the three text boxes. How can I do it?
>
> I am desparately looking for some help on this area because I am
> working on a critical project and badly need help on this.
>
> --
> Thanks!
> Bhavin
>
> --
> You received this message because you are subscribed to the Google Groups
> "Google Web Toolkit" group.
> To post to this group, send email to google-web-toolkit@googlegroups.com.
> To unsubscribe from this group, send email to
> google-web-toolkit+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/google-web-toolkit?hl=en.
>
>

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