Re: History question

2009-08-22 Thread Jan Ehrhardt
If you select one of the libraries, listed there, you will come to the wiki,
where you'll find URLs with '#'. It's the only save way to get history
behaviour in an GWT app. You can try others, but they won't work so smooth.
I think, the reason, why there are URLs without '#', is, that the page isn't
a GWT app. It's a plain webpage with maybe a little script on one or another
page.

Regards
Jan Ehrhardt

On Sat, Aug 22, 2009 at 7:09 PM, MamboJumbo  wrote:

>
> Does anyone know how GWT history is maintained in
> http://code.google.com/p/gwt-google-apis
> website? There are no # signs in the URLs of the pages. Is there any
> other way to implement history other than explained in GWT tutorials?
> (like this one http://gwttutorials.com/2009/08/06/gwt-history/#more-215)
> Thank you.
> >
>

--~--~-~--~~~---~--~~
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: Why do we define AsyncCallbacks inline?

2009-08-22 Thread Jan Ehrhardt
It's common practice to use inner classes in Java for listeners or other
simple things like callbacks.
What you want to do in the case of a callback, is invoking a method after
the the asynchronous RPC has been finished. The easiest solution would be,
to put this method as an argument to the RPC method, but since Java has no
closures, using inner classes is a nice solution. In Java 1.4, where no
inner classes where available, people implemented the AsyncCallback
interface in the class, which was calling the RPC method, so they could do
something like:

service.getSomthing(this);

But with Java 5 inner classes have become the prefered way.
Sure, you can also create your own class for this, but that's the worse
practice, I think.

What would be the best solution for this, you think?

Regards
Jan Ehrhardt

On Sat, Aug 22, 2009 at 10:43 PM, jack  wrote:

>
> In every RPC example I've seen, AsyncCallback are all defined inline?
> Why is this so?  What are the advantages?
>
> 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-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: " No source code is available for ... "

2009-08-22 Thread venki

There you are using Generator class in ur module right?? Go to API to
find it's corresponding module XML file name. So that you can find
it's module name and then inherit that module in ur module xml
descriptor file.

On Aug 5, 4:46 am, "ent...@googlemail.com" 
wrote:
> I am abit tied of this error messages . I understand that i need
> something inherit :) . but how to understand what should i inherit
> what xml file and where can i find this info ? for example for
>
> "[ERROR] Line 6: No source code is available for type
> com.google.gwt.core.ext.Generator; did you forget to inherit a
> required module?"
>
> what my actions  should be  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-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 use a suggestbox where the value does not have to be in the suggestions

2009-08-22 Thread Isaac Truett

suggestBox.setAutoSelectEnabled(false);



On Sat, Aug 22, 2009 at 6:54 PM, Jaap wrote:
>
> Hi,
>
> I want to you a suggestbox like google uses it on google.com. So on
> google.com if I am typing I get selections (but none is selected yet).
> If I then press arrow down I can select one of the suggestions but if
> my suggestion is not there I keep on typing and hit enter and it
> searches what I typed.
>
> However in GWT when I make suggest box it automatically selects the
> first entry and uses that. So let's say I typed "harry" and hit enter
> it will make the entry "harry potter" if that is the first suggestion.
> I don't want that behavior. I just want to search what the user has
> typed. Only when the users presses arrow down and selects one of the
> suggestions it should search for that suggestion.
>
> How can I achieve that?
>
> Thanks
>
> Jaap
> >
>

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



Hide pannel

2009-08-22 Thread rasp

Hi all!
How can I create some hide-panel, like this:
http://code.google.com/docreader/#p=google-web-toolkit-incubator&s=google-web-toolkit-incubator&t=google-web-toolkit-incubator
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-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
-~--~~~~--~~--~--~---



Why do we define AsyncCallbacks inline?

2009-08-22 Thread jack

In every RPC example I've seen, AsyncCallback are all defined inline?
Why is this so?  What are the advantages?

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-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: javascript in war folder not included after building war file

