Fixed a possible endless recursion (just do a ResizeBy(0.4, 0.4) or something like this

in your FrameResized() method - exposed by the TextView auto resizing feature).


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@16687 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
Axel Dörfler 2006-03-10 12:40:01 +00:00
parent 73bc0d629e
commit e0e1c52865
1 changed files with 3 additions and 3 deletions

View File

@ -3482,13 +3482,13 @@ BView::ResizeBy(float deltaWidth, float deltaHeight)
if (fBounds.bottom + deltaHeight < 0)
deltaHeight = -fBounds.bottom;
if (deltaWidth == 0 && deltaHeight == 0)
return;
// BeBook says we should do this. And it makes sense.
deltaWidth = roundf(deltaWidth);
deltaHeight = roundf(deltaHeight);
if (deltaWidth == 0 && deltaHeight == 0)
return;
if (fOwner) {
check_lock();
fOwner->fLink->StartMessage(AS_LAYER_RESIZE_TO);