Ignore:
Timestamp:
Mar 8, 2010, 12:52:58 PM (15 years ago)
Author:
Dmitry A. Kuminov
Message:

trunk: Merged in qt 4.6.2 sources.

Location:
trunk
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk

  • trunk/src/gui/graphicsview/qgraphicsscenebsptreeindex.cpp

    r561 r651  
    11/****************************************************************************
    22**
    3 ** Copyright (C) 2009 Nokia Corporation and/or its subsidiary(-ies).
     3** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies).
    44** All rights reserved.
    55** Contact: Nokia Corporation (qt-info@nokia.com)
     
    636636    update the BSP tree if necessary.
    637637*/
    638 void QGraphicsSceneBspTreeIndex::itemChange(const QGraphicsItem *item, QGraphicsItem::GraphicsItemChange change, const QVariant &value)
     638void QGraphicsSceneBspTreeIndex::itemChange(const QGraphicsItem *item, QGraphicsItem::GraphicsItemChange change, const void *const value)
    639639{
    640640    Q_D(QGraphicsSceneBspTreeIndex);
     
    642642    case QGraphicsItem::ItemFlagsChange: {
    643643        // Handle ItemIgnoresTransformations
     644        QGraphicsItem::GraphicsItemFlags newFlags = *static_cast<const QGraphicsItem::GraphicsItemFlags *>(value);
    644645        bool ignoredTransform = item->d_ptr->flags & QGraphicsItem::ItemIgnoresTransformations;
    645         bool willIgnoreTransform = value.toUInt() & QGraphicsItem::ItemIgnoresTransformations;
     646        bool willIgnoreTransform = newFlags & QGraphicsItem::ItemIgnoresTransformations;
    646647        bool clipsChildren = item->d_ptr->flags & QGraphicsItem::ItemClipsChildrenToShape;
    647         bool willClipChildren = value.toUInt() & QGraphicsItem::ItemClipsChildrenToShape;
     648        bool willClipChildren = newFlags & QGraphicsItem::ItemClipsChildrenToShape;
    648649        if ((ignoredTransform != willIgnoreTransform) || (clipsChildren != willClipChildren)) {
    649650            QGraphicsItem *thatItem = const_cast<QGraphicsItem *>(item);
     
    662663        d->invalidateSortCache();
    663664        // Handle ItemIgnoresTransformations
    664         QGraphicsItem *newParent = qVariantValue<QGraphicsItem *>(value);
     665        const QGraphicsItem *newParent = static_cast<const QGraphicsItem *>(value);
    665666        bool ignoredTransform = item->d_ptr->itemIsUntransformable();
    666667        bool willIgnoreTransform = (item->d_ptr->flags & QGraphicsItem::ItemIgnoresTransformations)
     
    683684        break;
    684685    }
    685     return QGraphicsSceneIndex::itemChange(item, change, value);
    686686}
    687687/*!
Note: See TracChangeset for help on using the changeset viewer.