mirror of
https://github.com/qelectrotech/qelectrotech-source-mirror.git
synced 2026-02-05 12:09:58 +01:00
Add new element panel
git-svn-id: svn+ssh://svn.tuxfamily.org/svnroot/qet/qet/trunk@4283 bfdf4180-ca20-0410-9c96-a3a8aa849046
This commit is contained in:
@@ -215,6 +215,20 @@ bool ElementsCollectionCache::fetchElement(ElementDefinition *element)
|
||||
}
|
||||
}
|
||||
|
||||
bool ElementsCollectionCache::fetchElement(ElementLocation location)
|
||||
{
|
||||
if (fetchNameFromCache(location.collectionPath(), location.uuid()) &&
|
||||
fetchPixmapFromCache(location.collectionPath(), location.uuid()))
|
||||
return true;
|
||||
else if (fetchData(ElementsLocation(location.collectionPath())))
|
||||
{
|
||||
cacheName(location.collectionPath(), location.uuid());
|
||||
cachePixmap(location.collectionPath(), location.uuid());
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
/**
|
||||
@return The last name fetched through fetchElement().
|
||||
*/
|
||||
|
||||
Reference in New Issue
Block a user