1
0
mirror of https://github.com/AvengeMedia/DankMaterialShell.git synced 2026-08-04 12:38:31 -04:00

qs: large sweep of dead code removals

This commit is contained in:
bbedward
2026-07-26 23:22:22 -04:00
parent bab2078dfd
commit c67b185076
113 changed files with 1467 additions and 3254 deletions
@@ -3,23 +3,11 @@ import qs.Common
import qs.Services
import qs.Widgets
import qs.Modules.Settings.Widgets
import "../../Common/Format.js" as Format
Item {
id: root
function formatGammaTime(isoString) {
if (!isoString)
return "";
try {
const date = new Date(isoString);
if (isNaN(date.getTime()))
return "";
return date.toLocaleTimeString(Qt.locale(), "HH:mm");
} catch (e) {
return "";
}
}
DankFlickable {
anchors.fill: parent
clip: true
@@ -195,7 +183,7 @@ Item {
}
onTabClicked: index => {
DisplayService.setNightModeAutomationMode(index === 1 ? "location" : "time");
SessionData.setNightModeAutoMode(index === 1 ? "location" : "time");
currentIndex = index;
}
@@ -562,7 +550,7 @@ Item {
}
StyledText {
text: root.formatGammaTime(DisplayService.gammaSunriseTime)
text: Format.formatIsoTime(DisplayService.gammaSunriseTime)
font.pixelSize: Theme.fontSizeLarge
font.weight: Font.Medium
color: Theme.surfaceText
@@ -598,7 +586,7 @@ Item {
}
StyledText {
text: root.formatGammaTime(DisplayService.gammaSunsetTime)
text: Format.formatIsoTime(DisplayService.gammaSunsetTime)
font.pixelSize: Theme.fontSizeLarge
font.weight: Font.Medium
color: Theme.surfaceText
@@ -645,7 +633,7 @@ Item {
}
StyledText {
text: root.formatGammaTime(DisplayService.gammaNextTransition)
text: Format.formatIsoTime(DisplayService.gammaNextTransition)
font.pixelSize: Theme.fontSizeMedium
font.weight: Font.Medium
color: Theme.surfaceText