diff options
author | corvid <corvid@lavabit.com> | 2010-04-29 21:41:51 +0000 |
---|---|---|
committer | corvid <corvid@lavabit.com> | 2010-04-29 21:41:51 +0000 |
commit | 38c798787810b52da2695df7fe6623f9010ef204 (patch) | |
tree | 62f563e7df65252b7e842816cb74c0e9d3cc87ac | |
parent | a12f41162beec5d3aead82a53b38e1e6955c9fbf (diff) |
don't need switch anymore
it became unnecessary when anchors were separated out in November
-rw-r--r-- | dw/textblock.cc | 12 |
1 files changed, 3 insertions, 9 deletions
diff --git a/dw/textblock.cc b/dw/textblock.cc index 3e188cab..89dbfcf7 100644 --- a/dw/textblock.cc +++ b/dw/textblock.cc @@ -354,8 +354,7 @@ void Textblock::sizeAllocateImpl (core::Allocation *allocation) redrawY = misc::min (redrawY, lineYOffsetWidget (line)); } - switch (word->content.type) { - case core::Content::WIDGET: + if (word->content.type == core::Content::WIDGET) { /** \todo Justification within the line is done here. */ childAllocation.x = xCursor + allocation->x; /* align=top: @@ -412,20 +411,15 @@ void Textblock::sizeAllocateImpl (core::Allocation *allocation) misc::min(childAllocation.y - allocation->y + childAllocation.ascent + childAllocation.descent, oldChildAllocation->y - this->allocation.y + - oldChildAllocation->ascent + oldChildAllocation->descent); + oldChildAllocation->ascent + + oldChildAllocation->descent); redrawY = misc::min (redrawY, childChangedY); } else { redrawY = misc::min (redrawY, lineYOffsetWidget (line)); } } - word->content.widget->sizeAllocate (&childAllocation); - break; - - default: - // make compiler happy - break; } xCursor += (word->size.width + word->effSpace); |