background-overview: improved init to avoid noctalia bg showing

This commit is contained in:
Lemmy
2026-02-11 21:11:14 -05:00
parent 46584adab0
commit 208e0509b0
2 changed files with 11 additions and 1 deletions
+7
View File
@@ -97,6 +97,10 @@ Variants {
Connections {
target: CompositorService
function onDisplayScalesChanged() {
if (!WallpaperService.isInitialized) {
return;
}
const currentPath = WallpaperService.getWallpaper(modelData.name);
if (!currentPath || WallpaperService.isSolidColorPath(currentPath)) {
return;
@@ -646,6 +650,9 @@ Variants {
_solidColor2 = colorStr;
// No image to load, start transition immediately
nextWallpaper.source = "";
if (!wallpaperReady) {
wallpaperReady = true;
}
currentWallpaper.asynchronous = false;
transitionAnimation.start();
} else {
+4 -1
View File
@@ -19,10 +19,12 @@ Loader {
required property ShellScreen modelData
property string wallpaper: ""
property string preprocessedWallpaper: "" // Pre-resized wallpaper from Background.qml
property bool isSolidColor: false
property bool isSolidColor: Settings.data.wallpaper.useSolidColor
property color solidColor: Settings.data.wallpaper.solidColor
property color tintColor: Settings.data.colorSchemes.darkMode ? Color.mSurface : Color.mOnSurface
visible: wallpaper !== "" || isSolidColor
Component.onCompleted: {
if (modelData) {
Logger.d("Overview", "Loading overview for Niri on", modelData.name);
@@ -83,6 +85,7 @@ Loader {
Rectangle {
anchors.fill: parent
color: tintColor
opacity: Settings.data.wallpaper.overviewTint
}
}