summaryrefslogtreecommitdiff
path: root/gui/main.qml
diff options
context:
space:
mode:
authorkali <kali@win>2021-12-14 18:18:16 +0100
committerkali kaneko (leap communications) <kali@leap.se>2021-12-14 18:21:32 +0100
commit5d9788388c9cf176a331d1fddc708420d88c4ce5 (patch)
treec85e59d6e63c72201d63067a82a7e6ef07603046 /gui/main.qml
parenta36b1312503d0f5d3e27bd4e296c0c9adb5e492b (diff)
[pkg] bugfixes windows
Diffstat (limited to 'gui/main.qml')
-rw-r--r--gui/main.qml13
1 files changed, 9 insertions, 4 deletions
diff --git a/gui/main.qml b/gui/main.qml
index 56220f5..f6660df 100644
--- a/gui/main.qml
+++ b/gui/main.qml
@@ -156,17 +156,22 @@ ApplicationWindow {
}
function loadTheme() {
- let arr = flavor.split("/")
+ var arr
+ if (Qt.platform.os == "windows") {
+ arr = flavor.split("\\")
+ } else {
+ arr = flavor.split("/")
+ }
var providerFlavor = arr[arr.length-1]
console.debug("flavor: " + providerFlavor)
- if (providerFlavor == "riseup-vpn") {
+ if (providerFlavor.startsWith("riseup-vpn")) {
return "themes/Riseup.qml"
- } else if (providerFlavor== "calyx-vpn") {
+ } else if (providerFlavor.startsWith("calyx-vpn")) {
return "themes/Calyx.qml"
} else {
// we should do a Default theme, with a fallback
// mechanism
- return "Riseup.qml"
+ return "themes/Riseup.qml"
}
}