summaryrefslogtreecommitdiff
path: root/src/FbTk/Container.cc
diff options
context:
space:
mode:
Diffstat (limited to 'src/FbTk/Container.cc')
-rw-r--r--src/FbTk/Container.cc11
1 files changed, 6 insertions, 5 deletions
diff --git a/src/FbTk/Container.cc b/src/FbTk/Container.cc
index 8175829..381f13f 100644
--- a/src/FbTk/Container.cc
+++ b/src/FbTk/Container.cc
@@ -332,7 +332,8 @@ void Container::repositionItems() {
332 // calling Container::resize here risks infinite loops 332 // calling Container::resize here risks infinite loops
333 unsigned int neww = total_width, newh = height; 333 unsigned int neww = total_width, newh = height;
334 translateSize(m_orientation, neww, newh); 334 translateSize(m_orientation, neww, newh);
335 if (align == RIGHT && m_orientation != ROT270 || align == LEFT && m_orientation == ROT270) { 335 if ((align == RIGHT && m_orientation != ROT270) ||
336 (align == LEFT && m_orientation == ROT270)) {
336 int deltax = 0; 337 int deltax = 0;
337 int deltay = 0; 338 int deltay = 0;
338 if (m_orientation == ROT0 || m_orientation == ROT180) 339 if (m_orientation == ROT0 || m_orientation == ROT180)
@@ -477,10 +478,10 @@ void Container::setOrientation(Orientation orient) {
477 for (; it != it_end; ++it) 478 for (; it != it_end; ++it)
478 (*it)->setOrientation(orient); 479 (*it)->setOrientation(orient);
479 480
480 if ((m_orientation == ROT0 || m_orientation == ROT180) && 481 if (((m_orientation == ROT0 || m_orientation == ROT180) &&
481 (orient == ROT90 || orient == ROT270) || 482 (orient == ROT90 || orient == ROT270)) ||
482 (m_orientation == ROT90 || m_orientation == ROT270) && 483 ((m_orientation == ROT90 || m_orientation == ROT270) &&
483 (orient == ROT0 || orient == ROT180)) { 484 (orient == ROT0 || orient == ROT180))) {
484 // flip width and height 485 // flip width and height
485 m_orientation = orient; 486 m_orientation = orient;
486 resize(height(), width()); 487 resize(height(), width());