2009-08-22 Thread Frank

Try this way:




On Jul 4, 11:35 pm, Marko Vuksanovic 
wrote:
> I have copied ext-js library into war folder of my gwt project. Then I
> have included it in my project.gwt.xml file as follows:
>
>         
>         
>         
>         
>         
>         
>         
>         
>
> after building the project, using the ant script that was created by
> the gwt sdk command line tool, the ext folder is not included in the
> \js\ folder (nor in the ).
>
> There is also one more problem that I encountered - When I deploy the
> war file onto a server- when I typehttp://localhost:8080/project
> (which is the name of the war file as well as the gwt project itself)
> the application looks for the javascript files 
> athttp://localhost:8080/js/ext..
> and it should be looking for them athttp://localhost:8080/project/js/ext.
>
> Any help on this issue would be greatly appreciated.

--~--~-~--~~~---~--~~
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: javascript in war folder not included after building war file

2009-08-22 Thread Frank

Try this way:


On Jul 4, 11:35 pm, Marko Vuksanovic 
wrote:
> I have copied ext-js library into war folder of my gwt project. Then I
> have included it in my project.gwt.xml file as follows:
>
>         
>         
>         
>         
>         
>         
>         
>         
>
> after building the project, using the ant script that was created by
> the gwt sdk command line tool, the ext folder is not included in the
> \js\ folder (nor in the ).
>
> There is also one more problem that I encountered - When I deploy the
> war file onto a server- when I typehttp://localhost:8080/project
> (which is the name of the war file as well as the gwt project itself)
> the application looks for the javascript files 
> athttp://localhost:8080/js/ext..
> and it should be looking for them athttp://localhost:8080/project/js/ext.
>
> Any help on this issue would be greatly appreciated.

--~--~-~--~~~---~--~~
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 change the arrow icon of DisclosurePanel

2009-08-22 Thread alessandro.loche

http://groups.google.com/group/Google-Web-Toolkit/browse_thread/thread/4d0f853de76af51e

Ale

On 22 Ago, 20:56, hezjing  wrote:
> Hi
> May I know how to change the arrow icon of the DisclosurePanel?
>
> --
>
> Hez

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



how to customize brows window (i want to show only specific file formats to select)

2009-08-22 Thread Rishi

i am new to GWT, i am creating a file upload web application, could
you suggest me how i can customize the browse window, i want to show
only specific file formats(type) to upload.


thank you in advance.

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



Re: What is Google App Engine?

2009-08-22 Thread GTM

I'm still kind of new to this, so from what I understand from your
post and reading, google app engine would allow me to upload my own
projects onto googles website (which is what you mean by google's
existing infrastructure, right?). If I choose not to use it, the only
difference is that I will not be allowed to upload it to google's site
(right?)

On Aug 21, 2:43 pm, Dalla  wrote:
> Google App Engine is Googles cloud platform, which allows you to use
> Googles existing infrustructure for your own projects.
> You don´t need to use it at all if you don´t want to.
>
> Read more athttp://code.google.com/intl/sv-SE/appengine/
>
> On 21 Aug, 19:14, GTM  wrote:
>
>
>
> > I accidentally enabled it and the program I moved over said that some
> > lines were not supported. I tried reading up on it on google but im a
> > little confused. Do I need it to upload stuff onto the internet, or
> > for my programs to work?
--~--~-~--~~~---~--~~
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
-~--~~~~--~~--~--~---



How to use a suggestbox where the value does not have to be in the suggestions

2009-08-22 Thread Jaap

Hi,

I want to you a suggestbox like google uses it on google.com. So on
google.com if I am typing I get selections (but none is selected yet).
If I then press arrow down I can select one of the suggestions but if
my suggestion is not there I keep on typing and hit enter and it
searches what I typed.

