use more hyprland dispatch exec instead of a process for simple stuff

This commit is contained in:
end-4
2025-04-27 23:22:27 +02:00
parent 9b0d769598
commit ab9b17a188
6 changed files with 17 additions and 48 deletions
@@ -24,11 +24,6 @@ Item {
Layout.fillWidth: true
clip: !popup
Process {
id: copyNotificationBody
command: ["bash", "-c", `wl-copy "${notificationObject.body}"`]
}
implicitHeight: ready ? notificationColumnLayout.implicitHeight + notificationListSpacing : 0
Behavior on implicitHeight {
enabled: enableAnimation
@@ -125,7 +120,7 @@ Item {
}
onPressAndHold: (mouse) => {
if (mouse.button === Qt.LeftButton) {
copyNotificationBody.running = true
Hyprland.dispatch(`exec wl-copy '${notificationObject.body}'`)
notificationSummaryText.text = `${notificationObject.summary} (copied)`
}
}
@@ -531,7 +526,7 @@ Item {
(contentItem.implicitWidth + leftPadding + rightPadding)
onClicked: {
copyNotificationBody.running = true
Hyprland.dispatch(`exec wl-copy '${notificationObject.body}'`)
copyIcon.text = "inventory"
copyIconTimer.stop()
copyIconTimer.start()