- this.p1.style.height = Math.floor(this.pos - this.p1pos.y - this.layer.height / 2 + this.offset_1) + 'px';
- this.p2.style.top = Math.ceil(this.pos + (this.layer.height / 2 + this.offset_2)) + 'px';
- this.layer.move(this.layer.x, Math.round(this.pos - this.layer.height / 2 + 1));
+ var lh = this.layer.height - this.offset * 2;
+ this.p1.style.height = Math.floor(this.pos - this.p1pos.y - lh / 2) + 'px';
+ this.p2.style.top = Math.ceil(this.pos + lh / 2) + 'px';
+ this.layer.move(this.layer.x, Math.round(this.pos - lh / 2 + 1));
+ if (bw.ie)
+ {
+ var new_height = (parseInt(this.p2.parentNode.offsetHeight) - parseInt(this.p2.style.top));
+ this.p2.style.height = (new_height > 0 ? new_height : 0) +'px';
+ }