Changeset View
Changeset View
Standalone View
Standalone View
lookandfeel/contents/windowswitcher/WindowSwitcher.qml
Show First 20 Lines • Show All 65 Lines • ▼ Show 20 Line(s) | 64 | onCurrentIndexChanged: { | |||
---|---|---|---|---|---|
66 | thumbnailListView.positionViewAtIndex(thumbnailListView.currentIndex, ListView.Contain) | 66 | thumbnailListView.positionViewAtIndex(thumbnailListView.currentIndex, ListView.Contain) | ||
67 | } | 67 | } | ||
68 | } | 68 | } | ||
69 | 69 | | |||
70 | delegate: MouseArea { | 70 | delegate: MouseArea { | ||
71 | width: thumbnailListView.width | 71 | width: thumbnailListView.width | ||
72 | height: delegateColumn.implicitHeight + 2 * delegateColumn.y | 72 | height: delegateColumn.implicitHeight + 2 * delegateColumn.y | ||
73 | 73 | | |||
74 | onClicked: thumbnailListView.currentIndex = index | 74 | onClicked: { | ||
75 | if (tabBox.noModifierGrab) { | ||||
76 | tabBox.model.activate(index); | ||||
77 | } else { | ||||
78 | thumbnailListView.currentIndex = index; | ||||
79 | } | ||||
80 | } | ||||
75 | 81 | | |||
76 | ColumnLayout { | 82 | ColumnLayout { | ||
77 | id: delegateColumn | 83 | id: delegateColumn | ||
78 | anchors.horizontalCenter: parent.horizontalCenter | 84 | anchors.horizontalCenter: parent.horizontalCenter | ||
79 | // anchors.centerIn causes layouting glitches | 85 | // anchors.centerIn causes layouting glitches | ||
80 | y: units.smallSpacing | 86 | y: units.smallSpacing | ||
81 | width: parent.width - 2 * units.smallSpacing | 87 | width: parent.width - 2 * units.smallSpacing | ||
82 | spacing: units.smallSpacing | 88 | spacing: units.smallSpacing | ||
▲ Show 20 Lines • Show All 42 Lines • Show Last 20 Lines |