diff options
author | Tomaz Canabrava <tomaz.canabrava@intel.com> | 2014-07-11 19:13:01 -0300 |
---|---|---|
committer | Dirk Hohndel <dirk@hohndel.org> | 2014-07-11 17:01:12 -0700 |
commit | e18f4dfdeecfb8fdc3cf7bcb7168d84613d4fc7b (patch) | |
tree | c498c5401d2601b3128499b30136997796b2f487 /qt-ui/profile/divecartesianaxis.cpp | |
parent | 2171b981ac5a827e732cadefabf8a09762a8c45c (diff) | |
download | subsurface-e18f4dfdeecfb8fdc3cf7bcb7168d84613d4fc7b.tar.gz |
Code cleanup: removed bogus animation functions
All animations are now on the Animations namespace, which resulted in a
bit of code cleanup, which is nice.
Signed-off-by: Tomaz Canabrava <tomaz.canabrava@intel.com>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Diffstat (limited to 'qt-ui/profile/divecartesianaxis.cpp')
-rw-r--r-- | qt-ui/profile/divecartesianaxis.cpp | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/qt-ui/profile/divecartesianaxis.cpp b/qt-ui/profile/divecartesianaxis.cpp index 4053ee1cd..f5123ae9e 100644 --- a/qt-ui/profile/divecartesianaxis.cpp +++ b/qt-ui/profile/divecartesianaxis.cpp @@ -173,9 +173,9 @@ void DiveCartesianAxis::updateTicks(color_indice_t color) labels[i]->setText(textForValue(currValueText)); if (orientation == LeftToRight || orientation == RightToLeft) { - labels[i]->animateMoveTo(childPos, m.y1() + tick_size); + Animations::moveTo(labels[i],childPos, m.y1() + tick_size); } else { - labels[i]->animateMoveTo(m.x1() - tick_size, childPos); + Animations::moveTo(labels[i],m.x1() - tick_size, childPos); } } @@ -185,9 +185,9 @@ void DiveCartesianAxis::updateTicks(color_indice_t color) begin - i * stepSize; if (orientation == LeftToRight || orientation == RightToLeft) { - lines[i]->animateMoveTo(childPos, m.y1()); + Animations::moveTo(lines[i],childPos, m.y1()); } else { - lines[i]->animateMoveTo(m.x1(), childPos); + Animations::moveTo(lines[i],m.x1(), childPos); } } @@ -208,11 +208,11 @@ void DiveCartesianAxis::updateTicks(color_indice_t color) if (orientation == RightToLeft || orientation == LeftToRight) { label->setAlignment(Qt::AlignBottom | Qt::AlignHCenter); label->setPos(scene()->sceneRect().width() + 10, m.y1() + tick_size); // position it outside of the scene); - label->animateMoveTo(childPos, m.y1() + tick_size); + Animations::moveTo(label,childPos, m.y1() + tick_size); } else { label->setAlignment(Qt::AlignVCenter | Qt::AlignLeft); label->setPos(m.x1() - tick_size, scene()->sceneRect().height() + 10); - label->animateMoveTo(m.x1() - tick_size, childPos); + Animations::moveTo(label,m.x1() - tick_size, childPos); } } @@ -235,13 +235,13 @@ void DiveCartesianAxis::updateTicks(color_indice_t color) if (orientation == RightToLeft || orientation == LeftToRight) { line->setLine(0, -line_size, 0, 0); line->setPos(scene()->sceneRect().width() + 10, m.y1()); // position it outside of the scene); - line->animateMoveTo(childPos, m.y1()); + Animations::moveTo(line,childPos, m.y1()); } else { QPointF p1 = mapFromScene(3, 0); QPointF p2 = mapFromScene(line_size, 0); line->setLine(p1.x(), 0, p2.x(), 0); line->setPos(m.x1(), scene()->sceneRect().height() + 10); - line->animateMoveTo(m.x1(), childPos); + Animations::moveTo(line,m.x1(), childPos); } } |