summaryrefslogtreecommitdiff
path: root/libcaja-private/caja-file.c
diff options
context:
space:
mode:
Diffstat (limited to 'libcaja-private/caja-file.c')
-rw-r--r--libcaja-private/caja-file.c21
1 files changed, 21 insertions, 0 deletions
diff --git a/libcaja-private/caja-file.c b/libcaja-private/caja-file.c
index c57ffd38..3ebb337b 100644
--- a/libcaja-private/caja-file.c
+++ b/libcaja-private/caja-file.c
@@ -4679,6 +4679,27 @@ caja_file_get_icon_pixbuf (CajaFile *file,
return pixbuf;
}
+cairo_surface_t *
+caja_file_get_icon_surface (CajaFile *file,
+ int size,
+ gboolean force_size,
+ int scale,
+ CajaFileIconFlags flags)
+{
+ CajaIconInfo *info;
+ cairo_surface_t *surface;
+
+ info = caja_file_get_icon (file, size, scale, flags);
+ if (force_size) {
+ surface = caja_icon_info_get_surface_at_size (info, size);
+ } else {
+ surface = caja_icon_info_get_surface (info);
+ }
+ g_object_unref (info);
+
+ return surface;
+}
+
char *
caja_file_get_custom_icon (CajaFile *file)
{