StIcon: add support for GIcon

Add a "gicon" property so that a GIcon can be used instead of an
icon name, while still getting icon recoloring from the theme.
Also include a compatibility wrapper in libshell until GJS has
support for interface static methods.

https://bugzilla.gnome.org/show_bug.cgi?id=622451
This commit is contained in:
Giovanni Campagna
2010-09-26 17:18:26 +02:00
committed by Giovanni Campagna
parent 0c5d87d79b
commit 21ac225981
11 changed files with 157 additions and 42 deletions

16
src/shell-util.h Normal file
View File

@ -0,0 +1,16 @@
/* -*- mode: C; c-file-style: "gnu"; indent-tabs-mode: nil; -*- */
#ifndef __SHELL_UTIL_H__
#define __SHELL_UTIL_H__
#include <gio/gio.h>
G_BEGIN_DECLS
char *shell_util_get_label_for_uri (const char *text_uri);
GIcon *shell_util_get_icon_for_uri (const char *text_uri);
GIcon *shell_util_icon_from_string (const char *string, GError **error);
G_END_DECLS
#endif /* __SHELL_UTIL_H__ */