Changeset View
Changeset View
Standalone View
Standalone View
src/file/unindexedfileindexer.cpp
Show First 20 Lines • Show All 53 Lines • ▼ Show 20 Line(s) | 49 | while (!it.next().isEmpty()) { | |||
---|---|---|---|---|---|
54 | 54 | | |||
55 | // We handle modified files by simply updating the mTime and filename in the Db and marking them for ContentIndexing | 55 | // We handle modified files by simply updating the mTime and filename in the Db and marking them for ContentIndexing | ||
56 | const quint64 id = job.document().id(); | 56 | const quint64 id = job.document().id(); | ||
57 | if (tr.hasDocument(id)) { | 57 | if (tr.hasDocument(id)) { | ||
58 | 58 | | |||
59 | DocumentOperations ops = DocumentTime; | 59 | DocumentOperations ops = DocumentTime; | ||
60 | if (it.cTimeChanged()) { | 60 | if (it.cTimeChanged()) { | ||
61 | ops |= XAttrTerms; | 61 | ops |= XAttrTerms; | ||
62 | if (tr.documentUrl(id) != it.filePath()) { | 62 | if (it.nameChanged()) { | ||
63 | ops |= (FileNameTerms | DocumentUrl); | 63 | ops |= (FileNameTerms | DocumentUrl); | ||
64 | } | 64 | } | ||
65 | } | 65 | } | ||
66 | tr.replaceDocument(job.document(), ops); | 66 | tr.replaceDocument(job.document(), ops); | ||
67 | 67 | | |||
68 | if (it.mTimeChanged()) { | 68 | if (it.mTimeChanged()) { | ||
69 | tr.setPhaseOne(id); | 69 | tr.setPhaseOne(id); | ||
70 | } | 70 | } | ||
Show All 10 Lines |