However in GWT when I make suggest box it automatically selects the
first entry and uses that. So let's say I typed "harry" and hit enter
it will make the entry "harry potter" if that is the first suggestion.
I don't want that behavior. I just want to search what the user has
typed. Only when the users presses arrow down and selects one of the
suggestions it should search for that suggestion.

How can I achieve that?

Thanks

Jaap
--~--~-~--~~~---~--~~
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 plugin framework with GWT

2009-08-22 Thread Nathan Wells

Dave,

the first thing need to know is that you're attempting to break some
core rules. Widgets can only be created on the client-side. There are
numerous reasons for this, but essentially it boils down to this: RPC
calls should be about the model... data transfer, not UI component
transfer. That's not to say that what you're talking about is
impossible, it's just not going to be as pretty as you would like it
to be. You can make it so that your TreeItem contains an "HTML"
widget. Then you would probably provide some hook on the server-side
for someone to specify what that html is.

Again, this breaks the rules, though


On Aug 21, 4:56 am, Dave  wrote:
> Hi,
>
> I am trying to figure out how to create a plugin framework with GWT,
> let me explain
>
> I have created an application that has a menu on the left side and a
> form on the right site of the screen.  The menu is a tree and the form
> is a vertical panel (think of the example mail application).
>
> I have created a new class called CustomTreeItem that extends
> TreeItem.
> My custom class contains a member variable which is a vertical panel.
> When a user click on a instance of CustomTreeItem in the menu the
> vertical panel is displayed on the right site of the screen.
>
> I would like to extend this by allowing developers to produce custom
> forms. i.e allow developers to add in there own CustomTreeItems,
> without having to recompile with my code.
> My inital plan was to have a directory in the classpath, so at runtime
> a class loader on the server side would look for any classes that were
> derived from my CustomTreeItem in that folder and load them.
> The client would make an RPC request for the tree items, so it could
> build up the Tree.  I quickly discovered that VerticalPanel couldn't
> be serialized (I assume because this is translated to javascript), so
> this wouldn't work.
>
> Is it possible for developers to create a vertical panel, and then
> translate it to js (storing it somewhere on the server)
> Then within my application if I know the name of the js/verticalpanel
> instance, load in and construct the panel?
>
> Any info/ideas/suggestions would be appreciated
>
> Cheers
--~--~-~--~~~---~--~~
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
-~--~~~~--~~--~--~---



How to change the arrow icon of DisclosurePanel

2009-08-22 Thread hezjing
Hi
May I know how to change the arrow icon of the DisclosurePanel?


-- 

Hez

--~--~-~--~~~---~--~~
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: At new item to a list at each position

2009-08-22 Thread Tobe

The next problem is how to evaluate this nested form? Is there any
good way to structure the fields and evaluate the complete form
together with GWT?

On Aug 18, 2:42 pm, Tobe  wrote:
> I had AbsolutePanels with other Widgets added to it, but now I just
> have one Widget in each. In other cases I used VerticalPanels instead
> of AbsolutePanels to get access to the different Widgets in the rows.
> Unfortunately I can't get the Widget of a Widget e. g. when I have a
> ListBox inside a VerticalPanel and the VerticalPanel inside a
> FlexTable by using flextable.getWidget(1,0).getWidget(0);, but it
> works when I get the Widgets step by step and cast it in each step.
>
> On Aug 17, 11:48 pm, Ian Bambury  wrote:
>
>
>
> > You should only ever have one widget in the cell. The method setWidget(int
> > row, int column, Widget widget) removes any existing widget.
> > I think you might need a design review ;-)
>
> > Ian
>
> >http://examples.roughian.com
>
> > 2009/8/17Tobe
>
> > > Ok, but in this case inside the (1,0) there can be some more Elements
> > > and always the last one is the nested FlexTable I need. I
> > > tried .getElement().getLastChild() but can't cast the received Node to
> > > a FlexTable.
>
> > > On Aug 17, 6:41 pm, Ian Bambury  wrote:
> > > > Can we try this in words, not html :-)
> > > > You have an outer table with 'Insert' buttons in the even rows
> > > (0,2,4,...)
> > > > and child tables in the first column of the odd rows (1,3,...)
>
> > > > To access the first child table, you use
>
> > > > FlexTable inner = (FlexTable)outer.getWidget(1, 0);
>
> > > > Ian
>
> > > >http://examples.roughian.com
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To post to this group, send email to google-web-toolkit@googlegroups.com
To unsubscribe from this group, send email to 
google-web-toolkit+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/google-web-toolkit?hl=en
-~--~~~~--~~--~--~---



