Menu

#12 Browser bug cause subwindows to get less wide multiple times

open
nobody
None
5
2010-01-09
2010-01-09
BenRayfield
No

Happens in some computers but not others, but I've not seen much pattern in which does it more except that it happens more often when its running faster (less delay between screen/physics updates). This is about version 0.7.

When the following code is changed in version 0.7, it appears to fix the bug:

CHANGE FROM:
this.wantWidth = this.theDiv.scrollWidth; //TODO create 1 more width var. 1 for "want" and 1 for "is".

CHANGE TO:
if(Math.abs(this.theDiv.scrollWidth - this.wantWidth) > 50){ //if width changed enough (This reduces a browser bug that makes the subwindows get smaller width and bigger height)
this.wantWidth = this.theDiv.scrollWidth; //TODO create 1 more width var. 1 for "want" and 1 for "is".
}

Discussion


Log in to post a comment.