Friday, May 3, 2013

Re: WindowBuilder (GWTDesigner) error

What does init() do? It is part of MyControlPanel()? Hard to tell you without seeing what it does.


On Friday, May 3, 2013 1:58:27 AM UTC-4, Mike Dee wrote:
I'm getting the following error when I try to switch to design mode.

GWT Designer can't load a module because of error in gwt.xml module description, incorrect resource which requires processing with GWT generator or by some other configuration error.

Please check your $project_dir/.gwt/.gwt-log for GWT-specific errors (not GWT Designer errors).

This log has the following error messages:

[ERROR] Failed to create an instance of 'com.mycompany.app.client.panels.MyControlPanel' via deferred binding   

This error occurs when attempting to view  MyView.ui.xml in design mode.  MyView includes MyControlPanel.ui.xml.

The app actually runs fine.  I just can't use WindowBuilder.

After playing around with this for a while I noticed that MyControlPanel() has two constructors (as shown below).  They both call init() which does common initialization.  If I remove the call to init(null) in the first, it works fine!

public MyControlPanel()
{
initWidget( uiBinder.createAndBindUi( this ) );
init( null );
}
public MyControlPanel( Settings settings )
{
initWidget( uiBinder.createAndBindUi( this ) );
init( settings );
}

Any clues?

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

No comments:

Post a Comment