From 1d806cee36e22e79fdc464837a5a85402aeeee91 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Dr=2E=20J=C3=B6rg=20Wurzer?= Date: Sat, 21 Dec 2024 22:41:20 +0100 Subject: [PATCH] Fixes for icon and name mapping --- AppGrid.qml | 122 +----------------------------------- AppGroup.qml | 2 +- Settings.qml | 6 ++ Springboard.qml | 6 +- android/AndroidManifest.xml | 2 +- main.qml | 38 ++++++++++- 6 files changed, 46 insertions(+), 130 deletions(-) diff --git a/AppGrid.qml b/AppGrid.qml index 41d53e9..ce8e9d1 100644 --- a/AppGrid.qml +++ b/AppGrid.qml @@ -14,126 +14,6 @@ LauncherPage { property string textInput property real labelPointSize: 16 - property var iconMap: { - "com.simplemobiletools.dialer": "/icons/dial-phone@4x.png", - "com.simplemobiletools.smsmessenger": "/icons/message@4x.png", - "com.simplemobiletools.gallery.pro": "/icons/photo-gallery@4x.png", - "com.simplemobiletools.contacts.pro": "/icons/people-contacts-agenda@4x.png", - "com.simplemobiletools.clock": "/icons/clock@4x.png", - "com.simplemobiletools.calendar.pro": "/icons/calendar@4x.png", - "com.simplemobiletools.filemanager.pro": "/icons/folder@4x.png", - "com.simplemobiletools.notes.pro": "/icons/notes@4x.png", - "com.simplemobiletools.calculator": "/icons/calculator@4x_104x104px.png", - "org.fossify.phone": "/icons/dial-phone@4x.png", - "org.fossify.smsmessenger": "/icons/message@4x.png", - "org.fossify.gallery": "/icons/photo-gallery@4x.png", - "org.fossify.contacts": "/icons/people-contacts-agenda@4x.png", - "org.fossify.clock": "/icons/clock@4x.png", - "org.fossify.calendar": "/icons/calendar@4x.png", - "org.fossify.filemanager": "/icons/folder@4x.png", - "org.fossify.notes": "/icons/notes@4x.png", - "org.fossify.calculator": "/icons/calculator@4x_104x104px.png", - "org.fossify.musicplayer": "/icons/music@4x.png", - "com.volla.messages": "/icons/volla-messages@4x.png", - "com.contactoffice.mailfence": "/icons/email@4x.png", - "com.emclient.mailclient": "/icons/email@4x.png", - "net.thunderbird.android": "/icons/email@4x.png", - "be.engie.smart": "/icons/engie@4x.png", - "be.bmid.itsme": "/icons/itsme@4x.png", - "com.facebook.lite": "/icons/facebook-lite@4x.png", - "nl.apcreation.woolsocks": "/icons/woolsocks@4x.png", - "com.zhiliaoapp.musically": "/icons/tiktok@4x.png", - "com.proximus.proximusplus": "/icons/my-proximus@4x.png", - "mobi.inthepocket.bcmc.bancontact": "/icons/payconiq@4x.png", - "com.symantec.mobilesecurity": "/icons/norton-360@4x.png", - "be.nexuzhealth.mobile.mynexuz": "/icons/my-nexuzhealth@4x.png", - "com.bookmark.money": "/icons/money-lover@4x.png", - "be.bpost.mybpost": "/icons/bpost@4x.png", - "be.ixor.doccle.android": "/icons/doccle@4x.png", - "com.themobilecompany.delijn": "/icons/de-lijn@4x.png", - "com.x8bit.bitwarden": "/icons/bitwarden@4x.png", - "com.beeper.android": "/icons/beeper@4x.png", - "be.argenta.bankieren": "/icons/argenta@4x.png", - "com.android.dialer": "/icons/dial-phone@4x.png", - "com.android.mms" : "/icons/message@4x.png", - "com.android.messaging": "/icons/message@4x.png", - "com.google.android.apps.messaging" : "/icons/message@4x.png", - "net.osmand.plus": "/icons/route-directions-map@4x.png", - "com.mediatek.camera": "/icons/camera@4x.png", - "com.android.camera2": "/icons/camera@4x.png", - "com.android.gallery3d": "/icons/photo-gallery@4x.png", - "com.android.deskclock": "/icons/clock@4x.png", - "com.android.settings": "/icons/settings@4x.png", - "com.android.documentsui": "/icons/folder@4x.png", - "org.telegram.messenger": "/icons/telegram@4x.png", - "com.android.email": "/icons/email@4x.png", - "com.fsck.k9": "/icons/email@4x.png", - "com.google.android.gm": "/icons/email@4x.png", - "com.Slack": "/icons/slack@4x.png", - "org.mozilla.fennec_fdroid": "/icons/browser@4x.png", - "com.maxfour.music": "/icons/music@4x.png", - "com.instagram.android": "/icons/instagram@4x.png", - "com.github.yeriomin.yalpstore": "/icons/yalp-store@4x.png", - "com.aurora.store": "/icons/aurora-store-line@4x.png", - "com.amazon.mShop.android.shopping": "/icons/amazon@4x.png", - "de.hafas.android.db": "/icons/db-navigator@4x.png", - "com.dropbox.android": "/icons/dropbox@4x.png", - "org.fdroid.fdroid": "/icons/f-droid@4x.png", - "com.facebook.katana": "/icons/facebook@4x.png", - "de.gmx.mobile.android.mail": "/icons/gmx@4x.png", - "hideme.android.vpn.noPlayStore": "/icons/hide-me@4x.png", - "com.linkedin.android": "/icons/linkedin@4x.png", - "com.nextcloud.client": "/icons/nextcloud@4x.png", - "com.paypal.android.p2pmobile": "/icons/paypal@4x.png", - "com.skype.raider": "/icons/skype@4x.png", - "com.spotify.music": "/icons/spotify@4x.png", - "de.tutao.tutanota": "/icons/tutanota@4x.png", - "com.volla.launcher": "/icons/volla-settings@4x.png", - "de.web.mobile.android.mail": "/icons/web-de@4x.png", - "com.wetter.androidclient": "/icons/wetter-com@4x.png", - "com.whatsapp": "/icons/whats-app@4x.png", - "com.android.fmradio": "/icons/radio@4x_104x104px.png", - "at.bitfire.davdroid": "/icons/sync@4x_104x104px.png", - "org.thoughtcrime.securesms": "/icons/signal@4x_104x104px.png", - "de.baumann.weather": "/icons/weather@4x_104x104px.png", - "com.android.calculator2": "/icons/calculator@4x_104x104px.png", - "eu.siacs.conversations": "/icons/xmpp@4x_104x104px.png", - "one.socializer.android": "/icons/socializer@4x.png", - "im.status.ethereum": "/icons/status.im@4x.png", - "org.liberty.android.freeotpplus": "/icons/freeOTP@4x.png", - "com.kickstarter.kickstarter": "/icons/kickstarter@4x.png", - "com.ebay.kleinanzeigen": "/icons/ebay@4x.png", - "com.secuso.privacyFriendlyCodeScanner": "/icons/qr-scanner@4x.png", - "com.twitter.android": "/icons/twitter@4x.png", - "com.commerzbank.photoTAN": "/icons/photoTAN@4x.png" - } - property var labelMap: { - "com.simplemobiletools.filemanager.pro": qsTr("Files"), - "com.simplemobiletools.smsmessenger": qsTr("Messages"), - "org.fossify.filemanager": qsTr("Files"), - "org.fossify.smsmessenger": qsTr("Messages"), - "org.fossify.musicplayer": qsTr("Music"), - "mobi.inthepocket.bcmc.bancontact": qsTr("Bancontact"), - "be.sncbnmbs.b2cmobapp": qsTr("De Trein"), - "be.nexuzhealth.mobile.mynexuz": qsTr("Mynexuzhealth"), - "com.codesynd.cashfree": qsTr("Bonsai"), - "be.introlution.myonlinecalendar": qsTr("MijnOnlineAgenda"), - "com.facebook.lite": qsTr("Facebook"), - "org.mozilla.fennec_fdroid": qsTr("Browser"), - "com.google.android.gm" : qsTr("Mail"), - "eu.faircode.email" : qsTr("Mail"), - "com.emclient.mailclient" : qsTr("Mail"), - "net.thunderbird.android" : qsTr("Mail"), - "com.fsck.k9": qsTr("Mail"), - "at.bitfire.davdroid": qsTr("Sync"), - "hideme.android.vpn.noPlayStore": qsTr("VPN"), - "com.aurora.store": qsTr("Store"), - "com.aurora.adroid": qsTr("A-Droid"), - "net.osmand.plus": qsTr("Maps"), - "com.volla.launcher": qsTr("Settings"), - "com.android.fmradio" : qsTr("Radio"), - "de.baumann.weather": qsTr("Weather") - } property var appGroups: [] // QML elements with app grids property var pinnedShortcuts: [] @@ -253,7 +133,7 @@ LauncherPage { "selectedGroupIndex": appLauncher.selectedGroup, "textInput": appLauncher.textInput, "iconMap": mainView.iconMap, - "labelMap": appLauncher.labelMap, + "labelMap": mainView.labelMap, "phoneApp": mainView.phoneApp, "messageApp": mainView.messageApp, "labelPointSize": appLauncher.labelPointSize, diff --git a/AppGroup.qml b/AppGroup.qml index be95405..ff1d111 100644 --- a/AppGroup.qml +++ b/AppGroup.qml @@ -186,7 +186,7 @@ Item { id: gridButton anchors.top: parent.top anchors.centerIn: gridCell - topPadding: groupItem.innerSpacing / 2 + topPadding: (gridCircle.height - buttonIcon.height) / 2 //groupItem.innerSpacing / 2 width: parent.width text: model.label contentItem: Column { diff --git a/Settings.qml b/Settings.qml index 9347f58..a655b42 100644 --- a/Settings.qml +++ b/Settings.qml @@ -918,10 +918,16 @@ LauncherPage { function setData(data) { console.log("Settings | Menu size is " + data.length) clear() + data.forEach(function(app, i) { + data[i].label = app.package in mainView.labelMap && app.shortcutId === undefined + ? qsTr(mainView.labelMap[app.package]) : app.label + data[i].itemId = app.shortcutId !== undefined ? app.shortcutId : app.package + }) for (var i = 0; i < data.length; i++) { append(data[i]) } } + } } diff --git a/Springboard.qml b/Springboard.qml index c469aea..8d80ba4 100644 --- a/Springboard.qml +++ b/Springboard.qml @@ -927,8 +927,6 @@ LauncherPage { font.pointSize: mainView.smallFontSize opacity: 0.6 } - - } onClicked: { @@ -1129,8 +1127,8 @@ LauncherPage { Timer { id: weather30MinuteTimer interval: 1800000 // 30 minutes in milliseconds (30 * 60 * 1000) - repeat: true // Set to true to repeat every 30 minutes - running: true // Start the timer immediately + repeat: widgetsFlow.visible // Set to true to repeat every 30 minutes + running: widgetsFlow.visible // Start the timer immediately onTriggered: { weatherWidget.getWeather(); // Call the function to execute service } diff --git a/android/AndroidManifest.xml b/android/AndroidManifest.xml index 5ae3e11..f95fa5d 100644 --- a/android/AndroidManifest.xml +++ b/android/AndroidManifest.xml @@ -1,5 +1,5 @@ - +