summaryrefslogtreecommitdiff
path: root/dw/ooffloatsmgr.cc
diff options
context:
space:
mode:
Diffstat (limited to 'dw/ooffloatsmgr.cc')
-rw-r--r--dw/ooffloatsmgr.cc21
1 files changed, 8 insertions, 13 deletions
diff --git a/dw/ooffloatsmgr.cc b/dw/ooffloatsmgr.cc
index 0f9a6faa..fe6d25d4 100644
--- a/dw/ooffloatsmgr.cc
+++ b/dw/ooffloatsmgr.cc
@@ -649,19 +649,14 @@ void OOFFloatsMgr::markSizeChange (int ref)
assert (vloat->getWidget()->getWidgetReference() != NULL);
- int first = findTBInfo (vloat->yReal);
- // The determination of the last element could perhaps be optimized, but we
- // do not yet know the *new* height of the float.
- int last = tbInfos->size () - 1;
-
- DBG_OBJ_MSGF ("resize.oofm", 1, "updating from %d to %d", first, last);
-
- if (first <= last)
- tbInfos->get(first)->getOOFAwareWidget()
- ->updateReference (vloat->getWidget()->getWidgetReference()
- ->parentRef);
-
- for (int i = first + 1; i <= last; i++)
+ int first = getOOFAwareWidget(vloat->generator)->index;
+ DBG_OBJ_MSGF ("resize.oofm", 1, "updating from %d", first);
+
+ tbInfos->get(first)->getOOFAwareWidget()
+ ->updateReference (vloat->getWidget()->getWidgetReference()
+ ->parentRef);
+
+ for (int i = first + 1; i < tbInfos->size(); i++)
tbInfos->get(first)->getOOFAwareWidget()->updateReference(0);
DBG_OBJ_LEAVE ();