diff options
author | Olivier Goffart <ogoffart@trolltech.com> | 2009-08-17 08:17:27 (GMT) |
---|---|---|
committer | Olivier Goffart <ogoffart@trolltech.com> | 2009-08-19 15:50:56 (GMT) |
commit | 919b723088b8617b202b92d80b8d0983e4fd9500 (patch) | |
tree | 022472bc157e4f4e888929fe29f5b11ee8fef371 /src/gui/graphicsview/qgraphicsscene_p.h | |
parent | 555fafe46e26b352e9d8ab5586910591761ab5ad (diff) | |
download | Qt-919b723088b8617b202b92d80b8d0983e4fd9500.zip Qt-919b723088b8617b202b92d80b8d0983e4fd9500.tar.gz Qt-919b723088b8617b202b92d80b8d0983e4fd9500.tar.bz2 |
Improve memory usage of the connectionlists inside QObject
... by not allocating space for slots in the vector.
Before, the vector uses the signal index as index. The problem is that
the slots and signal are mixed in the same index space.
We solve the problem by having a different index space for the signal in
the connectionlists vector. All we need to do is to add the information
about the number of signals in the moc.
Also, we are not connecting to cloned signal but only to the orginial
ones. For example, destroyed(QObject * = 0) would generate two signal,
we now only connect to the first one.
This also improve a little bit the performence while activating signals
since it removed one call to indexOfMethod.
Reviewed-by: Brad
Diffstat (limited to 'src/gui/graphicsview/qgraphicsscene_p.h')
-rw-r--r-- | src/gui/graphicsview/qgraphicsscene_p.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/gui/graphicsview/qgraphicsscene_p.h b/src/gui/graphicsview/qgraphicsscene_p.h index 685f534..f1ddb5a 100644 --- a/src/gui/graphicsview/qgraphicsscene_p.h +++ b/src/gui/graphicsview/qgraphicsscene_p.h @@ -87,7 +87,7 @@ public: static QGraphicsScenePrivate *get(QGraphicsScene *q); - quint32 changedSignalMask; + static int changedSignalIndex; QGraphicsScene::ItemIndexMethod indexMethod; QGraphicsSceneIndex *index; |