History question

2009-08-22 Thread MamboJumbo

Does anyone know how GWT history is maintained in 
http://code.google.com/p/gwt-google-apis
website? There are no # signs in the URLs of the pages. Is there any
other way to implement history other than explained in GWT tutorials?
(like this one http://gwttutorials.com/2009/08/06/gwt-history/#more-215)
Thank you.
--~--~-~--~~~---~--~~
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: Question about app context.

2009-08-22 Thread Chad

David,

You don't have to do all that. Just reference your images as:

"images/status.png"

Notice the lack of the slash before images. If your images folder is
in your war folder, it should work in both hosted mode and web mode.
That slash would force a non-relative path requiring you to go through
the extra hoops you found.

HTH,
Chad

On Aug 21, 4:35 pm, "David C. Hicks"  wrote:
> Found it.
> GWT.getHostPageBaseURL().
>
>
>
> David C. Hicks wrote:
> > To *almost* answer my own question, I think this comes down to knowing
> > what the web context root is to be pre-pended to URLs.  So, now I'm
> > looking for a way to get that context root.
--~--~-~--~~~---~--~~
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
-~--~~~~--~~--~--~---



Tab Panel with one dropdown

2009-08-22 Thread James

Hello All,
I have a requirement to convert a header bar with a list of menu items
that run left to right across the top of a page to a tab panel. What
they want is when the user selects a tab and hovers over the text at
the bottom of the tab with the mouse, a single dropdown item appears
that will open up a new page if it's clicked.

The basic layout would be something like this below using surrounding
X's to give a somewhat graphical appearance:
(Hey I'm no artist!):

X
X tab title 
X   
X tab text at the bottom of the tab XX
XX
   dropdown item here

What is the best way to do the dropdown here? Do I put a listbox in as
they want it directly below the tab on the right side or Is a menu
item the right choice or should I use something else?
Thanks,
jamesEston
--~--~-~--~~~---~--~~
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
-~--~~~~--~~--~--~---



Tab Panel with one dropdown

2009-08-22 Thread James

Hello All,
I have a requirement to convert a header bar with a list of menu items
that run left to right across the top of a page to a tab panel. What
they want is when the user selects a tab and hovers over the text at
the bottom of the tab a dropdown appears that will open up a new page
if the dropdown is clicked there is only one dropdown item available.
The basic layout would be something like this:

tab title

tab text at the bottom of the tab
dropdown item is here
(on the right side of the tab)



--~--~-~--~~~---~--~~
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: generics, events, dependency injection

2009-08-22 Thread Etienne Neveu

Hi,

I believe Ricardo was talking about using google-gin (Guice for GWT),
and using what they call a "provider method":

In Guice, when you want to create your classes in a specific way, you
can either create a class implementing Provider (
http://code.google.com/p/google-guice/wiki/ProviderBindings ), or you
can add a "provider method" in your Guice module to avoid creating an
entire class for that ( 
http://code.google.com/p/google-guice/wiki/ProvidesMethods
).


Regards,
-Etienne

On Aug 18, 5:25 pm, Eugen Paraschiv  wrote:
> Quick question...when you say provider, what do you mean exactly? Is
> there a specific provider method pattern?

--~--~-~--~~~---~--~~
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: Problem with GWT RPC when parameter contains collection.

2009-08-22 Thread Yanick

On Aug 21, 2:01 pm, Arkady  wrote:
> Actually the request is never posted and therefore never arrives to
> the impl class. I suspect that the problem is with the serialization
> of the MyItem class.
>

Your interface may be serializable, but are all your fields also
serializable in your implementations of this class? (ie. are all
members of AItem extends MyItem serializable?)
--~--~-~--~~~---~--~~
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 application does not run ie7

2009-08-22 Thread Ian Bambury
Obviously *your app* does not work on certain Ie7 machines but unless, as
Arthur requested, you indicate the error you are getting, or you post some
code to reproduce the problem, there isn't much anyone can do to help.
Ian

http://examples.roughian.com


2009/8/22 aftershock 

>
> No, I have not resiricted it.
> Since I asked this question, I came across the tool Ietester.
> I managed to find that the application works in Ie7,ie6 in ietester
> but it does not work on another machine where IE7 was installed.
>
> I guess it means that it does not work on certain Ie7 machines...
> I
> >
>

--~--~-~--~~~---~--~~
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 plugin framework with GWT

2009-08-22 Thread Yanick

On Aug 21, 6:56 am, Dave  wrote:
> I would like to extend this by allowing developers to produce custom
> forms. i.e allow developers to add in there own CustomTreeItems,
> without having to recompile with my code.
> My inital plan was to have a directory in the classpath, so at runtime
> a class loader on the server side would look for any classes that were
> derived from my CustomTreeItem in that folder and load them.
> The client would make an RPC request for the tree items, so it could
> build up the Tree.  I quickly discovered that VerticalPanel couldn't
> be serialized (I assume because this is translated to javascript), so
> this wouldn't work.

Hi,
I didn't write much code yet in GWT (been watching projects for quite
some times now, but never got into serious programming with it...
until now), but your approach doesn't seem write from the base. :)
Sorry to pull this off so soon, but there is a lack of reusable
pattern here. Patterns are proven and tested in software engineering.

OO programming is nice because you can relate to real world example to
explain stuff; in a big corporation, the more responsibilities
employees have, the harder it is to manage them, and the whole
society. (Think about replacing 1 employee to knows many things in the
corporation vs. replacing an employee who know only one thing, for
example.) Well, programming is pretty much the same, the more parts of
you application knows about other parts, the harder it is to add/
remove parts of it.

For example, take a look at the MVP pattern, you'll see that your tree
doesn't even have to know your vertical panel at all. This way, you
can provide anything to handle your tree item selection. One option
would have to have the tree items have a method like node.getType()
that would return some enum value. Upon item click, an event would be
fired across the event bus based on the node type, which would then
notify the associated command, which would then execute the proper
code to display whatever needs to be displayed with the selected node.
Then adding new functionality to your application (or removing some)
would simply be a matter of registering new node types (model),
associate them with new events (provider), and display whatever needs
to be displayed by the associated action command in an associated
widget (view).

The level of complexity is up to you. But don't just take my word for
it, Google IO 2009 have some nice educational videos that you can
watch to be convinced :)

Hope this helps.
--~--~-~--~~~---~--~~
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: "Use an Event Bus" - Ray

2009-08-22 Thread lowecg2004

Hi Nathan,

The gwt-presenter project defines an EventBus class which wraps the
HandlerManager.  I've put an example on my blog that converts the
default starter application that is created by the Google Plugin for
Eclipse to use:

gwt-presenter (MVP, Event Bus Patterns);
gwt-dispatch (Command Pattern);
google gin (Dependency Injection).

http://blog.hivedevelopment.co.uk/2009/08/google-web-toolkit-gwt-mvp-example.html

I hope you find it useful,

Chris.

On Aug 21, 10:41 am, Nathan  wrote:
> Okay, thanks everyone for your comments.  That certainly helps.
>
>   Now I'd like to extend this topic to a "how" -- Do we have any good
> examples of an EventBus wrapper ("decorator?") for the HandlerManager
> class?  I can think of a few different design approaches to it, and
> I'd rather stick to convention or to whatever makes GWT most able to
> compile effectively... Don't see any reason to re-invent the wheel on
> this one, and this seems like something that has almost certainly been
> written in some form of open source way by now... :)
>
>   Thanks for any thoughts on the subject.
>
> -nathan
--~--~-~--~~~---~--~~
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: "Use an Event Bus" - Ray

