GWT Obfuscation crashes iPad Safari browser

2010-11-16 Thread tbb
Hi all,
I discovered a strange problem with a pretty big GWT application. It's
about 6MB unobfuscated Javascript and about 2.4MB if compiled
obfuscated.
The app itself works fine in all major browsers and on the iPhone (IOS
4.1) if compiled as obfuscated Javascript. For quite a long time we're
having issues that it crashes iPad's Safari browser and after some
endless digging around I found that it works perfectly on the iPad if
it's compiled with the 'PRETTY' option.
Has anybody experienced anything similar? Could it be to the extreme
line lengths generated by the obfuscation??
It happens with BOTH GWT 2.0.4 and GWT 2.1.

Cheers
Thomas

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



Re: DockLayoutPanel inside UiBinder requires height=100%

2010-11-16 Thread suersh babu
Even I faced the same problem in UI binder only shows  the north side when I
put it in RootPanel I also wasted little time over it,  Thanks for
information provided.


Regards
Suresh Babu G

On Tue, Nov 16, 2010 at 12:58 PM, zixzigma zixzi...@gmail.com wrote:

 g:ScrollPanel : )

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




-- 
Regards

Suresh Babu G

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



Re: Problem with Google App Engine

2010-11-16 Thread Seb H
Hi Didier,

thanks for the good news. I haven't actually seen the Spring Roo framework
so far and I don't really need it. Can anyone point out how I can deploy my
App so that all used classes, including javax.swing.event.EventlistenerList
will be supported?

Thanks,
Sebastian

2010/11/15 Didier Durand durand.did...@gmail.com

 Hi Sebastian,

 Yes, when you use GWT in conjonction with Tomcat or any other app
 engine that you control, you can use whatever you want / need on the
 backend.

 Question: did you give the last devs between Spring and App Engine a
 chance ? See

 http://java.dzone.com/articles/creating-application-using?utm_source=feedburnerutm_medium=feedutm_campaign=Feed:+javalobby/frontpage+%28Javalobby+/+Java+Zone%29

 regards

 didier

 On Nov 15, 9:09 am, Sebastian Hob hoze...@googlemail.com wrote:
  Dear fellow GWT programmers,
 
  I would like to make a call to a java class that utilizes
  javax.swing.event.EventlistenerList as a private member. The call
  should be made from within the greetServer method in the
  GreetingServiceImpl class.
 
  Unfortunately, I get an error on the line of the
  javax.swing.event.EventlistenerList with the added information that
  this class is not supported by Google App Engine's Java Runtime
  Environment.
 
  Is it possible to replace the Google App Engine JRE with a full JRE
  when deploying to Tomcat?
 
  Thanks so much in advance!
 
  Sebastian

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



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



Re: Problem with Google App Engine

2010-11-16 Thread Shawn Brown
 thanks for the good news. I haven't actually seen the Spring Roo framework
 so far and I don't really need it. Can anyone point out how I can deploy my
 App so that all used classes, including javax.swing.event.EventlistenerList
 will be supported?

Deploy my App means to Tomcat right?

I don't know how to switch an AppEngine project to Tomcat but you
might try within Eclipse to:

1) take out the AE jars from your build path (maybe just by removing
the AE SDK from the libraries tab of your java build path (under
project, properties)
2) uncheck the google app engine validator (under project, properties,
Builders).

Then you have to deploy to Tomcat and get that set up to run in dev mode.

I wonder if starting with a fresh GWT project out of the box that
isn't GAE would be easier.

I think you intend to develop the way you have it though (as a GAE
project), and then just want to deploy to Tomcat.  I wouldn't try that
myself.

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-tool...@googlegroups.com.
To unsubscribe from this group, send email to 
google-web-toolkit+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/google-web-toolkit?hl=en.



RootLayoutPanel strange code using MVP

2010-11-16 Thread Baloe
Hi all,

We are using MVP as much as possible, but it has been a pain so far,
not a lot of documentation. There is one thing that we really couldn't
get right. Please see how much boilerplate blabla this application
needs, and see how ugly the class at the end is. We don't want the
class near the end. And if someone has a tip how to clean up this
code, please! Thanks a lot!

Baloe

public class OurApp implements EntryPoint {

@Override
public void onModuleLoad() {

AppGinjector injector = GWT.create(AppGinjector.class);
Root app = new Root();

EventBus eventBus = injector.getEventBus();
PlaceController placeController = injector.getPlaceController();
ActivityMapper activityMapper = injector.getActivityMapper();

ActivityManager activityManager = new
ActivityManager(activityMapper, eventBus);
activityManager.setDisplay(app);

AppPlaceHistoryMapper historyMapper =
GWT.create(AppPlaceHistoryMapper.class);
PlaceHistoryHandler historyHandler = new
PlaceHistoryHandler(historyMapper);
historyHandler.register(placeController, eventBus,
((AppPlaceController) placeController).getDefault());

historyHandler.handleCurrentHistory();
RootLayoutPanel.get().add(app);

Resources.Instance.css().ensureInjected();
}

private class Root extends LayoutPanel implements AcceptsOneWidget {
@Override
public void setWidget(IsWidget w) {
if (w == null) {
clear();
} else {
add(w);
}
}

}

}


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



Re: array of suggestBox?

2010-11-16 Thread Jack
If you just want the selected item then use

SuggestBox box = new SuggestBox(countryOracle);
box.addSelectionHandler(new SelectionHandlerSuggestion() {

  @Override
  public void onSelection(SelectionEventSuggestion event) {

 System.out.println(event.getSelectedItem());

  }

});

Or

SuggestBox box = new SuggestBox(countryOracle);
box.addValueChangeHandler(new ValueChangeHandlerString() {

  @Override
  public void onValueChanged(ValueChangeEventString event) {

 System.out.println(event.getValue());

  }

});

The first example gives you the object (country) that the user has
selected in the suggestion popup and the second one gives you the
string from the SuggestionBox's TextBox whenever it changes.

If you really want to override protected abstract
SuggestOracle.Suggestion getCurrentSelection() from the
SuggestionDisplay then you have to use

SuggestBox box = new SuggestBox(countryOracle, new TextBox(), new
YourCustomSuggestionDisplay());

where YourCustomSuggestionDisplay is

public class YourCustomSuggestionDisplay extends
DefaultSuggestionDisplay

or

public class YourCustomSuggestionDisplay extends
SuggestBox.SuggestionDisplay


Hope that helps.


On 15 Nov., 20:22, seven.reeds seven.re...@gmail.com wrote:
 Thanks,

 I am still such a java newbie that I was not thinking about the what I
 was really trying to accomplish.  I didn't need an array of suggest
 boxes.  Duh, on me.

 What I do need though is the proper way to get to the protected
 methods of the nested class: SuggestBox.SuggestionDisplay

 In there is the method

     protected abstract  SuggestOracle.Suggestion
 getCurrentSelection()

 I have seen some java tutorials that say that I can get at this method
 if I correctly extend the class... but I do not seem to know how to
 properly extend the class.

 I have a suggest box and I have set up a valueChangeHandler.  In there
 I would like to get the currently selected value but am at a loss as
 to how to make that work.

 help?

 s.r.

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



Re: All I Want for Christmas is a powerful Widget Library from Google !

2010-11-16 Thread Marcin Misiewicz
+1

