2 #ifndef __EGG_RECENT_ITEM_H__
3 #define __EGG_RECENT_ITEM_H__
7 #include <glib-object.h>
11 #define EGG_TYPE_RECENT_ITEM (egg_recent_item_get_type ())
13 #define EGG_RECENT_ITEM_LIST_UNREF(list) \
14 g_list_foreach (list, (GFunc)egg_recent_item_unref, NULL); \
17 typedef struct _EggRecentItem EggRecentItem;
19 struct _EggRecentItem {
20 /* do not access any of these directly */
25 gboolean private_data;
32 GType egg_recent_item_get_type (void) G_GNUC_CONST;
35 EggRecentItem * egg_recent_item_new (void);
37 EggRecentItem * egg_recent_item_ref (EggRecentItem *item);
38 EggRecentItem * egg_recent_item_unref (EggRecentItem *item);
40 /* automatically fetches the mime type, etc */
41 EggRecentItem * egg_recent_item_new_from_uri (const gchar *uri);
43 gboolean egg_recent_item_set_uri (EggRecentItem *item, const gchar *uri);
44 gchar * egg_recent_item_get_uri (const EggRecentItem *item);
45 gchar * egg_recent_item_get_uri_utf8 (const EggRecentItem *item);
46 gchar * egg_recent_item_get_uri_for_display (const EggRecentItem *item);
47 gchar * egg_recent_item_get_short_name (const EggRecentItem *item);
49 void egg_recent_item_set_mime_type (EggRecentItem *item, const gchar *mime);
50 gchar * egg_recent_item_get_mime_type (const EggRecentItem *item);
52 void egg_recent_item_set_timestamp (EggRecentItem *item, time_t timestamp);
53 time_t egg_recent_item_get_timestamp (const EggRecentItem *item);
55 G_CONST_RETURN gchar *egg_recent_item_peek_uri (const EggRecentItem *item);
59 G_CONST_RETURN GList * egg_recent_item_get_groups (const EggRecentItem *item);
61 gboolean egg_recent_item_in_group (const EggRecentItem *item,
62 const gchar *group_name);
64 void egg_recent_item_add_group (EggRecentItem *item,
65 const gchar *group_name);
67 void egg_recent_item_remove_group (EggRecentItem *item,
68 const gchar *group_name);
70 void egg_recent_item_set_private (EggRecentItem *item,
73 gboolean egg_recent_item_get_private (const EggRecentItem *item);
78 #endif /* __EGG_RECENT_ITEM_H__ */