GtkSharp/gnome/IconTheme.custom

24 lines
634 B
Plaintext
Raw Normal View History

// IconTheme.custom - customizations to Gnome.IconTheme
//
// Authors: Mike Kestner <mkestner@ximian.com>
//
// Copyright (c) 2004 Novell, Inc.
[DllImport("gnomeui-2")]
static extern IntPtr gnome_icon_theme_list_icons (IntPtr raw, string context);
public string[] ListIcons (string context)
{
IntPtr list_ptr = gnome_icon_theme_list_icons (Handle, context);
if (list_ptr == IntPtr.Zero)
return new string [0];
GLib.List list = new GLib.List (list_ptr, typeof (string));
string[] result = new string [list.Count];
int i = 0;
foreach (string val in list)
result [i++] = val;
return result;
}