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:
parent
73bc0d629e
commit
e0e1c52865
|
@ -3482,13 +3482,13 @@ BView::ResizeBy(float deltaWidth, float deltaHeight)
|
||||||
if (fBounds.bottom + deltaHeight < 0)
|
if (fBounds.bottom + deltaHeight < 0)
|
||||||
deltaHeight = -fBounds.bottom;
|
deltaHeight = -fBounds.bottom;
|
||||||
|
|
||||||
if (deltaWidth == 0 && deltaHeight == 0)
|
|
||||||
return;
|
|
||||||
|
|
||||||
// BeBook says we should do this. And it makes sense.
|
// BeBook says we should do this. And it makes sense.
|
||||||
deltaWidth = roundf(deltaWidth);
|
deltaWidth = roundf(deltaWidth);
|
||||||
deltaHeight = roundf(deltaHeight);
|
deltaHeight = roundf(deltaHeight);
|
||||||
|
|
||||||
|
if (deltaWidth == 0 && deltaHeight == 0)
|
||||||
|
return;
|
||||||
|
|
||||||
if (fOwner) {
|
if (fOwner) {
|
||||||
check_lock();
|
check_lock();
|
||||||
fOwner->fLink->StartMessage(AS_LAYER_RESIZE_TO);
|
fOwner->fLink->StartMessage(AS_LAYER_RESIZE_TO);
|
||||||
|
|
Loading…
Reference in New Issue