Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 20 additions & 0 deletions panels/dock/tray/package/tray.qml
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,9 @@ AppletItem {

property alias dropHover: stashContainer.dropHover
property alias stashItemDragging: stashContainer.stashItemDragging
property bool preCreating: false

opacity: preCreating ? 0 : 1

popupX: DockPanelPositioner.x
popupY: DockPanelPositioner.y
Expand Down Expand Up @@ -79,8 +82,25 @@ AppletItem {
DockPanelPositioner.bounding = Qt.binding(function () {
return Qt.rect(collapsedBtnCenterPoint.x, collapsedBtnCenterPoint.y, stashedPopup.width, stashedPopup.height)
})
// Pre-create popup to avoid first-open lag
Qt.callLater(function() {
stashedPopup.preCreating = true
stashedPopup.open()
preCreateCloseTimer.start()
})
}
}

Timer {
id: preCreateCloseTimer
interval: 200
repeat: false
onTriggered: {
stashedPopup.close()
stashedPopup.preCreating = false
}
}

Connections {
target: DDT.TraySortOrderModel
function onActionsAlwaysVisibleChanged(val) {
Expand Down
Loading