Add function to test whether hlcache_handle's content is locked.
svn path=/trunk/netsurf/; revision=10287
This commit is contained in:
parent
9a28ace52b
commit
2fba2249ee
|
@ -1301,6 +1301,23 @@ struct bitmap *content__get_bitmap(struct content *c)
|
|||
return c->bitmap;
|
||||
}
|
||||
|
||||
/**
|
||||
* Return whether a content is currently locked
|
||||
*
|
||||
* \param c Content to test
|
||||
* \return true iff locked, else false
|
||||
*/
|
||||
|
||||
bool content_is_locked(hlcache_handle *h)
|
||||
{
|
||||
return content__is_locked(hlcache_handle_get_content(h));
|
||||
}
|
||||
|
||||
bool content__is_locked(struct content *c)
|
||||
{
|
||||
return c->locked;
|
||||
}
|
||||
|
||||
/**
|
||||
* Retrieve the low-level cache handle for a content
|
||||
*
|
||||
|
|
|
@ -145,4 +145,6 @@ void content_invalidate_reuse_data(struct hlcache_handle *c);
|
|||
const char *content_get_refresh_url(struct hlcache_handle *c);
|
||||
struct bitmap *content_get_bitmap(struct hlcache_handle *c);
|
||||
|
||||
bool content_is_locked(struct hlcache_handle *h);
|
||||
|
||||
#endif
|
||||
|
|
|
@ -220,4 +220,6 @@ void content__invalidate_reuse_data(struct content *c);
|
|||
const char *content__get_refresh_url(struct content *c);
|
||||
struct bitmap *content__get_bitmap(struct content *c);
|
||||
|
||||
bool content__is_locked(struct content *c);
|
||||
|
||||
#endif
|
||||
|
|
Loading…
Reference in New Issue