fix RTL appearance for ComboBox

Summary:
-- when the combobox isnt inside the main Item
but rather a sub-Item it doesnt inherit the
LayoutMirroring properties. This is a workaround
to handle that behavior.
QTBUG: https://bugreports.qt.io/browse/QTBUG-66446

Test Plan:
checkout that LayoutMirroring works properly in
such case

Reviewers: #plasma, mart, safaalfulaij

Reviewed By: safaalfulaij

Subscribers: safaalfulaij, plasma-devel, #frameworks

Tags: #plasma, #frameworks

Differential Revision: https://phabricator.kde.org/D10592
This commit is contained in:
Michail Vourlakos 2018-02-17 00:11:47 +02:00
parent 6cbea20bf9
commit 1ff405cca5

View File

@ -110,7 +110,11 @@ T.ComboBox {
currentIndex: control.highlightedIndex
highlightRangeMode: ListView.ApplyRange
highlightMoveDuration: 0
LayoutMirroring.enabled: true
// HACK: When the ComboBox is not inside a top-level Window, it's Popup does not inherit
// the LayoutMirroring options. This is a workaround to fix this by enforcing
// the LayoutMirroring options properly.
// QTBUG: https://bugreports.qt.io/browse/QTBUG-66446
LayoutMirroring.enabled: Qt.application.layoutDirection === Qt.RightToLeft
LayoutMirroring.childrenInherit: true
T.ScrollBar.vertical: Controls.ScrollBar { }
}