forked from Shinonome/dots-hyprland
translations: update qsTrs to Translation.tr and allow translation of notifications
This commit is contained in:
@@ -99,7 +99,11 @@ ColumnLayout {
|
||||
Quickshell.execDetached(["bash", "-c",
|
||||
`echo '${StringUtils.shellSingleQuoteEscape(segmentContent)}' > '${downloadPath}/code.${segmentLang || "txt"}'`
|
||||
])
|
||||
Quickshell.execDetached(["bash", "-c", `notify-send 'Code saved to file' '${downloadPath}/code.${segmentLang || "txt"}' -a Shell`])
|
||||
Quickshell.execDetached(["notify-send",
|
||||
Translation.tr("Code saved to file"),
|
||||
Translation.tr("Saved to %1").arg(`${downloadPath}/code.${segmentLang || "txt"}`),
|
||||
"-a", "Shell"
|
||||
])
|
||||
saveCodeButton.activated = true
|
||||
saveIconTimer.restart()
|
||||
}
|
||||
|
||||
@@ -181,7 +181,7 @@ Button {
|
||||
onClicked: {
|
||||
root.showActions = false
|
||||
Quickshell.execDetached(["bash", "-c",
|
||||
`curl '${root.imageData.file_url}' -o '${root.imageData.is_nsfw ? root.nsfwPath : root.downloadPath}/${root.fileName}' && notify-send '${qsTr("Download complete")}' '${root.downloadPath}/${root.fileName}' -a 'Shell'`
|
||||
`curl '${root.imageData.file_url}' -o '${root.imageData.is_nsfw ? root.nsfwPath : root.downloadPath}/${root.fileName}' && notify-send '${Translation.tr("Download complete")}' '${root.downloadPath}/${root.fileName}' -a 'Shell'`
|
||||
])
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user