On Nov 15, 11:05 pm, Jaroslav Záruba jaroslav.zar...@gmail.com
wrote:
 +1 (Isn't there a enhancement request for this?)

 Please make it not only richer, but also sleeker looking.
 I 3 Google but I think the design/look quite often lacks heavily
 behind the service itself, YouTube being one blatant example, IMHO. (I
 believe Zuckerberg is glad Google does not seem to realize how great
 potential YouTube presents in terms of social services.)

 On Nov 15, 10:46 pm, zixzigma zixzi...@gmail.com wrote:







  That's great news.
  Thank You

  On Nov 15, 1:43 pm, Eric Clayberg clayb...@google.com wrote:

   FYI...the UiBinder support in GWT Designer is no longer in beta as of
   GWT Designer v8.1 and GWT 2.1.

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



Re: Editor and enumeration or object cast

2010-11-16 Thread Jerome C.
nobody has an idea on how to manage enum with the new editor framework
without rewriting a class for each enum ?

I just want to create a RadioButtonGroup which is used to edit
enumeration but I don't know how to cast my enum...

Any help is welcome.

On 12 nov, 11:39, Jerome C. jerome.ca...@gmail.com wrote:
 Hello,

 I try to create editors with neweditormechanism. How do you do when
 your bean property is not the same that youreditor.

 For example, how can I have aneditorwhich can edit Enumeration ?

 I've tried to create a RadioButtonGroup which displays values of an
 enumeration and try to make this class aneditor.

 Here is the code: this is just a flow panel where each child is a
 RadioButton

 public class RadioButtonGroupT extendsEnumT extends FlowPanel
 implements LeafValueEditorT
 {
         public RadioButtonGroup()
         {

         }

         @Override
         public T getValue()
         {
                 T result = null;

                 for (int i = 0; i  getWidgetCount(); i++)
                 {
                         RadioButton radio = (RadioButton) getWidget(i);

                         if (radio.getValue())
                         {
                                 // ? how can I cast it ?
                                 result = radio.getFormValue();
                                 break;
                         }
                 }

                 return result;
         }

         @Override
         public void setValue(T value)
         {
                 for (int i = 0; i  getWidgetCount(); i++)
                 {
                         RadioButton radio = (RadioButton) getWidget(i);

                         if (radio.getFormValue().equals(value.toString()))
                         {
                                 radio.setValue(true);
                                 break;
                         }
                 }
         }

 }

 thanks for any help

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



Log is missing in console ? when I changed from App engine 1.3.5 to 1.3.8

2010-11-16 Thread suersh babu
Hi,

I am using Eclipse 3.6, with gwt 2.1 Also I have changed the google app
engine version 1.3.5 to 1.3.8.  Ever think works fine except the log is
missing when server side logged.

I am getting in console like this ...

Initializing AppEngine server
2010-11-16 12:14:23.609:INFO::Logging to STDERR via
org.mortbay.log.StdErrLog
2010-11-16 12:14:24.093:INFO::jetty-6.1.x
[WARN] 2010-11-16 17:44:24 IST
2010-11-16 12:14:25.718:INFO::Started selectchannelconnec...@0.0.0.0:


I will be grateful If you got any suggestion over this.

*
Regards

Suresh Babu G
*

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



Change CSS class attribute value at runtime

2010-11-16 Thread MickeyR
Hi,

Can anyone help me to change the value of a class at runtime. So, for
example, I have a css class that I apply to certain objects:-

.highlight {color: blue;}

And at runtime I would like to change the 'color' attribute of this
class. So effectively making this:-

.highlight {color: yellow;}

I want to use something similar to this javascript this function:-
changecss(theClass,element,value)

Or can anyone suggest how I can use that javascript function ? I tried
this, but it failed:-

private native void changeCSS() /*-{
$doc.changecss('.highlight','color','yellow');
}-*/;


Thanks in advance,
Martin.

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



Re: RequestFactory - Send error to client

2010-11-16 Thread DK
I've encountered the same problem. Intuition says that throwing an
error should trigger the onFailure() method, not the onSuccess()
method with a SEVERE logging the exception. Is this a known bug?

On Nov 6, 5:03 am, Henrique F M fm.henri...@gmail.com wrote:
 Hi there,

 I didn't find the solution to this anywhere, so I'm creating this new
 discussion.

 I want to be able to send errors from my RequestFactory to the client.
 Let me give an example: let's say my app is a simple Person CRUD. My
 Person class has a String name attribute and I don't want to have more
 than two Persons with the same name. So i was thinking something like
 this:

 -- RequestFactory Server Implementation 
 public static Person createNewPerson(String name){
         
         if( isThereAnotherPersonWithThisName(name) ){

                 //do something HERE

         }else{
                 pm.makePersistent(person);
         }
         ...

 }

 -- Client ---
 ().fire(
         new ReceiverPerson() {
                 @Override
                 public void onSuccess(Person person) {
                         Window.alert(OK!);
                         //do stuff
                 }
                 @Override
                 public void onFailure(ServerFailure error) {
                         Window.alert(Fail!);
                         Window.alert(error.getMessage());
                         //do stuff
                 }
         });

 
 I don't know what I have to do on HERE to make my Receiver go to
 onFailure. I've tried to throw Exceptions, RequestException, but it
 only make my server log the error and the response never arrives to
 the client.
 Am I missing something here? What would you suggest?

 Thanks

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



getting size of center in a docklayoutpanel

2010-11-16 Thread Chris
I have an application running in a DockLayoutPanel. I'm trying to
display an image in the center component (the center contains a
FlowPanel which contains the image) and have that image fill as much
of the center as possible. I'm doing this by setting the image width
to 100%. The problem is that if the browser is very wide the image
will overflow and get cut off at the bottom. In this case I'd like to
set it to 100% height so that this doesn't happen. I can't figure out
how to get the visible height of the center component to make this
change when the browser is resized.
Is there something obvious that I'm missing?

Thanks,
-Chris

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



Filtering Code Splitting

2010-11-16 Thread Burly Jez
Hi GWT peeps,

I have a debug-only panel which I want to remove from my production
deployment.

I've used code splitting and sure enough, I can remove the deferred-js
from the final war and everything is rosy.

But what if I want to split other things, like deferring the main UI
code until after login? Is there a way to decorate splitting-points in
some way so I can delete the right code?


Thanks in advance for any help!


Jason

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



Ability to set element id trough UIBinder widget

2010-11-16 Thread Janusz
Hello,
  I've been looking for a way to set DOM element id trough UIBinder
but I couldn't find any solution. Example of what I'd like to do:

g:HTMLPanel
  label for=usernameInputSome label/label
  g:TextBox ui:field=field id=usernameInput/
/g:HTMLPanel

Id like this to be rendered as:
div
  label for=usernameInputSome label/label
  input type=text id=usernameInput /
/div

Sadly this doesn't work the way I wanted it to. As far as I can
understand id attribute in UIBinder is treated as an id for XML
element that is being parsed by UIBinder processor. I've tried things
like JSP/JSF syntax:

  g:TextBox ui:field=field element.id=usernameInput/

but this doesn't work either. Does anyone know if it is possible in
UIBinder to set an id for resulting DOM element? Currently to achieve
this one has to go to java code and use field.getElement().setId().

Thanks

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



Re: GWT+Roo a few days later

2010-11-16 Thread Jim Northrup
this style of project dates back to corba days.

i have a roo project far from mature but what we've sussed out so far:

* inherit from the templates
* use echo quit|roo in hudson, and don't check in the roo turds,
use .gitignore/svnignore etc.
* roo's file system scanner is inadequate at completing large passes
of fresh changes, at least on ubuntu64, so use echo quit|roo instead
of camping in the roo shell
* ignore non-JPA features at this time, vmware wants your project to
be continued long enough to let them finish (marketing thier
paywalled) docs.

my toplevel .gitignore:

classes
.classpath
.directory
foreel.iml
foreel.ipr
foreel.iws
foreel.properties
foreel.script
.idea
*.iml
*.ipr
*.iws
log.roo
.metadata
META-INF
otherdirectoryvalue
out
proj
.project
.settings
.springBeans
target
test-classes
war
*_Roo_*

 (also a .gitignore exists above managed dir in gwt client)


On Nov 5, 10:25 pm, zixzigma zixzi...@gmail.com wrote:
 is there a way to tell Roo to just generate Places or just
 Presenters ? instead of everything ?
 the thing is with CRUD part of app, there is a mapping between
 Entities(entityproxies) and Places/Activity/Presenters.

 but there are times that many entities need to collaborate to present
 the information to the user.
 the data is not coming from one entity, rather 3-4 entities.
 in this case, Roo generates Presenter/Acitivity/Places/Views that are
 not going to be used.

 because those 4 entities would be presented by one complex widget.

 the first thing Roo asks is : give me your domain models.
 what about asking for Places ? or Presenters ?

 i had developed GWT apps using MVP, prior to Roo release.
 and i understand the exampes, concepts, and Roo generated code.
 but have difficulty creating a non-crud app with Roo.

 and writing MVP without Roo is very difficult, lots of scaffolding
 code.
 there are other frameworks, such as GWTP, i had found it more easier
 to work with.
 but since Google's MVP is out, want to give that a try.

 so, i'm in the same boat, experimenting.

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



Re: Memcache problem : Cannot use as key: 'com.server.floor.par...@d65362'

2010-11-16 Thread Israel Paixão
I don't recognize this put method as a memcached functionality, but
anyways, it seems you're using the key and value in wrong order.
Try cache.put(parcel.getKey(), parcel);

Regards,
Israel.

On 15 nov, 13:01, tito100 mostk...@gmail.com wrote:
 Hi All,
 I have class Parcel :
 @PersistenceCapable(identityType = IdentityType.APPLICATION)
 public class Parcel implements Serializable{
         @NotPersistent
         public static byte NUM_CELLS = 125;
         @NotPersistent
         public static byte NUM_ROWS = 125;
         @PrimaryKey
         @Persistent
         private String key;
         @Persistent
         private byte columnPos;
         @Persistent
         private byte rowPos;
         @Persistent
         private Key[] players;

         @NotPersistent
         Cache cache;
 

 in this class is cachce workinkg corectly . but when I wont save this
 class to memcachce like this :
 .
 Parcel parcel = new Parcel(0, 0);
 pm.makePersistent(parcel);
 System.out.println(       putting parcel to cache with key: +
 parcel.getKey());
 cache.put(parcel, parcel.getKey());

 then output is :
         putting parcel to cache. key:aglwb3Bva2VjYWxyDwsSB3BhcmNlbDoiAjoxDA
 [ERROR] javax.servlet.ServletContext log: unavailable
 java.lang.IllegalArgumentException: Cannot use as key:
 'com.server.floor.par...@d65362'
         at
 com.google.appengine.api.memcache.MemcacheServiceImpl.put(MemcacheServiceImpl.java:
 363)
         at
 com.google.appengine.api.memcache.jsr107cache.GCache.put(GCache.java:
 173)
         at com.server.floor.Floor.createParcel(Floor.java:127)

 thank you for your suggestion.

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



class ‎[class name]‎ is not presented in JRE Emu lation library so it cannot be used in client code

2010-11-16 Thread Yacov Schondorf
I have a Swing application which I want to convert to GWT. I am using
IntelliJ IDE and have already done a few tutorials successfully. I
added a GWT module and created a service in the client package. I am
trying to define a method in the service that uses a class from the
Swing application. However, I am getting the following inspection
error:

'class ‎[class name]‎ is not presented in JRE Emulation library so it
cannot be used in client code

Is there any procedure I need to follow in order to use classes
external to the GWT module?

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



Re: Paging a simple CellTable freezes

2010-11-16 Thread stefannMeisner
Hi

I Am experiencing the same problem. I have tried to setup a simple MVP
application. When I get the bar with the moving bands I press a link
that
goes to the same page. The updated page shows the CellTable with the
correct
lines visible.

Any help appreciated. A working example with CellTable and SimplePager
would
be nice! The documentation seems to be outdated on this subject.

Regards,
Stefan

On 11 Nov., 20:13, Nick Newman nick.x.new...@gmail.com wrote:
 Hi,

 I'm trying the CellTable from GWT 2.1 and I must be doing something
 silly because I cannot get it to page.  When I display the table I see
 the first page just fine, but when I press the page-forward button I
 get a busy indication (a bar with moving bands) and that stays there
 forever.

 Could some kind soul take a look at the following sample code (copied
 from an example with minor changes) to see what I'm doing wrong.

 Thanks,
 Nick

 public class MyModule implements EntryPoint
 {
     /**
      * A simple data type that represents a contact.
      */
     static class Contact
     {
         private final String address;

         private final Date birthday;

         private final String name;

         public Contact(String name, Date birthday, String address)
         {
             this.name = name;
             this.birthday = birthday;
             this.address = address;
         }
     }

     public void onModuleLoad()
     {
         /**
          * The list of data to display.
          */
         ListContact CONTACTS = new ArrayListContact();

         ListContact sample = Arrays.asList( //
                 new Contact(John, new Date(80, 4, 12), 123 Fourth
 Avenue), //
                 new Contact(Joe, new Date(85, 2, 22), 22 Lance
 Ln), //
                 new Contact(George, new Date(46, 6, 6), 1600
 Pennsylvania Avenue));

         // Make lots of entries
         for (int i = 0; i  50; ++i)
             CONTACTS.addAll(sample);

         // Create a CellTable.
         CellTableContact table = new CellTableContact();

 table.setKeyboardSelectionPolicy(KeyboardSelectionPolicy.ENABLED);

         // Add a text column to show the name.
         TextColumnContact nameColumn = new TextColumnContact()
         {
             @Override
             public String getValue(Contact object)
             {
                 return object.name;
             }
         };
         table.addColumn(nameColumn, Name);

         // Set the total row count. This isn't strictly necessary, but
 it affects
         // paging calculations, so its good habit to keep the row
 count up to date.
         table.setRowCount(CONTACTS.size(), true);

         // Push the data into the widget.
         table.setRowData(0, CONTACTS);

         /*
          * Add a pager
          */
        SimplePager.Resources pagerResources =
 GWT.create(SimplePager.Resources.class);
        SimplePagerpager = newSimplePager(TextLocation.CENTER,
 pagerResources, false, 0, true);
         pager.setDisplay(table);

         VerticalPanel resultPanel = new VerticalPanel();
         resultPanel.add(pager);
         resultPanel.add(table);
         RootPanel.get(gwt).add(resultPanel);
     }

 }

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



Re: class ‎[class name]‎ is not presented in JRE Emulation library so it cannot be used in client code

2010-11-16 Thread Didier Durand
Hi Yacov,

The list of jre classes supported / emulated by GWT is here (be
careful: some methods are missing in some cases):
http://code.google.com/webtoolkit/doc/latest/RefJreEmulation.html

For the rest, you either have to provide the source code limited to
the use of emulated classes or inherits from other GWT-compiled
modules using same rules.

Hope it helps

regards
didier



On Nov 15, 7:03 pm, Yacov Schondorf yacov.schond...@gmail.com wrote:
 I have a Swing application which I want to convert to GWT. I am using
 IntelliJ IDE and have already done a few tutorials successfully. I
 added a GWT module and created a service in the client package. I am
 trying to define a method in the service that uses a class from the
 Swing application. However, I am getting the following inspection
 error:

 'class ‎[class name]‎ is not presented in JRE Emulation library so it
 cannot be used in client code

 Is there any procedure I need to follow in order to use classes
 external to the GWT module?

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



How to get the next day of week date?

2010-11-16 Thread anthony.more...@stambia.com
Hello,
I'm just starting with GWT and Dates (so sad I can't use Calendar),
and I have no idea how to get the date of the next tuesday (or any day
of the week) without using Calendar. I've been trying that to do that
for a few hours now so any help would be appreciated.

Regards

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



Re: Filtering Code Splitting

2010-11-16 Thread Chris Conroy
Code splitting is good, but you're describing a need for using
deferred binding.

http://code.google.com/webtoolkit/doc/latest/DevGuideCodingBasicsDeferred.html

On Mon, Nov 15, 2010 at 4:59 PM, Burly Jez jez.ch...@googlemail.com wrote:
 Hi GWT peeps,

 I have a debug-only panel which I want to remove from my production
 deployment.

 I've used code splitting and sure enough, I can remove the deferred-js
 from the final war and everything is rosy.

 But what if I want to split other things, like deferring the main UI
 code until after login? Is there a way to decorate splitting-points in
 some way so I can delete the right code?


 Thanks in advance for any help!


 Jason

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



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



Re: RequestFactory - Send error to client

2010-11-16 Thread Dain Kaplan
I dug around a bit and discovered why the onFailure() handler was not being 
called. The DynaTableRf sample that ships with GWT 2.1 uses the new Editor 
framework. In the PersonEditorWorkflow.java class it initializes the editor and 
keeps a copy of the RequestContext as follows:

  PersonRequest context = requestFactory.personRequest();
  context.persist().using(person);

When the user clicks the Save button, the onSave() click handler gets called, 
which basically does:

  context.fire(new ReceiverVoid() {
@Override
public void onSuccess(Void response) {
  dialog.hide();
}

@Override
public void onViolation(SetViolation errors) {
  dialog.setText(Errors detected on the server);
  editorDriver.setViolations(errors);
}
  });

For dealing with successes and violations, that works fine. The problem happens 
when you want to deal with exceptions thrown on the server. The RequestContext 
and Request objects seem to have their own Receiver() instances, but only the 
Receiver instance for the Request (and NOT the RequestContext) gets parsed for 
server-side exceptions (see 
com.google.gwt.requestfactory.client.impl.AbstractRequest.handleResponseText() 
for the error parsing code, and AbstractRequestContext.doFire() for 
RequestContext code that ignores any errors). To briefly show what's going on, 
below is a snippet from the TransportReceiver that gets created in the 
AbstractRequestContext.doFire() method for handling the request:

  public void onTransportSuccess(String payload) {
try {
  // TODO: chained methods
  assert invocations.size() == 1;
  invocations.get(0).handleResponseText(payload);

  if (receiver != null) {
if (errors.isEmpty()) {
  receiver.onSuccess(null);
  // After success, shut down the context
  editedProxies.clear();
  invocations.clear();
  returnedProxies.clear();
} else {
  receiver.onViolation(errors);
}
  }
} finally {
  postRequestCleanup();
}
  }

What winds up happening is that if the payload contains errors, they get 
processed in the handleResponseText() method call, but only if the request 
instance has a Receiver set. The code below that does not handle errors at all, 
so even on error the onSuccess() method of your receiver gets called.

Is such behavior intentional?

The workaround is to set the Request's Receiver instance and call 
context.fire() instead, but still leaves the DynaTableRf sample a bit 
misleading.

DK

On Nov 16, 2010, at 4:43 PM, DK wrote:

 I've encountered the same problem. Intuition says that throwing an
 error should trigger the onFailure() method, not the onSuccess()
 method with a SEVERE logging the exception. Is this a known bug?
 
 On Nov 6, 5:03 am, Henrique F M fm.henri...@gmail.com wrote:
 Hi there,
 
 I didn't find the solution to this anywhere, so I'm creating this new
 discussion.
 
 I want to be able to send errors from my RequestFactory to the client.
 Let me give an example: let's say my app is a simple Person CRUD. My
 Person class has a String name attribute and I don't want to have more
 than two Persons with the same name. So i was thinking something like
 this:
 
 -- RequestFactory Server Implementation 
 public static Person createNewPerson(String name){
 
 if( isThereAnotherPersonWithThisName(name) ){
 
 //do something HERE
 
 }else{
 pm.makePersistent(person);
 }
 ...
 
 }
 
 -- Client ---
 ().fire(
 new ReceiverPerson() {
 @Override
 public void onSuccess(Person person) {
 Window.alert(OK!);
 //do stuff
 }
 @Override
 public void onFailure(ServerFailure error) {
 Window.alert(Fail!);
 Window.alert(error.getMessage());
 //do stuff
 }
 });
 
 
 I don't know what I have to do on HERE to make my Receiver go to
 onFailure. I've tried to throw Exceptions, RequestException, but it
 only make my server log the error and the response never arrives to
 the client.
 Am I missing something here? What would you suggest?
 
 Thanks
 
 -- 
 You received this message because you are subscribed to the Google Groups 
 Google Web Toolkit group.
 To post to this group, send email to google-web-tool...@googlegroups.com.
 To unsubscribe from this group, send email to 
 google-web-toolkit+unsubscr...@googlegroups.com.
 For more options, visit this group at 
 http://groups.google.com/group/google-web-toolkit?hl=en.
 

-- 
You received this message because you are subscribed to the Google Groups 
Google Web Toolkit group.
To post to this group, send email to google-web-tool...@googlegroups.com.
To unsubscribe from this group, send email to 

Re: How to get the next day of week date?

2010-11-16 Thread Blagoja Chavkoski
Hi,

Just use now= new Date(), and then from this date do what ever u like to
do

one day after... new Date ( new Date().getTime() + 24 * 60 * 60 * 1000)
one day before... new Date ( new Date().getTime() - 24 * 60 * 60 * 1000)

one week after ...new Date ( new Date().getTime() + 7 * 24 * 60 * 60 * 1000)
one week before...new Date ( new Date().getTime() - 7 * 24 * 60 * 60 * 1000)

etc...

Regards,
B

On Tue, Nov 16, 2010 at 4:15 PM, anthony.more...@stambia.com 
anthony.more...@stambia.com wrote:

 Hello,
 I'm just starting with GWT and Dates (so sad I can't use Calendar),
 and I have no idea how to get the date of the next tuesday (or any day
 of the week) without using Calendar. I've been trying that to do that
 for a few hours now so any help would be appreciated.

 Regards

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



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



