OSDN Git Service

no more paddings
authorIvailo Monev <xakepa10@gmail.com>
Fri, 22 Jul 2016 21:44:47 +0000 (21:44 +0000)
committerIvailo Monev <xakepa10@gmail.com>
Fri, 22 Jul 2016 21:44:47 +0000 (21:44 +0000)
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
src/gui/graphicsview/qgraphicsitem_p.h
src/gui/graphicsview/qgraphicsscene.cpp
src/gui/graphicsview/qgraphicsscene.h
src/gui/graphicsview/qgraphicsscene_p.h
src/gui/graphicsview/qgraphicsview_p.h
src/gui/graphicsview/qgraphicswidget_p.h
src/gui/widgets/qcombobox_p.h

index e1146b6..c6c61af 100644 (file)
@@ -584,7 +584,6 @@ public:
     quint32 mayHaveChildWithGraphicsEffect : 1;
     quint32 isDeclarativeItem : 1;
     quint32 sendParentChangeNotification : 1;
-    quint32 padding : 21;
 
     // Optional stacking order
     int globalStackingOrder;
index 37e1729..6c68e24 100644 (file)
@@ -304,7 +304,6 @@ QGraphicsScenePrivate::QGraphicsScenePrivate()
       allItemsIgnoreHoverEvents(true),
       allItemsUseDefaultCursor(true),
       painterStateProtection(true),
-      sortCacheEnabled(false),
       allItemsIgnoreTouchEvents(true),
       selectionChanging(0),
       rectAdjust(2),
@@ -1898,27 +1897,6 @@ void QGraphicsScene::setBspTreeDepth(int depth)
 }
 
 /*!
-    \property QGraphicsScene::sortCacheEnabled
-    \brief whether sort caching is enabled
-    \since 4.5
-    \obsolete
-
-    Since Qt 4.6, this property has no effect.
-*/
-bool QGraphicsScene::isSortCacheEnabled() const
-{
-    Q_D(const QGraphicsScene);
-    return d->sortCacheEnabled;
-}
-void QGraphicsScene::setSortCacheEnabled(bool enabled)
-{
-    Q_D(QGraphicsScene);
-    if (d->sortCacheEnabled == enabled)
-        return;
-    d->sortCacheEnabled = enabled;
-}
-
-/*!
     Calculates and returns the bounding rect of all items on the scene. This
     function works by iterating over all items, and because if this, it can
     be slow for large scenes.
index 1b59d7c..52e263e 100644 (file)
@@ -107,7 +107,6 @@ class Q_GUI_EXPORT QGraphicsScene : public QObject
     Q_PROPERTY(int bspTreeDepth READ bspTreeDepth WRITE setBspTreeDepth)
     Q_PROPERTY(QPalette palette READ palette WRITE setPalette)
     Q_PROPERTY(QFont font READ font WRITE setFont)
-    Q_PROPERTY(bool sortCacheEnabled READ isSortCacheEnabled WRITE setSortCacheEnabled)
     Q_PROPERTY(bool stickyFocus READ stickyFocus WRITE setStickyFocus)
 
 public:
@@ -143,9 +142,6 @@ public:
     ItemIndexMethod itemIndexMethod() const;
     void setItemIndexMethod(ItemIndexMethod method);
 
-    bool isSortCacheEnabled() const;
-    void setSortCacheEnabled(bool enabled);
-
     int bspTreeDepth() const;
     void setBspTreeDepth(int depth);
 
index d53334b..fd552e3 100644 (file)
@@ -113,9 +113,7 @@ public:
     quint32 allItemsIgnoreHoverEvents : 1;
     quint32 allItemsUseDefaultCursor : 1;
     quint32 painterStateProtection : 1;
-    quint32 sortCacheEnabled : 1; // for compatibility
     quint32 allItemsIgnoreTouchEvents : 1;
-    quint32 padding : 15;
 
     QRectF growingItemsBoundingRect;
 
index 05080ad..c930dfa 100644 (file)
@@ -93,7 +93,6 @@ public:
     quint32 mustResizeBackgroundPixmap : 1;
     quint32 fullUpdatePending : 1;
     quint32 hasUpdateClip : 1;
-    quint32 padding : 18;
 
     QRectF sceneRect;
     void updateLastCenterPoint();
index a1750d0..7441dca 100644 (file)
@@ -77,8 +77,8 @@ public:
           layout(0),
           inheritedPaletteResolveMask(0),
           inheritedFontResolveMask(0),
-          inSetGeometry(0),
           polished(0),
+          inSetGeometry(0),
           inSetPos(0),
           autoFillBackground(0),
           refCountInvokeRelayout(0),
@@ -183,12 +183,11 @@ public:
     }
     // 32 bits
     quint32 attributes : 10;
-    quint32 inSetGeometry : 1;
     quint32 polished: 1;
+    quint32 inSetGeometry : 1;
     quint32 inSetPos : 1;
     quint32 autoFillBackground : 1;
     quint32 refCountInvokeRelayout : 16;
-    quint32 padding : 2;    // feel free to use
 
     // Focus
     Qt::FocusPolicy focusPolicy;
index cf405ec..6ccf08f 100644 (file)
@@ -390,7 +390,6 @@ public:
     uint autoCompletion : 1;
     uint duplicatesEnabled : 1;
     uint frame : 1;
-    uint padding : 26;
     int maxVisibleItems;
     int maxCount;
     int modelColumn;