Add glassMxrph shell sources
Initial commit of the Quickshell desktop suite: bar, dock, launcher, settings, Control Center, dashboard, OSD, lock screen, desktop widgets, plugin host with the vendored Noctalia/Omarchy compatibility layer, helpers, packaging, tests and phase documentation. Includes the optimization work so far: usage widgets and dashboard gauges no longer animate continuously, desktop widgets pause while covered, system controls stop flickering on background polls, dock app matching uses an indexed catalog, and workspace ghosts are created only for occupied slots. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
commit
99e64a7713
433 files changed
+57792
No files matched your search
@@ -0,0 +1,43 @@
|
||||
import QtQuick
|
||||
|
||||
QtObject {
|
||||
id: root
|
||||
|
||||
// List of all template IDs that existed as booleans in the old format
|
||||
readonly property var templateIds: ["gtk", "qt", "kcolorscheme", "alacritty", "kitty", "ghostty", "foot", "wezterm", "fuzzel", "discord", "pywalfox", "vicinae", "walker", "code", "spicetify", "telegram", "cava", "yazi", "emacs", "niri", "hyprland", "mango", "zed", "helix", "zenBrowser"]
|
||||
|
||||
function migrate(adapter, logger, rawJson) {
|
||||
logger.i("Migration39", "Migrating templates from boolean format to activeTemplates array");
|
||||
|
||||
// Check if old format exists (any boolean template property)
|
||||
const oldTemplates = rawJson?.templates;
|
||||
if (!oldTemplates) {
|
||||
logger.d("Migration39", "No templates section found, skipping migration");
|
||||
return true;
|
||||
}
|
||||
|
||||
// Check if already migrated (has activeTemplates array)
|
||||
if (Array.isArray(oldTemplates.activeTemplates)) {
|
||||
logger.d("Migration39", "Already has activeTemplates array, skipping migration");
|
||||
return true;
|
||||
}
|
||||
|
||||
// Build the new activeTemplates array from old boolean values
|
||||
const activeTemplates = [];
|
||||
for (const templateId of templateIds) {
|
||||
if (oldTemplates[templateId] === true) {
|
||||
activeTemplates.push({
|
||||
"id": templateId,
|
||||
"enabled": true
|
||||
});
|
||||
logger.d("Migration40", "Migrated enabled template: " + templateId);
|
||||
}
|
||||
}
|
||||
|
||||
// Write the new format
|
||||
adapter.templates.activeTemplates = activeTemplates;
|
||||
logger.i("Migration40", "Migrated " + activeTemplates.length + " templates to new array format");
|
||||
|
||||
return true;
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user