diff options
author | Sebastian Geerken <devnull@localhost> | 2014-04-09 23:21:09 +0200 |
---|---|---|
committer | Sebastian Geerken <devnull@localhost> | 2014-04-09 23:21:09 +0200 |
commit | b7b6cb6dbe45ae258e19595c805cdf317865674c (patch) | |
tree | 1e113d200019118da74fdf5231116aa3603b4740 /dw/outofflowmgr.cc | |
parent | 7a45186914fd6a805127e430d13e51601fcf47b6 (diff) |
Finished refactoring.
Diffstat (limited to 'dw/outofflowmgr.cc')
-rw-r--r-- | dw/outofflowmgr.cc | 36 |
1 files changed, 24 insertions, 12 deletions
diff --git a/dw/outofflowmgr.cc b/dw/outofflowmgr.cc index 4bd6b7ff..f901d366 100644 --- a/dw/outofflowmgr.cc +++ b/dw/outofflowmgr.cc @@ -57,17 +57,6 @@ void OutOfFlowMgr::WidgetInfo::update (bool wasAllocated, int xCB, int yCB, DBG_OBJ_SET_NUM_O (widget, "<WidgetInfo>.height", height); } -void OutOfFlowMgr::WidgetInfo::updateAllocation () -{ - DBG_OBJ_MSG_O ("resize.oofm", 0, widget, "<b>updateAllocation</b> ()"); - DBG_OBJ_MSG_START_O (widget); - - update (isNowAllocated (), getNewXCB (), getNewYCB (), getNewWidth (), - getNewHeight ()); - - DBG_OBJ_MSG_END_O (widget); -} - // ---------------------------------------------------------------------- OutOfFlowMgr::Float::Float (OutOfFlowMgr *oofm, Widget *widget, @@ -92,6 +81,17 @@ OutOfFlowMgr::Float::Float (OutOfFlowMgr *oofm, Widget *widget, } } +void OutOfFlowMgr::Float::updateAllocation () +{ + DBG_OBJ_MSG_O ("resize.oofm", 0, getWidget (), "<b>updateAllocation</b> ()"); + DBG_OBJ_MSG_START_O (getWidget ()); + + update (isNowAllocated (), getNewXCB (), getNewYCB (), getNewWidth (), + getNewHeight ()); + + DBG_OBJ_MSG_END_O (getWidget ()); +} + void OutOfFlowMgr::Float::intoStringBuffer(StringBuffer *sb) { sb->append ("{ widget = "); @@ -446,7 +446,8 @@ OutOfFlowMgr::TBInfo::TBInfo (OutOfFlowMgr *oofm, Textblock *textblock, leftFloatsGB = new SortedFloatsVector (oofm, LEFT, SortedFloatsVector::GB); rightFloatsGB = new SortedFloatsVector (oofm, RIGHT, SortedFloatsVector::GB); - updateAllocation (); + wasAllocated = getWidget()->wasAllocated (); + allocation = *(getWidget()->getAllocation ()); } OutOfFlowMgr::TBInfo::~TBInfo () @@ -455,6 +456,17 @@ OutOfFlowMgr::TBInfo::~TBInfo () delete rightFloatsGB; } +void OutOfFlowMgr::TBInfo::updateAllocation () +{ + DBG_OBJ_MSG_O ("resize.oofm", 0, getWidget (), "<b>updateAllocation</b> ()"); + DBG_OBJ_MSG_START_O (getWidget ()); + + update (isNowAllocated (), getNewXCB (), getNewYCB (), getNewWidth (), + getNewHeight ()); + + DBG_OBJ_MSG_END_O (getWidget ()); +} + OutOfFlowMgr::AbsolutelyPositioned::AbsolutelyPositioned (OutOfFlowMgr *oofm, Widget *widget, Textblock |