Re: Ability to set element id trough UIBinder widget

2010-11-16 Thread Stephen Haberman

 Does anyone know if it is possible in UIBinder to set an id for
 resulting DOM element?

I wanted to do this as well when I started working with UIBinder, but
the feedback I got was that the GWT team thinks that setting ids inside
of ui.xml files is an anti-pattern.

Their reasoning is that, technically, foo.ui.xml could be inserted into
the page several times, and so the DOM ids would no longer unique.

I see their point, but it is also a pain for exactly what you're doing,
working with labels. If you look at CheckBox, it manages both the
input/ and the label/ and keeps the label for in sync with the
input's id. You could potentially make your own text box that mimicks
that.

- Stephen


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



Re: CellTable ImageResource

2010-11-16 Thread Daniele
I do like this:

ImageCell imgCell = new ImageCell();
ColumnYourObject, String imgColumn = new ColumnYourObject,
String(imgCell) {
  @Override
  public String getValue(YourObject obj) {
return obj.geturl();
  }
};


YourObject is the object that I display in the row.




On Nov 15, 12:36 pm, davidtse davidts...@hotmail.com wrote:
 Hello,

 I'm trying since few hours to display an image located  in a directory
 of my website but without succes. My problem is when i create an image
 the constructor Column want a CellImage , please explain me how to
 do? Or if you have an example, it would be great? Thanks per advance
 and sorry for english faults,

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



Re: Filtering Code Splitting

2010-11-16 Thread Janusz Prokulewicz
Hello,

yes there's a way to do it, I guess.

Let's say you have block of code launched asynchronously:


GWT.runAsync(new RunAsyncCallback() {
  public void onFailure(Throwable caught) {
Window.alert(Code download failed);
  }

  public void onSuccess() {

ToRemoveComponent.stupidMethodDoingSthMeaningless(DEFERRED_SCRIPT_TO_REMOVE);
Window.alert(Hello, AJAX);
  }
});

When you compile the code above it will be easy to find in one of js
files if you search for string DEFERRED_SCRIPT_TO_REMOVE (it should be
unique). I am not sure but I think that used method cannot be empty
because gwt compiler can make some optimization by removing empty
method. Maybe marking it as native one is the way to go.

I can't check it right now so please let me know when you try this
approach.


Good luck,
Janusz Prokulewicz



On 15 Lis, 22:59, Burly Jez jez.ch...@googlemail.com wrote:
 Hi GWT peeps,

 I have a debug-only panel which I want to remove from my production
 deployment.

 I've used code splitting and sure enough, I can remove the deferred-js
 from the final war and everything is rosy.

 But what if I want to split other things, like deferring the main UI
 code until after login? Is there a way to decorate splitting-points in
 some way so I can delete the right code?

 Thanks in advance for any help!

 Jason

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



Re: Filtering Code Splitting

2010-11-16 Thread Janusz Prokulewicz
Hello,

yes there's a way to do it, I guess.

Let's say you have block of code launched asynchronously:


GWT.runAsync(new RunAsyncCallback() {
  public void onFailure(Throwable caught) {
Window.alert(Code download failed);
  }

  public void onSuccess() {

ToRemoveComponent.stupidMethodDoingSthMeaningless(DEFERRED_SCRIPT_TO_REMOVE);
Window.alert(Hello, AJAX);
  }
});

When you compile the code above it will be easy to find in one of js
files if you search for string DEFERRED_SCRIPT_TO_REMOVE (it should be
unique). I am not sure but I think that used method cannot be empty
because gwt compiler can make some optimization by removing empty
method. Maybe marking it as native one is the way to go.

I can't check it right now so please let me know when you try this
approach.


Good luck,
Janusz Prokulewicz



On 15 Lis, 22:59, Burly Jez jez.ch...@googlemail.com wrote:
 Hi GWT peeps,

 I have a debug-only panel which I want to remove from my production
 deployment.

 I've used code splitting and sure enough, I can remove the deferred-js
 from the final war and everything is rosy.

 But what if I want to split other things, like deferring the main UI
 code until after login? Is there a way to decorate splitting-points in
 some way so I can delete the right code?

 Thanks in advance for any help!

 Jason

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



Re: How to get the next day of week date?

2010-11-16 Thread Lothar Kimmeringer
Am 16.11.2010 16:30, schrieb Blagoja Chavkoski:

 Just use now= new Date(), and then from this date do what ever u like to do
 
 one day after... new Date ( new Date().getTime() + 24 * 60 * 60 * 1000)
 one day before... new Date ( new Date().getTime() - 24 * 60 * 60 * 1000)
 
 one week after ...new Date ( new Date().getTime() + 7 * 24 * 60 * 60 * 1000)
 one week before...new Date ( new Date().getTime() - 7 * 24 * 60 * 60 * 1000)
 
 etc...


... and hope you're not residing at a place where daylight saving
times do exist.

@anthony: There was a similar discussion where I answered already.
I don't remember the exact date but using the search option of the
mail-archive should bring it up.


Regards, Lothar

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



Re: Ability to set element id trough UIBinder widget

2010-11-16 Thread Thomas Broyer


On 15 nov, 18:12, Janusz janusz.parfien...@gmail.com wrote:
 Hello,
   I've been looking for a way to set DOM element id trough UIBinder
 but I couldn't find any solution. Example of what I'd like to do:

 g:HTMLPanel
   label for=usernameInputSome label/label
   g:TextBox ui:field=field id=usernameInput/
 /g:HTMLPanel

 Id like this to be rendered as:
 div
   label for=usernameInputSome label/label
   input type=text id=usernameInput /
 /div

 Sadly this doesn't work the way I wanted it to. As far as I can
 understand id attribute in UIBinder is treated as an id for XML
 element that is being parsed by UIBinder processor.

No, actually, using ui:field= implies adding a (temporary) id to the
element (or a placeholder element in your case) so it can be retrieved
later (in your case, to replace it with the TextBox through
HTMLPanel's addAndReplaceElement method)

 I've tried things
 like JSP/JSF syntax:

   g:TextBox ui:field=field element.id=usernameInput/

 but this doesn't work either. Does anyone know if it is possible in
 UIBinder to set an id for resulting DOM element? Currently to achieve
 this one has to go to java code and use field.getElement().setId().

See https://wave.google.com/wave/waveref/googlewave.com/w+EI8yh67GA

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



Incorrect escaping of XML entities (e.g. less-than) in GWT XMLParser

2010-11-16 Thread googelybear
Hi all,

The GWT XMLParser seems to have a bug wtih respect to escaping of xml
entities like the less-than sign. E.g. writting a less-than sign in a
text node should become 'lt;'. This escaping is performed correctly
when writing the text content in the TEXT node, but when the text node
is added to a parent element it is UNescaped again. Resulting in
invalid XML.

To better illustrate this issue I created a test case:
public class XMLEncodeTest extends GWTTestCase {

public static final String TEST_TEXT = Hello   World;
public static final String TEST_TAG = test;
public static final String EXPECTED_XML = testHello lt; gt;
World/test;

@Test
public void testTestEscape() {
Document doc = XMLParser.createDocument();
Text textNode = doc.createTextNode(TEST_TEXT); // everything
is well here, escaping is performed
Element element = doc.createElement(TEST_TAG);
element.appendChild(textNode); // BUG: text is unescaped
again!
doc.appendChild(element);
Assert.assertTrue(EXPECTED_XML.equals(element.toString()));
}

@Override
public String getModuleName() {
return my.tests.gwt.tests;
}

}

Am I doing something wrong here? Should I report an issue for this on
the gwt issue tracker?

best regards,
Dennis

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



Re: How to get the next day of week date?

2010-11-16 Thread Blagoja Chavkoski
This is true...but the mistake is just one hour, and the day when daylight
saving
time happens.

The Date class is not that correct:) , but the calendar class wich shouldv
been the repair is not correct also..once joshua bloch on a presentation
said...when u re-doing something, at list do it right:)

On Tue, Nov 16, 2010 at 4:38 PM, Lothar Kimmeringer j...@kimmeringer.dewrote:

 Am 16.11.2010 16:30, schrieb Blagoja Chavkoski:

  Just use now= new Date(), and then from this date do what ever u like
 to do
 
  one day after... new Date ( new Date().getTime() + 24 * 60 * 60 * 1000)
  one day before... new Date ( new Date().getTime() - 24 * 60 * 60 * 1000)
 
  one week after ...new Date ( new Date().getTime() + 7 * 24 * 60 * 60 *
 1000)
  one week before...new Date ( new Date().getTime() - 7 * 24 * 60 * 60 *
 1000)
 
  etc...


 ... and hope you're not residing at a place where daylight saving
 times do exist.

 @anthony: There was a similar discussion where I answered already.
 I don't remember the exact date but using the search option of the
 mail-archive should bring it up.


 Regards, Lothar

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



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



Re: Editor and enumeration or object cast

2010-11-16 Thread Thomas Broyer


On 16 nov, 11:58, Jerome C. jerome.ca...@gmail.com wrote:
 nobody has an idea on how to manage enum with the new editor framework
 without rewriting a class for each enum ?

 I just want to create a RadioButtonGroup which is used to edit
 enumeration but I don't know how to cast my enum...

How about passing your Enum's class to your widget's constructor so
you can use Enum.valueOf(enumCls, radio.getFormValue())?
RadioButtonGroupMyEnumeration myEnumFieldEditor = new
RadioButtonGroupMyEnumeration(MyEnumeration.class);

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



Re: Change CSS class attribute value at runtime

2010-11-16 Thread suersh babu
You could use widget,setstyleName(MysytleClassName);  where you can give
style name for that widget

On Tue, Nov 16, 2010 at 6:26 PM, MickeyR mnroo...@gmail.com wrote:

 Hi,

 Can anyone help me to change the value of a class at runtime. So, for
 example, I have a css class that I apply to certain objects:-

 .highlight {color: blue;}

 And at runtime I would like to change the 'color' attribute of this
 class. So effectively making this:-

 .highlight {color: yellow;}

 I want to use something similar to this javascript this function:-
 changecss(theClass,element,value)

 Or can anyone suggest how I can use that javascript function ? I tried
 this, but it failed:-

 private native void changeCSS() /*-{
$doc.changecss('.highlight','color','yellow');
 }-*/;


 Thanks in advance,
 Martin.

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




-- 
*Regards

Suresh Babu G*

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



Re: eclipse does not show any log

2010-11-16 Thread suersh babu
I too have the same problem, my log not showing up.  I am using eclipse 3.6
with gwt 2.1 and I changed app engine 1.3.5 to 1.3.8

On Tue, Nov 16, 2010 at 8:09 PM, Vik vik@gmail.com wrote:

 Hie

 Sorry this is specific to my eclipse ide. I am using Galileo latest
 version.  My console does not show any output like sops etc.

 any idea how to fix this?

 Thankx and Regards

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

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




-- 
*Regards

Suresh Babu G*

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



Re: ImageBundle and IE7

2010-11-16 Thread Thomas Broyer


