summaryrefslogtreecommitdiffstats
path: root/src/plugins/styles/mac/qmacstyle_mac_p_p.h
diff options
context:
space:
mode:
authorGabriel de Dietrich <gabriel.dedietrich@qt.io>2017-05-15 13:29:07 -0700
committerGabriel de Dietrich <gabriel.dedietrich@qt.io>2017-05-15 22:40:18 +0000
commit6f3b59bfe4d22f8c717f1727816d3f8e775996be (patch)
treefb767cf4cdd2dd56da99ce4867d46ab6c1c446e9 /src/plugins/styles/mac/qmacstyle_mac_p_p.h
parentee1868df2b6b60d59dff1a14fa2c16a9e759ef19 (diff)
QMacStyle: Use NSStepperCell for QSpinBox buttons
Includes painting and subcontrol rectangles. Change-Id: I9a4c704bdea4f20f8dca94de24063f3e14dbaf91 Reviewed-by: Jake Petroules <jake.petroules@qt.io>
Diffstat (limited to 'src/plugins/styles/mac/qmacstyle_mac_p_p.h')
-rw-r--r--src/plugins/styles/mac/qmacstyle_mac_p_p.h6
1 files changed, 5 insertions, 1 deletions
diff --git a/src/plugins/styles/mac/qmacstyle_mac_p_p.h b/src/plugins/styles/mac/qmacstyle_mac_p_p.h
index f312adac52..3aacd14e60 100644
--- a/src/plugins/styles/mac/qmacstyle_mac_p_p.h
+++ b/src/plugins/styles/mac/qmacstyle_mac_p_p.h
@@ -118,6 +118,7 @@
Q_FORWARD_DECLARE_MUTABLE_CG_TYPE(CGContext);
Q_FORWARD_DECLARE_OBJC_CLASS(NSView);
+Q_FORWARD_DECLARE_OBJC_CLASS(NSCell);
Q_FORWARD_DECLARE_OBJC_CLASS(NSButtonCell);
Q_FORWARD_DECLARE_OBJC_CLASS(QT_MANGLE_NAMESPACE(NotificationReceiver));
@@ -147,7 +148,8 @@ enum QCocoaWidgetKind {
QCocoaHorizontalScroller,
QCocoaVerticalScroller,
QCocoaHorizontalSlider,
- QCocoaVerticalSlider
+ QCocoaVerticalSlider,
+ QCocoaStepper // QSpinBox buttons
};
typedef QPair<QCocoaWidgetKind, QStyleHelper::WidgetSizePolicy> QCocoaWidget;
@@ -227,6 +229,7 @@ public:
void setAutoDefaultButton(QObject *button) const;
NSView *cocoaControl(QCocoaWidget widget) const;
+ NSCell *cocoaCell(QCocoaWidget widget) const;
void setupNSGraphicsContext(CGContextRef cg, bool flipped) const;
void restoreNSGraphicsContext(CGContextRef cg) const;
@@ -252,6 +255,7 @@ public:
NSButtonCell *indicatorBranchButtonCell;
NSView *backingStoreNSView;
QHash<QCocoaWidget, NSView *> cocoaControls;
+ QHash<QCocoaWidget, NSCell *> cocoaCells;
};
QT_END_NAMESPACE