2009-08-22 Thread eneveu

Hi,

In our application, we use the "EventBus" interface (
http://code.google.com/p/gwt-presenter/source/browse/trunk/src/main/java/net/customware/gwt/presenter/client/EventBus.java
) and "DefaultEventBus" implementation (
http://code.google.com/p/gwt-presenter/source/browse/trunk/src/main/java/net/customware/gwt/presenter/client/DefaultEventBus.java
) from the gwt-presenter project ( http://code.google.com/p/gwt-presenter/
- which is incidently my favorite library for the MVP pattern so far,
thanks David!).

We program against the "EventBus" interface in our code, which is
injected by google-gin.

The "DefaultEventBus" implementation simply extends GWT's
"HandlerManager" and provides a Guice-injectable constructor (thus
avoiding the need to create a guice provider, which would have been
needed if we tried to inject a HandlerManager directly).
Another solution would be to wrap a "HandlerManager" and delegate to
it. The GWT compiler should optimize out such delegate methods calls.

In both cases we would use the "HandlerManager" class under the hood,
as suggested by Ray Ryan in his talk. This class is at the heart of
GWT's new event system, and I believe it has been optimized by the GWT
team to perform very well.

Also, such an EventBus handles only GwtEvents. At first it will be
painful to create ***Event classes and ***Handler interfaces and the
necessary boilerplate code, but you will quickly get the hang of it.
And the "new" GWT 1.6 event system design is quite interesting.