On 16 nov, 00:32, Frédéric MINATCHY frederic.minat...@gmail.com
wrote:
 Hello...

 As I said before I used the ImageResource in my code like this :

 public interface UsersAdministrationImagesResources extends ClientBundle {

     public static UsersAdministrationImagesResources INSTANCE =
 GWT.create(UsersAdministrationImagesResources.class);

     @Source(user_add.png)
     ImageResource addUserImage();

     @Source(user_delete.png)
     ImageResource deleteUserImage();

     @Source(user_edit.png)
     ImageResource editUserImage();

 I get the images by using
 GWT.create(UsersAdministrationImagesResources.class).

 And then on Internet Explorer 7 some images ont gwt and smartgwt component
 are not correctly displayed.

 On the gwt button all the image resources are shown (whereas only one should
 be shown)

As Dave wrote, ImageResource generates data: URLs for those browsers
that supports it (everyone except IE6/7) and a sprite image (see
http://css-tricks.com/css-sprites ) otherwise; so what you see really
is the intended behavior.

 and on the smartgwt elements a white square is shown.

I don't know what SmartGWT (or rather, SmartClient) does.

 What is the difference with @sprite and Image bundle?

@sprite will generate the appropriate CSS properties whichever
technique is used: background: url(data:) for all browsers but
IE6/7, and a bunch of properties for IE6/7 (background-image,
background-position, width and height; see link above).
Using an Image widget with an ImageResource does exactly the same as
@sprite does at the CssResource level.

See 
http://code.google.com/intl/fr-FR/webtoolkit/doc/latest/DevGuideClientBundle.html#ImageResource
and 
http://code.google.com/intl/fr-FR/webtoolkit/doc/latest/DevGuideClientBundle.html#Image_Sprites

 How can I choose to use explicitly one of them?

 Thank you for clues... I hope they will help me to find a correct solution.

 But if you have another idea do not hesitate.

 regards.

 Fred

 2010/11/15 Thomas Broyer t.bro...@gmail.com









  On 15 nov, 11:38, Frédéric MINATCHY frederic.minat...@gmail.com
  wrote:
   Thank you for your advise...

   But is there a way to make it work with all browser??

  ImageResource really is designed to work with either the Image widget
  or a @sprite in a CssResource.

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

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



Re: All I Want for Christmas is a powerful Widget Library from Google !

2010-11-16 Thread har_shan
This should be there in almost all developer's wish list who are using
GWT.

 zixzigma,

thanks for bringing up this and i think its better to log a feature
request in Issues list and get more stars (than to get +1 in the post)
in it to draw more attention..

On Nov 16, 3:50 pm, Marcin Misiewicz misq...@gmail.com wrote:
 +1

 On Nov 15, 11:05 pm, Jaroslav Záruba jaroslav.zar...@gmail.com
 wrote:







  +1 (Isn't there a enhancement request for this?)

  Please make it not only richer, but also sleeker looking.
  I 3 Google but I think the design/look quite often lacks heavily
  behind the service itself, YouTube being one blatant example, IMHO. (I
  believe Zuckerberg is glad Google does not seem to realize how great
  potential YouTube presents in terms of social services.)

  On Nov 15, 10:46 pm, zixzigma zixzi...@gmail.com wrote:

   That's great news.
   Thank You

   On Nov 15, 1:43 pm, Eric Clayberg clayb...@google.com wrote:

FYI...the UiBinder support in GWT Designer is no longer in beta as of
GWT Designer v8.1 and GWT 2.1.

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



Re: Multiple Highlighting

2010-11-16 Thread Francesco
I'll try to explain better: when you have to select more than one icon
in your Desktop what do you do? You click over and empty spot and draw
a rectangle over the group of icons you want to select. I've seen an
example of this, in a webpage, only in Google Docs for Presentation.
As I want to implement this feature (the rectangle) in a webdesktop
I'm developing, I was wandering: how do you realize this with GWT?
Thanks :)


On 15 Nov, 11:58, Kasper Hansen kbhdk1...@gmail.com wrote:
 Hi,

 Maybe you are thinking of a:hover i CSS ? Or you can accomplish what I
 think you are talking about, using onMouseOver and onMouseOut events.

 Or maybe I misunderstand you completely... ;-)







 On Sun, Nov 14, 2010 at 10:14 PM, Francesco fran.sa...@gmail.com wrote:
  Hi there!
  I don't know how it's called, but I would like to implement in my web
  desktop a multiple highlighting for the icons. It's the common
  rectangle that appears in any desktop when you drag the mouse, and
  it's present in Google Docs (Presentation) so I know it's technically
  Javascript-implementable. Maybe the problem is that I don't know its
  name, but I can't find a way to implement it. Any suggestion?
  Thanks

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

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



Re: Paging a simple CellTable freezes

2010-11-16 Thread John LaBanca
Put your list in a ListDataProvider and set the cellTable as the display:
ListDataProviderContact dataProvider = new ListDataProviderContact(
CONTACTS);
dataProvider.addDataDisplay(cellTable);

When you change the visible range of a CellTable, it clears its current data
and fires a RangeChangeEvent.  Something (like a ListDataProvider) has to be
listening for the event and provide more data.  In your case, you are
pushing the initial data, but the CellTable is only retaining the data on
the current page.  When you change the page, the CellTable is waiting for a
data provider to push more data into it.

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


On Mon, Nov 15, 2010 at 11:47 AM, stefannMeisner
ste...@meisner-larsen.dkwrote:

 Hi

 I Am experiencing the same problem. I have tried to setup a simple MVP
 application. When I get the bar with the moving bands I press a link
 that
 goes to the same page. The updated page shows the CellTable with the
 correct
 lines visible.

 Any help appreciated. A working example with CellTable and SimplePager
 would
 be nice! The documentation seems to be outdated on this subject.

 Regards,
 Stefan

 On 11 Nov., 20:13, Nick Newman nick.x.new...@gmail.com wrote:
  Hi,
 
  I'm trying the CellTable from GWT 2.1 and I must be doing something
  silly because I cannot get it to page.  When I display the table I see
  the first page just fine, but when I press the page-forward button I
  get a busy indication (a bar with moving bands) and that stays there
  forever.
 
  Could some kind soul take a look at the following sample code (copied
  from an example with minor changes) to see what I'm doing wrong.
 
  Thanks,
  Nick
 
  public class MyModule implements EntryPoint
  {
  /**
   * A simple data type that represents a contact.
   */
  static class Contact
  {
  private final String address;
 
  private final Date birthday;
 
  private final String name;
 
  public Contact(String name, Date birthday, String address)
  {
  this.name = name;
  this.birthday = birthday;
  this.address = address;
  }
  }
 
  public void onModuleLoad()
  {
  /**
   * The list of data to display.
   */
  ListContact CONTACTS = new ArrayListContact();
 
  ListContact sample = Arrays.asList( //
  new Contact(John, new Date(80, 4, 12), 123 Fourth
  Avenue), //
  new Contact(Joe, new Date(85, 2, 22), 22 Lance
  Ln), //
  new Contact(George, new Date(46, 6, 6), 1600
  Pennsylvania Avenue));
 
  // Make lots of entries
  for (int i = 0; i  50; ++i)
  CONTACTS.addAll(sample);
 
  // Create a CellTable.
  CellTableContact table = new CellTableContact();
 
  table.setKeyboardSelectionPolicy(KeyboardSelectionPolicy.ENABLED);
 
  // Add a text column to show the name.
  TextColumnContact nameColumn = new TextColumnContact()
  {
  @Override
  public String getValue(Contact object)
  {
  return object.name;
  }
  };
  table.addColumn(nameColumn, Name);
 
  // Set the total row count. This isn't strictly necessary, but
  it affects
  // paging calculations, so its good habit to keep the row
  count up to date.
  table.setRowCount(CONTACTS.size(), true);
 
  // Push the data into the widget.
  table.setRowData(0, CONTACTS);
 
  /*
   * Add a pager
   */
 SimplePager.Resources pagerResources =
  GWT.create(SimplePager.Resources.class);
 SimplePagerpager = newSimplePager(TextLocation.CENTER,
  pagerResources, false, 0, true);
  pager.setDisplay(table);
 
  VerticalPanel resultPanel = new VerticalPanel();
  resultPanel.add(pager);
  resultPanel.add(table);
  RootPanel.get(gwt).add(resultPanel);
  }
 
  }

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



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



Re: Paging a simple CellTable freezes

2010-11-16 Thread Nick Newman
Thank you so much!  I knew it had to be something simple.

Nick

On Tue, Nov 16, 2010 at 9:58 AM, John LaBanca jlaba...@google.com wrote:

 Put your list in a ListDataProvider and set the cellTable as the display:
 ListDataProviderContact dataProvider = new ListDataProviderContact(
 CONTACTS);
 dataProvider.addDataDisplay(cellTable);

 When you change the visible range of a CellTable, it clears its current
 data and fires a RangeChangeEvent.  Something (like a ListDataProvider) has
 to be listening for the event and provide more data.  In your case, you are
 pushing the initial data, but the CellTable is only retaining the data on
 the current page.  When you change the page, the CellTable is waiting for a
 data provider to push more data into it.

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


 On Mon, Nov 15, 2010 at 11:47 AM, stefannMeisner ste...@meisner-larsen.dk
  wrote:

 Hi

 I Am experiencing the same problem. I have tried to setup a simple MVP
 application. When I get the bar with the moving bands I press a link
 that
 goes to the same page. The updated page shows the CellTable with the
 correct
 lines visible.

 Any help appreciated. A working example with CellTable and SimplePager
 would
 be nice! The documentation seems to be outdated on this subject.

 Regards,
 Stefan

 On 11 Nov., 20:13, Nick Newman nick.x.new...@gmail.com wrote:
  Hi,
 
  I'm trying the CellTable from GWT 2.1 and I must be doing something
  silly because I cannot get it to page.  When I display the table I see
  the first page just fine, but when I press the page-forward button I
  get a busy indication (a bar with moving bands) and that stays there
  forever.
 
  Could some kind soul take a look at the following sample code (copied
  from an example with minor changes) to see what I'm doing wrong.
 
  Thanks,
  Nick
 
  public class MyModule implements EntryPoint
  {
  /**
   * A simple data type that represents a contact.
   */
  static class Contact
  {
  private final String address;
 
  private final Date birthday;
 
  private final String name;
 
  public Contact(String name, Date birthday, String address)
  {
  this.name = name;
  this.birthday = birthday;
  this.address = address;
  }
  }
 
  public void onModuleLoad()
  {
  /**
   * The list of data to display.
   */
  ListContact CONTACTS = new ArrayListContact();
 
  ListContact sample = Arrays.asList( //
  new Contact(John, new Date(80, 4, 12), 123 Fourth
  Avenue), //
  new Contact(Joe, new Date(85, 2, 22), 22 Lance
  Ln), //
  new Contact(George, new Date(46, 6, 6), 1600
  Pennsylvania Avenue));
 
  // Make lots of entries
  for (int i = 0; i  50; ++i)
  CONTACTS.addAll(sample);
 
  // Create a CellTable.
  CellTableContact table = new CellTableContact();
 
  table.setKeyboardSelectionPolicy(KeyboardSelectionPolicy.ENABLED);
 
  // Add a text column to show the name.
  TextColumnContact nameColumn = new TextColumnContact()
  {
  @Override
  public String getValue(Contact object)
  {
  return object.name;
  }
  };
  table.addColumn(nameColumn, Name);
 
  // Set the total row count. This isn't strictly necessary, but
  it affects
  // paging calculations, so its good habit to keep the row
  count up to date.
  table.setRowCount(CONTACTS.size(), true);
 
  // Push the data into the widget.
  table.setRowData(0, CONTACTS);
 
  /*
   * Add a pager
   */
 SimplePager.Resources pagerResources =
  GWT.create(SimplePager.Resources.class);
 SimplePagerpager = newSimplePager(TextLocation.CENTER,
  pagerResources, false, 0, true);
  pager.setDisplay(table);
 
  VerticalPanel resultPanel = new VerticalPanel();
  resultPanel.add(pager);
  resultPanel.add(table);
  RootPanel.get(gwt).add(resultPanel);
  }
 
  }

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


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

Re: All I Want for Christmas is a powerful Widget Library from Google !

2010-11-16 Thread Thomas Broyer


On 16 nov, 17:33, har_shan harsha...@gmail.com wrote:
 This should be there in almost all developer's wish list who are using
 GWT.

Er, absolutely not. I'm more than happy with a widget set that gives
me a total latitude towards how my app will look like. That's one of
the biggest issues of Sencha: more than half the sites/apps in their
spotlight series [1] feels Sencha, tates Sencha, smells
Sencha (well that's also because their developers are not creative
enough: half the apps I've seen using Sencha copy their Explorer
sample and even its awful and unintuitive UX! but Sencha full-
featured widgets are, before all, recognizable amongst all); and
that's definitely NOT something I want!

[1] http://www.sencha.com/blog/category/spotlight/

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



Re: All I Want for Christmas is a powerful Widget Library from Google !

2010-11-16 Thread Chad
I completely agree with Thomas on this one. Just look at GXT apps for
another example. By GWT not having slick looking widgets, it forces a
developer to create a look and feel for their own apps. I'd much
prefer the GWT team to keep pumping out more function over form.

Chad Bourque
www.milamade.com

On Nov 16, 11:28 am, Thomas Broyer t.bro...@gmail.com wrote:
 On 16 nov, 17:33, har_shan harsha...@gmail.com wrote:

  This should be there in almost all developer's wish list who are using
  GWT.

 Er, absolutely not. I'm more than happy with a widget set that gives
 me a total latitude towards how my app will look like. That's one of
 the biggest issues of Sencha: more than half the sites/apps in their
 spotlight series [1] feels Sencha, tates Sencha, smells
 Sencha (well that's also because their developers are not creative
 enough: half the apps I've seen using Sencha copy their Explorer
 sample and even its awful and unintuitive UX! but Sencha full-
 featured widgets are, before all, recognizable amongst all); and
 that's definitely NOT something I want!

 [1]http://www.sencha.com/blog/category/spotlight/

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



Re: All I Want for Christmas is a powerful Widget Library from Google !

2010-11-16 Thread Stephen Haberman

 I completely agree with Thomas on this one.

Me too.

 I'd much prefer the GWT team to keep pumping out more function over form.

Agreed!

- Stephen

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



CellTree and RPC

2010-11-16 Thread Jerome C.
Hi,

I don't know how to load datas for my CellTree via RPC.

The getNodeInfo is synchronous so how can I send a request to the
server and then (when the response comes back) update the CellTree ?

Or if we can't, how to load my tree in one request and after use this
structure in getNodeInfo ?

thanks

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



Re: All I Want for Christmas is a powerful Widget Library from Google !

2010-11-16 Thread Hilco Wijbenga
On 16 November 2010 10:16, Stephen Haberman stephen.haber...@gmail.com wrote:
 I completely agree with Thomas on this one.

 Me too.

 I'd much prefer the GWT team to keep pumping out more function over form.

 Agreed!

If the OP and everyone who +1d his request each created a single
widget you'd already have a nice start for a library. Why does Google
have to do everything? :-)

Start with simple widgets (something like a label and a textbox) and
make them configurable and skinnable/themeable. Put it on Google Code
and get more people involved. Even if it doesn't work out, it would be
far more valuable than +1. :-)

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



Re: All I Want for Christmas is a powerful Widget Library from Google !

2010-11-16 Thread Flori
I agree with Thomas, but on the other hand it would be nice to have
some more core functionality by default like drag and drop, fx or
something like a light weight (and easy customizable through own
stylesheets) tree widget (without any icons, mouseover styles etc.).
So I also agree with zixzigma.

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



Re: CellTree and RPC

2010-11-16 Thread John LaBanca
You can pass a ListDataProvider or AsyncDataProvider into DefaultNodeInfo.
Then you can return the NodeInfo synchronously, but populate the data
provider asynchronously.

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


On Tue, Nov 16, 2010 at 1:36 PM, Jerome C. jerome.ca...@gmail.com wrote:

 Hi,

 I don't know how to load datas for my CellTree via RPC.

 The getNodeInfo is synchronous so how can I send a request to the
 server and then (when the response comes back) update the CellTree ?

 Or if we can't, how to load my tree in one request and after use this
 structure in getNodeInfo ?

 thanks

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



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



Re: Filtering Code Splitting

2010-11-16 Thread Burly Jez
Thanks for the ideas, guys. Both good.

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



Re: RootLayoutPanel strange code using MVP

2010-11-16 Thread PhilBeaudoin
Why make the Root a inner class? I think it should be either a static
nested class or a top-level class.

Also, you can remove a lot of your boilerplate and ugly news there
using GIN and binding asEagerSingleton. In this way you could bind:
- Root
- PlaceController
- ActivityMapper
- MyActivityManager:
   Inherit ActivityManager with a @Inject constructor receiving
ActivityMapper, EventBus and Root. Then call setDisplay(root)
- AppPlaceHistoryMapper
- MyPlaceHistoryHandler
   Inherit PlaceHistoryHandler with a @Inject constructor receiving
