mirror of
https://github.com/AvengeMedia/DankMaterialShell.git
synced 2026-06-07 19:59:14 -04:00
fix(IconTheme): apply stored icon theme at startup (#2511)
Add applyStoredIconTheme() calls alongside existing applyStoredTheme() calls in loadSettings(), onLoaded, and onLoadFailed, ensuring the stored icon theme is synced to GTK/Qt/Cosmic configs on every startup and reload. The applyStoredIconTheme() function and its _hooks entry already existed in the codebase but were never invoked during initial settings loading. Co-authored-by: lingdiansr <2077258365@qq.com> Co-authored-by: Claude Opus 4.7 <noreply@anthropic.com>
This commit is contained in:
@@ -1384,6 +1384,7 @@ Singleton {
|
||||
_loadedSettingsSnapshot = JSON.stringify(Store.toJson(root));
|
||||
_hasLoaded = true;
|
||||
applyStoredTheme();
|
||||
applyStoredIconTheme();
|
||||
updateCompositorCursor();
|
||||
Processes.detectQtTools();
|
||||
|
||||
@@ -1394,6 +1395,7 @@ Singleton {
|
||||
log.error("Failed to parse settings.json - file will not be overwritten. Error:", msg);
|
||||
Qt.callLater(() => ToastService.showError(I18n.tr("Failed to parse settings.json"), msg));
|
||||
applyStoredTheme();
|
||||
applyStoredIconTheme();
|
||||
} finally {
|
||||
_loading = false;
|
||||
}
|
||||
@@ -3152,6 +3154,7 @@ Singleton {
|
||||
_loadedSettingsSnapshot = JSON.stringify(Store.toJson(root));
|
||||
_hasLoaded = true;
|
||||
applyStoredTheme();
|
||||
applyStoredIconTheme();
|
||||
updateCompositorCursor();
|
||||
} catch (e) {
|
||||
_parseError = true;
|
||||
@@ -3165,6 +3168,7 @@ Singleton {
|
||||
onLoadFailed: error => {
|
||||
if (!isGreeterMode) {
|
||||
applyStoredTheme();
|
||||
applyStoredIconTheme();
|
||||
}
|
||||
}
|
||||
onSaveFailed: error => {
|
||||
|
||||
Reference in New Issue
Block a user