简体   繁体   English

在GWT中基于浏览器用户代理更改UiTemplate

[英]Change UiTemplate based on browser user-agent in GWT

I've been working on a web application that will be used by both iPads and desktop browsers. 我一直在研究一个iPad和台式机浏览器都将使用的Web应用程序。 I have two UiBinder templates created that have the same fields, just rearranged differently with different CSS. 我创建了两个具有相同字段的UiBinder模板,只是使用不同的CSS进行了不同的重新排列。

Is there a way to have GWT automatically use a different UiTemplate when a mobile browser's user-agent is detected? 当检测到移动浏览器的用户代理时,是否可以让GWT自动使用其他UiTemplate?

you might want to take a look at m-gwt ( http://www.m-gwt.com ). 您可能想看看m-gwt( http://www.m-gwt.com )。 This is a mobile widget library for GWT. 这是GWT的移动小部件库。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM