mirror of
https://github.com/qelectrotech/qelectrotech-source-mirror.git
synced 2025-12-17 20:50:34 +01:00
Implemented a SQLite-based cache to speed up the elements panel loading.
git-svn-id: svn+ssh://svn.tuxfamily.org/svnroot/qet/qet/branches/0.3@1329 bfdf4180-ca20-0410-9c96-a3a8aa849046
This commit is contained in:
@@ -198,3 +198,14 @@ void FileElementDefinition::setFilePath(const QString &path) {
|
||||
}
|
||||
file_path = file_info.canonicalFilePath();
|
||||
}
|
||||
|
||||
/**
|
||||
@return the time of the last modification (mtime) for this element file
|
||||
*/
|
||||
QDateTime FileElementDefinition::modificationTime() const {
|
||||
QFileInfo file_info(file_path);
|
||||
if (!file_info.exists() || !file_info.isReadable()) {
|
||||
return QDateTime();
|
||||
}
|
||||
return(file_info.lastModified());
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user