fix: stuck if no images available
This commit is contained in:
+4
-5
@@ -4,8 +4,7 @@
|
||||
"~/Pictures/116327446_p0.jpg"
|
||||
],
|
||||
"dirs": [
|
||||
"~/.config/backgrounds",
|
||||
"~/Pictures/逆流茶会/"
|
||||
"~/.config/backgrounds"
|
||||
],
|
||||
"excludes": [
|
||||
"~/.config/backgrounds/nao-stars-crop-adjust-flop.jpg",
|
||||
@@ -22,10 +21,10 @@
|
||||
"image_focus_width": 480,
|
||||
"window_width": 750,
|
||||
"window_height": 500,
|
||||
"no_loading_screen": true
|
||||
"no_loading_screen": false
|
||||
},
|
||||
"sort": {
|
||||
"type": "none",
|
||||
"reverse": false
|
||||
"type": "date",
|
||||
"reverse": true
|
||||
}
|
||||
}
|
||||
@@ -1,7 +1,7 @@
|
||||
/*
|
||||
* @Author: Uyanide pywang0608@foxmail.com
|
||||
* @Date: 2025-08-05 01:22:53
|
||||
* @LastEditTime: 2025-08-08 05:12:37
|
||||
* @LastEditTime: 2025-08-11 19:44:06
|
||||
* @Description: Animated carousel widget for displaying and selecting images.
|
||||
*/
|
||||
#include "images_carousel.h"
|
||||
@@ -86,6 +86,11 @@ ImagesCarousel::~ImagesCarousel() {
|
||||
}
|
||||
|
||||
void ImagesCarousel::appendImages(const QStringList& paths) {
|
||||
if (paths.isEmpty()) {
|
||||
warn("No images to add to display.");
|
||||
emit loadingCompleted(0);
|
||||
return;
|
||||
}
|
||||
{
|
||||
QMutexLocker locker(&m_countMutex);
|
||||
m_addedImagesCount += paths.size();
|
||||
|
||||
Reference in New Issue
Block a user