Benefits of this architecture:
- Flexibility / Low coupling: your classes only know the "EventBus"
interface, so you may change the implementation in the future if you
so choose. In such an event, you would simply need to bind the new
implementation in your GIN module:
bind(EventBus.class).to(MyNewEventBusImplementation.class).in
(Singleton.class);
- Testability: you can easily mock the "EventBus" interface in your
tests.
- Plus all the EventBus pattern benefits...

Note on using external libraries directly:
If you wish to add methods to your EventBus interface and to insulate
your application from using an external library directly, you could
create your own "MyEventBus" interface, which would extend gwt-
presenter's "EventBus" and add some methods, and then create a
"MyDefaultEventBus" implementation (which could extends
DefaultEventBus if you want it to), and bind them in your GIN Module.


Regards,
-Etienne
--~--~-~--~~~---~--~~
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: Confused about GWT + App Engine

2009-08-22 Thread Shawn Brown

On Sat, Aug 22, 2009 at 12:18 AM, philipmac wrote:
>
> Just to clarify, all of the AppEngine stuff runs exclusively upon
> Google Hardware, correct?
>
> That is, I cannot get my own local instance of an AppEngine.

Well yes and no.  Yes you can run in hosted mode on a local server
where your database will be local.  But no that is only for
development purposes and may be ever so slightly different that the
real deal -- i.e works in hosted mode but throws and error when
deployed to AppEngine.

Shawn

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



Display form in GWT after redirect.

2009-08-22 Thread kamal

Hi,
I want to redirect the to the other java class(dashboard.java)
which is working fine, but after redirecting t that page, i want to
add widgets and panels but i m not getting that how to display. To
redirect i have given url that i have defined in web.xml, but error is
that it is not a servlet, and if i give servlet i have to make that
file as a servlet but then it is not adding widgets and error occurs
of initialization . So i want to know that what url should i give in
web.xml and in which package should be that file ? and if other
possible way then it is welcomed.

This is code for redirection in entrypoint class - "Window.open
(GWT.getModuleBaseURL()+"dashboard","_self",null);"
and in web.xml :- 
DashboardImpl
icopals.server.DashboardImpl
  

  
DashboardImpl
/icopals_2/dashboard
  

