Changeset View
Changeset View
Standalone View
Standalone View
src/declarativeimports/plasmacomponents3/ComboBox.qml
Show First 20 Lines • Show All 104 Lines • ▼ Show 20 Line(s) | 97 | popup: T.Popup { | |||
---|---|---|---|---|---|
105 | contentItem: ListView { | 105 | contentItem: ListView { | ||
106 | id: listview | 106 | id: listview | ||
107 | clip: true | 107 | clip: true | ||
108 | implicitHeight: contentHeight | 108 | implicitHeight: contentHeight | ||
109 | model: control.popup.visible ? control.delegateModel : null | 109 | model: control.popup.visible ? control.delegateModel : null | ||
110 | currentIndex: control.highlightedIndex | 110 | currentIndex: control.highlightedIndex | ||
111 | highlightRangeMode: ListView.ApplyRange | 111 | highlightRangeMode: ListView.ApplyRange | ||
112 | highlightMoveDuration: 0 | 112 | highlightMoveDuration: 0 | ||
113 | LayoutMirroring.enabled: true | 113 | // HACK: When the ComboBox is not inside a top-level Window, it's Popup does not inherit | ||
114 | // the LayoutMirroring options. This is a workaround to fix this by enforcing | ||||
115 | // the LayoutMirroring options properly. | ||||
116 | // QTBUG: https://bugreports.qt.io/browse/QTBUG-66446 | ||||
117 | LayoutMirroring.enabled: Qt.application.layoutDirection === Qt.RightToLeft | ||||
safaalfulaij: When the ComboBox is not inside a top-level Window, it's Popup does not inherit | |||||
114 | LayoutMirroring.childrenInherit: true | 118 | LayoutMirroring.childrenInherit: true | ||
115 | T.ScrollBar.vertical: Controls.ScrollBar { } | 119 | T.ScrollBar.vertical: Controls.ScrollBar { } | ||
116 | } | 120 | } | ||
117 | background: Rectangle { | 121 | background: Rectangle { | ||
118 | anchors { | 122 | anchors { | ||
119 | fill: parent | 123 | fill: parent | ||
120 | margins: -1 | 124 | margins: -1 | ||
121 | } | 125 | } | ||
Show All 16 Lines |
When the ComboBox is not inside a top-level Window, it's Popup does not inherit