I want to set different themes to my Vaadin application, depending on the user agent. In particular I want to distinguish at least between mobile devices (iPhone, Android,...) and desktop web browser.
Vaadin's API reveals two interesting classes:
BrowserInfo
seems to do the job perfectly for my needs, but fails on instancing via its get
-method:
SEVERE: javax.servlet.ServletException: ...
Caused by: java.lang.UnsatisfiedLinkError: com.vaadin.terminal.gwt.client.BrowserInfo.getBrowserString()Ljava/lang/String;
Couldn't find a way to access WebBrowser
from within my application either.
- Did I choose the right approach for browser distinction?
- Why does accessing
BrowserInfo
fail?