Dashboardimpl is class in which widgets display code is displayed.


How i can add widgets in DashboardImpl.java to display on redirection.
--~--~-~--~~~---~--~~
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: Image with embeded text

2009-08-22 Thread luigi

Hi, you can put a Image img=new Image() and after you can put some
HTML html=new HTML("text blabala"); and with style
you can postion the text inside the image with absolute position, and
after you can change the text with some native method
you can do $wnd.document.getElementbyId("1").innerHTML="new text
blabla..."
nice work

On 21 ago, 20:04, svanhook  wrote:
> Does anyone know how I can put text on an image using gwt? I need to
> be able to dynamically change the text when requested. 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-toolkit@googlegroups.com
To unsubscribe from this group, send email to 
google-web-toolkit+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/google-web-toolkit?hl=en
-~--~~~~--~~--~--~---



Re: Problem with GWT RPC when parameter contains collection.

2009-08-22 Thread DaveS

Have you tried enabling debugging in the browser, to see if any JS
exceptions are being thrown?

On Aug 21, 7:01 pm, Arkady  wrote:
> Actually the request is never posted and therefore never arrives to
> the impl class. I suspect that the problem is with the serialization
> of the MyItem class.
>
> On Aug 20, 5:42 pm, tolga ozdemir  wrote:
>
> > Can you post the method of your impl class here to investigate the
> > problem? I do not know yet but maybe my sample helps you to compare
> > your code as well..
>
> >http://www.tolgaozdemir.net/2009/08/19/gwt-101-lessons-2-gwt-17-with-...
>
> > On Aug 20, 11:37 pm, Arkady  wrote:
>
> > > I am having problem with GWT RPC in the following scenario.
>
> > > I have a service:
>
> > > public interface MyService extends RemoteService {
>
> > >       public MyResult getMyResult(MyParam param);
>
> > > }
>
> > > with corresponding Async version and Impl version. MyParam class
> > > contains ArrayList:
>
> > > public class MyParam implements Serializable {
> > >    private ArrayList items;
>
> > >    public MyParam() {
>
> > >    }
>
> > >    public MyParam(ArrayList items) {
> > >          this.items = items;
> > >    }
>
> > >    public ArrayList getItems() {
> > >          return items;
> > >    }
>
> > >    public void setItems(ArrayList items) {
> > >          this.items = items;
> > >    }
>
> > > }
>
> > > public class MyItem implements Serializable {
>
> > > }
>
> > > When I invoke getMyResult(new MyParam(new ArrayList()))
> > > everything works fine and the execution reaches the Impl class on the
> > > server. But if I invoke getMyResult() with non-empty list of items the
> > > request is never posted to the server and there is no exception in the
> > > log.
>
> > > Any help will be greatly appreciated.
>
> > > Thanks.- Hide quoted text -
>
> > - Show quoted text -
--~--~-~--~~~---~--~~
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 configure Jetty in GWT

2009-08-22 Thread willemsl...@gmail.com

Hi Christoph,

Thanks for the info, that was a real good starting point.

Also helpful where these posts:
http://humblecode.blogspot.com/2009/05/gwt-16-using-jndi-datasource.html
http://groups.google.com/group/Google-Web-Toolkit/browse_thread/thread/3f5369b0aea1a265
http://groups.google.com/group/Google-Web-Toolkit/browse_thread/thread/d37a823d8fac8693

I'm putting some advice and my configuration files here, they might be
useful to somebody.

First about about my webapp: it uses jndi to lookup a datasource, and
applies container managed security via JDBCRealm, all data is stored
in an Oracle database.
It was developed using GWT 1.5, and has a working Tomcat
configuration.

In the end of my conversion to Jetty, I didn't manage to get the
container-managed-security via JDBCRealm working because Jetty assumes
the ID's in the tables are ints (mine are varchar2s), so it throws the
java.sql.SQLException: Fail to convert to internal representation.
For development/debugging purposes a HashUserRealm is fine, and it's
very easy to setup.

--
- I assume you have your oracle jdbc jar in your lib folder )
--
- download jetty-6.1.19.zip, unzip and copy lib/naming/jetty-
naming-6.1.19.jar and lib/plus/jetty-plus-6.1.19.jar to your war/WEB-
INF/lib
--
- add to your eclipse launch:  (advice from
http://humblecode.blogspot.com/2009/05/gwt-16-using-jndi-datasource.html)
   -
Djava.naming.factory.initial=org.mortbay.naming.InitialContextFactory
--
- Put the security constraint and database resource ref in your war/
WEB-INF/web.xml


..
 .. .. 
etc..
..

  
  MyWebApp
  MyWebApp
  /protected/*
  
  
  admin
  user
  
  

  
FORM
MyWebApp

  /logon.jsp
  /logonerror.jsp

  

  
My DataSource Reference For The Database
jdbc/myapp
javax.sql.DataSource
Container
  
..

--
Define your database and security in the war/WEB-INF/jetty-web.xml


http://jetty.mortbay.org/configure.dtd";>


  

java:comp/env/jdbc/myapp

  
jdbc:oracle:thin:@localhost:1521:XE
myapp_user
myapp_pwd
  

  

  

  

  MyWebApp
  config/dev_realm.properties

  

  

--
File: config/dev_realm.properties
bob:bob,admin

(yes, just one line with the username:password,role)
--

And fire it up!

I still get a warning though, when starting up my app:
[WARN] Unable to process 'file:war/WEB-INF/web.xml' for servlet

I guess it's to do with the security configuration in the web.xml,
I'll look at it later.

Regards,

Willem




On Aug 21, 10:19 am, cschoett  wrote:
> Maybe one of my earlier post helps 
> you:http://groups.google.com/group/google-web-toolkit/browse_thread/threa...
>
> Regards,
> Christoph
>
> On Aug 19, 4:14 pm, "willemsl...@gmail.com" 
> wrote:
>
> > Thanks for your answer, Lothar.
>
> > The info onjettyyou provided I had already found. What I am actually
> > looking for is that specific info in the context of GWT 1.7,
> > So as to be able to use all the debugging features (as well client as
> > server code debugging) when running my gwt-app in eclipse, in hosted
> > mode usingjettyas a server.
>
> > To rephrase my question: how do you configure jndi and container
> > managed security in theJettyinstance that comes along with GWT 1.7.
>
> > Ciao,
>
> > W.
>
> > On Aug 19, 2:26 pm, Lothar Kimmeringer  wrote:
>
> > > willemsl...@gmail.com schrieb:
>
> > > > I've recently migrated from GWT 1.5.x to 1.7.0 and I'm looking for
> > > > pointers to articles/documentation/... on:
> > > > 1) how to configure the JNDI lookup withinJetty(I want to define my
> > > > database connection details)
>
> > >http://www.google.de/search?q=jetty+jndi+configuration
>
> > > > 2) how to configure container managed security withinJetty
>
> > >http://www.google.de/search?q=jetty+container+managed+security
>
> > > > If the above are too specific, then maybe just how to configureJetty
> > > > in general, within the GWT - eclipse environment.
>
> > > That I was never doing, I always use the Tomcat-server being
> > > "shipped" with GWT. But installing a GWT-application is simply
> > > adding the WAR-file to the web-app-directory or define it as
> > > specific WebApplication.
>
> > > 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-toolkit@

Re: gwt application does not run ie7

2009-08-22 Thread aftershock

No, I have not resiricted it.
Since I asked this question, I came across the tool Ietester.
I managed to find that the application works in Ie7,ie6 in ietester
but it does not work on another machine where IE7 was installed.

I guess it means that it does not work on certain Ie7 machines...
I
--~--~-~--~~~---~--~~
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
-~--~~~~--~~--~--~---