Instead of calling getPosition() twice and getSize(), use getCoordinates and save it to a variable.
var coords = this.el.getCoordinates();
this.mainDiv = new Element('div', {
'styles' : {
'position': 'absolute',
'margin': 0,
'padding': 0,
'width': '100%',
'left': coords.left,
'top': coords.bottom
}
});
--
Guillermo Rauch
http://devthought.com
