From 8172d77c914b3d2cdbf1ff51f728f5c8860b64d9 Mon Sep 17 00:00:00 2001 From: Michael Terry Date: Mon, 19 Apr 2004 15:19:32 +0000 Subject: Update the calendar to use the icon theme through the EIconFactory object 2004-04-19 Michael Terry * gui/GNOME_Evolution_Calendar.server.in.in: * gui/calendar-commands.c: * gui/calendar-component.c: * gui/e-calendar-table.c: * gui/e-calendar-view.c: * gui/e-day-view-main-item.c: * gui/e-day-view-top-item.c: * gui/e-day-view.c: * gui/e-day-view.h: * gui/e-itip-control.c: * gui/e-timezone-entry.c: * gui/e-week-view-event-item.c: * gui/e-week-view.c: * gui/e-week-view.h: * gui/tasks-component.c: * gui/alarm-notify/alarm-notify-dialog.c: * gui/alarm-notify/alarm-queue.c: * gui/dialogs/comp-editor.c: * gui/dialogs/event-editor.c: Update the calendar to use the icon theme through the EIconFactory object in e-util svn path=/trunk/; revision=25515 --- calendar/gui/dialogs/comp-editor.c | 41 ++++++++++++++++++++++---------------- 1 file changed, 24 insertions(+), 17 deletions(-) (limited to 'calendar/gui/dialogs/comp-editor.c') diff --git a/calendar/gui/dialogs/comp-editor.c b/calendar/gui/dialogs/comp-editor.c index 976cae4493..0e93f7b68a 100644 --- a/calendar/gui/dialogs/comp-editor.c +++ b/calendar/gui/dialogs/comp-editor.c @@ -33,11 +33,11 @@ #include #include #include -#include #include #include #include #include +#include #include #include "../print.h" #include "../comp-util.h" @@ -122,18 +122,18 @@ static gint delete_event_cb (GtkWidget *widget, GdkEvent *event, gpointer data); static EPixmap pixmaps [] = { - E_PIXMAP ("/menu/File/FileSave", "save-16.png"), - E_PIXMAP ("/menu/File/FileSaveAndClose", "save-16.png"), - E_PIXMAP ("/menu/File/FileSaveAs", "save-as-16.png"), + E_PIXMAP ("/menu/File/FileSave", "stock_save", 16), + E_PIXMAP ("/menu/File/FileSaveAndClose", "stock_save", 16), + E_PIXMAP ("/menu/File/FileSaveAs", "stock_save_as", 16), - E_PIXMAP ("/menu/File/FileDelete", "evolution-trash-mini.png"), + E_PIXMAP ("/menu/File/FileDelete", "stock_delete", 16), - E_PIXMAP ("/menu/File/FilePrint", "print.xpm"), - E_PIXMAP ("/menu/File/FilePrintPreview", "print-preview.xpm"), + E_PIXMAP ("/menu/File/FilePrint", "stock_print", 16), + E_PIXMAP ("/menu/File/FilePrintPreview", "stock_print-preview", 16), - E_PIXMAP ("/Toolbar/FileSaveAndClose", "buttons/save-24.png"), - E_PIXMAP ("/Toolbar/FilePrint", "buttons/print.png"), - E_PIXMAP ("/Toolbar/FileDelete", "buttons/delete-message.png"), + E_PIXMAP ("/Toolbar/FileSaveAndClose", "stock_save", 24), + E_PIXMAP ("/Toolbar/FilePrint", "stock_print", 24), + E_PIXMAP ("/Toolbar/FileDelete", "stock_delete", 24), E_PIXMAP_END }; @@ -971,18 +971,18 @@ make_icon_from_comp (ECalComponent *comp) ECalComponentVType type; if (!comp) - return EVOLUTION_IMAGESDIR "/evolution-calendar-mini.png"; + return "stock_calendar"; type = e_cal_component_get_vtype (comp); switch (type) { case E_CAL_COMPONENT_EVENT: - return EVOLUTION_IMAGESDIR "/buttons/new_appointment.png"; + return "stock_new-appointment"; break; case E_CAL_COMPONENT_TODO: - return EVOLUTION_IMAGESDIR "/buttons/new_task.png"; + return "stock_task"; break; default: - return EVOLUTION_IMAGESDIR "/evolution-calendar-mini.png"; + return "stock_calendar"; } } @@ -1015,11 +1015,18 @@ static void set_icon_from_comp (CompEditor *editor) { CompEditorPrivate *priv; - const char *file; + const char *icon_name; + GList *icon_list; priv = editor->priv; - file = make_icon_from_comp (priv->comp); - gnome_window_icon_set_from_file (GTK_WINDOW (editor), file); + icon_name = make_icon_from_comp (priv->comp); + + icon_list = e_icon_factory_get_icon_list (icon_name); + if (icon_list) { + gtk_window_set_icon_list (GTK_WINDOW (editor), icon_list); + g_list_foreach (icon_list, (GFunc) g_object_unref, NULL); + g_list_free (icon_list); + } } static void -- cgit v1.2.3