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:
blacksun
2015-12-08 16:52:10 +00:00
parent d06df8af6d
commit 827fba8ce4
16 changed files with 1820 additions and 7 deletions

View File

@@ -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().
*/