PDA

View Full Version : Speeding up ViewPort in hybrid app



ngd
6 Jan 2011, 6:00 AM
We create a viewport on every page i.e we are not a 100% ajax based app.

We render the 'meat' of the page in a div and have the viewport suck it in the 'center' area. The performance is quite poor. We can speed this up dramatically by adding display:none style to the meat div, creating the viewport, then unhiding the meat div and finally calling a doLayout on viewport. However some elements (sometimes) rendered in the meat div don't work correctly. Setting class to x-hidden instead of display:none, causes the same performance problem.

Is there anything I am missing?

Any help will be appreciated.

6 Jan 2011, 3:25 PM
is your HTML overly dense? It's hard to suggest anything at this point. Perhaps, you should not inject the HTML until after the viewport is rendered.

ngd
6 Jan 2011, 6:47 PM
No, it's not "overly dense".

And injecting it after viewport is created is what I am trying to do. And that's why I was setting the display to none. Is there a better way to inject it? My HTML (i.e. the meat of the page) also has javascript code in it and it also instantiates ExtJS components like ComboBox.

Thanks