Notification, load at first start a wallpaper, bugfix restart on after first enable

This commit is contained in:
2023-07-13 14:32:13 +02:00
parent 43fcd83b17
commit 4798b9438d
7 changed files with 37 additions and 11 deletions

View File

@@ -0,0 +1 @@
../5.4/icon/

View File

@@ -1 +1 @@
../icon.png
../5.4/icon/icon.png

View File

@@ -76,6 +76,23 @@ CinnamonDynamicWallpaperExtension.prototype = {
this.setImageToTime()
this._loop()
// Check for the first startup
if (this.settings.getValue("first_start")) {
this.showNotification("Welcome to Cinnamon Dynamic Wallpaper", "Check the preferences to choose a dynamic wallpaper", true)
this.settings.setValue("first_start", false)
// Copy the default wallpaper to the folder
Util.spawnCommandLine("mkdir " + DIRECTORY.path + "/images/selected/")
global.log("mkdir " + DIRECTORY.path + "/images/selected")
for (let i = 1; i <= 9; i++) {
Util.spawnCommandLine("ln -s " +
DIRECTORY.path + "/images/included_image_sets/lakeside/" + i + ".jpg " +
DIRECTORY.path + "/images/selected/" + i + ".jpg");
}
}
},

View File

@@ -0,0 +1 @@
icon/icon.png

View File

Before

Width:  |  Height:  |  Size: 1.3 KiB

After

Width:  |  Height:  |  Size: 1.3 KiB

View File

@@ -123,52 +123,56 @@
},
"etr_choosen_image_set": {
"type": "entry",
"default": "",
"default": "lakeside",
"description": ""
},
"etr_img_morning_twilight": {
"type": "entry",
"default": "",
"default": "1.jpg",
"description": ""
},
"etr_img_sunrise": {
"type": "entry",
"default": "",
"default": "2.jpg",
"description": ""
},
"etr_img_morning": {
"type": "entry",
"default": "",
"default": "3.jpg",
"description": ""
},
"etr_img_noon": {
"type": "entry",
"default": "",
"default": "4.jpg",
"description": ""
},
"etr_img_afternoon": {
"type": "entry",
"default": "",
"default": "5.jpg",
"description": ""
},
"etr_img_evening": {
"type": "entry",
"default": "",
"default": "6.jpg",
"description": ""
},
"etr_img_sunset": {
"type": "entry",
"default": "",
"default": "7.jpg",
"description": ""
},
"etr_img_night_twilight": {
"type": "entry",
"default": "",
"default": "8.jpg",
"description": ""
},
"etr_img_night": {
"type": "entry",
"default": "",
"default": "9.jpg",
"description": ""
},
"first_start": {
"type": "generic",
"default": true
}
}