Change indicator arrow direction in Fusion style
[ChangeLog][Important Behavior Changes] Arrow indicator now consistent with platform styles Task-number: QTBUG-34611 Change-Id: If55e00a37a22288b2179e03fba299aeebad0ebcf Reviewed-by: J-P Nurmi <jpnurmi@theqtcompany.com>bb10
parent
61f2e9a9a7
commit
9f779088f4
|
|
@ -554,11 +554,19 @@ void QFusionStyle::drawPrimitive(PrimitiveElement elem,
|
|||
QColor arrowColor = header->palette.foreground().color();
|
||||
QPoint offset = QPoint(0, -1);
|
||||
|
||||
#if defined(Q_OS_LINUX)
|
||||
if (header->sortIndicator & QStyleOptionHeader::SortUp) {
|
||||
arrow = colorizedImage(QLatin1String(":/qt-project.org/styles/commonstyle/images/fusion_arrow.png"), arrowColor);
|
||||
} else if (header->sortIndicator & QStyleOptionHeader::SortDown) {
|
||||
arrow = colorizedImage(QLatin1String(":/qt-project.org/styles/commonstyle/images/fusion_arrow.png"), arrowColor, 180);
|
||||
}
|
||||
#else
|
||||
if (header->sortIndicator & QStyleOptionHeader::SortUp) {
|
||||
arrow = colorizedImage(QLatin1String(":/qt-project.org/styles/commonstyle/images/fusion_arrow.png"), arrowColor, 180);
|
||||
} else if (header->sortIndicator & QStyleOptionHeader::SortDown) {
|
||||
arrow = colorizedImage(QLatin1String(":/qt-project.org/styles/commonstyle/images/fusion_arrow.png"), arrowColor);
|
||||
}
|
||||
#endif
|
||||
|
||||
if (!arrow.isNull()) {
|
||||
r.setSize(QSize(arrow.width()/2, arrow.height()/2));
|
||||
|
|
|
|||
Loading…
Reference in New Issue