add code for getting device width and height on window devices

Change-Id: Ib1b84745cd1211a5194da78d83646ade4b01e72a
only use OpenGL for window devices for now

That fixes the build problems that I have seen.

Change-Id: Ida89aa153d73ce4e07e3f0e0499df567e4df5009