all you need, then call regiser(...) handleCurrentHistory in your
constructor.

Also, instead of Root extending LayoutPanel, you can have it simply
implement AcceptsOneWidget, then in setWidget you call directly
RootLayoutMapnel.get().add(...)

Cheers,

   Philippe

On Nov 16, 1:57 am, Baloe nielsba...@gmail.com wrote:
 Hi all,

 We are using MVP as much as possible, but it has been a pain so far,
 not a lot of documentation. There is one thing that we really couldn't
 get right. Please see how much boilerplate blabla this application
 needs, and see how ugly the class at the end is. We don't want the
 class near the end. And if someone has a tip how to clean up this
 code, please! Thanks a lot!

 Baloe

 public class OurApp implements EntryPoint {

         @Override
         public void onModuleLoad() {

                 AppGinjector injector = GWT.create(AppGinjector.class);
                 Root app = new Root();

                 EventBus eventBus = injector.getEventBus();
                 PlaceController placeController = 
 injector.getPlaceController();
                 ActivityMapper activityMapper = injector.getActivityMapper();

                 ActivityManager activityManager = new
 ActivityManager(activityMapper, eventBus);
                 activityManager.setDisplay(app);

                 AppPlaceHistoryMapper historyMapper =
 GWT.create(AppPlaceHistoryMapper.class);
                 PlaceHistoryHandler historyHandler = new
 PlaceHistoryHandler(historyMapper);
                 historyHandler.register(placeController, eventBus,
 ((AppPlaceController) placeController).getDefault());

                 historyHandler.handleCurrentHistory();
                 RootLayoutPanel.get().add(app);

                 Resources.Instance.css().ensureInjected();
         }

         private class Root extends LayoutPanel implements AcceptsOneWidget {
                 @Override
                 public void setWidget(IsWidget w) {
                         if (w == null) {
                                 clear();
                         } else {
                                 add(w);
                         }
                 }

         }







 }

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



Re: Problem with Google App Engine

2010-11-16 Thread Seb H
Dear Shawn and Didier,

so I followed your advice to set up a completely new GWT project in eclipse
without App Engine support (unchecked during creation of the project). When
I linked the classes i need that are not supported by GAE, I did no longer
get an error from Eclipse. So I thought: success. After running the GWT
compiler and deploying the whole thing to Tomcat, the application runs, but
when the non-compliant code is triggered, I get an error message from the
GreetSerciveImpl.class. When commenting these non-compliant lines of code
out, there is no more error.

What am I doing wrong?

Kind regards,
Sebastian

2010/11/16 Shawn Brown big.coffee.lo...@gmail.com

  thanks for the good news. I haven't actually seen the Spring Roo
 framework
  so far and I don't really need it. Can anyone point out how I can deploy
 my
  App so that all used classes, including
 javax.swing.event.EventlistenerList
  will be supported?

 Deploy my App means to Tomcat right?

 I don't know how to switch an AppEngine project to Tomcat but you
 might try within Eclipse to:

 1) take out the AE jars from your build path (maybe just by removing
 the AE SDK from the libraries tab of your java build path (under
 project, properties)
 2) uncheck the google app engine validator (under project, properties,
 Builders).

 Then you have to deploy to Tomcat and get that set up to run in dev mode.

 I wonder if starting with a fresh GWT project out of the box that
 isn't GAE would be easier.

 I think you intend to develop the way you have it though (as a GAE
 project), and then just want to deploy to Tomcat.  I wouldn't try that
 myself.

 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-tool...@googlegroups.com.
 To unsubscribe from this group, send email to
 google-web-toolkit+unsubscr...@googlegroups.comgoogle-web-toolkit%2bunsubscr...@googlegroups.com
 .
 For more options, visit this group at
 http://groups.google.com/group/google-web-toolkit?hl=en.



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



Re: All I Want for Christmas is a powerful Widget Library from Google !

2010-11-16 Thread Jeff Larsen
The new editor framework is easily worth 100 GXT widget libraries.

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



Re: GWT+Roo a few days later

2010-11-16 Thread koma
Completely following Amir's conclusion... don't go the Spring Roo way.
Finding some useful code after the clutter is the main challenge;

Moreover, the dependencies on Maven - yikes

Try to get deeper understanding programming GWT 2.1 by hand - this
blog series is great : http://tbroyer.posterous.com/

K.

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



Re: Problem with Google App Engine

2010-11-16 Thread Shawn Brown
 so I followed your advice to set up a completely new GWT project in eclipse
 without App Engine support (unchecked during creation of the project). When
 I linked the classes i need that are not supported by GAE, I did no longer
 get an error from Eclipse. So I thought: success. After running the GWT
 compiler and deploying the whole thing to Tomcat, the application runs, but
 when the non-compliant code is triggered, I get an error message from the
 GreetSerciveImpl.class. When commenting these non-compliant lines of code
 out, there is no more error.

What is the error?  Same one - not supported in GAE?

If so, are you sure that class was recompiled after your switch?  Are
you sure you have no GAE in you lib or builders?

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-tool...@googlegroups.com.
To unsubscribe from this group, send email to 
google-web-toolkit+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/google-web-toolkit?hl=en.



Re: Problem with Google App Engine

2010-11-16 Thread Shawn Brown
 What is the error?

Are you sure javax.swing.* is supported in GWT?

 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-tool...@googlegroups.com.
To unsubscribe from this group, send email to 
google-web-toolkit+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/google-web-toolkit?hl=en.



help with the new layout deprecations

2010-11-16 Thread rjcarr
I've been using GWT for several years now but after updating to the
2.1.0 release I'm seeing hundreds of warnings, mostly to do with the
deprecation of ui panels (e.g., DockPanel).  I assume the panels
weren't strictly compatible with the UIBinder (something I haven't
gotten into), so new LayoutPanels were needed, but does this mean the
previous panels need to be deprecated?

I've looked into updating my (for example) DockPanels to
DockLayoutPanels and they aren't close to the same.  I've just started
and I've already come up with:

 * Docs say you must use standards mode (not a big problem)

 * Docs say you should use RootLayoutPanel instead of RootPanel, but I
can't do this because I need to grab specific components from the DOM
with RootPanel.get(String)

 * The DockLayoutPanel constructor takes a unit (for what?)

 * The DockLayoutPanel takes a size parameter when adding an element
