diff options
author | Geir Vattekar <geir.vattekar@nokia.com> | 2011-02-23 13:50:25 (GMT) |
---|---|---|
committer | Geir Vattekar <geir.vattekar@nokia.com> | 2011-02-23 13:50:25 (GMT) |
commit | 719a3079e5675936bc72b65121ac0a0245e29d62 (patch) | |
tree | 1e26fd42dca2fde2bac3679f22ac6169d38b3a01 /src/gui/graphicsview | |
parent | 1464b5e16a40f9af62ff153cfc7650c846bdf765 (diff) | |
download | Qt-719a3079e5675936bc72b65121ac0a0245e29d62.zip Qt-719a3079e5675936bc72b65121ac0a0245e29d62.tar.gz Qt-719a3079e5675936bc72b65121ac0a0245e29d62.tar.bz2 |
Doc: Work on QGraphicsItem::ItemSceneChange/ItemSceneHasChanged
Task-number: QTBUG-16900
Diffstat (limited to 'src/gui/graphicsview')
-rw-r--r-- | src/gui/graphicsview/qgraphicsitem.cpp | 20 |
1 files changed, 11 insertions, 9 deletions
diff --git a/src/gui/graphicsview/qgraphicsitem.cpp b/src/gui/graphicsview/qgraphicsitem.cpp index f463887..265029b 100644 --- a/src/gui/graphicsview/qgraphicsitem.cpp +++ b/src/gui/graphicsview/qgraphicsitem.cpp @@ -574,19 +574,21 @@ QGraphicsItem pointer). The return value is unused; you cannot adjust anything in this notification. - \value ItemSceneChange The item is moved to a new scene. This notification - is also sent when the item is added to its initial scene, and when it is - removed. The value argument is the new scene (i.e., a QGraphicsScene + \value ItemSceneChange The item is moved to a new scene. This notification is + also sent when the item is added to its initial scene, and when it is removed. + The item's scene() is the old scene (or 0 if the item has not been added to a + scene yet). The value argument is the new scene (i.e., a QGraphicsScene pointer), or a null pointer if the item is removed from a scene. Do not - override this change by passing this item to QGraphicsScene::addItem() as - this notification is delivered; instead, you can return the new scene from + override this change by passing this item to QGraphicsScene::addItem() as this + notification is delivered; instead, you can return the new scene from itemChange(). Use this feature with caution; objecting to a scene change can quickly lead to unwanted recursion. - \value ItemSceneHasChanged The item's scene has changed. The value - argument is the new scene (i.e., a pointer to a QGraphicsScene). Do not - call setScene() in itemChange() as this notification is delivered. The - return value is ignored. + \value ItemSceneHasChanged The item's scene has changed. The item's scene() is + the new scene. This notification is also sent when the item is added to its + initial scene, and when it is removed.The value argument is the new scene + (i.e., a pointer to a QGraphicsScene). Do not call setScene() in itemChange() + as this notification is delivered. The return value is ignored. \value ItemCursorChange The item's cursor changes. The value argument is the new cursor (i.e., a QCursor). Do not call setCursor() in itemChange() |