Topic
  • 1 reply
  • Latest Post - ‏2012-12-10T09:30:49Z by Eric Durocher
SystemAdmin
SystemAdmin
2327 Posts

Pinned topic android environment CSS to support large screens

‏2012-12-08T21:41:11Z |
I'm running an android 4.1.2 emulator with a 480x800 screen. My app uses a series of dojox.mobile.Views. (not ScrollableViews) If I generate my android environment and run it on the emulator, all is well, and the Views fill the screen. But the app looks fuzzy.

I go into the Android Manifest file, and enable Supports screens-> large screens.

Now my app looks sharp, but the views no longer fill the screen. They extend down far enough to fit all the widgets in the view, and the rest of the screen is white.

If I switch to dojox.mobile.ScrollableView, those fill the screen at all resolutions that I have tried.

The only way that I have found to make dojox.mobile.Views fill the screen when support large screens is enabled is to modify the css in the android environment:

html, body { // added html
height: 100%; // was: auto
min-height: 100%;
overflow: auto;
}

/*Worklight container div */
#content {
height: 100%; // was: auto
min-height: 100%;
width: 100%;
}

Is there a reason why height was set to auto rather than 100% in the first place? Is there a better solution to this problem?
  • Eric Durocher
    Eric Durocher
    38 Posts

    Re: android environment CSS to support large screens

    ‏2012-12-10T09:30:49Z  
    Hi,

    I think your solution of setting height: 100% is good from the Dojo perspective, do you have any problem with this?

    I can't really say why this is initially set to auto in the Android CSS, maybe others will be able to comment on that...

    Best regards,

    Eric