In general if you have two different HTML host pages you also need a way to 
tell the browser which HTML page to load. So you would make at least one 
additional request just to get redirected to Desktop.html or Mobile.html. 
This could be avoided if you use GWT's deferred binding feature to select 
the correct permutation based on the browser vendor and the form factor of 
the device. That way you would only have a single app/EntryPoint with 12 
permutations (2 form factors * 6 browsers).

GWT SDK contains a sample project called MobileWebApp that works this way. 
Try it and take a look at its source. The MobileWebApp pretty much defines 
its views as interfaces and then uses three factory classes to instantiate 
the real view implementations based on the form factor.

https://gwt.googlesource.com/gwt/+/2.5.0/samples/mobilewebapp/src/main/java/com/google/gwt/sample/mobilewebapp/client/



As already mentioned, a way simpler is to use a responsive approach where 
just the css will be switched by the browser if certain screen resolution 
thresholds are reached. Examples (make browser slowly smaller): 
http://sixrevisions.com/design-showcase-inspiration/responsive-webdesign-examples/

GWT-Bootstrap has some features for responsive 
designs: http://gwtbootstrap.github.com/#layout:responsiveUtilities

Although responsive web design sounds simple I think you also need some 
effort to get it right and it must fit to your app you want to build.

-- J.

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