MCPcopy Create free account
hub / github.com/FreeCAD/FreeCAD / getCacheKey

Method getCacheKey

src/Mod/Start/Gui/FileCardDelegate.cpp:175–185  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

173}
174
175QString FileCardDelegate::getCacheKey(const QString& path, int thumbnailSize) const
176{
177 QFileInfo fileInfo(path);
178 if (!fileInfo.exists()) {
179 return {};
180 }
181
182 // create cache key: path:modtime:size
183 QString modTime = QString::number(fileInfo.lastModified().toSecsSinceEpoch());
184 return QStringLiteral("%1:%2:%3").arg(path, modTime, QString::number(thumbnailSize));
185}
186
187QPixmap FileCardDelegate::loadAndCacheThumbnail(const QString& path, int thumbnailSize) const
188{

Callers

nothing calls this directly

Calls 2

lastModifiedMethod · 0.80
existsMethod · 0.45

Tested by

no test coverage detected