From 3a7fc30a5f1c0945c021abf185274e88f72e7080 Mon Sep 17 00:00:00 2001 From: Vincent Sanders Date: Wed, 13 May 2020 19:03:14 +0100 Subject: implement content opacity check through the function table --- content/handlers/image/image_cache.c | 11 +++++++++++ 1 file changed, 11 insertions(+) (limited to 'content/handlers/image/image_cache.c') diff --git a/content/handlers/image/image_cache.c b/content/handlers/image/image_cache.c index a1de01da5..bc0b91408 100644 --- a/content/handlers/image/image_cache.c +++ b/content/handlers/image/image_cache.c @@ -858,6 +858,17 @@ void *image_cache_get_internal(const struct content *c, void *context) return image_cache_get_bitmap(c); } +/* exported interface documented in image_cache.h */ +bool image_cache_is_opaque(struct content *c) +{ + struct bitmap *bmp; + bmp = image_cache_get_bitmap(c); + if (bmp != NULL) { + return guit->bitmap->get_opaque(bmp); + } + return false; +} + /* exported interface documented in image_cache.h */ content_type image_cache_content_type(void) { -- cgit v1.2.3