summaryrefslogtreecommitdiff
path: root/libcaja-private/caja-file.c
diff options
context:
space:
mode:
authorVictor Kareh <[email protected]>2019-07-05 12:55:05 -0400
committerlukefromdc <[email protected]>2019-07-05 18:50:12 +0000
commitedb9b6f0a426686350e9ac9ea903507d358c1994 (patch)
treedc008d2bf7659aae8d5e588948140148fedf4602 /libcaja-private/caja-file.c
parentb8519b3787ad7f177fb64fc618a66c887b055a35 (diff)
downloadcaja-edb9b6f0a426686350e9ac9ea903507d358c1994.tar.bz2
caja-edb9b6f0a426686350e9ac9ea903507d358c1994.tar.xz
Render file-conflict icons as cairo_surface vectors
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)
{