I need to create two versions of the same GWT application.  One will be for 
Desktop / Tablets and the other for CellPhones.  The functionality will be 
identical, only the presentation will differ.  I have done a fair amount of 
google searching and come up with a structure something like this:

    com.mycompany.project.client
      Common Code
    
    com.mycompany.project.client.Desktop
      Desktop / Tablet specific code
      Desktop.java (entry point)
    
    com.mycompany.project.client.Mobile
       CellPhone specific code
       Mobile.java (entry point)

I have two gwt.xml files, Desktop.gwt.xml and Mobile.gwt.xml.
I have two html files.  Desktop.html and Mobile.html
Finally I have two css files, Desktop.css and Mobile.css

The HTML files have been updated to use the right css.

The intent is that a cell-phone user will go to /Mobile.html and desktop / 
tablet to Desktop.html
Now I have several questions:

1.  Is there anything wrong with this approach?  By that I mean, I get well 
into development and then I discover some horrible limitation or some big 
problem that will cause a lot of trouble.  I just kind of hacked this idea 
together from reading various stuff on some web sites.  It seems to work, 
but I want to make sure there isn't something I am overlooking.

2.  Some web sites suggested having only one gwt.xml file and putting both 
entry points in the one file.  I am not sure I understand this.  Is this a 
good idea?  Can I still have my separate web sites via the HTML files?

3.  Whenever I edit Mobile.java (or any class under the client.mobile 
package) and change any CSS stuff, it ends up changing stuff in the 
Desktop.css.  Is there a way to get the editor to recognize that these 
files are using a different css?  Or should I just be using one css for 
both sites?

4.  If this approach is a bad idea, how should I organize it?  There is 
going to be a lot of shared code since the web sites will be identical 
except for presentation.

-- 
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+unsubscr...@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.


Reply via email to