diff options
author | Tomaz Canabrava <tomaz.canabrava@intel.com> | 2015-01-16 18:50:28 -0200 |
---|---|---|
committer | Dirk Hohndel <dirk@hohndel.org> | 2015-01-17 10:41:18 +1300 |
commit | e0280048bcd9e602fb5073bc5f5526a5dffd1886 (patch) | |
tree | 87c70c49df4a80f9288e070e7b864138f5b32732 /qt-ui | |
parent | c9499baf2225a0c0584c57b6c47eff53c40249b1 (diff) | |
download | subsurface-e0280048bcd9e602fb5073bc5f5526a5dffd1886.tar.gz |
Cache the complex items to give us a boost of speed
This cache give us a huge gain in performance, going from
17% moving the mouse frenetically to 9%, wich is quite acceptable.
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/diveprofileitem.cpp | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/qt-ui/profile/diveprofileitem.cpp b/qt-ui/profile/diveprofileitem.cpp index 7531b2acb..490f045fd 100644 --- a/qt-ui/profile/diveprofileitem.cpp +++ b/qt-ui/profile/diveprofileitem.cpp @@ -23,6 +23,7 @@ AbstractProfilePolygonItem::AbstractProfilePolygonItem() : QObject(), QGraphicsPolygonItem(), hAxis(NULL), vAxis(NULL), dataModel(NULL), hDataColumn(-1), vDataColumn(-1) { + setCacheMode(DeviceCoordinateCache); connect(PreferencesDialog::instance(), SIGNAL(settingsChanged()), this, SLOT(settingsChanged())); } |