move translations into quickshell folder

This commit is contained in:
end-4
2025-10-14 12:02:33 +02:00
parent 8dc31cc790
commit 57a5c0f743
15 changed files with 3 additions and 2 deletions
@@ -14,6 +14,7 @@ Singleton {
property bool isScanning: scanLanguagesProcess.running property bool isScanning: scanLanguagesProcess.running
property bool isLoading: false property bool isLoading: false
property string translationKeepSuffix: "/*keep*/" property string translationKeepSuffix: "/*keep*/"
property string translationsPath: Quickshell.shellPath("translations")
property string languageCode: { property string languageCode: {
var configLang = Config?.options.language.ui ?? "auto"; var configLang = Config?.options.language.ui ?? "auto";
@@ -26,7 +27,7 @@ Singleton {
Process { Process {
id: scanLanguagesProcess id: scanLanguagesProcess
command: ["find", FileUtils.trimFileProtocol(Qt.resolvedUrl(Directories.config + "/quickshell/translations/").toString()), "-name", "*.json", "-exec", "basename", "{}", ".json", ";"] command: ["find", root.translationsPath, "-name", "*.json", "-exec", "basename", "{}", ".json", ";"]
running: true running: true
stdout: SplitParser { stdout: SplitParser {
@@ -60,7 +61,7 @@ Singleton {
FileView { FileView {
id: translationFileView id: translationFileView
path: root.languageCode?.length > 0 ? Qt.resolvedUrl(Directories.config + "/quickshell/translations/" + root.languageCode + ".json") : "" path: root.languageCode?.length > 0 ? Qt.resolvedUrl(`${root.translationsPath}/${root.languageCode}.json`) : ""
onLoaded: { onLoaded: {
var textContent = ""; var textContent = "";