Some cleanups

This commit is contained in:
Ingo Weyrich
2019-11-26 15:25:11 +01:00
parent f054ed00e8
commit 2a4891827d
53 changed files with 120 additions and 162 deletions

View File

@@ -114,16 +114,16 @@ void findOriginalEntries (const std::vector<ThumbBrowserEntryBase*>& entries)
// Find the original image for each bucket
for (BasenameIterator bucket = byBasename.begin (); bucket != byBasename.end (); ++bucket) {
const EntryVector& entries = bucket->second;
const EntryVector& lentries = bucket->second;
ThumbBrowserEntryBase* original = nullptr;
// Select the most likely original in a first pass...
for (EntryIterator entry = entries.begin (); entry != entries.end (); ++entry) {
for (EntryIterator entry = lentries.begin (); entry != lentries.end (); ++entry) {
original = selectOriginalEntry (original, *entry);
}
// ...and link all other images to it in a second pass.
for (EntryIterator entry = entries.begin (); entry != entries.end (); ++entry) {
for (EntryIterator entry = lentries.begin (); entry != lentries.end (); ++entry) {
(*entry)->setOriginal (*entry != original ? original : nullptr);
}
}