How do I know the client is a mobile?

I’m sure this was asked already, but I can’t find the answer.

I want to make some mobile specific screens. If a mobile connects I’ll show them the mobile version of the screen, otherwise the full version.

I could be good enough if I can get the device screen size.

There is a MOBILE_FLAG bit that gets set in the system.util.getSystemFlags() call.

Thanks