(but I don't know what the size is)

 * The DockLayoutPanel isn't a cell panel so you can't set alignment
(there is likely a way around this)

So now I have 500 warnings in my IDE and no easy way to fix them.  I
completely understand that code needs to be deprecated from time to
time, but I don't feel like it was done with reasonable alternatives
nor do I feel like it was ready to make official.  Looking at the
Showcase it still has DockPanel as one of the layout options (included
with other deprecated items) and no usage of DockLayoutPanel.

Do I have any other alternatives other than reverting back to 2.0.x?

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



Re: Filtering Code Splitting

2010-11-16 Thread Burly Jez
(In the end I'm going to just grep for a string I know will only exist
in the debug code)

On Nov 16, 7:05 pm, Burly Jez jez.ch...@googlemail.com wrote:
 Thanks for the ideas, guys. Both good.

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



Preferred way to display preformatted text?

2010-11-16 Thread David Balažic
Hi!

What UI component should be used to display text that is formatted by
spaces and newlines?

Label converts all white space as we know...

For example:

foo barbaz

baz-bar  foo

I think that using a HTML element and manually escape the possible
HTML tags is unclean and inelegant.

I found this suggestion here*:

DOM.setStyleAttribute(theLabel.getElement(), whiteSpace, pre);
// and devised this hopefully equivalent solution**
theLabel.getElement().getStyle().setProperty(whiteSpace, pre);

Any suggestions, comments?


* - 
http://groups.google.com/group/google-web-toolkit/browse_thread/thread/abc75b44567812ea/2cce7ad404c998b9

** - the second throws  java.lang.IncompatibleClassChangeError: Found
interface com.google.gwt.user.client.Element, but class was expected
after I change the code in Eclipse while debugging (even for changing
java comments)
and retriggers the code (by clicking a button in my web page),
similar as in this issue: 
http://code.google.com/p/google-web-toolkit/issues/detail?id=5252


Regards,
David

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



ConcurrentModificationException when Controller forwarding the event to child

2010-11-16 Thread m_and_m
The case: Meanwhile the Controller is in the forwarding the child
(forwardToChild) and looping, an other code adds the new Controller to
the children (addChild).
The symptom: In the next loop an ConcurrentModificationException
thrown by the java.util.IteratorE in the List of children.

It was working in gwt-2.0.3. (I didn't compare the old and new code,
yet)

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



How to stop IE8 from caching my Ajax requests ?

2010-11-16 Thread magat
Hi all,

I'm using a RequestBuilder from com.google.gwt.http.client to update
informations in my app (calling an external home-made API which I must
call with http GET).

Everything works just the way I want to, except when using IE8 (and
maybe other IEs, haven't tested them yet). When in IE, the requests
are cached, and the server never receives any past the first one.

I found out that this problem is related to the way IE caches Ajax
requests (someone had the same problem with JQuery here :
http://stackoverflow.com/questions/1013637/unexpected-caching-of-ajax-results-in-ie8).

Unfortunately, asking my users to change the caching params in IE is
not possible, so I'm trying to solve the problem in the request
builder itself.

I tried to add http headers to prevent IE from caching the requests :

requestBuilder.setHeader(Cache-Control, max-age=0,no-cache,no-
store,post-check=0,pre-check=0);
requestBuilder.setHeader(Expires, Mon, 26 Jul 1997 05:00:00 GMT);


But IE ignores them :(

I'm open to every suggestions, thanks for your help !

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



Re: Ability to set element id trough UIBinder widget

2010-11-16 Thread Jason
I believe you would do this with the debugId attribute as follows:

g:TextBox ui:field=field debugId=usernameInput/

On Nov 15, 11:12 am, Janusz janusz.parfien...@gmail.com wrote:
 Hello,
   I've been looking for a way to set DOM element id trough UIBinder
 but I couldn't find any solution. Example of what I'd like to do:

 g:HTMLPanel
   label for=usernameInputSome label/label
   g:TextBox ui:field=field id=usernameInput/
 /g:HTMLPanel

 Id like this to be rendered as:
 div
   label for=usernameInputSome label/label
   input type=text id=usernameInput /
 /div

 Sadly this doesn't work the way I wanted it to. As far as I can
 understand id attribute in UIBinder is treated as an id for XML
 element that is being parsed by UIBinder processor. I've tried things
 like JSP/JSF syntax:

   g:TextBox ui:field=field element.id=usernameInput/

 but this doesn't work either. Does anyone know if it is possible in
 UIBinder to set an id for resulting DOM element? Currently to achieve
 this one has to go to java code and use field.getElement().setId().

 Thanks

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



SimpleBeanEditorDriver object changes checking

2010-11-16 Thread Fábio Miranda
Hi,

Is there any way to check if an editor/object states has changed,
something analogous to flush method, but without generating errors and
making changes to the object?

Use case: when implementing an EditActivity:

public String mayStop() {
   return editor.hasChanges() ? Are you sure? : null;
}

Editor:

public boolean hasChanges() {
   return driver.hasChanges(); // if something like this exists,
editor.hasChanges is a trivial delegate to editorDriver!
}

An workaround can be Editor making a object copy to driver edit, flush
driver on that copy, and than compare the flushed copy with the
original object, but could be simpler if driver could check this
automatically for us...

Regards,
Fábio Miranda

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



Getting mixed security mode warning in IE8 over SSL

2010-11-16 Thread Jeff
Im using gwt 2.0.3 in a secure site and whenever a DialogBox is closed
on the application, IE8 gives the mixed  mode security popup.  Of
course it works fine in FireFox and Chrome.  It only happens once
after a fresh browser is opened, and then it does not happen again.

I saw some older postings on this happening in IE6, but it was
supposedly fixed.  It had something to do with the src of an iframe
not being set.  Is this bug back for IE 8?


Jeff

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



Starting GWT dev mode within Eclipse causes Maven-managed resources to disappear

2010-11-16 Thread Chris
Hi,

I'm working on upgrading our development environment from GWT 2.0.4 to
2.1 - this involved upgrading GPE to 1.4 as well as the gwt-maven-
plugin to 2.1.  So far things have gone pretty smoothly except for one
nagging problem.

We have in our code tree a POM module that holds just shared resources
- images  CSS - that we make available to all GWT modules in our
codebase.  This is managed by maven-assembly-plugin that unpacks a zip
file from the repo into our target/GWT module directory.

'mvn package' builds the directory structure correctly, and the
resultant war file can be deployed to an external Tomcat server with
no problem.  But when I try to run the app in developer mode it seems
that GPE is deleting the maven-assemly-plugin managed resources prior
to startup.

I've tried just about everything I can think of, but can't for the
life of me figure out why this resources directory is being removed.
Has anyone ever had a problem like this?

Thanks in advance for any help.

- C

---
Google Plugin for Eclipse 3.5   1.4.0.v201010280047
Eclipse Platform3.5.2.R35x_v20100210-0800-9hEiFzmFst-
TiEn9hNYgDWg1XN8ulH_JvCNGB
Google Web Toolkit SDK 2.1.02.1.0.v201010280047

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



Variable TabBar width based on text

2010-11-16 Thread Angel Delgado
I am trying to have my application change the width of the tabs based
on the text inside.  I cannot seem to get it working.  Any help is
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-tool...@googlegroups.com.
To unsubscribe from this group, send email to 
google-web-toolkit+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/google-web-toolkit?hl=en.



RequestFactory + Cell Widgets

2010-11-16 Thread Andrea
The last section here: 
http://code.google.com/webtoolkit/doc/trunk/DevGuideRequestFactory.html
mentions that future articles will discuss RequestFactory integration
with Cell Widgets.

In the meantime, I'm currently working on extending AsyncDataProvider
so that when the Pager hits onRangeChanged I can grab the next page
asynchronously via RequestFactory.

I don't plan on pushing the whole result set up to the client at any
point.  Before I use my own data manager I want to see if this is
handled anywhere that I overlooked.  Any ideas?

Thanks.

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



webappcreator maven 2.1.0

2010-11-16 Thread PeteUK
Hello,

Just got GWT 2.1.0 and used webappcreator with the -maven option. I've
imported my project into Eclipse 3.6 (Helios).

I know I'm probably being a bit dense, but how do I run/debug my
application? If I right-click on my project, under Run As I'm used
to seeing Web Application but it isn't there. How can I enter
development mode?

Thanks,

Pete

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



CellTree with different types at same level

2010-11-16 Thread decitrig
The docs for CellTree say that nodes at the same level usually share
a common type, but that it isn't necessary. However, since the data
providers  node info are parameterized, nodes seem to *have* to have
a common type at a given level. What am I missing? are there examples
anywhere of having types with nothing in common at the same level? Is
it just returning a raw NodeInfo and then doing the type checking/
casting in the cell?

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



Re: Multiple Modules in Eclipse IDE

2010-11-16 Thread Jim Majure
I think I figured out the problem. In the source path=path tag, I
was using the dot notation. So instead of saying dir1/dir2, I was
saying dir1.dir2.

Thanks for the response.

On Nov 12, 8:16 am, Jamesg james.gust...@googlemail.com wrote:
 Is the class of the type in the correct package?
 Its has to be in client or shared to be compiled by the GWT compiler.

 This can be configured in your  [AppName].gwt.xml
 ie source path='client' source path='shared'

 On Nov 10, 12:59 pm, Jim Majure jim.maj...@gmail.com wrote:







  I am trying to create multiple modules in a single Eclipse project. I
  consistently get the No source code is available for type type: did
  you forget to inherit a required module?

  I am using Eclipse 3.5, with the latest version of the GWT plugin. I
  do have the proper inherits tags. The runtime configuration has the
  source directory in the classpath, so the java source should be
  available at runtime.

  Clearly, I'm missing something. Any help is 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-tool...@googlegroups.com.
To unsubscribe from this group, send email to 
google-web-toolkit+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/google-web-toolkit?hl=en.



Re: CellTree with different types at same level

2010-11-16 Thread David Pinn
I think type checking and casting within the cell is necessary in that
case.

On Nov 17, 10:47 am, decitrig rws...@gmail.com wrote:
 The docs for CellTree say that nodes at the same level usually share
 a common type, but that it isn't necessary. However, since the data
 providers  node info are parameterized, nodes seem to *have* to have
 a common type at a given level. What am I missing? are there examples
 anywhere of having types with nothing in common at the same level? Is
 it just returning a raw NodeInfo and then doing the type checking/
 casting in the cell?

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



Re: All I Want for Christmas is a powerful Widget Library from Google !

2010-11-16 Thread zixzigma
I agree with  all the issues that were pointed out about Sencha/Ext.

However, comparing GXT to GWT is comparing apples to oranges.

GXT is only a widget library, you can certainly build applications out
of just putting together some widgets.

but to develop scalable apps with great user experience, you need more
than just bunch of pretty looking widgets.
you need architecture. thats where GWT with its MVP, Editor, Server
Communication mechanisms come to play.

i didnt suggest a cookie cutter widget solution, that you just drag
some widgets into your IDE, and write few lines of event code, and bam
youre done.
ofcrouse not.

a powerful widget library can Complement GWT.
and you would have the same flexibility you have now as how you want
to design your app.


and those who suggest go create your own,
there haver been a number of open source projects out there, trying to
tackle this issue.
but after a while the activity/participation drops. leaving it too
experimental.

asking deverlopers to build their own widget libraries,
is just plain wrong. goes against re-usability, maintanance,
interoperability, etc.
you well know these widgets must be tested on a number of browsers,
each with different versions,
your core application is one thing, but you spend your efffort
elsewhere.
talk about re-inventing the wheel.

do you write your own String library from scratch on every project or
in every company you go to?
do you implement your own LinkedList or HashMap ?
 do you write your own I/O library ? your own web framework ?
ofcourse you can, you can create your own programming language or
operating system if you want.
but in a real world, with tight deadlines, and whole set of other
architectural decisions to deal with,
building drag and drop for tree is the last thing on your priority
list.
if this is your line of work or something you enjoy, then that's
great.

Software Development with GWT is more than just creating widgets,
the challenge is is how you put together everything in a sound end to
end architecture.
Still when it comes to User Interface design, if you have a powerful
widget library, you can implement more complex user interactions.
the core widgets provided by GWT are good, but not good enough.
i can see 10-20 variations/features on each of the widgets. and many
more.

i agree on this that we as a community can participate and
collectively contribute to this.
this requires a bit of change in the way the things are handled.

i am not sure if you are familiar with Vaadin. http://vaadin.com/directory
one thing i like about them is the way they get the community involved
and how they make it easier for the developers to submit their add-on/
plugins.
they have an official section that users can submit the plugins they
have implemented.
other developers who use the plugins can provide feedback.
so instead of scattered google code projects that end up with no
activity after a while,
there would be a central place where plugins/widgets are submitted,
reviewed.
incubator seems to have this purpose, but i am not sure how successful
it has been so far.




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



GWT MVP ActivityMapper with GIN

2010-11-16 Thread zixzigma
from GWT MVP documentation for Activity Mapper:

[ActivityMapper] will likely have lots of code like if (place
instanceof SomePlace) return new SomeActivity(place). A better way to
implement the chain of nested ifs would be with a GIN module.

Can someone please provide some tips on how GIN injection can replace
the nested IFs ?

I am familiar with GIN and have set it up, and use it, but have no
idea how it can be used in this case ?

http://code.google.com/webtoolkit/doc/latest/DevGuideMvpActivitiesAndPlaces.html#ActivityMapper

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-tool...@googlegroups.com.
To unsubscribe from this group, send email to 
google-web-toolkit+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/google-web-toolkit?hl=en.



GWT-Connectors: Delete Shape

2010-11-16 Thread AgitoM
For a Education project I am doing using GWT, I need to implement a
diagram modeling feature. I am attempting to do this in GWT.

The type of model I am attempting to construct essentially requires a
Widget to be dragged to a canvas. (Currently implemented as a
AbsolutePanel with GWT DnD for the drag and drop interface) and the
widgets on the canvas to be connected by a line. It should be possible
to move the widgets are afterwards. (And the lines moving along with
them).

I'm currently using GWT-Connectors to implement the connection of
widgets.

I'm using this piece of code to create a new GWT-Connectors Shape
and add it to the AbsolutePanel:

Diagram diagram = new Diagram(this.boundaryPanel);

SquareSprite square = new SquareSprite(); //My defined Composite
Widget
Shape shapeSquare = new Shape(square); //Wrapping it into a GWT-
Connectors Shape
square.addClickHandler(new ShapeClickHandler(square)); //Adding a
Click handler to allow selection
this.boundaryPanel.add(square, leftCoord, topCoord); //Adding Widget
to AbsolutePanel
shapeSquare.showOnDiagram(diagram); //Show Shape on GWT-Connectors
Diagram

I add a Connector to the same Diagram using this code:

Connector connector = new Connector(leftCoord, topCoord, leftCoord
+100, topCoord+40);
connector.showOnDiagram(diagram);

I then use the drag and drop functionality of the GWT-Connectors shape
and connector to allow the connector to be connected between shapes.

However things become a problem when I attempt to drag a connector
around after having deleted a widget using this code:

this.selectedShape.removeFromDiagram(diagram);
boundaryPanel.remove(this.selectedShape);

Attempting to drag a Connector around, will result in the following
error after attempting to delete a widget:

com.google.gwt.dev.shell.BrowserChannelServer.run(BrowserChannelServer.java:
352)
at java.lang.Thread.run(Thread.java:662)
Caused by: java.lang.IllegalStateException: Unattached drop target.
You must call DragController#unregisterDropController for all drop
targets not attached to the DOM.
at com.allen_sauer.gwt.dnd.client.DropControllerCollection
$Candidate.init(DropControllerCollection.java:48)
at
com.allen_sauer.gwt.dnd.client.DropControllerCollection.resetCache(DropControllerCollection.java:
137)
at
com.allen_sauer.gwt.dnd.client.PickupDragController.resetCache(PickupDragController.java:
349)
at
com.allen_sauer.gwt.dnd.client.AbstractDragController.dragStart(AbstractDragController.java:
155)
at
com.allen_sauer.gwt.dnd.client.PickupDragController.dragStart(PickupDragController.java:
206)
at pl.tecna.gwt.connectors.client.Diagram
$4.dragStart(Diagram.java:
171)

For a more elaborate, see my post in the GWT-Connectors group:
http://groups.google.com/group/gwt-connectors/browse_thread/thread/637880f74f3c9e60

My questions are:
Am I creating and deleting the Widget and Shape properly:
If yes, how can I correct the error?
If no, how am I supposed to do it then?

Sorry I post this question here, the GWT-Connectors group seems to be
very inactive.

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



Re: GWT MVP ActivityMapper with GIN

2010-11-16 Thread Ashton Thomas
http://groups.google.com/group/google-web-toolkit/browse_thread/thread/2ed199a42c500156/9cf373ccdbd1b43a

Unfortunately, the mere mention of a need for something does not
imply
its current availability :-) I wrote the Activities and Places doc and
really should have left GIN out of it for the time being.


On Nov 16, 10:10 pm, zixzigma zixzi...@gmail.com wrote:
 from GWT MVP documentation for Activity Mapper:

 [ActivityMapper] will likely have lots of code like if (place
 instanceof SomePlace) return new SomeActivity(place). A better way to
 implement the chain of nested ifs would be with a GIN module.

 Can someone please provide some tips on how GIN injection can replace
 the nested IFs ?

 I am familiar with GIN and have set it up, and use it, but have no
 idea how it can be used in this case ?

 http://code.google.com/webtoolkit/doc/latest/DevGuideMvpActivitiesAnd...

 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-tool...@googlegroups.com.
To unsubscribe from this group, send email to 
google-web-toolkit+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/google-web-toolkit?hl=en.



A Alternative to GWT-Connectors?

2010-11-16 Thread AgitoM
For my currently project I am attempting to implement a drag and drop
diagram/modeling feature. Essentially I need to be able to connect 2
composite widgets, that have been dragged on a Absolute Panel. After
connecting, the widgets needs to be able to me moved around. Next to
that, it must be possible to delete widgets and connections.  To
facilitate I am currently using GWT-Connectors. However I have been
encountering problems with GWT-Connectors that so far I've been unable
to overcome. The problems occur after deleting a widget from the
absolute panel.

Since development on GWT-Connectors seems to be slow, or not existing
at all, and the group related to the project is also very inactive, I
need a plan B in case I can't get the problems with GWT-Connectors
solved.

Therefore I would like to ask, is the a alternative library to GWT-
Connectors available?
I'm even willing to consider GWT Libraries for which I will have to
pay, because I really need this functionality.

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



Re: Problem with Google App Engine

2010-11-16 Thread Didier Durand
Hi,

Think I understand now: you want to use the class on client side (i.e.
within he browser) and you did put it in the client directory. Right ?

Then, GWT wants to compile it to Javascript. At this point,2
solutions: a) either you provide the source of the class or b) you
inherit the javascript from a module compiled by somebody else.

I think none is possible in your case: you'll have to find another
design without your Swing class: tell us what your purpose is and we
may help.

regards
didier

On Nov 16, 10:36 pm, Shawn Brown big.coffee.lo...@gmail.com wrote:
  What is the error?

 Are you sure javax.swing.* is supported in GWT?

  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-tool...@googlegroups.com.
To unsubscribe from this group, send email to 
google-web-toolkit+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/google-web-toolkit?hl=en.



Gwt 2.1 cell widget for my requirment ?

2010-11-16 Thread suersh babu
Hi,

I am using Gwt 2.1,  I have requirement such that each row which contains
label, suggestion box, and text box. And
this rows increased when you click on add new row button.

So which one is good cell Widget for my requirement.

Any suggestion ?


-- 
*Regards

Suresh Babu G*

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



Re: GWT 2.1 hellomvp using GIN

2010-11-16 Thread zixzigma

in the following code fragment posted:

 @Override
 public Activity getActivity(Place place) {
 if (place instanceof HelloPlace) {
 return injector.getHelloActivity().withPlace((HelloPlace)


injector.getHelloActivity().withPlace((HelloPlace)


could you please explain this withPlace bit ?

injector.getHelloActivity(), gives you the interface
but how can you chain it with withPlace( .,, ) ?

is it some custom code you wrote ?

Thank You



On Oct 23, 4:24 pm, Henrik Schmidt henrik@gmail.com wrote:
 I've been playing around with this for som time. I can't see a more
 reasonable solution than the one Amir and Aigeec proposed.

 Sure, the getActivity method with a long list of if-the-else's doesn't
 seem nice, but this alternative is just too much boilerplate for my
 liking. Lots of Provider classes with the only benefit of avoiding one
 ugly method seems to be more trouble than it's worth.

 In other words, I gonna stick with the below until something better
 comes along:

 public class AppActivityMapper implements ActivityMapper {

     private AppGinjector injector;

     @Inject
     public AppActivityMapper(MailGinjector injector) {
         this.injector = injector;
     }

     @Override
     public Activity getActivity(Place place) {
         if (place instanceof HelloPlace) {
             return injector.getHelloActivity().withPlace((HelloPlace)
 place);
         }
         else if (place instanceof GoodbyePlace) {
             return
 injector.getGoodbyeActivity().withPlace((GoodbyePlace) place);
         }
         return null;
     }

 }

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



Re: Gwt 2.1 cell widget for my requirment ?

2010-11-16 Thread zixzigma
I think you can do it with FlexTable.

It is my understanding that CellWidgets are better for times when you
have a list of data and you want to show it.

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



Re: GWT 2.1 hellomvp using GIN

2010-11-16 Thread zixzigma
gives you the Activity*

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



CellTable, Column, and ActionCell

2010-11-16 Thread GregD
I have a CellTable that is going to display excerpts from 65,000 rows
at about 130 columns per row.  I have a couple of ways to try to make
this manageable for the users.  The first is I'm providing them
various filters they can use to cut down on the number of rows.  The
second is I'm giving them ToggleButtons with which they can select
which groups of Columns they want to see.

I'd like to add a third way, which is to have some columns that are
buttons, where clicking on the button brings up a dialog box that
displays the relevant data for that row.  The ActionCell seems like it
would be prefect for this.  Is that correct?

If it is, how do I get a Column with an ActionCell?  Do I need to make
a new class that extends Column, or is there a simpler / better way?

TIA,

Greg

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



Roo+GWT: how to custom persist operation at server side?

2010-11-16 Thread Sun
hi all:
i'm trying to do a web project using roo+gwt, the goal is simple: i
create a entity(bean) from web UI,then send to server and persist it,
but before persistence, i need to modify  beans using setter. how can
achieve this from Roo generated project. seems there is no way of
doing so?

anyone can give some suggestion about this? thanks a lot.

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



[gwt-contrib] Re: Update some references to document to be $doc (issue1112801)

2010-11-16 Thread conroy

LGTM

http://gwt-code-reviews.appspot.com/1112801/show

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


[gwt-contrib] Error inside documentation

2010-11-16 Thread aquinault
Hi,

this line from 
http://code.google.com/intl/fr/webtoolkit/doc/latest/DevGuideRequestFactory.html

// properties, getters, and setters omitted public static
ListEmployee findAllEmployees() {

must be remplaced by
// properties, getters, and setters omitted
public static ListEmployee findAllEmployees() {

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


[gwt-contrib] Re: First-pass for adding HTML5's Canvas. (issue1082801)

2010-11-16 Thread jlabanca

LGTM


http://gwt-code-reviews.appspot.com/1082801/diff/50001/51001
File user/src/com/google/gwt/canvas/Canvas.gwt.xml (right):

http://gwt-code-reviews.appspot.com/1082801/diff/50001/51001#newcode17
user/src/com/google/gwt/canvas/Canvas.gwt.xml:17: inherits
name=com.google.gwt.canvas.dom.DOM/
I think we need to inherit User here because Canvas extends FocusWidget.

http://gwt-code-reviews.appspot.com/1082801/diff/50001/51003
File user/src/com/google/gwt/canvas/dom/DOM.gwt.xml (right):

http://gwt-code-reviews.appspot.com/1082801/diff/50001/51003#newcode17
user/src/com/google/gwt/canvas/dom/DOM.gwt.xml:17: inherits
name=com.google.gwt.user.User/
Does this really need User?  I think it just need
com.google.gwt.dom.DOM.  Not sure though.

http://gwt-code-reviews.appspot.com/1082801/diff/50001/51004
File user/src/com/google/gwt/canvas/dom/client/CanvasGradient.java
(right):

http://gwt-code-reviews.appspot.com/1082801/diff/50001/51004#newcode35
user/src/com/google/gwt/canvas/dom/client/CanvasGradient.java:35: public
final native void addColorStop(float offset, String color) /*-{
use value().addColorStop()

http://gwt-code-reviews.appspot.com/1082801/diff/50001/51008
File user/src/com/google/gwt/canvas/dom/client/Context2d.java (right):

http://gwt-code-reviews.appspot.com/1082801/diff/50001/51008#newcode304
user/src/com/google/gwt/canvas/dom/client/Context2d.java:304: return
[this.createLinearGradient(x0, y0, x1, y1)];
JavaDoc this zaniness.

http://gwt-code-reviews.appspot.com/1082801/diff/50001/51009
File user/src/com/google/gwt/canvas/dom/client/CssColor.java (right):

http://gwt-code-reviews.appspot.com/1082801/diff/50001/51009#newcode59
user/src/com/google/gwt/canvas/dom/client/CssColor.java:59: public final
native String value() /*-{
Move value() up to FillStrokeStyle and JavaDoc why it works the way it
does.

http://gwt-code-reviews.appspot.com/1082801/diff/50001/51010
File user/src/com/google/gwt/canvas/dom/client/FillStrokeStyle.java
(right):

http://gwt-code-reviews.appspot.com/1082801/diff/50001/51010#newcode29
user/src/com/google/gwt/canvas/dom/client/FillStrokeStyle.java:29:
public final native int getType() /*-{
If you move value() from CssColor to here, you can get rid of the
isScript() check.
var value = value();
if (typeof(value) == string)
etc...

http://gwt-code-reviews.appspot.com/1082801/show

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


[gwt-contrib] Re: Adds some StringInterner references to reduce overall memory usage (issue1108801)

2010-11-16 Thread zundel

http://gwt-code-reviews.appspot.com/1108801/show

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


[gwt-contrib] Fixing a bug in SingleSelectionModel where deselecting a random value causes the selected value ... (issue1114801)

2010-11-16 Thread jlabanca

Reviewers: pdr,

Description:
Fixing a bug in SingleSelectionModel where deselecting a random value
causes the selected value to be deselected, even if the deselected value
wasn't selected to begin with.


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

Affected files:
  M user/src/com/google/gwt/view/client/SelectionModel.java
  M user/src/com/google/gwt/view/client/SingleSelectionModel.java
  M user/test/com/google/gwt/view/client/SingleSelectionModelTest.java


Index: user/src/com/google/gwt/view/client/SelectionModel.java
===
--- user/src/com/google/gwt/view/client/SelectionModel.java (revision 9235)
+++ user/src/com/google/gwt/view/client/SelectionModel.java (working copy)
@@ -71,7 +71,8 @@
 }

 public Object getKey(T item) {
-  return keyProvider == null ? item : keyProvider.getKey(item);
+  return (keyProvider == null || item == null) ? item
+  : keyProvider.getKey(item);
 }

 /**
Index: user/src/com/google/gwt/view/client/SingleSelectionModel.java
===
--- user/src/com/google/gwt/view/client/SingleSelectionModel.java	(revision  
9235)
+++ user/src/com/google/gwt/view/client/SingleSelectionModel.java	(working  
copy)

@@ -68,6 +68,14 @@
   }

   public void setSelected(T object, boolean selected) {
+// If we are deselecting a value that isn't actually selected, ignore  
it.

+if (!selected) {
+  Object oldKey = newSelectedPending ? getKey(newSelectedObject) :  
curKey;

+  Object newKey = getKey(object);
+  if (!equalsOrBothNull(oldKey, newKey)) {
+return;
+  }
+}
 newSelectedObject = object;
 newSelected = selected;
 newSelectedPending = true;
@@ -82,13 +90,17 @@
 resolveChanges();
   }

+  private boolean equalsOrBothNull(Object a, Object b) {
+return (a == null) ? (b == null) : a.equals(b);
+  }
+
   private void resolveChanges() {
 if (!newSelectedPending) {
   return;
 }

-Object key = (newSelectedObject == null) ? null :  
getKey(newSelectedObject);

-boolean sameKey = curKey == null ? key == null : curKey.equals(key);
+Object key = getKey(newSelectedObject);
+boolean sameKey = equalsOrBothNull(curKey, key);
 boolean changed = false;
 if (newSelected) {
   changed = !sameKey;
Index: user/test/com/google/gwt/view/client/SingleSelectionModelTest.java
===
--- user/test/com/google/gwt/view/client/SingleSelectionModelTest.java	 
(revision 9235)
+++ user/test/com/google/gwt/view/client/SingleSelectionModelTest.java	 
(working copy)

@@ -19,6 +19,18 @@
  * Tests for {...@link SingleSelectionModel}.
  */
 public class SingleSelectionModelTest extends AbstractSelectionModelTest {
+
+  /**
+   * Test that deselecting a value other than the pending selection does  
not

+   * cause the pending selection to be lost.
+   */
+  public void testDeselectWhileSelectionPending() {
+SingleSelectionModelString model = createSelectionModel(null);
+model.setSelected(test, true);
+model.setSelected(other, false);
+assertTrue(model.isSelected(test));
+assertEquals(test, model.getSelectedObject());
+  }

   public void testGetSelectedObject() {
 SingleSelectionModelString model = createSelectionModel(null);


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


[gwt-contrib] Re: Adds some StringInterner references to reduce overall memory usage (issue1108801)

2010-11-16 Thread conroy

On 2010/11/16 16:08:56, zundel wrote:


LGTM

http://gwt-code-reviews.appspot.com/1108801/show

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


[gwt-contrib] Re: Fixing a bug in SingleSelectionModel where deselecting a random value causes the selected value ... (issue1114801)

2010-11-16 Thread jlabanca


http://gwt-code-reviews.appspot.com/1114801/diff/1/2
File user/src/com/google/gwt/view/client/SelectionModel.java (right):

http://gwt-code-reviews.appspot.com/1114801/diff/1/2#newcode75
user/src/com/google/gwt/view/client/SelectionModel.java:75: :
keyProvider.getKey(item);
Cell Widgets already check if the item is null before passing it to the
key provider.  Technically, null is a valid value and a key provider
could provide a non-null key.  However, the 99% use case is that the key
provider would just return null, and passing null is more likely to
cause an NPE in user code.

http://gwt-code-reviews.appspot.com/1114801/show

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


[gwt-contrib] IE devmode plugin: 64 bits support end-to-end, build fixes cleanup, other polishing items. (issue1115801)

2010-11-16 Thread fabiomfv

Reviewers: jat, knorton, conroy,

Description:
IE devmode plugin: 64 bits support end-to-end, build fixes  cleanup,
other polishing items.


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

Affected files:
  A plugins/ie/README.txt
  A plugins/ie/build.cmd
  D plugins/ie/build.xml
  M plugins/ie/installer/README.txt
  A plugins/ie/installer/build.cmd
  D plugins/ie/installer/build.xml
  A plugins/ie/installer/generate-wxsfile.cmd
  M plugins/ie/installer/installer.wxs.xml
  A plugins/ie/installer/oophm.wxs
  A plugins/ie/installer/wix/candle.exe.config
  A plugins/ie/installer/wix/heat.exe.config
  A plugins/ie/installer/wix/light.exe.config
  M plugins/ie/oophm/oophm.sln
  M plugins/ie/oophm/oophm/dllmain.cpp
  M plugins/ie/oophm/oophm/oophm.vcproj
  M plugins/ie/oophm/oophm/plugin.htm


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


[gwt-contrib] Re: Patch for Issue 5588: Fix Ant warning about includeantruntime not being set (issue1105801)

2010-11-16 Thread Hilco Wijbenga
On 15 November 2010 10:08, Hilco Wijbenga hilco.wijbe...@gmail.com wrote:
 On 15 November 2010 09:37, John Tamplin j...@google.com wrote:
 When was that attribute added?  We still have people using ant 1.6.5,
 so if older ants will fail we can't add that attribute.

 In 1.8.0, it doesn't seem to affect older Ants (I just ran the build
 with 1.7.0).

I should be a bit more precise here. The *warning* was introduced in
1.8.0, the attribute itself has been a part of the Javac task from the
very beginning AFAICT.

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


[gwt-contrib] [google-web-toolkit] r9236 committed - Adds some StringInterner references to reduce overall memory usage...

2010-11-16 Thread codesite-noreply

Revision: 9236
Author: zun...@google.com
Date: Tue Nov 16 06:16:48 2010
Log: Adds some StringInterner references to reduce overall memory usage
under compile report (soyc).  On A large code base, I witnessed a
reduction from 369M to 301M of heap when running the compileReport.

Review at http://gwt-code-reviews.appspot.com/1108801

Review by: con...@google.com
http://code.google.com/p/google-web-toolkit/source/detail?r=9236

Modified:
  
/trunk/dev/core/src/com/google/gwt/core/ext/linker/impl/StandardCastableTypeMap.java
  
/trunk/dev/core/src/com/google/gwt/core/ext/soyc/impl/DependencyRecorder.java

 /trunk/dev/core/src/com/google/gwt/dev/jjs/JavaToJavaScriptCompiler.java
 /trunk/dev/core/src/com/google/gwt/dev/jjs/SourceOrigin.java
 /trunk/dev/core/src/com/google/gwt/dev/jjs/impl/GenerateJavaScriptAST.java
 /trunk/dev/core/src/com/google/gwt/dev/js/ast/JsName.java
 /trunk/dev/core/src/com/google/gwt/dev/util/Memory.java
 /trunk/dev/core/src/com/google/gwt/soyc/SoycDashboard.java

===
---  
/trunk/dev/core/src/com/google/gwt/core/ext/linker/impl/StandardCastableTypeMap.java	 
Mon Aug 16 17:56:17 2010
+++  
/trunk/dev/core/src/com/google/gwt/core/ext/linker/impl/StandardCastableTypeMap.java	 
Tue Nov 16 06:16:48 2010

@@ -22,10 +22,12 @@
  * The standard implementation of {...@link CastableTypeMap}.
  */
 public class StandardCastableTypeMap implements CastableTypeMap {
+  // Save some memory by defining this constant string.
+  private static final String EMPTY_JSON_REF = {};

   final String jsonData;
   public StandardCastableTypeMap(String jsonData) {
-this.jsonData = jsonData;
+this.jsonData = jsonData.equals(EMPTY_JSON_REF) ? EMPTY_JSON_REF :  
jsonData;

   }

   public String toJs() {
===
---  
/trunk/dev/core/src/com/google/gwt/core/ext/soyc/impl/DependencyRecorder.java	 
Tue Nov 24 19:27:05 2009
+++  
/trunk/dev/core/src/com/google/gwt/core/ext/soyc/impl/DependencyRecorder.java	 
Tue Nov 16 06:16:48 2010

@@ -19,8 +19,8 @@
 import com.google.gwt.dev.jjs.InternalCompilerException;
 import com.google.gwt.dev.jjs.ast.JMethod;
 import com.google.gwt.dev.jjs.ast.JProgram;
-import com.google.gwt.dev.jjs.impl.ControlFlowAnalyzer;
 import  
com.google.gwt.dev.jjs.impl.CodeSplitter.MultipleDependencyGraphRecorder;

+import com.google.gwt.dev.jjs.impl.ControlFlowAnalyzer;
 import com.google.gwt.util.tools.Utility;

 import java.io.IOException;
@@ -121,7 +121,7 @@
   }
   printPost();

-  writer.write(builder.toString());
+  flushOutput();
   Utility.close(writer);

 } catch (Throwable e) {
===
---  
/trunk/dev/core/src/com/google/gwt/dev/jjs/JavaToJavaScriptCompiler.java	 
Tue Nov 16 03:30:48 2010
+++  
/trunk/dev/core/src/com/google/gwt/dev/jjs/JavaToJavaScriptCompiler.java	 
Tue Nov 16 06:16:48 2010

@@ -24,9 +24,9 @@
 import com.google.gwt.core.ext.linker.ArtifactSet;
 import com.google.gwt.core.ext.linker.CompilationMetricsArtifact;
 import com.google.gwt.core.ext.linker.EmittedArtifact;
+import com.google.gwt.core.ext.linker.EmittedArtifact.Visibility;
 import com.google.gwt.core.ext.linker.ModuleMetricsArtifact;
 import com.google.gwt.core.ext.linker.PrecompilationMetricsArtifact;
-import com.google.gwt.core.ext.linker.EmittedArtifact.Visibility;
 import com.google.gwt.core.ext.linker.StatementRanges;
 import com.google.gwt.core.ext.linker.SymbolData;
 import com.google.gwt.core.ext.linker.SyntheticArtifact;
@@ -308,7 +308,7 @@

   // (7) Generate a JavaScript code DOM from the Java type declarations
   jprogram.typeOracle.recomputeAfterOptimizations();
-  JavaToJavaScriptMap map = GenerateJavaScriptAST.exec(jprogram,  
jsProgram,
+  JavaToJavaScriptMap jjsmap = GenerateJavaScriptAST.exec(jprogram,  
jsProgram,

   options.getOutput(), symbolTable, propertyOracles);

   // (8) Normalize the JS AST.
@@ -317,7 +317,7 @@
   // Resolve all unresolved JsNameRefs.
   JsSymbolResolver.exec(jsProgram);
   // Move all function definitions to a top-level scope, to reduce  
weirdness

-  EvalFunctionsAtTopScope.exec(jsProgram, map);
+  EvalFunctionsAtTopScope.exec(jsProgram, jjsmap);

   // (9) Optimize the JS AST.
   if (optimizationLevel  OptionOptimize.OPTIMIZE_LEVEL_DRAFT) {
@@ -340,7 +340,7 @@
   SyntheticArtifact dependencies = null;
   if (options.isRunAsyncEnabled()) {
 ByteArrayOutputStream baos = new ByteArrayOutputStream();
-CodeSplitter.exec(logger, jprogram, jsProgram, map,
+CodeSplitter.exec(logger, jprogram, jsProgram, jjsmap,
 chooseDependencyRecorder(options.isSoycEnabled(), baos));
 if (baos.size() == 0  options.isSoycEnabled()) {
   recordNonSplitDependencies(jprogram, baos);
@@ -423,7 +423,7 @@
   new SizeBreakdown[js.length] : null;
   ListMapRange, SourceInfo sourceInfoMaps = options.isSoycExtra() ?
   new 

[gwt-contrib] Re: IE devmode plugin: 64 bits support end-to-end, build fixes cleanup, other polishing items. (issue1115801)

2010-11-16 Thread Fabio Valbuena
Please take a look at mondrian as well as the binary changes do not show up
in rietveld.

thx
afbio


On Tue, Nov 16, 2010 at 11:59 AM, fabio...@google.com wrote:

 Reviewers: jat, knorton, conroy,

 Description:
 IE devmode plugin: 64 bits support end-to-end, build fixes  cleanup,
 other polishing items.


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

 Affected files:
  A plugins/ie/README.txt
  A plugins/ie/build.cmd
  D plugins/ie/build.xml
  M plugins/ie/installer/README.txt
  A plugins/ie/installer/build.cmd
  D plugins/ie/installer/build.xml
  A plugins/ie/installer/generate-wxsfile.cmd
  M plugins/ie/installer/installer.wxs.xml
  A plugins/ie/installer/oophm.wxs
  A plugins/ie/installer/wix/candle.exe.config
  A plugins/ie/installer/wix/heat.exe.config
  A plugins/ie/installer/wix/light.exe.config
  M plugins/ie/oophm/oophm.sln
  M plugins/ie/oophm/oophm/dllmain.cpp
  M plugins/ie/oophm/oophm/oophm.vcproj
  M plugins/ie/oophm/oophm/plugin.htm




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

[gwt-contrib] Re: Fixing a bug in SingleSelectionModel where deselecting a random value causes the selected value ... (issue1114801)

2010-11-16 Thread pdr

LGTM.

I took a look at MultiSelectionModel and it doesn't appear to have this
problem. Can you confirm that?

http://gwt-code-reviews.appspot.com/1114801/show

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


[gwt-contrib] Re: Fixing a bug in SingleSelectionModel where deselecting a random value causes the selected value ... (issue1114801)

2010-11-16 Thread jlabanca

MultiSelectionModel shouldn't have this problem because it accrues
changes in a list then resolves them in order.

http://gwt-code-reviews.appspot.com/1114801/show

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


[gwt-contrib] Re: Issue 5518 Fix: Panel Alignment Attributes Have No Effect (issue1109801)

2010-11-16 Thread rjrjr


http://gwt-code-reviews.appspot.com/1109801/diff/12001/13001
File
user/src/com/google/gwt/uibinder/elementparsers/HasAlignmentParser.java
(right):

http://gwt-code-reviews.appspot.com/1109801/diff/12001/13001#newcode29
user/src/com/google/gwt/uibinder/elementparsers/HasAlignmentParser.java:29:
*
p

http://gwt-code-reviews.appspot.com/1109801/diff/12001/13001#newcode30
user/src/com/google/gwt/uibinder/elementparsers/HasAlignmentParser.java:30:
* See http://code.google.com/p/google-web-toolkit/issues/detail?id=5518
for
put {...@link } around the URL

http://gwt-code-reviews.appspot.com/1109801/diff/12001/13003
File
user/test/com/google/gwt/uibinder/elementparsers/HasAlignmentParserTest.java
(right):

http://gwt-code-reviews.appspot.com/1109801/diff/12001/13003#newcode79
user/test/com/google/gwt/uibinder/elementparsers/HasAlignmentParserTest.java:79:
tester.logger.died == null);
These are optional, aren't they? There should be no catch statement
here.

http://gwt-code-reviews.appspot.com/1109801/show

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


[gwt-contrib] Re: Issue 5518 Fix: Panel Alignment Attributes Have No Effect (issue1109801)

2010-11-16 Thread sbrubaker

http://gwt-code-reviews.appspot.com/1109801/show

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


[gwt-contrib] Re: Issue 5518 Fix: Panel Alignment Attributes Have No Effect (issue1109801)

2010-11-16 Thread sbrubaker


http://gwt-code-reviews.appspot.com/1109801/diff/12001/13001
File
user/src/com/google/gwt/uibinder/elementparsers/HasAlignmentParser.java
(right):

http://gwt-code-reviews.appspot.com/1109801/diff/12001/13001#newcode29
user/src/com/google/gwt/uibinder/elementparsers/HasAlignmentParser.java:29:
*
On 2010/11/16 18:37:20, rjrjr wrote:

p


Done.

http://gwt-code-reviews.appspot.com/1109801/diff/12001/13001#newcode30
user/src/com/google/gwt/uibinder/elementparsers/HasAlignmentParser.java:30:
* See http://code.google.com/p/google-web-toolkit/issues/detail?id=5518
for
On 2010/11/16 18:37:20, rjrjr wrote:

put {...@link } around the URL


Done.

http://gwt-code-reviews.appspot.com/1109801/diff/12001/13003
File
user/test/com/google/gwt/uibinder/elementparsers/HasAlignmentParserTest.java
(right):

http://gwt-code-reviews.appspot.com/1109801/diff/12001/13003#newcode79
user/test/com/google/gwt/uibinder/elementparsers/HasAlignmentParserTest.java:79:
tester.logger.died == null);
On 2010/11/16 18:37:20, rjrjr wrote:

These are optional, aren't they? There should be no catch statement

here.

Done.

http://gwt-code-reviews.appspot.com/1109801/show

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


[gwt-contrib] Re: Public: Handle constraints on Primitive fields. (issue1110801)

2010-11-16 Thread rchandia

LGTM

http://gwt-code-reviews.appspot.com/1110801/show

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


[gwt-contrib] Re: Issue 5518 Fix: Panel Alignment Attributes Have No Effect (issue1109801)

2010-11-16 Thread rjrjr

LGTM with one more fix, below


http://gwt-code-reviews.appspot.com/1109801/diff/19001/20003
File
user/test/com/google/gwt/uibinder/elementparsers/HasAlignmentParserTest.java
(right):

http://gwt-code-reviews.appspot.com/1109801/diff/19001/20003#newcode69
user/test/com/google/gwt/uibinder/elementparsers/HasAlignmentParserTest.java:69:
public void testNoAlignmentArgs() throws Exception {
Please be specific with throws exceptions

http://gwt-code-reviews.appspot.com/1109801/show

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


[gwt-contrib] [google-web-toolkit] r9237 committed - Fixing a bug in SingleSelectionModel where deselecting a random value ...

2010-11-16 Thread codesite-noreply

Revision: 9237
Author: jlaba...@google.com
Date: Tue Nov 16 08:49:35 2010
Log: Fixing a bug in SingleSelectionModel where deselecting a random value  
causes the selected value to be deselected, even if the deselected value  
wasn't selected to begin with.


Review at http://gwt-code-reviews.appspot.com/1114801

Review by: p...@google.com
http://code.google.com/p/google-web-toolkit/source/detail?r=9237

Modified:
 /trunk/user/src/com/google/gwt/view/client/SelectionModel.java
 /trunk/user/src/com/google/gwt/view/client/SingleSelectionModel.java
 /trunk/user/test/com/google/gwt/view/client/SingleSelectionModelTest.java

===
--- /trunk/user/src/com/google/gwt/view/client/SelectionModel.java	Tue Oct  
12 07:55:56 2010
+++ /trunk/user/src/com/google/gwt/view/client/SelectionModel.java	Tue Nov  
16 08:49:35 2010

@@ -71,7 +71,8 @@
 }

 public Object getKey(T item) {
-  return keyProvider == null ? item : keyProvider.getKey(item);
+  return (keyProvider == null || item == null) ? item
+  : keyProvider.getKey(item);
 }

 /**
===
--- /trunk/user/src/com/google/gwt/view/client/SingleSelectionModel.java	 
Tue Oct 12 07:55:56 2010
+++ /trunk/user/src/com/google/gwt/view/client/SingleSelectionModel.java	 
Tue Nov 16 08:49:35 2010

@@ -68,6 +68,14 @@
   }

   public void setSelected(T object, boolean selected) {
+// If we are deselecting a value that isn't actually selected, ignore  
it.

+if (!selected) {
+  Object oldKey = newSelectedPending ? getKey(newSelectedObject) :  
curKey;

+  Object newKey = getKey(object);
+  if (!equalsOrBothNull(oldKey, newKey)) {
+return;
+  }
+}
 newSelectedObject = object;
 newSelected = selected;
 newSelectedPending = true;
@@ -81,14 +89,18 @@
 }
 resolveChanges();
   }
+
+  private boolean equalsOrBothNull(Object a, Object b) {
+return (a == null) ? (b == null) : a.equals(b);
+  }

   private void resolveChanges() {
 if (!newSelectedPending) {
   return;
 }

-Object key = (newSelectedObject == null) ? null :  
getKey(newSelectedObject);

-boolean sameKey = curKey == null ? key == null : curKey.equals(key);
+Object key = getKey(newSelectedObject);
+boolean sameKey = equalsOrBothNull(curKey, key);
 boolean changed = false;
 if (newSelected) {
   changed = !sameKey;
===
---  
/trunk/user/test/com/google/gwt/view/client/SingleSelectionModelTest.java	 
Tue Sep 28 06:28:02 2010
+++  
/trunk/user/test/com/google/gwt/view/client/SingleSelectionModelTest.java	 
Tue Nov 16 08:49:35 2010

@@ -19,6 +19,18 @@
  * Tests for {...@link SingleSelectionModel}.
  */
 public class SingleSelectionModelTest extends AbstractSelectionModelTest {
+
+  /**
+   * Test that deselecting a value other than the pending selection does  
not

+   * cause the pending selection to be lost.
+   */
+  public void testDeselectWhileSelectionPending() {
+SingleSelectionModelString model = createSelectionModel(null);
+model.setSelected(test, true);
+model.setSelected(other, false);
+assertTrue(model.isSelected(test));
+assertEquals(test, model.getSelectedObject());
+  }

   public void testGetSelectedObject() {
 SingleSelectionModelString model = createSelectionModel(null);

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


[gwt-contrib] Re: TypeOracle becomes interfaces (issue1113801)

2010-11-16 Thread zundel

Hey Scott, before continuing this review, I'd appreciate a patch I can
apply so I can look at this in Eclipse.


http://gwt-code-reviews.appspot.com/1113801/diff/1/4
File dev/core/src/com/google/gwt/core/ext/typeinfo/JAnnotationType.java
(right):

http://gwt-code-reviews.appspot.com/1113801/diff/1/4#newcode2
dev/core/src/com/google/gwt/core/ext/typeinfo/JAnnotationType.java:2: *
Copyright 2007 Google Inc.
(why didn't you change the date on this file?)

http://gwt-code-reviews.appspot.com/1113801/diff/1/4#newcode23
dev/core/src/com/google/gwt/core/ext/typeinfo/JAnnotationType.java:23:
throws NotFoundException;
Looks like this method is already defined in JClassType?

http://gwt-code-reviews.appspot.com/1113801/diff/1/10
File dev/core/src/com/google/gwt/core/ext/typeinfo/JField.java (right):

http://gwt-code-reviews.appspot.com/1113801/diff/1/10#newcode30
dev/core/src/com/google/gwt/core/ext/typeinfo/JField.java:30: boolean
isDefaultAccess();
isDefaultAccess(), isPrivate(), isProtected(), isPublic(), isStatic()
are defined in more than one class.  Deserves to be consolidated under
new HasAccess/HasProtection interface?

http://gwt-code-reviews.appspot.com/1113801/diff/1/28
File
dev/core/src/com/google/gwt/dev/javac/typemodel/JAbstractMethod.java
(right):

http://gwt-code-reviews.appspot.com/1113801/diff/1/28#newcode30
dev/core/src/com/google/gwt/dev/javac/typemodel/JAbstractMethod.java:30:
com.google.gwt.core.ext.typeinfo.JAbstractMethod {
This is a bit awkward to me.  Isn't the usual pattern to name the
implementation class XXXImpl so that you don't have to deal with two
classes with the same name at the same time?

http://gwt-code-reviews.appspot.com/1113801/show

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


  1   2   >