зеркало из https://github.com/mozilla/pjs.git
Added FlushCache method
This commit is contained in:
Родитель
75f2c0b82d
Коммит
03144d6fd2
|
@ -68,6 +68,12 @@ public:
|
|||
*/
|
||||
virtual PRInt32 ShrinkCache(void) = 0;
|
||||
|
||||
/**
|
||||
* Flush the image cache as much as possible. The only images not
|
||||
* flushed out will be those that are in use.
|
||||
*/
|
||||
NS_IMETHOD FlushCache(void) = 0;
|
||||
|
||||
/**
|
||||
* Determine the type of the image, based on the first few bytes of data.
|
||||
*
|
||||
|
|
|
@ -38,6 +38,7 @@ public:
|
|||
virtual void SetCacheSize(PRInt32 aCacheSize);
|
||||
virtual PRInt32 GetCacheSize(void);
|
||||
virtual PRInt32 ShrinkCache(void);
|
||||
NS_IMETHOD FlushCache(void);
|
||||
virtual nsImageType GetImageType(const char *buf, PRInt32 length);
|
||||
|
||||
private:
|
||||
|
@ -99,6 +100,13 @@ ImageManagerImpl::ShrinkCache(void)
|
|||
return IL_ShrinkCache();
|
||||
}
|
||||
|
||||
NS_IMETHODIMP
|
||||
ImageManagerImpl::FlushCache(void)
|
||||
{
|
||||
IL_FlushCache();
|
||||
return NS_OK;
|
||||
}
|
||||
|
||||
nsImageType
|
||||
ImageManagerImpl::GetImageType(const char *buf, PRInt32 length)
|
||||
{
|
||||
|
|
Загрузка…
Ссылка в новой задаче