mirror of
https://github.com/AvengeMedia/DankMaterialShell.git
synced 2026-04-11 08:12:09 -04:00
launcher v2: performance optimizations
- Use ListView in all tab - use filesystem cache to speed up first launch - apply highlights to visible models
This commit is contained in:
@@ -178,6 +178,33 @@ Singleton {
|
||||
}
|
||||
}
|
||||
|
||||
function loadLauncherCache() {
|
||||
try {
|
||||
var content = launcherCacheFile.text();
|
||||
if (content && content.trim())
|
||||
return JSON.parse(content);
|
||||
} catch (e) {
|
||||
console.warn("CacheData: Failed to parse launcher cache:", e.message);
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
function saveLauncherCache(sections) {
|
||||
if (_loading)
|
||||
return;
|
||||
launcherCacheFile.setText(JSON.stringify(sections));
|
||||
}
|
||||
|
||||
FileView {
|
||||
id: launcherCacheFile
|
||||
|
||||
path: isGreeterMode ? "" : _stateDir + "/DankMaterialShell/launcher_cache.json"
|
||||
blockLoading: true
|
||||
blockWrites: true
|
||||
atomicWrites: true
|
||||
watchChanges: false
|
||||
}
|
||||
|
||||
FileView {
|
||||
id: cacheFile
|
||||
|
||||
|
||||
Reference in New Issue
Block a user