Commit 0ed7253f2d2edcc342b29c0cf3fcc16c0dc9b316
1 parent
4e21bc9d
Better file count for emptyGallery
Showing
1 changed file
with
6 additions
and
1 deletions
openbr/plugins/gallery/empty.cpp
| ... | ... | @@ -40,7 +40,12 @@ class EmptyGallery : public Gallery |
| 40 | 40 | { |
| 41 | 41 | QDir dir(file.name); |
| 42 | 42 | QtUtils::touchDir(dir); |
| 43 | - gallerySize = dir.count(); | |
| 43 | + QDirIterator it(dir.absolutePath(), QDir::Files | QDir::NoDotAndDotDot, QDirIterator::Subdirectories); | |
| 44 | + gallerySize = 0; | |
| 45 | + while (it.hasNext()) { | |
| 46 | + it.next(); | |
| 47 | + gallerySize++; | |
| 48 | + } | |
| 44 | 49 | } |
| 45 | 50 | |
| 46 | 51 | TemplateList readBlock(bool *done) | ... | ... |