PDA

View Full Version : Maybe a small bug related to autoHeight in 0.33 RC2



glassy
24 Nov 2006, 10:40 AM
I've just tried using autoHeight and it's very cool. Something I wished for since I first started using the grid (which was just the 0.33 RC1 release actually).

From your blog post you say:


Note: If you render a grid to a container and that container element does not have a width or height set, it is assumed that the container is supposed to fit the grid and autoHeight is turned on

I tried this and it worked nicely ... except the bottom left corner of IE shows the dreaded JavaScript error icon. Firefox and Opera error consoles don't show any errors. (The worst kind of bug for me.)

It seems to be something in the grid.render() method.

My workaround was to
1. Put the height back in the container style
2. render the grid first, then set autoHeight to true, then load the (XML) dataModel

This way IE doesn't show an error.

I'm not sure if this is specific to something I'm doing in my code, but since there is an easy workaround its nothing major anyways.

jack.slocum
24 Nov 2006, 11:28 AM
Try setting autoHeight to true before calling render.

The xml grid examples in the docs center uses autoHeight so you may want to look there.

glassy
24 Nov 2006, 12:04 PM
Tried it in the examples - didn't happen. So it's definitely not a bug.
Probably just something in my code. No problem since my workaround works fine.