mirror of
https://github.com/xiaoyifang/goldendict-ng.git
synced 2024-11-30 13:24:05 +00:00
xapian indexisold function adjusted
This commit is contained in:
parent
e2a55e3f8f
commit
c930687055
|
@ -572,23 +572,13 @@ bool needToRebuildIndex( vector< string > const & dictionaryFiles,
|
|||
if(d.exists()){
|
||||
d.removeRecursively();
|
||||
}
|
||||
#endif
|
||||
QFileInfo fileInfo( FsEncoding::decode( indexFile.c_str() ) );
|
||||
|
||||
if ( !fileInfo.exists() )
|
||||
return true;
|
||||
|
||||
return fileInfo.lastModified().toSecsSinceEpoch() < lastModified;
|
||||
#else
|
||||
QFileInfo fileInfo( FsEncoding::decode( indexFile.c_str() ) );
|
||||
|
||||
if ( fileInfo.exists()&&fileInfo.isFile() )
|
||||
{
|
||||
QFile::remove(FsEncoding::decode( indexFile.c_str() ));
|
||||
return true;
|
||||
}
|
||||
|
||||
return false;
|
||||
#endif
|
||||
}
|
||||
|
||||
string getFtsSuffix(){
|
||||
|
|
Loading…
Reference in a new issue