diff options
author | Tomaz Canabrava <tomaz.canabrava@intel.com> | 2015-01-14 22:36:00 -0200 |
---|---|---|
committer | Dirk Hohndel <dirk@hohndel.org> | 2015-01-15 14:28:25 +1300 |
commit | 3169ec8dc9cf7f385a6662a3d75396c24ba0da5c (patch) | |
tree | b3c7bca24deac061b8c77c14e4602ff73b6c79c5 /qt-ui | |
parent | 806d9841079b5e171fa93bbc43525aa0283011df (diff) | |
download | subsurface-3169ec8dc9cf7f385a6662a3d75396c24ba0da5c.tar.gz |
Do not set the rectangle if it's the same
Strangelly, this method was being called even if the rectangle was the
same, so we deleted everything and recreated everything again. tsc tsc.
Some more improvement is needed but we are getting there.
Signed-off-by: Tomaz Canabrava <tomaz.canabrava@intel.com>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Diffstat (limited to 'qt-ui')
-rw-r--r-- | qt-ui/profile/divetooltipitem.cpp | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/qt-ui/profile/divetooltipitem.cpp b/qt-ui/profile/divetooltipitem.cpp index 46d50be02..db0963208 100644 --- a/qt-ui/profile/divetooltipitem.cpp +++ b/qt-ui/profile/divetooltipitem.cpp @@ -57,7 +57,9 @@ void ToolTipItem::clear() void ToolTipItem::setRect(const QRectF &r) { - // qDeleteAll(childItems()); + if( r == rectangle ) { + return; + } delete background; rectangle = r; |