Qt
Internal/Contributor docs for the Qt SDK. <b>Note:</b> These are NOT official API docs; those are found <a href='https://doc.qt.io/'>here</a>.
|
#include <qgraphicsscene_p.h>
Classes | |
struct | UpdatedRectsCmp |
Static Public Member Functions | |
static QGraphicsScenePrivate * | get (QGraphicsScene *q) |
static void | updateTouchPointsForItem (QGraphicsItem *item, QTouchEvent *touchEvent) |
Static Public Member Functions inherited from QObjectPrivate | |
static bool | removeConnection (Connection *c) |
static QObjectPrivate * | get (QObject *o) |
static const QObjectPrivate * | get (const QObject *o) |
template<typename Func1 , typename Func2 > | |
static QMetaObject::Connection | connect (const typename QtPrivate::FunctionPointer< Func1 >::Object *sender, Func1 signal, const typename QtPrivate::FunctionPointer< Func2 >::Object *receiverPrivate, Func2 slot, Qt::ConnectionType type=Qt::AutoConnection) |
template<typename Func1 , typename Func2 > | |
static bool | disconnect (const typename QtPrivate::FunctionPointer< Func1 >::Object *sender, Func1 signal, const typename QtPrivate::FunctionPointer< Func2 >::Object *receiverPrivate, Func2 slot) |
static QMetaObject::Connection | connectImpl (const QObject *sender, int signal_index, const QObject *receiver, void **slot, QtPrivate::QSlotObjectBase *slotObj, int type, const int *types, const QMetaObject *senderMetaObject) |
static QMetaObject::Connection | connect (const QObject *sender, int signal_index, QtPrivate::QSlotObjectBase *slotObj, Qt::ConnectionType type) |
static QMetaObject::Connection | connect (const QObject *sender, int signal_index, const QObject *receiver, QtPrivate::QSlotObjectBase *slotObj, Qt::ConnectionType type) |
static bool | disconnect (const QObject *sender, int signal_index, void **slot) |
static bool | disconnect (const QObject *sender, int signal_index, const QObject *receiver, void **slot) |
Additional Inherited Members | |
Public Types inherited from QObjectPrivate | |
typedef void(* | StaticMetaCallFunction) (QObject *, QMetaObject::Call, int, void **) |
using | ConnectionDataPointer = QExplicitlySharedDataPointer<ConnectionData> |
Definition at line 47 of file qgraphicsscene_p.h.
QGraphicsScenePrivate::QGraphicsScenePrivate | ( | ) |
Definition at line 248 of file qgraphicsscene.cpp.
void QGraphicsScenePrivate::_q_emitUpdated | ( | ) |
Definition at line 315 of file qgraphicsscene.cpp.
References calledEmitUpdated, changedSignalIndex, QObject::connect(), dirtyGrowingItemsBoundingRect, emit, growingItemsBoundingRect, hasSceneRect, QList< T >::isEmpty(), QObjectPrivate::isSignalConnected(), SIGNAL, SLOT, updateAll, updatedRects, view, and views.
Referenced by _q_processDirtyItems().
void QGraphicsScenePrivate::_q_polishItems | ( | ) |
Definition at line 408 of file qgraphicsscene.cpp.
References QList< T >::at(), QList< T >::clear(), QGraphicsItem::d_ptr, QScopedPointer< T, Cleanup >::data(), i, QMetaObject::invokeMethod(), QList< T >::isEmpty(), item, QGraphicsItem::itemChange(), QGraphicsItem::ItemVisibleChange, QGraphicsItem::ItemVisibleHasChanged, QGraphicsItemPrivate::pendingPolish, QEvent::Polish, QObjectData::q_ptr, Qt::QueuedConnection, QList< T >::remove(), QCoreApplication::sendEvent(), QList< T >::size(), QList< T >::squeeze(), and unpolishedItems.
Referenced by drawItems().
void QGraphicsScenePrivate::_q_processDirtyItems | ( | ) |
Definition at line 445 of file qgraphicsscene.cpp.
References _q_emitUpdated(), calledEmitUpdated, dirtyGrowingItemsBoundingRect, emit, growingItemsBoundingRect, hasSceneRect, processDirtyItemsEmitted, processDirtyItemsRecursive(), Q_ASSERT, resetDirtyItem(), topLevelItems, updateAll, view, and views.
void QGraphicsScenePrivate::_q_updateLater | ( | ) |
void QGraphicsScenePrivate::_q_updateScenePosDescendants | ( | ) |
Definition at line 524 of file qgraphicsscene.cpp.
References QGraphicsItem::d_ptr, item, QGraphicsItemPrivate::parent, QGraphicsItemPrivate::scenePosDescendants, scenePosDescendantsUpdatePending, and scenePosItems.
void QGraphicsScenePrivate::addPopup | ( | QGraphicsWidget * | widget | ) |
Definition at line 866 of file qgraphicsscene.cpp.
References QListSpecialMethodsBase< T >::contains(), focusItem, QEvent::FocusOut, QWidget::focusWidget(), grabKeyboard(), grabMouse(), Qt::PopupFocusReason, popupWidgets, Q_ASSERT, sendEvent(), QWidget::setFocus(), QList< T >::size(), and widget.
void QGraphicsScenePrivate::addView | ( | QGraphicsView * | view | ) |
Definition at line 5793 of file qgraphicsscene.cpp.
References QHash< Key, T >::constBegin(), QHash< Key, T >::constEnd(), grabbedGestures, it, view, and views.
Definition at line 6429 of file qgraphicsscene.cpp.
References QHash< Key, T >::begin(), d, DEBUG, QHash< Key, T >::end(), Qt::GestureCanceled, gestureTargets, QApplicationPrivate::instance(), QGraphicsItem::isAncestorOf(), item, items, itemsAtPosition(), iter, list, Q_ASSERT, QGestureManager::recycle(), QHash< Key, T >::remove(), sendEvent(), QGraphicsItem::toGraphicsObject(), and QHash< Key, T >::value().
Referenced by gestureEventHandler().
void QGraphicsScenePrivate::clearKeyboardGrabber | ( | ) |
Definition at line 1077 of file qgraphicsscene.cpp.
References QList< T >::constFirst(), QList< T >::isEmpty(), keyboardGrabberItems, and ungrabKeyboard().
void QGraphicsScenePrivate::clearMouseGrabber | ( | ) |
Definition at line 1006 of file qgraphicsscene.cpp.
References QList< T >::constFirst(), QList< T >::isEmpty(), lastMouseGrabberItem, mouseGrabberItems, and QGraphicsItem::ungrabMouse().
Referenced by mousePressEventHandler(), and sendMouseEvent().
void QGraphicsScenePrivate::cloneDragDropEvent | ( | QGraphicsSceneDragDropEvent * | dest, |
QGraphicsSceneDragDropEvent * | source ) |
Definition at line 1232 of file qgraphicsscene.cpp.
References QGraphicsSceneDragDropEvent::setButtons(), QGraphicsSceneDragDropEvent::setDropAction(), QGraphicsSceneDragDropEvent::setMimeData(), QGraphicsSceneDragDropEvent::setModifiers(), QGraphicsSceneDragDropEvent::setPos(), QGraphicsSceneDragDropEvent::setPossibleActions(), QGraphicsSceneDragDropEvent::setProposedAction(), QGraphicsSceneDragDropEvent::setScenePos(), QGraphicsSceneDragDropEvent::setScreenPos(), QGraphicsSceneDragDropEvent::setSource(), and QGraphicsSceneEvent::setWidget().
bool QGraphicsScenePrivate::dispatchHoverEvent | ( | QGraphicsSceneHoverEvent * | hoverEvent | ) |
This event handler, for event hoverEvent, can be reimplemented in a subclass to receive hover enter events.
The default implementation forwards the event to the topmost visible item that accepts hover events at the scene position from the event.
Note: See items() for a definition of which items are considered visible by this function.
Definition at line 3763 of file qgraphicsscene.cpp.
References allItemsIgnoreHoverEvents, cachedItemsUnderMouse, QGraphicsItem::commonAncestorItem(), QList< T >::constLast(), QEvent::GraphicsSceneHoverEnter, QEvent::GraphicsSceneHoverLeave, QEvent::GraphicsSceneHoverMove, hoverItems, i, index, QListSpecialMethodsBase< T >::indexOf(), QList< T >::isEmpty(), it, item, itemAcceptsHoverEvents_helper(), itemsAtPosition(), QGraphicsItem::panel(), QObjectData::parent, QGraphicsItem::parentItem(), QGraphicsSceneHoverEvent::scenePos(), QGraphicsSceneHoverEvent::screenPos(), sendHoverEvent(), QList< T >::size(), QList< T >::takeLast(), and QGraphicsSceneEvent::widget().
Referenced by enterModal(), and leaveModal().
void QGraphicsScenePrivate::draw | ( | QGraphicsItem * | item, |
QPainter * | painter, | ||
const QTransform * const | viewTransform, | ||
const QTransform * const | transformPtr, | ||
QRegion * | exposedRegion, | ||
QWidget * | widget, | ||
qreal | opacity, | ||
const QTransform * const | effectTransform, | ||
bool | wasDirtyParentSceneTransform, | ||
bool | drawItem ) |
Definition at line 4790 of file qgraphicsscene.cpp.
References adjustedItemBoundingRect(), QList< T >::at(), QPainter::brush(), QGraphicsItemPrivate::cacheMode, child, QObjectData::children, QGraphicsItemPrivate::children, QObject::d_ptr, QGraphicsItem::d_ptr, drawItemHelper(), QPainter::drawRect(), drawSubtreeRecursive(), QGraphicsItemPrivate::ensureSortedChildren(), QGraphicsItemPrivate::flags, QColor::fromHsv(), i, QGraphicsItemPrivate::initStyleOption(), QList< T >::isEmpty(), QGraphicsItemPrivate::isOpacityNull(), QGraphicsItemPrivate::isWidget, item, QGraphicsItem::ItemClipsChildrenToShape, QGraphicsItem::ItemClipsToShape, QGraphicsItem::ItemHasNoContents, QGraphicsItem::ItemIgnoresParentOpacity, QGraphicsItem::ItemStacksBehindParent, Qt::NoBrush, QGraphicsItem::paint(), painter, painterStateProtection, QPainter::pen(), ptr(), Q_ASSERT, qEnvironmentVariableIntValue(), QPainter::restore(), QPainter::save(), QPainter::setBrush(), setClip(), QPainter::setOpacity(), QPainter::setPen(), setWorldTransform(), QList< T >::size(), styleOptionTmp, and widget.
Referenced by drawSubtreeRecursive().
void QGraphicsScenePrivate::drawItemHelper | ( | QGraphicsItem * | item, |
QPainter * | painter, | ||
const QStyleOptionGraphicsItem * | option, | ||
QWidget * | widget, | ||
bool | painterStateProtection ) |
Draws items directly, or using cache.
Definition at line 4304 of file qgraphicsscene.cpp.
References _q_adjustRect(), _q_paintIntoCache(), _q_paintItem(), QRect::adjust(), QRect::adjusted(), QRectF::adjusted(), QGraphicsItemCache::allExposed, QGraphicsItem::boundingRect(), QGraphicsItemCache::boundingRect, QGraphicsItemCache::DeviceData::cacheIndent, QList< T >::clear(), QGraphicsItem::d_ptr, QScopedPointer< T, Cleanup >::data(), QPainter::device(), QGraphicsItem::DeviceCoordinateCache, QGraphicsItemCache::deviceData, QPaintDevice::devicePixelRatio(), deviceRect, QPainter::drawPixmap(), QGraphicsItemCache::exposed, QStyleOptionGraphicsItem::exposedRect, QGraphicsItemPrivate::ExtraMaxDeviceCoordCacheSize, QPixmapCache::find(), QGraphicsItemCache::fixedSize, QTransform::fromTranslate(), QRect::height(), QRectF::height(), QSize::height(), QPixmapCache::insert(), QTransform::inverted(), QList< T >::isEmpty(), QRect::isEmpty(), QSize::isEmpty(), QPixmap::isNull(), QSize::isValid(), QGraphicsItem::isWidget(), item, QGraphicsItem::ItemCoordinateCache, QGraphicsItemCache::key, QGraphicsItemCache::DeviceData::key, QGraphicsItemCache::DeviceData::lastTransform, QRect::left(), QTransform::mapRect(), QGraphicsItem::NoCache, QPainter::opacity(), painter, painterStateProtection, pix, proxy, rect, QWidget::rect, QPixmapCache::remove(), QPainter::renderHints(), QPixmap::setDevicePixelRatio(), QPainter::setOpacity(), QPainter::setWorldTransform(), QPixmap::size(), QRect::size(), styleOptionTmp, QRectF::toAlignedRect(), QRect::top(), QRect::topLeft(), transformIsSimple(), Qt::transparent, QTransform::TxTranslate, QTransform::type(), widget, QRect::width(), QRectF::width(), QSize::width(), QPainter::worldTransform(), QRect::x(), and QRect::y().
Referenced by draw().
void QGraphicsScenePrivate::drawItems | ( | QPainter * | painter, |
const QTransform *const | viewTransform, | ||
QRegion * | exposedRegion, | ||
QWidget * | widget ) |
Definition at line 4610 of file qgraphicsscene.cpp.
References _q_polishItems(), QRect::adjusted(), Qt::AscendingOrder, QRegion::boundingRect(), drawSubtreeRecursive(), indexMethod, QTransform::inverted(), QList< T >::isEmpty(), QTransform::mapRect(), QGraphicsScene::NoIndex, painter, unpolishedItems, updateAll, and widget.
void QGraphicsScenePrivate::drawSubtreeRecursive | ( | QGraphicsItem * | item, |
QPainter * | painter, | ||
const QTransform * const | viewTransform, | ||
QRegion * | exposedRegion, | ||
QWidget * | widget, | ||
qreal | parentOpacity = qreal(1.0), | ||
const QTransform *const | effectTransform = nullptr ) |
Definition at line 4629 of file qgraphicsscene.cpp.
References QRect::adjust(), adjustedItemEffectiveBoundingRect(), QGraphicsItemPrivate::children, QGraphicsItemPrivate::childrenCombineOpacity(), QGraphicsItemPrivate::combineOpacityFromParent(), QGraphicsItem::d_ptr, Qt::DeviceCoordinates, QGraphicsItem::deviceTransform(), QGraphicsItemPrivate::dirtySceneTransform, draw(), QGraphicsEffect::draw(), QTransform::dx(), QTransform::dy(), ENSURE_TRANSFORM_PTR, QGraphicsItemPrivate::flags, QGraphicsItemPrivate::graphicsEffect, info, QHash< Key, T >::insert(), QRegion::intersects(), QGraphicsItemPrivate::invalidateChildrenSceneTransform(), QList< T >::isEmpty(), QGraphicsEffect::isEnabled(), QGraphicsItemPrivate::isOpacityNull(), item, QGraphicsItem::ItemClipsChildrenToShape, QGraphicsItem::ItemContainsChildrenInShape, QGraphicsItem::ItemHasNoContents, QGraphicsItemPrivate::itemIsUntransformable(), Qt::LogicalCoordinates, QTransform::mapRect(), minimumRenderSize, QGraphicsItemPrivate::paintedViewBoundingRects, painter, Q_ASSERT, rectAdjust, QPainter::setOpacity(), QPainter::setWorldTransform(), QGraphicsEffect::source(), styleOptionTmp, QGraphicsEffectSourcePrivate::TransformChanged, QRectF::translated(), QTransform::TxTranslate, QTransform::type(), Qt::Uninitialized, QGraphicsItemPrivate::updateSceneTransformFromParent(), QGraphicsItemPrivate::visible, widget, and QPainter::worldTransform().
Referenced by draw(), and drawItems().
void QGraphicsScenePrivate::enableMouseTrackingOnViews | ( | ) |
Definition at line 1083 of file qgraphicsscene.cpp.
void QGraphicsScenePrivate::enableTouchEventsOnViews | ( | ) |
Definition at line 6030 of file qgraphicsscene.cpp.
References view, views, and Qt::WA_AcceptTouchEvents.
void QGraphicsScenePrivate::ensureSequentialTopLevelSiblingIndexes | ( | ) |
Ensures that the list of toplevels is sorted by insertion order, and that the siblingIndexes are packed (no gaps), and start at 0.
QGraphicsItemPrivate::ensureSequentialSiblingIndex().
Definition at line 1480 of file qgraphicsscene.cpp.
References QList< T >::begin(), QList< T >::end(), holesInTopLevelSiblingIndex, i, QGraphicsItemPrivate::insertionOrder(), needSortTopLevelItems, QList< T >::size(), topLevelItems, and topLevelSequentialOrdering.
Referenced by registerTopLevelItem().
|
inline |
Definition at line 253 of file qgraphicsscene_p.h.
References qt_notclosestLeaf().
Referenced by QGraphicsSceneIndex::estimateTopLevelItems().
void QGraphicsScenePrivate::enterModal | ( | QGraphicsItem * | item, |
QGraphicsItem::PanelModality | panelModality = QGraphicsItem::NonModal ) |
Definition at line 6042 of file qgraphicsscene.cpp.
References QList< T >::constLast(), QObject::d_ptr, dispatchHoverEvent(), hoverItems, QGraphicsItem::isBlockedByModalPanel(), QList< T >::isEmpty(), QGraphicsItem::isPanel(), item, lastMouseGrabberItemHasImplicitMouseGrab, lastSceneMousePos, modalPanels, mouseGrabberItems, QGraphicsItem::NonModal, panel, QList< T >::prepend(), Q_ASSERT, QList< T >::removeAll(), sendEvent(), QGraphicsSceneHoverEvent::setScenePos(), ungrabMouse(), QEvent::WindowBlocked, and QEvent::WindowUnblocked.
bool QGraphicsScenePrivate::filterDescendantEvent | ( | QGraphicsItem * | item, |
QEvent * | event ) |
Definition at line 1159 of file qgraphicsscene.cpp.
References QGraphicsItemPrivate::AncestorFiltersChildEvents, QGraphicsItemPrivate::ancestorFlags, QObject::d_ptr, QGraphicsItem::d_ptr, item, QObjectData::parent, and QGraphicsItem::parentItem().
Referenced by sendEvent().
bool QGraphicsScenePrivate::filterEvent | ( | QGraphicsItem * | item, |
QEvent * | event ) |
Definition at line 1177 of file qgraphicsscene.cpp.
References QMultiMap< Key, T >::contains(), it, item, QMultiMap< Key, T >::lowerBound(), sceneEventFilters, and QMultiMap< Key, T >::upperBound().
Referenced by sendEvent().
int QGraphicsScenePrivate::findClosestTouchPointId | ( | const QPointF & | scenePos | ) |
Definition at line 5819 of file qgraphicsscene.cpp.
References QLineF::length(), and sceneCurrentTouchPoints.
Referenced by touchEventHandler().
void QGraphicsScenePrivate::gestureEventHandler | ( | QGestureEvent * | event | ) |
Definition at line 6182 of file qgraphicsscene.cpp.
References QList< T >::append(), QList< T >::at(), QHash< Key, T >::begin(), QList< T >::begin(), QSet< T >::begin(), cachedAlreadyDeliveredGestures, cachedItemGestures, cachedTargetItems, QGesture::CancelAllInContext, cancelGesturesForChildren(), QList< T >::clear(), QHash< Key, T >::clear(), QList< T >::constBegin(), QList< T >::constEnd(), QHash< Key, T >::contains(), QGraphicsItem::contains(), d, QGraphicsItem::data(), DEBUG, QList< T >::end(), QSet< T >::end(), QHash< Key, T >::end(), QSet< T >::erase(), QTransform::fromTranslate(), Qt::GestureCanceled, QGraphicsItemPrivate::gestureContext, Qt::GestureFinished, QEvent::GestureOverride, Qt::GestureStarted, gestureTargets, gestureTargetsAtHotSpots(), QGesture::gestureType, i, Qt::IgnoredGesturesPropagateToParent, QHash< Key, T >::insert(), QTransform::inverted(), QGraphicsItem::isPanel(), it, item, QHash< Key, T >::keys(), QTransform::map(), QGraphicsItem::parentItem(), qt_closestItemFirst(), Qt::ReceivePartialGestures, QHash< Key, T >::remove(), QSet< T >::remove(), sendEvent(), QList< T >::size(), QGraphicsItem::toGraphicsObject(), QHash< Key, T >::value(), QMap< Key, T >::value(), viewport(), QGraphicsView::viewportTransform(), QPoint::x(), and QPoint::y().
void QGraphicsScenePrivate::gestureTargetsAtHotSpots | ( | const QSet< QGesture * > & | gestures, |
Qt::GestureFlag | flag, | ||
QHash< QGraphicsObject *, QSet< QGesture * > > * | targets, | ||
QSet< QGraphicsObject * > * | itemsSet = nullptr, | ||
QSet< QGesture * > * | normal = nullptr, | ||
QSet< QGesture * > * | conflicts = nullptr ) |
Definition at line 6135 of file qgraphicsscene.cpp.
References QList< T >::at(), QSet< T >::constEnd(), QSet< T >::constFind(), d, QGraphicsItem::isBlockedByModalPanel(), QGraphicsItem::isPanel(), it, item, items, itemsAtPosition(), j, QList< T >::size(), QGraphicsItem::toGraphicsObject(), and void.
Referenced by gestureEventHandler().
|
static |
Definition at line 310 of file qgraphicsscene.cpp.
void QGraphicsScenePrivate::grabGesture | ( | QGraphicsItem * | , |
Qt::GestureType | gesture ) |
Definition at line 6513 of file qgraphicsscene.cpp.
References grabbedGestures, QGestureManager::instance(), view, views, and void.
void QGraphicsScenePrivate::grabKeyboard | ( | QGraphicsItem * | item | ) |
Definition at line 1016 of file qgraphicsscene.cpp.
References QList< T >::constLast(), QListSpecialMethodsBase< T >::contains(), QEvent::GrabKeyboard, QList< T >::isEmpty(), item, keyboardGrabberItems, qWarning, sendEvent(), and QEvent::UngrabKeyboard.
Referenced by addPopup().
void QGraphicsScenePrivate::grabMouse | ( | QGraphicsItem * | item, |
bool | implicit = false ) |
Definition at line 916 of file qgraphicsscene.cpp.
References QList< T >::constLast(), QListSpecialMethodsBase< T >::contains(), QEvent::GrabMouse, QList< T >::isEmpty(), item, lastMouseGrabberItemHasImplicitMouseGrab, mouseGrabberItems, Q_ASSERT, qWarning, sendEvent(), QEvent::UngrabMouse, and QGraphicsItem::ungrabMouse().
Referenced by addPopup(), and mousePressEventHandler().
void QGraphicsScenePrivate::init | ( | ) |
Definition at line 292 of file qgraphicsscene.cpp.
References changedSignalIndex, polishItemsIndex, processDirtyItemsIndex, qApp, and signalIndex.
void QGraphicsScenePrivate::installSceneEventFilter | ( | QGraphicsItem * | watched, |
QGraphicsItem * | filter ) |
Definition at line 1133 of file qgraphicsscene.cpp.
References QMultiMap< Key, T >::insert(), and sceneEventFilters.
bool QGraphicsScenePrivate::itemAcceptsHoverEvents_helper | ( | const QGraphicsItem * | item | ) | const |
Definition at line 3745 of file qgraphicsscene.cpp.
References QGraphicsItemPrivate::acceptsHover, QGraphicsItem::d_ptr, QGraphicsItem::isBlockedByModalPanel(), QGraphicsItemPrivate::isWidget, and item.
Referenced by dispatchHoverEvent(), and leaveScene().
QList< QGraphicsItem * > QGraphicsScenePrivate::itemsAtPosition | ( | const QPoint & | screenPos, |
const QPointF & | scenePos, | ||
QWidget * | widget ) const |
Returns all items for the screen position in event.
Definition at line 1092 of file qgraphicsscene.cpp.
References Qt::DescendingOrder, Qt::IntersectsItemShape, QTransform::inverted(), QTransform::map(), QWidget::mapFromGlobal(), QTransform::mapRect(), QWidget::parentWidget(), QTransform::TxScale, QTransform::type(), view, and widget.
Referenced by cancelGesturesForChildren(), dispatchHoverEvent(), gestureTargetsAtHotSpots(), mousePressEventHandler(), sendTouchBeginEvent(), and touchEventHandler().
void QGraphicsScenePrivate::leaveModal | ( | QGraphicsItem * | item | ) |
Definition at line 6103 of file qgraphicsscene.cpp.
References dispatchHoverEvent(), QGraphicsItem::isBlockedByModalPanel(), QGraphicsItem::isPanel(), item, lastSceneMousePos, modalPanels, panel, Q_ASSERT, QList< T >::removeAll(), sendEvent(), QGraphicsSceneHoverEvent::setScenePos(), and QEvent::WindowUnblocked.
Referenced by removeItemHelper().
Handles all actions necessary to clean up the scene when the mouse leaves the view.
Definition at line 3840 of file qgraphicsscene.cpp.
References QEvent::GraphicsSceneHoverLeave, QToolTip::hideText(), hoverItems, QList< T >::isEmpty(), itemAcceptsHoverEvents_helper(), QCursor::pos(), QGraphicsSceneHoverEvent::scenePos(), QGraphicsSceneHoverEvent::screenPos(), sendHoverEvent(), QGraphicsSceneHoverEvent::setLastScenePos(), QGraphicsSceneHoverEvent::setLastScreenPos(), QGraphicsSceneHoverEvent::setScenePos(), QGraphicsSceneHoverEvent::setScreenPos(), QGraphicsSceneEvent::setWidget(), QList< T >::takeLast(), view, and viewport().
void QGraphicsScenePrivate::markDirty | ( | QGraphicsItem * | item, |
const QRectF & | rect = QRectF(), | ||
bool | invalidateChildren = false, | ||
bool | force = false, | ||
bool | ignoreOpacity = false, | ||
bool | removingItemFromScene = false, | ||
bool | updateBoundingRect = false ) |
Definition at line 4915 of file qgraphicsscene.cpp.
References QGraphicsItemPrivate::allChildrenDirty, changedSignalIndex, QGraphicsItem::d_ptr, QGraphicsItemPrivate::dirty, QGraphicsItemPrivate::dirtyChildren, QGraphicsItemPrivate::discardUpdateRequest(), QGraphicsItemPrivate::flags, QGraphicsItemPrivate::fullUpdatePending, QGraphicsItemPrivate::graphicsEffect, QGraphicsItemPrivate::ignoreOpacity, QGraphicsItemPrivate::ignoreVisible, QList< T >::isEmpty(), QObjectPrivate::isSignalConnected(), item, QGraphicsItem::ItemHasNoContents, QGraphicsItemPrivate::markParentDirty(), method, QGraphicsItemPrivate::needsRepaint, QGraphicsItemPrivate::paintedViewBoundingRects, QGraphicsItemPrivate::parent, processDirtyItemsEmitted, processDirtyItemsIndex, Q_ASSERT, QObjectData::q_ptr, Qt::QueuedConnection, rect, QRect::translate(), updateAll, QHash< Key, T >::value(), view, and views.
Referenced by removeItemHelper().
void QGraphicsScenePrivate::mousePressEventHandler | ( | QGraphicsSceneMouseEvent * | mouseEvent | ) |
Definition at line 1309 of file qgraphicsscene.cpp.
References QEvent::accept(), QGraphicsItem::acceptedMouseButtons(), QGraphicsSceneMouseEvent::button(), QGraphicsSceneMouseEvent::buttonDownPos(), QGraphicsSceneMouseEvent::buttonDownScenePos(), QGraphicsSceneMouseEvent::buttonDownScreenPos(), QGraphicsSceneMouseEvent::buttons(), cachedItemsUnderMouse, clearMouseGrabber(), Qt::ClickFocus, QList< T >::constFirst(), QList< T >::constLast(), Qt::ControlModifier, QGraphicsItem::d_ptr, disabled, QGraphicsItem::flags(), QGraphicsItemPrivate::flags, QGraphicsItem::focusItem(), grabMouse(), QEvent::GraphicsSceneMouseDoubleClick, QEvent::GraphicsSceneMousePress, QEvent::ignore(), QEvent::isAccepted(), QGraphicsItem::isBlockedByModalPanel(), QList< T >::isEmpty(), QGraphicsItem::isEnabled(), QGraphicsItem::isPanel(), QGraphicsItem::isWidget(), item, QGraphicsItem::ItemIsFocusable, itemsAtPosition(), QGraphicsItem::ItemStopsClickFocusPropagation, QGraphicsItem::ItemStopsFocusHandling, lastMouseGrabberItem, modalPanels, QGraphicsSceneMouseEvent::modifiers(), Qt::MouseFocusReason, mouseGrabberItems, QGraphicsItemPrivate::mouseSetsFocus, QWidget::parentWidget(), QGraphicsItem::SceneModal, QGraphicsSceneMouseEvent::scenePos(), QGraphicsSceneMouseEvent::screenPos(), QGraphicsView::ScrollHandDrag, sendMouseEvent(), QEvent::setAccepted(), QEvent::spontaneous(), stickyFocus, storeMouseButtonsForMouseGrabber(), QEvent::type(), ungrabMouse(), QList< T >::value(), view, void, QGraphicsSceneEvent::widget(), and QGraphicsItem::window().
void QGraphicsScenePrivate::processDirtyItemsRecursive | ( | QGraphicsItem * | item, |
bool | dirtyAncestorContainsChildren = false, | ||
qreal | parentOpacity = qreal(1.0) ) |
Definition at line 5050 of file qgraphicsscene.cpp.
References _q_adjustRect(), adjustedItemEffectiveBoundingRect(), QGraphicsItemPrivate::allChildrenDirty, QGraphicsItem::boundingRect(), QGraphicsItem::boundingRegionGranularity(), changedSignalIndex, child, QGraphicsItemPrivate::children, QGraphicsItemPrivate::childrenCombineOpacity(), QGraphicsItemPrivate::combineOpacityFromParent(), QGraphicsItem::d_ptr, QScopedPointer< T, Cleanup >::data(), QGraphicsItemPrivate::dirty, QGraphicsItemPrivate::dirtyChildren, QGraphicsItemPrivate::dirtySceneTransform, QTransform::dx(), QTransform::dy(), QGraphicsItemPrivate::flags, QGraphicsItemPrivate::fullUpdatePending, QGraphicsItemPrivate::geometryChanged, QGraphicsItemPrivate::graphicsEffect, growingItemsBoundingRect, hasSceneRect, QGraphicsItemPrivate::ignoreOpacity, QGraphicsItemPrivate::ignoreVisible, QGraphicsItemPrivate::invalidateChildrenSceneTransform(), QList< T >::isEmpty(), QRectF::isEmpty(), QGraphicsItemPrivate::isOpacityNull(), QObjectPrivate::isSignalConnected(), item, QGraphicsItem::ItemClipsChildrenToShape, QGraphicsItem::ItemContainsChildrenInShape, QGraphicsItem::ItemHasNoContents, QGraphicsItemPrivate::itemIsUntransformable(), QTransform::mapRect(), QGraphicsItemPrivate::needsRepaint, QGraphicsView::NoViewportUpdate, QGraphicsItemPrivate::paintedViewBoundingRects, QGraphicsItemPrivate::paintedViewBoundingRectsNeedRepaint, processDirtyItemsRecursive(), Q_ASSERT, qFuzzyIsNull(), rect, resetDirtyItem(), QGraphicsItemPrivate::sceneTransform, QGraphicsItemPrivate::sceneTransformTranslateOnly, updateAll, updateHelper(), QGraphicsItemPrivate::updateSceneTransformFromParent(), view, views, and QGraphicsItemPrivate::visible.
Referenced by _q_processDirtyItems(), and processDirtyItemsRecursive().
void QGraphicsScenePrivate::registerScenePosItem | ( | QGraphicsItem * | item | ) |
Definition at line 506 of file qgraphicsscene.cpp.
References QSet< T >::insert(), item, scenePosItems, and setScenePosItemEnabled().
void QGraphicsScenePrivate::registerTopLevelItem | ( | QGraphicsItem * | item | ) |
Definition at line 376 of file qgraphicsscene.cpp.
References QList< T >::append(), QGraphicsItem::d_ptr, ensureSequentialTopLevelSiblingIndexes(), item, needSortTopLevelItems, QGraphicsItemPrivate::siblingIndex, QList< T >::size(), and topLevelItems.
void QGraphicsScenePrivate::removeItemHelper | ( | QGraphicsItem * | item | ) |
Schedules an item for removal. This function leaves some stale indexes around in the BSP tree if called from the item's destructor; these will be cleaned up the next time someone triggers purgeRemovedItems().
Note: This function might get called from QGraphicsItem's destructor. item is being destroyed, so we cannot call any pure virtual functions on it (such as boundingRect()). Also, it is unnecessary to update the item's own state in any way.
Definition at line 548 of file qgraphicsscene.cpp.
References activePanel, QHash< Key, T >::begin(), QMap< Key, T >::begin(), QMultiMap< Key, T >::begin(), cachedAlreadyDeliveredGestures, cachedItemGestures, cachedItemsUnderMouse, cachedTargetItems, child, QGraphicsItemPrivate::children, QGraphicsItem::clearFocus(), QGraphicsItemPrivate::clearSubFocus(), QMap< Key, T >::constBegin(), QMap< Key, T >::constEnd(), QListSpecialMethodsBase< T >::contains(), QGraphicsItem::d_ptr, dragDropItem, emit, QMap< Key, T >::end(), QMultiMap< Key, T >::end(), QHash< Key, T >::end(), QHash< Key, T >::erase(), QMap< Key, T >::erase(), QMultiMap< Key, T >::erase(), QGraphicsItem::flags(), focusItem, QGraphicsWidgetPrivate::focusNext, QGraphicsItemPrivate::gestureContext, gestureTargets, hoverItems, QGraphicsItemPrivate::inDestructor, QListSpecialMethodsBase< T >::indexOf(), QGraphicsItem::isPanel(), QGraphicsItem::isVisible(), QGraphicsItem::isWidget(), it, item, itemForTouchPointId, QGraphicsItem::ItemSendsScenePositionChanges, keyboardGrabberItems, lastActivePanel, lastFocusItem, lastMouseGrabberItem, leaveModal(), markDirty(), mouseGrabberItems, QGraphicsItem::NonModal, QGraphicsItem::panelModality(), QGraphicsItem::parentItem(), passiveFocusItem, QGraphicsItemPrivate::pendingPolish, Q_ASSERT_X, QHash< Key, T >::remove(), QMap< Key, T >::remove(), QSet< T >::remove(), QList< T >::removeAll(), QGraphicsScene::removeItem(), QList< T >::removeOne(), resetDirtyItem(), QGraphicsItemPrivate::resetFocusProxy(), QGraphicsItem::scene(), sceneCurrentTouchPoints, sceneEventFilters, selectedItems, selectionChanging, QGraphicsItem::setParentItem(), QSet< T >::size(), tabFocusFirst, QGraphicsItem::toGraphicsObject(), ungrabGesture(), ungrabKeyboard(), ungrabMouse(), unpolishedItems, unregisterScenePosItem(), unregisterTopLevelItem(), and widget.
void QGraphicsScenePrivate::removePopup | ( | QGraphicsWidget * | widget, |
bool | itemIsDying = false ) |
Remove widget from the popup list. Important notes:
widget is guaranteed to be in the list of popups, but it might not be the last entry; you can hide any item in the pop list before the others, and this must cause all later mouse grabbers to lose the grab.
Definition at line 892 of file qgraphicsscene.cpp.
References QListSpecialMethodsBase< T >::contains(), QEvent::FocusIn, focusItem, i, index, QListSpecialMethodsBase< T >::indexOf(), QList< T >::isEmpty(), QWidget::isVisible(), keyboardGrabberItems, Qt::PopupFocusReason, popupWidgets, Q_ASSERT, sendEvent(), QList< T >::size(), QList< T >::takeLast(), ungrabKeyboard(), ungrabMouse(), and widget.
Referenced by ungrabMouse().
void QGraphicsScenePrivate::removeSceneEventFilter | ( | QGraphicsItem * | watched, |
QGraphicsItem * | filter ) |
Definition at line 1141 of file qgraphicsscene.cpp.
References QMultiMap< Key, T >::contains(), QMultiMap< Key, T >::erase(), it, QMultiMap< Key, T >::lowerBound(), sceneEventFilters, and QMultiMap< Key, T >::upperBound().
void QGraphicsScenePrivate::removeView | ( | QGraphicsView * | view | ) |
Definition at line 5803 of file qgraphicsscene.cpp.
References QList< T >::removeAll(), view, and views.
|
inline |
Definition at line 218 of file qgraphicsscene_p.h.
References QGraphicsItemPrivate::allChildrenDirty, QList< T >::at(), QGraphicsItemPrivate::children, QGraphicsItem::d_ptr, QGraphicsItemPrivate::dirty, QGraphicsItemPrivate::dirtyChildren, QGraphicsItemPrivate::fullUpdatePending, QGraphicsItemPrivate::geometryChanged, QGraphicsItemPrivate::graphicsEffect, i, QGraphicsItemPrivate::ignoreOpacity, QGraphicsItemPrivate::ignoreVisible, item, QGraphicsItemPrivate::needsRepaint, QGraphicsItemPrivate::notifyBoundingRectChanged, QGraphicsItemPrivate::notifyInvalidated, QGraphicsItemPrivate::paintedViewBoundingRectsNeedRepaint, Q_ASSERT, QList< T >::size(), QGraphicsEffect::SourceBoundingRectChanged, QGraphicsEffect::sourceChanged(), and QGraphicsEffect::SourceInvalidated.
Referenced by _q_processDirtyItems(), processDirtyItemsRecursive(), and removeItemHelper().
void QGraphicsScenePrivate::resolveFont | ( | ) |
Resolve the scene's font against the application font, and propagate the changes too all items in the scene.
Definition at line 1513 of file qgraphicsscene.cpp.
References font, QApplication::font(), QFont::resolve(), and updateFont().
void QGraphicsScenePrivate::resolvePalette | ( | ) |
Resolve the scene's palette against the application palette, and propagate the changes too all items in the scene.
Definition at line 1570 of file qgraphicsscene.cpp.
References QGuiApplication::palette(), palette, QPalette::resolve(), and updatePalette().
void QGraphicsScenePrivate::sendDragDropEvent | ( | QGraphicsItem * | item, |
QGraphicsSceneDragDropEvent * | dragDropEvent ) |
Definition at line 1251 of file qgraphicsscene.cpp.
References QGraphicsItem::d_ptr, QGraphicsItemPrivate::genericMapFromScene(), item, and sendEvent().
bool QGraphicsScenePrivate::sendEvent | ( | QGraphicsItem * | item, |
QEvent * | event ) |
This is the final dispatch point for any events from the scene to the item. It filters the event first - if the filter returns true
, the event is considered to have been eaten by the filter, and is therefore stopped (the default filter returns false
). Then/otherwise, if the item is enabled, the event is sent; otherwise it is stopped.
Definition at line 1202 of file qgraphicsscene.cpp.
References filterDescendantEvent(), filterEvent(), QGestureManager::filterEvent(), QApplicationPrivate::instance(), QGraphicsItem::isEnabled(), item, o, qt_sendSpontaneousEvent(), QGraphicsItem::sceneEvent(), QCoreApplication::sendEvent(), and QGraphicsItem::toGraphicsObject().
Referenced by addPopup(), cancelGesturesForChildren(), enterModal(), gestureEventHandler(), grabKeyboard(), grabMouse(), leaveModal(), removePopup(), sendDragDropEvent(), sendHoverEvent(), sendMouseEvent(), sendTouchBeginEvent(), setFocusItemHelper(), touchEventHandler(), ungrabKeyboard(), and ungrabMouse().
void QGraphicsScenePrivate::sendHoverEvent | ( | QEvent::Type | type, |
QGraphicsItem * | item, | ||
QGraphicsSceneHoverEvent * | hoverEvent ) |
Definition at line 1261 of file qgraphicsscene.cpp.
References QGraphicsItem::d_ptr, QGraphicsItemPrivate::genericMapFromSceneTransform(), item, QGraphicsSceneHoverEvent::lastScenePos(), QGraphicsSceneHoverEvent::lastScreenPos(), QTransform::map(), QGraphicsSceneHoverEvent::modifiers(), QGraphicsSceneHoverEvent::scenePos(), QGraphicsSceneHoverEvent::screenPos(), sendEvent(), and QGraphicsSceneEvent::widget().
Referenced by dispatchHoverEvent(), and leaveScene().
void QGraphicsScenePrivate::sendMouseEvent | ( | QGraphicsSceneMouseEvent * | mouseEvent | ) |
Definition at line 1280 of file qgraphicsscene.cpp.
References button, QGraphicsSceneMouseEvent::button(), QGraphicsSceneMouseEvent::buttons(), clearMouseGrabber(), QList< T >::constLast(), QGraphicsItem::d_ptr, QGraphicsItemPrivate::genericMapFromSceneTransform(), i, QGraphicsItem::isBlockedByModalPanel(), item, lastMouseGrabberItemHasImplicitMouseGrab, QGraphicsSceneMouseEvent::lastScenePos(), QTransform::map(), mouseGrabberButtonDownPos, mouseGrabberButtonDownScenePos, mouseGrabberButtonDownScreenPos, mouseGrabberItems, QGraphicsSceneMouseEvent::scenePos(), QGraphicsSceneMouseEvent::screenPos(), sendEvent(), QGraphicsSceneMouseEvent::setButtonDownPos(), QGraphicsSceneMouseEvent::setButtonDownScenePos(), QGraphicsSceneMouseEvent::setButtonDownScreenPos(), QGraphicsSceneMouseEvent::setLastPos(), QGraphicsSceneMouseEvent::setPos(), QMap< Key, T >::value(), and QGraphicsSceneEvent::widget().
Referenced by mousePressEventHandler().
bool QGraphicsScenePrivate::sendTouchBeginEvent | ( | QGraphicsItem * | item, |
QTouchEvent * | touchEvent ) |
Definition at line 5958 of file qgraphicsscene.cpp.
References QGraphicsItemPrivate::acceptedTouchBeginEvent, QGraphicsItem::acceptTouchEvents(), cachedItemsUnderMouse, Qt::ClickFocus, QList< T >::constFirst(), QGraphicsItem::d_ptr, QMap< Key, T >::first(), QGraphicsItem::flags(), QGraphicsItemPrivate::flags, QGraphicsItem::focusItem(), focusOnTouch, QEventPoint::id, QList< T >::isEmpty(), QGraphicsItem::isEnabled(), QGraphicsItem::isPanel(), QGraphicsItem::isWidget(), item, itemForTouchPointId, QGraphicsItem::ItemIsFocusable, itemsAtPosition(), QGraphicsItem::ItemStopsClickFocusPropagation, QGraphicsItem::ItemStopsFocusHandling, Qt::MouseFocusReason, QGraphicsItemPrivate::mouseSetsFocus, QTest::QTouchEventSequence::points, sendEvent(), stickyFocus, updateTouchPointsForItem(), and QMap< Key, T >::value().
Referenced by touchEventHandler().
void QGraphicsScenePrivate::setActivePanelHelper | ( | QGraphicsItem * | item, |
bool | duringActivationEvent ) |
Definition at line 710 of file qgraphicsscene.cpp.
References QEvent::ActivationChange, activePanel, Qt::ActiveWindowFocusReason, emit, QGraphicsItem::focusItem(), focusItem, QGraphicsWidget::focusPolicy, QGraphicsItem::isPanel(), QGraphicsItem::isVisible(), item, QGraphicsItem::ItemIsFocusable, items, lastActivePanel, panel, QGraphicsItem::panel(), QGraphicsItem::parentItem(), qWarning, QGraphicsItem::scene(), QCoreApplication::sendEvent(), setFocusItemHelper(), Qt::TabFocus, QEvent::WindowActivate, and QEvent::WindowDeactivate.
void QGraphicsScenePrivate::setFocusItemHelper | ( | QGraphicsItem * | item, |
Qt::FocusReason | focusReason, | ||
bool | emitFocusChanged = true ) |
emitFocusChanged needs to be false when focus passes from one item to another through setActivePanel(); i.e. when activation passes from one panel to another, to avoid getting two focusChanged() emissions; one focusChanged(0, lastFocus), then one focusChanged(newFocus, 0). Instead setActivePanel() emits the signal once itself: focusChanged(newFocus, oldFocus).
Definition at line 800 of file qgraphicsscene.cpp.
References emit, QGraphicsItem::flags(), QEvent::FocusIn, focusItem, QEvent::FocusOut, QGuiApplication::inputMethod(), QGraphicsItem::isEnabled(), QGraphicsItem::isVisible(), item, QGraphicsItem::ItemAcceptsInputMethod, QGraphicsItem::ItemIsFocusable, lastFocusItem, qApp, QGraphicsItem::scene(), sendEvent(), QGraphicsItem::setFocus(), and updateInputMethodSensitivityInViews().
Referenced by setActivePanelHelper().
Set the font and propagate the changes if the font is different from the current font.
Definition at line 1500 of file qgraphicsscene.cpp.
References font, QFont::resolveMask(), and updateFont().
Set the palette and propagate the changes if the palette is different from the current palette.
Definition at line 1557 of file qgraphicsscene.cpp.
References palette, QPalette::resolveMask(), and updatePalette().
void QGraphicsScenePrivate::setScenePosItemEnabled | ( | QGraphicsItem * | item, |
bool | enabled ) |
Definition at line 490 of file qgraphicsscene.cpp.
References QGraphicsItem::d_ptr, enabled, QMetaObject::invokeMethod(), item, QGraphicsItemPrivate::parent, Qt::QueuedConnection, QGraphicsItemPrivate::scenePosDescendants, and scenePosDescendantsUpdatePending.
Referenced by registerScenePosItem(), and unregisterScenePosItem().
void QGraphicsScenePrivate::storeMouseButtonsForMouseGrabber | ( | QGraphicsSceneMouseEvent * | event | ) |
Definition at line 1117 of file qgraphicsscene.cpp.
References QList< T >::constLast(), QGraphicsItem::d_ptr, QGraphicsItemPrivate::genericMapFromScene(), i, QMap< Key, T >::insert(), mouseGrabberButtonDownPos, mouseGrabberButtonDownScenePos, mouseGrabberButtonDownScreenPos, and mouseGrabberItems.
Referenced by mousePressEventHandler().
void QGraphicsScenePrivate::touchEventHandler | ( | QTouchEvent * | touchEvent | ) |
Definition at line 5833 of file qgraphicsscene.cpp.
References QGraphicsItemPrivate::acceptedTouchBeginEvent, cachedItemsUnderMouse, QMap< Key, T >::constBegin(), QSet< T >::constBegin(), QList< T >::constFirst(), QListSpecialMethodsBase< T >::contains(), QMap< Key, T >::contains(), QGraphicsItem::d_ptr, findClosestTouchPointId(), QMap< Key, T >::first(), QMap< Key, T >::insert(), QGraphicsItem::isBlockedByModalPanel(), QMap< Key, T >::isEmpty(), QList< T >::isEmpty(), it, item, itemForTouchPointId, itemsAtPosition(), QTest::QTouchEventSequence::points, QEventPoint::Pressed, Q_ASSERT, QEventPoint::Released, QMap< Key, T >::remove(), sceneCurrentTouchPoints, sendEvent(), sendTouchBeginEvent(), QEventPoint::Stationary, QMap< Key, T >::take(), QEvent::TouchBegin, QEvent::TouchEnd, QInputDevice::TouchPad, QInputDevice::TouchScreen, QEvent::TouchUpdate, updateTouchPointsForItem(), QMap< Key, T >::value(), and void.
void QGraphicsScenePrivate::ungrabGesture | ( | QGraphicsItem * | item, |
Qt::GestureType | gesture ) |
Definition at line 6522 of file qgraphicsscene.cpp.
References QGraphicsItem::d_ptr, grabbedGestures, QGestureManager::instance(), QGraphicsItemPrivate::isObject, item, Q_ASSERT, view, and views.
Referenced by removeItemHelper().
void QGraphicsScenePrivate::ungrabKeyboard | ( | QGraphicsItem * | item, |
bool | itemIsDying = false ) |
Definition at line 1044 of file qgraphicsscene.cpp.
References QList< T >::at(), QList< T >::constLast(), QEvent::GrabKeyboard, QList< T >::isEmpty(), item, keyboardGrabberItems, QListSpecialMethodsBase< T >::lastIndexOf(), qWarning, sendEvent(), QList< T >::takeLast(), QEvent::UngrabKeyboard, and ungrabKeyboard().
Referenced by clearKeyboardGrabber(), removeItemHelper(), removePopup(), and ungrabKeyboard().
void QGraphicsScenePrivate::ungrabMouse | ( | QGraphicsItem * | item, |
bool | itemIsDying = false ) |
Definition at line 959 of file qgraphicsscene.cpp.
References QList< T >::at(), QList< T >::constLast(), QEvent::GrabMouse, QListSpecialMethodsBase< T >::indexOf(), QList< T >::isEmpty(), item, lastMouseGrabberItemHasImplicitMouseGrab, mouseGrabberItems, popupWidgets, qWarning, removePopup(), sendEvent(), QList< T >::takeLast(), QEvent::UngrabMouse, and ungrabMouse().
Referenced by enterModal(), mousePressEventHandler(), removeItemHelper(), removePopup(), and ungrabMouse().
void QGraphicsScenePrivate::unregisterScenePosItem | ( | QGraphicsItem * | item | ) |
Definition at line 515 of file qgraphicsscene.cpp.
References item, QSet< T >::remove(), scenePosItems, and setScenePosItemEnabled().
Referenced by removeItemHelper().
void QGraphicsScenePrivate::unregisterTopLevelItem | ( | QGraphicsItem * | item | ) |
Definition at line 389 of file qgraphicsscene.cpp.
References QGraphicsItem::d_ptr, holesInTopLevelSiblingIndex, item, QList< T >::removeAt(), QList< T >::removeOne(), QGraphicsItemPrivate::siblingIndex, QList< T >::size(), topLevelItems, and topLevelSequentialOrdering.
Referenced by removeItemHelper().
Update the font, and whether or not it has changed, reresolve all fonts in the scene.
Definition at line 1527 of file qgraphicsscene.cpp.
References QGraphicsItem::d_ptr, font, QEvent::FontChange, item, items, QGraphicsItem::parentItem(), QGraphicsItemPrivate::resolveFont(), QFont::resolveMask(), and QCoreApplication::sendEvent().
Referenced by resolveFont(), and setFont_helper().
void QGraphicsScenePrivate::updateInputMethodSensitivityInViews | ( | ) |
Definition at line 6036 of file qgraphicsscene.cpp.
Referenced by setFocusItemHelper().
Update the palette, and whether or not it has changed, reresolve all palettes in the scene.
Definition at line 1584 of file qgraphicsscene.cpp.
References QGraphicsItem::d_ptr, item, items, palette, QEvent::PaletteChange, QGraphicsItem::parentItem(), QPalette::resolveMask(), QGraphicsItemPrivate::resolvePalette(), and QCoreApplication::sendEvent().
Referenced by resolvePalette(), and setPalette_helper().
|
static |
Definition at line 5808 of file qgraphicsscene.cpp.
References QGraphicsItem::d_ptr, QGraphicsItemPrivate::genericMapFromSceneTransform(), i, item, QTransform::map(), and QTest::QTouchEventSequence::point().
Referenced by sendTouchBeginEvent(), and touchEventHandler().
QGraphicsWidget * QGraphicsScenePrivate::windowForItem | ( | const QGraphicsItem * | item | ) | const |
int QGraphicsScenePrivate::activationRefCount |
Definition at line 138 of file qgraphicsscene_p.h.
QGraphicsItem* QGraphicsScenePrivate::activePanel |
Definition at line 136 of file qgraphicsscene_p.h.
Referenced by removeItemHelper(), and setActivePanelHelper().
quint32 QGraphicsScenePrivate::allItemsIgnoreHoverEvents |
Definition at line 79 of file qgraphicsscene_p.h.
Referenced by dispatchHoverEvent().
quint32 QGraphicsScenePrivate::allItemsIgnoreTouchEvents |
Definition at line 83 of file qgraphicsscene_p.h.
quint32 QGraphicsScenePrivate::allItemsUseDefaultCursor |
Definition at line 80 of file qgraphicsscene_p.h.
QBrush QGraphicsScenePrivate::backgroundBrush |
Definition at line 128 of file qgraphicsscene_p.h.
QHash<QGraphicsObject *, QSet<QGesture *> > QGraphicsScenePrivate::cachedAlreadyDeliveredGestures |
Definition at line 287 of file qgraphicsscene_p.h.
Referenced by gestureEventHandler(), and removeItemHelper().
QHash<QGraphicsObject *, QSet<QGesture *> > QGraphicsScenePrivate::cachedItemGestures |
Definition at line 286 of file qgraphicsscene_p.h.
Referenced by gestureEventHandler(), and removeItemHelper().
QList<QGraphicsItem *> QGraphicsScenePrivate::cachedItemsUnderMouse |
Definition at line 162 of file qgraphicsscene_p.h.
Referenced by dispatchHoverEvent(), mousePressEventHandler(), removeItemHelper(), sendTouchBeginEvent(), and touchEventHandler().
QList<QGraphicsObject *> QGraphicsScenePrivate::cachedTargetItems |
Definition at line 284 of file qgraphicsscene_p.h.
Referenced by gestureEventHandler(), and removeItemHelper().
quint32 QGraphicsScenePrivate::calledEmitUpdated |
Definition at line 70 of file qgraphicsscene_p.h.
Referenced by _q_emitUpdated(), and _q_processDirtyItems().
int QGraphicsScenePrivate::changedSignalIndex |
Definition at line 56 of file qgraphicsscene_p.h.
Referenced by _q_emitUpdated(), init(), markDirty(), and processDirtyItemsRecursive().
int QGraphicsScenePrivate::childExplicitActivation |
Definition at line 139 of file qgraphicsscene_p.h.
quint32 QGraphicsScenePrivate::dirtyGrowingItemsBoundingRect |
Definition at line 68 of file qgraphicsscene_p.h.
Referenced by _q_emitUpdated(), and _q_processDirtyItems().
QGraphicsItem* QGraphicsScenePrivate::dragDropItem |
Definition at line 159 of file qgraphicsscene_p.h.
Referenced by removeItemHelper().
QGraphicsWidget* QGraphicsScenePrivate::enterWidget |
Definition at line 160 of file qgraphicsscene_p.h.
QGraphicsItem* QGraphicsScenePrivate::focusItem |
Definition at line 132 of file qgraphicsscene_p.h.
Referenced by addPopup(), removeItemHelper(), removePopup(), setActivePanelHelper(), and setFocusItemHelper().
quint32 QGraphicsScenePrivate::focusOnTouch |
Definition at line 84 of file qgraphicsscene_p.h.
Referenced by sendTouchBeginEvent().
QFont QGraphicsScenePrivate::font |
Definition at line 265 of file qgraphicsscene_p.h.
Referenced by resolveFont(), setFont_helper(), and updateFont().
QBrush QGraphicsScenePrivate::foregroundBrush |
Definition at line 129 of file qgraphicsscene_p.h.
QHash<QGesture *, QGraphicsObject *> QGraphicsScenePrivate::gestureTargets |
Definition at line 288 of file qgraphicsscene_p.h.
Referenced by cancelGesturesForChildren(), gestureEventHandler(), and removeItemHelper().
QHash<Qt::GestureType, int> QGraphicsScenePrivate::grabbedGestures |
Definition at line 289 of file qgraphicsscene_p.h.
Referenced by addView(), grabGesture(), and ungrabGesture().
QRectF QGraphicsScenePrivate::growingItemsBoundingRect |
Definition at line 89 of file qgraphicsscene_p.h.
Referenced by _q_emitUpdated(), _q_processDirtyItems(), and processDirtyItemsRecursive().
quint32 QGraphicsScenePrivate::hasFocus |
Definition at line 77 of file qgraphicsscene_p.h.
quint32 QGraphicsScenePrivate::hasSceneRect |
Definition at line 67 of file qgraphicsscene_p.h.
Referenced by _q_emitUpdated(), _q_processDirtyItems(), and processDirtyItemsRecursive().
quint32 QGraphicsScenePrivate::holesInTopLevelSiblingIndex |
Definition at line 73 of file qgraphicsscene_p.h.
Referenced by ensureSequentialTopLevelSiblingIndexes(), and unregisterTopLevelItem().
QList<QGraphicsItem *> QGraphicsScenePrivate::hoverItems |
Definition at line 163 of file qgraphicsscene_p.h.
Referenced by dispatchHoverEvent(), enterModal(), leaveScene(), and removeItemHelper().
QGraphicsSceneIndex* QGraphicsScenePrivate::index |
Definition at line 61 of file qgraphicsscene_p.h.
Referenced by dispatchHoverEvent(), and removePopup().
QGraphicsScene::ItemIndexMethod QGraphicsScenePrivate::indexMethod |
Definition at line 60 of file qgraphicsscene_p.h.
Referenced by drawItems().
QMap<int, QGraphicsItem *> QGraphicsScenePrivate::itemForTouchPointId |
Definition at line 277 of file qgraphicsscene_p.h.
Referenced by removeItemHelper(), sendTouchBeginEvent(), and touchEventHandler().
QList<QGraphicsItem *> QGraphicsScenePrivate::keyboardGrabberItems |
Definition at line 154 of file qgraphicsscene_p.h.
Referenced by clearKeyboardGrabber(), grabKeyboard(), removeItemHelper(), removePopup(), and ungrabKeyboard().
QGraphicsItem* QGraphicsScenePrivate::lastActivePanel |
Definition at line 137 of file qgraphicsscene_p.h.
Referenced by removeItemHelper(), and setActivePanelHelper().
Qt::DropAction QGraphicsScenePrivate::lastDropAction |
Definition at line 161 of file qgraphicsscene_p.h.
QGraphicsItem* QGraphicsScenePrivate::lastFocusItem |
Definition at line 133 of file qgraphicsscene_p.h.
Referenced by removeItemHelper(), and setFocusItemHelper().
int QGraphicsScenePrivate::lastItemCount |
Definition at line 63 of file qgraphicsscene_p.h.
QGraphicsItem* QGraphicsScenePrivate::lastMouseGrabberItem |
Definition at line 148 of file qgraphicsscene_p.h.
Referenced by clearMouseGrabber(), mousePressEventHandler(), and removeItemHelper().
quint32 QGraphicsScenePrivate::lastMouseGrabberItemHasImplicitMouseGrab |
Definition at line 78 of file qgraphicsscene_p.h.
Referenced by enterModal(), grabMouse(), sendMouseEvent(), and ungrabMouse().
QPointF QGraphicsScenePrivate::lastSceneMousePos |
Definition at line 164 of file qgraphicsscene_p.h.
Referenced by enterModal(), and leaveModal().
qreal QGraphicsScenePrivate::minimumRenderSize |
Definition at line 87 of file qgraphicsscene_p.h.
Referenced by drawSubtreeRecursive().
QList<QGraphicsItem *> QGraphicsScenePrivate::modalPanels |
Definition at line 304 of file qgraphicsscene_p.h.
Referenced by enterModal(), leaveModal(), and mousePressEventHandler().
QMap<Qt::MouseButton, QPointF> QGraphicsScenePrivate::mouseGrabberButtonDownPos |
Definition at line 166 of file qgraphicsscene_p.h.
Referenced by sendMouseEvent(), and storeMouseButtonsForMouseGrabber().
QMap<Qt::MouseButton, QPointF> QGraphicsScenePrivate::mouseGrabberButtonDownScenePos |
Definition at line 167 of file qgraphicsscene_p.h.
Referenced by sendMouseEvent(), and storeMouseButtonsForMouseGrabber().
QMap<Qt::MouseButton, QPoint> QGraphicsScenePrivate::mouseGrabberButtonDownScreenPos |
Definition at line 168 of file qgraphicsscene_p.h.
Referenced by sendMouseEvent(), and storeMouseButtonsForMouseGrabber().
QList<QGraphicsItem *> QGraphicsScenePrivate::mouseGrabberItems |
Definition at line 149 of file qgraphicsscene_p.h.
Referenced by clearMouseGrabber(), enterModal(), grabMouse(), mousePressEventHandler(), removeItemHelper(), sendMouseEvent(), storeMouseButtonsForMouseGrabber(), and ungrabMouse().
QHash<QGraphicsItem *, QPointF> QGraphicsScenePrivate::movingItemsInitialPositions |
Definition at line 112 of file qgraphicsscene_p.h.
quint32 QGraphicsScenePrivate::needSortTopLevelItems |
Definition at line 72 of file qgraphicsscene_p.h.
Referenced by ensureSequentialTopLevelSiblingIndexes(), and registerTopLevelItem().
quint32 QGraphicsScenePrivate::padding |
Definition at line 85 of file qgraphicsscene_p.h.
quint32 QGraphicsScenePrivate::painterStateProtection |
Definition at line 81 of file qgraphicsscene_p.h.
Referenced by draw(), and drawItemHelper().
QPalette QGraphicsScenePrivate::palette |
Definition at line 269 of file qgraphicsscene_p.h.
Referenced by resolvePalette(), setPalette_helper(), and updatePalette().
QGraphicsItem* QGraphicsScenePrivate::passiveFocusItem |
Definition at line 134 of file qgraphicsscene_p.h.
Referenced by removeItemHelper().
int QGraphicsScenePrivate::polishItemsIndex |
Definition at line 58 of file qgraphicsscene_p.h.
Referenced by init().
QList<QGraphicsWidget *> QGraphicsScenePrivate::popupWidgets |
Definition at line 144 of file qgraphicsscene_p.h.
Referenced by addPopup(), removePopup(), and ungrabMouse().
quint32 QGraphicsScenePrivate::processDirtyItemsEmitted |
Definition at line 71 of file qgraphicsscene_p.h.
Referenced by _q_processDirtyItems(), and markDirty().
int QGraphicsScenePrivate::processDirtyItemsIndex |
Definition at line 57 of file qgraphicsscene_p.h.
Referenced by init(), and markDirty().
quint32 QGraphicsScenePrivate::rectAdjust |
Definition at line 131 of file qgraphicsscene_p.h.
Referenced by drawSubtreeRecursive().
QMap<int, QEventPoint> QGraphicsScenePrivate::sceneCurrentTouchPoints |
Definition at line 276 of file qgraphicsscene_p.h.
Referenced by findClosestTouchPointId(), removeItemHelper(), and touchEventHandler().
QMultiMap<QGraphicsItem *, QGraphicsItem *> QGraphicsScenePrivate::sceneEventFilters |
Definition at line 178 of file qgraphicsscene_p.h.
Referenced by filterEvent(), installSceneEventFilter(), removeItemHelper(), and removeSceneEventFilter().
quint32 QGraphicsScenePrivate::scenePosDescendantsUpdatePending |
Definition at line 75 of file qgraphicsscene_p.h.
Referenced by _q_updateScenePosDescendants(), and setScenePosItemEnabled().
QSet<QGraphicsItem *> QGraphicsScenePrivate::scenePosItems |
Definition at line 120 of file qgraphicsscene_p.h.
Referenced by _q_updateScenePosDescendants(), registerScenePosItem(), and unregisterScenePosItem().
QRectF QGraphicsScenePrivate::sceneRect |
Definition at line 65 of file qgraphicsscene_p.h.
QSet<QGraphicsItem *> QGraphicsScenePrivate::selectedItems |
Definition at line 108 of file qgraphicsscene_p.h.
Referenced by removeItemHelper().
QPainterPath QGraphicsScenePrivate::selectionArea |
Definition at line 106 of file qgraphicsscene_p.h.
int QGraphicsScenePrivate::selectionChanging |
Definition at line 107 of file qgraphicsscene_p.h.
Referenced by removeItemHelper().
quint32 QGraphicsScenePrivate::sortCacheEnabled |
Definition at line 82 of file qgraphicsscene_p.h.
quint32 QGraphicsScenePrivate::stickyFocus |
Definition at line 76 of file qgraphicsscene_p.h.
Referenced by mousePressEventHandler(), and sendTouchBeginEvent().
QStyle* QGraphicsScenePrivate::style |
Definition at line 264 of file qgraphicsscene_p.h.
QStyleOptionGraphicsItem QGraphicsScenePrivate::styleOptionTmp |
Definition at line 274 of file qgraphicsscene_p.h.
Referenced by draw(), drawItemHelper(), and drawSubtreeRecursive().
QGraphicsWidget* QGraphicsScenePrivate::tabFocusFirst |
Definition at line 135 of file qgraphicsscene_p.h.
Referenced by QGraphicsWidget::~QGraphicsWidget(), and removeItemHelper().
QList<QGraphicsItem *> QGraphicsScenePrivate::topLevelItems |
Definition at line 110 of file qgraphicsscene_p.h.
Referenced by _q_processDirtyItems(), ensureSequentialTopLevelSiblingIndexes(), registerTopLevelItem(), and unregisterTopLevelItem().
quint32 QGraphicsScenePrivate::topLevelSequentialOrdering |
Definition at line 74 of file qgraphicsscene_p.h.
Referenced by ensureSequentialTopLevelSiblingIndexes(), and unregisterTopLevelItem().
QList<QGraphicsItem *> QGraphicsScenePrivate::unpolishedItems |
Definition at line 109 of file qgraphicsscene_p.h.
Referenced by _q_polishItems(), drawItems(), and removeItemHelper().
quint32 QGraphicsScenePrivate::updateAll |
Definition at line 69 of file qgraphicsscene_p.h.
Referenced by _q_emitUpdated(), _q_processDirtyItems(), drawItems(), markDirty(), and processDirtyItemsRecursive().
std::set<QRectF, UpdatedRectsCmp> QGraphicsScenePrivate::updatedRects |
Definition at line 104 of file qgraphicsscene_p.h.
Referenced by _q_emitUpdated().
QList<QGraphicsView *> QGraphicsScenePrivate::views |
Definition at line 174 of file qgraphicsscene_p.h.
Referenced by _q_emitUpdated(), _q_processDirtyItems(), addView(), enableMouseTrackingOnViews(), enableTouchEventsOnViews(), grabGesture(), markDirty(), processDirtyItemsRecursive(), removeView(), ungrabGesture(), and updateInputMethodSensitivityInViews().