diff options
author | Matthew Barnes <mbarnes@redhat.com> | 2008-08-12 01:04:32 +0800 |
---|---|---|
committer | Matthew Barnes <mbarnes@src.gnome.org> | 2008-08-12 01:04:32 +0800 |
commit | 434bc25ed6b3f458f3bf119e76bd8b2bcffe5178 (patch) | |
tree | b84c336fba38760d8fe438eb9c32a117c1998752 /calendar/gui/alarm-notify | |
parent | bf8758569da2efb6c4e237741325e8d2056dba45 (diff) | |
download | gsoc2013-evolution-434bc25ed6b3f458f3bf119e76bd8b2bcffe5178.tar.gz gsoc2013-evolution-434bc25ed6b3f458f3bf119e76bd8b2bcffe5178.tar.zst gsoc2013-evolution-434bc25ed6b3f458f3bf119e76bd8b2bcffe5178.zip |
** Fixes bug #546892
2008-08-11 Matthew Barnes <mbarnes@redhat.com>
** Fixes bug #546892
* e-util/e-icon-factory.c (e_icon_factory_get_image):
Kill this function. Use gtk_image_new_from_icon_name().
* e-util/e-icon-factory.c (e_icon_factory_get_icon_list):
Kill this function. Use gtk_window_set_icon_name().
* widgets/misc/e-activity-handler.c:
* widgets/misc/e-task-widget.c:
Purge the GdkPixbuf arguments from the API. We've been ignoring
them since the spinner icon was added.
* addressbook/gui/contact-editor/e-contact-editor-fullname.c:
* addressbook/gui/contact-editor/e-contact-editor-im.c:
* addressbook/gui/contact-editor/e-contact-editor-address.c:
* calendar/gui/alarm-notify/alarm-notify-dialog.c:
* calendar/gui/dialogs/alarm-dialog.c:
* calendar/gui/dialogs/alarm-list-dialog.c:
* calendar/gui/dialogs/cal-attachment-select-file.c:
* calendar/gui/dialogs/changed-comp.c:
* calendar/gui/dialogs/delete-error.c:
* calendar/gui/dialogs/select-source-dialog.c:
* mail/mail-send-recv.c:
* mail/message-tag-followup.c:
* widgets/misc/e-combo-button.c:
* widgets/misc/e-info-label.c:
* widgets/misc/e-url-entry.c:
* widgets/misc/e-task-widget.c:
Prefer gtk_window_set_icon_name() over gtk_window_set_icon_list().
* addressbook/gui/contact-editor/e-contact-editor-im.c:
* calendar/gui/dialogs/event-page.c:
* calendar/gui/e-timezone-entry.c:
* e-util/e-gui-utils.c:
* e-util/e-popup.c:
* plugins/import-ics-attachments/icsimporter.c:
* plugins/itip-formatter/itip-view.c:
* mail/em-folder-browser.c:
* mail/em-format-html-display.c:
* mail/mail-send-recv.c:
* mail/message-tag-followup.c:
Prefer gtk_image_new_from_icon_name() over e_icon_factory_get_image().
* calendar/gui/alarm-notify/alarm-queue.c:
* plugins/mail-notification/mail-notification.c:
Prefer gtk_status_icon_set_from_icon_name() over
gtk_status_icon_set_from_pixbuf().
* addressbook/gui/component/addressbook-view.c:
* calendar/gui/e-calendar-table.c:
* calendar/gui/e-calendar-view.c:
* calendar/gui/e-memo-table.c:
* mail/mail-mt.c:
e_activity_handler_operation_started() no longer takes a GdkPixbuf.
It was ignoring the pixbuf anyway ever since we added a spinner icon.
svn path=/trunk/; revision=35958
Diffstat (limited to 'calendar/gui/alarm-notify')
-rw-r--r-- | calendar/gui/alarm-notify/alarm-notify-dialog.c | 18 | ||||
-rw-r--r-- | calendar/gui/alarm-notify/alarm-queue.c | 17 |
2 files changed, 13 insertions, 22 deletions
diff --git a/calendar/gui/alarm-notify/alarm-notify-dialog.c b/calendar/gui/alarm-notify/alarm-notify-dialog.c index 3f7ad5fa4a..bfc0375c8f 100644 --- a/calendar/gui/alarm-notify/alarm-notify-dialog.c +++ b/calendar/gui/alarm-notify/alarm-notify-dialog.c @@ -32,7 +32,6 @@ #include "alarm-notify-dialog.h" #include "config-data.h" #include "util.h" -#include "e-util/e-icon-factory.h" #include "e-util/e-util-private.h" @@ -212,8 +211,6 @@ notified_alarms_dialog_new (void) GtkWidget *edit_btn; GtkWidget *snooze_btn; GtkWidget *image; - char *icon_path; - GList *icon_list; GtkCellRenderer *renderer = gtk_cell_renderer_text_new (); AlarmNotificationsDialog *na = NULL; AlarmNotify *an = g_new0 (AlarmNotify, 1); @@ -286,10 +283,9 @@ notified_alarms_dialog_new (void) gtk_widget_realize (an->dialog); gtk_container_set_border_width (GTK_CONTAINER (GTK_DIALOG (an->dialog)->vbox), 0); gtk_container_set_border_width (GTK_CONTAINER (GTK_DIALOG (an->dialog)->action_area), 12); - image = glade_xml_get_widget (an->xml, "alarm-image"); - icon_path = e_icon_factory_get_icon_filename ("stock_alarm", E_ICON_SIZE_DIALOG); - gtk_image_set_from_file (GTK_IMAGE (image), icon_path); - g_free (icon_path); + image = glade_xml_get_widget (an->xml, "alarm-image"); + gtk_image_set_from_icon_name ( + GTK_IMAGE (image), "stock_alarm", GTK_ICON_SIZE_DIALOG); g_signal_connect (edit_btn, "clicked", G_CALLBACK (edit_pressed_cb), an); g_signal_connect (snooze_btn, "clicked", G_CALLBACK (snooze_pressed_cb), an); @@ -298,12 +294,8 @@ notified_alarms_dialog_new (void) if (!GTK_WIDGET_REALIZED (an->dialog)) gtk_widget_realize (an->dialog); - icon_list = e_icon_factory_get_icon_list ("stock_alarm"); - if (icon_list) { - gtk_window_set_icon_list (GTK_WINDOW (an->dialog), icon_list); - g_list_foreach (icon_list, (GFunc) g_object_unref, NULL); - g_list_free (icon_list); - } + + gtk_window_set_icon_name (GTK_WINDOW (an->dialog), "stock_alarm"); /* Set callback for updating the snooze "minutes" label */ g_signal_connect (G_OBJECT (an->snooze_time_min), "value_changed", diff --git a/calendar/gui/alarm-notify/alarm-queue.c b/calendar/gui/alarm-notify/alarm-queue.c index 219dfdc82d..720a757eed 100644 --- a/calendar/gui/alarm-notify/alarm-queue.c +++ b/calendar/gui/alarm-notify/alarm-queue.c @@ -35,7 +35,6 @@ #include <libgnomeui/gnome-dialog-util.h> #include <libgnomeui/gnome-uidefs.h> -#include <e-util/e-icon-factory.h> #include <libecal/e-cal-time-util.h> #include <libecal/e-cal-component.h> @@ -1384,19 +1383,18 @@ static gboolean tray_icon_blink_cb (gpointer data) { static gboolean tray_blink_state = FALSE; - GdkPixbuf *pixbuf; + const gchar *icon_name; tray_blink_countdown--; tray_blink_state = !tray_blink_state; - pixbuf = e_icon_factory_get_icon ((tray_blink_state || tray_blink_countdown <= 0)? - "stock_appointment-reminder-excl" : - "stock_appointment-reminder", - E_ICON_SIZE_LARGE_TOOLBAR); + if (tray_blink_state || tray_blink_countdown <= 0) + icon_name = "stock_appointment-reminder-excl"; + else + icon_name = "stock_appointment-reminder"; if (tray_icon) - gtk_status_icon_set_from_pixbuf (tray_icon, pixbuf); - g_object_unref (pixbuf); + gtk_status_icon_set_from_icon_name (tray_icon, icon_name); if (tray_blink_countdown <= 0) tray_blink_id = -1; @@ -1480,7 +1478,8 @@ display_notification (time_t trigger, CompQueuedAlarms *cqa, /* create the tray icon */ if (tray_icon == NULL) { tray_icon = gtk_status_icon_new (); - gtk_status_icon_set_from_pixbuf (tray_icon, e_icon_factory_get_icon ("stock_appointment-reminder", E_ICON_SIZE_LARGE_TOOLBAR)); + gtk_status_icon_set_from_icon_name ( + tray_icon, "stock_appointment-reminder"); g_signal_connect (G_OBJECT (tray_icon), "activate", G_CALLBACK (icon_activated), NULL); g_signal_connect (G_OBJECT (tray_icon), "popup-menu", |