Changeset View
Changeset View
Standalone View
Standalone View
lookandfeel/contents/windowswitcher/WindowSwitcher.qml
Show All 39 Lines | 36 | PlasmaCore.Dialog { | |||
---|---|---|---|---|---|
40 | flags: Qt.X11BypassWindowManagerHint | 40 | flags: Qt.X11BypassWindowManagerHint | ||
41 | x: screenGeometry.x + (Qt.application.layoutDirection === Qt.RightToLeft ? screenGeometry.width - width : 0) | 41 | x: screenGeometry.x + (Qt.application.layoutDirection === Qt.RightToLeft ? screenGeometry.width - width : 0) | ||
42 | y: screenGeometry.y | 42 | y: screenGeometry.y | ||
43 | 43 | | |||
44 | mainItem: PlasmaExtras.ScrollArea { | 44 | mainItem: PlasmaExtras.ScrollArea { | ||
45 | id: dialogMainItem | 45 | id: dialogMainItem | ||
46 | 46 | | |||
47 | focus: true | 47 | focus: true | ||
48 | Component.onCompleted: forceActiveFocus() | ||||
broulik: Doesn't the `focus: true` imply that already? | |||||
It would if the window did end up having the focus in some form. As far as I can tell it doesn't ever get the focus (since kwin decided that it shouldn't). Doing this makes qt quick focus handling work while leaving the real window focus alone. gladhorn: It would if the window did end up having the focus in some form. As far as I can tell it… | |||||
Solutions like this always carry the risk of regression. What if in a future Qt release the window focus gets checked before focus gets force activated? romangg: Solutions like this always carry the risk of regression. What if in a future Qt release the… | |||||
48 | 49 | | |||
49 | width: tabBox.screenGeometry.width * 0.15 + (__verticalScrollBar.visible ? __verticalScrollBar.width : 0) | 50 | width: tabBox.screenGeometry.width * 0.15 + (__verticalScrollBar.visible ? __verticalScrollBar.width : 0) | ||
50 | height: tabBox.screenGeometry.height - dialog.margins.top - dialog.margins.bottom | 51 | height: tabBox.screenGeometry.height - dialog.margins.top - dialog.margins.bottom | ||
51 | 52 | | |||
52 | LayoutMirroring.enabled: Qt.application.layoutDirection === Qt.RightToLeft | 53 | LayoutMirroring.enabled: Qt.application.layoutDirection === Qt.RightToLeft | ||
53 | LayoutMirroring.childrenInherit: true | 54 | LayoutMirroring.childrenInherit: true | ||
54 | 55 | | |||
55 | ListView { | 56 | ListView { | ||
▲ Show 20 Lines • Show All 56 Lines • ▼ Show 20 Line(s) | 112 | PlasmaExtras.Heading { | |||
112 | Layout.fillWidth: true | 113 | Layout.fillWidth: true | ||
113 | height: undefined | 114 | height: undefined | ||
114 | level: 4 | 115 | level: 4 | ||
115 | text: model.caption | 116 | text: model.caption | ||
116 | elide: Text.ElideRight | 117 | elide: Text.ElideRight | ||
117 | wrapMode: Text.WrapAtWordBoundaryOrAnywhere | 118 | wrapMode: Text.WrapAtWordBoundaryOrAnywhere | ||
118 | maximumLineCount: 2 | 119 | maximumLineCount: 2 | ||
119 | lineHeight: 0.95 | 120 | lineHeight: 0.95 | ||
121 | focus: index == thumbnailListView.currentIndex | ||||
120 | } | 122 | } | ||
121 | } | 123 | } | ||
122 | } | 124 | } | ||
123 | } | 125 | } | ||
124 | 126 | | |||
125 | highlight: PlasmaComponents.Highlight {} | 127 | highlight: PlasmaComponents.Highlight {} | ||
126 | } | 128 | } | ||
127 | } | 129 | } | ||
128 | } | 130 | } | ||
129 | } | 131 | } | ||
130 | 132 | |
Doesn't the focus: true imply that already?