mirror of
https://repo.dactyloidae.xyz/Dactyloidae/UXP.git
synced 2026-09-20 07:17:32 +09:00
Issue #2928 - Avoid searching the image cache queue for an entry after we just popped it off the queue.
This commit is contained in:
parent
252cbabfd4
commit
3b799da2f8
2 changed files with 30 additions and 6 deletions
|
|
@ -316,7 +316,16 @@ public:
|
|||
nsresult InitCache();
|
||||
|
||||
bool RemoveFromCache(const ImageCacheKey& aKey);
|
||||
bool RemoveFromCache(imgCacheEntry* entry);
|
||||
|
||||
// Enumeration describing if a given entry is in the cache queue or not.
|
||||
// There are some cases we know the entry is definitely not in the queue.
|
||||
enum class QueueState {
|
||||
MaybeExists,
|
||||
AlreadyRemoved
|
||||
};
|
||||
|
||||
bool RemoveFromCache(imgCacheEntry* entry,
|
||||
QueueState aQueueState = QueueState::MaybeExists);
|
||||
|
||||
bool PutIntoCache(const ImageCacheKey& aKey, imgCacheEntry* aEntry);
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue