summaryrefslogtreecommitdiffstats
path: root/src/gui/styles/qstyle_p.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/gui/styles/qstyle_p.h')
-rw-r--r--src/gui/styles/qstyle_p.h17
1 files changed, 11 insertions, 6 deletions
diff --git a/src/gui/styles/qstyle_p.h b/src/gui/styles/qstyle_p.h
index ccc16a7..13ff054 100644
--- a/src/gui/styles/qstyle_p.h
+++ b/src/gui/styles/qstyle_p.h
@@ -43,6 +43,8 @@
#define QSTYLE_P_H
#include "private/qobject_p.h"
+#include "private/qstylehelper_p.h"
+#include <QtGui/qstyle.h>
QT_BEGIN_NAMESPACE
@@ -51,22 +53,24 @@ QT_BEGIN_NAMESPACE
// -------------
//
// This file is not part of the Qt API. It exists for the convenience
-// of qapplication_*.cpp, qwidget*.cpp and qfiledialog.cpp. This header
-// file may change from version to version without notice, or even be removed.
+// of qstyle_*.cpp. This header file may change from version to version
+// without notice, or even be removed.
//
// We mean it.
//
// Private class
+class QStyle;
+
class QStylePrivate: public QObjectPrivate
{
Q_DECLARE_PUBLIC(QStyle)
public:
inline QStylePrivate()
- : layoutSpacingIndex(-1)
- { }
+ : layoutSpacingIndex(-1), proxyStyle(0) {}
mutable int layoutSpacingIndex;
+ QStyle *proxyStyle;
};
@@ -75,9 +79,9 @@ public:
QPixmap internalPixmapCache; \
QImage imageCache; \
QPainter *p = painter; \
- QString unique = uniqueName((a), option, option->rect.size()); \
+ QString unique = QStyleHelper::uniqueName((a), option, option->rect.size()); \
int txType = painter->deviceTransform().type() | painter->worldTransform().type(); \
- bool doPixmapCache = UsePixmapCache && txType <= QTransform::TxTranslate; \
+ bool doPixmapCache = txType <= QTransform::TxTranslate; \
if (doPixmapCache && QPixmapCache::find(unique, internalPixmapCache)) { \
painter->drawPixmap(option->rect.topLeft(), internalPixmapCache); \
} else { \
@@ -89,6 +93,7 @@ public:
}
+
#define END_STYLE_PIXMAPCACHE \
if (doPixmapCache) { \
p->end(); \