aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJP Rosevear <jpr@ximian.com>2001-02-14 07:50:25 +0800
committerJP Rosevear <jpr@src.gnome.org>2001-02-14 07:50:25 +0800
commita74d594e2fcea73193b8ab208b0d333c76e9ece0 (patch)
tree01431b9cfa846c486b6cf1cd3f06fb204bcfe2ca
parent1cd5f1093b9803a0598d4aac1c1e03a49df94108 (diff)
downloadgsoc2013-evolution-a74d594e2fcea73193b8ab208b0d333c76e9ece0.tar.gz
gsoc2013-evolution-a74d594e2fcea73193b8ab208b0d333c76e9ece0.tar.zst
gsoc2013-evolution-a74d594e2fcea73193b8ab208b0d333c76e9ece0.zip
Set toolbar new appointment icon (set_pixmap): load files rather than
2001-02-13 JP Rosevear <jpr@ximian.com> * gui/calendar-commands.c (update_pixmaps): Set toolbar new appointment icon (set_pixmap): load files rather than create from xpm file * gui/*view.xpm: move to the art directory 2001-02-13 JP Rosevear <jpr@ximian.com> * art/Makefile.am: install new files * art/*view.xpm: add files from calendar/gui svn path=/trunk/; revision=8216
-rw-r--r--ChangeLog6
-rw-r--r--art/Makefile.am10
-rw-r--r--art/dayview.xpm (renamed from calendar/gui/dayview.xpm)0
-rw-r--r--art/monthview.xpm (renamed from calendar/gui/monthview.xpm)0
-rw-r--r--art/weekview.xpm (renamed from calendar/gui/weekview.xpm)0
-rw-r--r--art/workweekview.xpm (renamed from calendar/gui/workweekview.xpm)0
-rw-r--r--art/yearview.xpm (renamed from calendar/gui/yearview.xpm)0
-rw-r--r--calendar/ChangeLog10
-rw-r--r--calendar/gui/calendar-commands.c77
9 files changed, 60 insertions, 43 deletions
diff --git a/ChangeLog b/ChangeLog
index 7a4824424c..e5a930aac7 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,9 @@
+2001-02-13 JP Rosevear <jpr@ximian.com>
+
+ * art/Makefile.am: install new files
+
+ * art/*view.xpm: add files from calendar/gui
+
2001-02-11 Chris Toshok <toshok@ximian.com>
* configure.in: rework ldap check logic so it'll work to
diff --git a/art/Makefile.am b/art/Makefile.am
index 97856c5884..cb5161dbb7 100644
--- a/art/Makefile.am
+++ b/art/Makefile.am
@@ -37,6 +37,7 @@ images_DATA = \
globe.png \
house.png \
malehead.png \
+ new_contact.xpm \
service-close.png \
service-configure.png \
service-down.png \
@@ -54,11 +55,18 @@ buttons_DATA = \
add-service.png \
compose-message.png \
copy-message.png \
+ dayview.xpm \
fetch-mail.png \
forward.png \
+ monthview.xpm \
move-message.png \
+ new_appointment.png \
reply-to-all.png \
- reply.png
+ reply.png \
+ weekview.xpm \
+ workweekview.xpm \
+ yearview.xpm
+
EXTRA_DIST = \
add-service.png \
diff --git a/calendar/gui/dayview.xpm b/art/dayview.xpm
index dbabb24c5c..dbabb24c5c 100644
--- a/calendar/gui/dayview.xpm
+++ b/art/dayview.xpm
diff --git a/calendar/gui/monthview.xpm b/art/monthview.xpm
index 21c76151d5..21c76151d5 100644
--- a/calendar/gui/monthview.xpm
+++ b/art/monthview.xpm
diff --git a/calendar/gui/weekview.xpm b/art/weekview.xpm
index 869b9e722a..869b9e722a 100644
--- a/calendar/gui/weekview.xpm
+++ b/art/weekview.xpm
diff --git a/calendar/gui/workweekview.xpm b/art/workweekview.xpm
index 35cceedbdc..35cceedbdc 100644
--- a/calendar/gui/workweekview.xpm
+++ b/art/workweekview.xpm
diff --git a/calendar/gui/yearview.xpm b/art/yearview.xpm
index 0d4fa4135b..0d4fa4135b 100644
--- a/calendar/gui/yearview.xpm
+++ b/art/yearview.xpm
diff --git a/calendar/ChangeLog b/calendar/ChangeLog
index 49ffbec716..9b14aac03c 100644
--- a/calendar/ChangeLog
+++ b/calendar/ChangeLog
@@ -1,3 +1,11 @@
+2001-02-13 JP Rosevear <jpr@ximian.com>
+
+ * gui/calendar-commands.c (update_pixmaps): Set toolbar new
+ appointment icon
+ (set_pixmap): load files rather than create from xpm file
+
+ * gui/*view.xpm: move to the art directory
+
2001-02-13 Rodrigo Moya <rodrigo@ximian.com>
* pcs/cal-backend-db.c (cal_backend_db_get_alarms_for_object):
@@ -5,6 +13,8 @@
2001-02-13 JP Rosevear <jpr@ximian.com>
+ * gui/calendar-commands.c (update_pixmaps): Set toolbar new command
+
* gui/e-calendar-table.c: Add titles to pixbuf column for grouping
* gui/calendar-model.c (calendar_model_class_init): override value
diff --git a/calendar/gui/calendar-commands.c b/calendar/gui/calendar-commands.c
index a9a9d62101..29557e2d68 100644
--- a/calendar/gui/calendar-commands.c
+++ b/calendar/gui/calendar-commands.c
@@ -45,14 +45,6 @@
#include "print.h"
#include "dialogs/cal-prefs-dialog.h"
-#include "dayview.xpm"
-#include "workweekview.xpm"
-#include "weekview.xpm"
-#include "monthview.xpm"
-#if 0
-#include "yearview.xpm"
-#endif
-
/* A list of all of the calendars started */
static GList *all_calendars = NULL;
@@ -60,13 +52,6 @@ static GList *all_calendars = NULL;
/* We have one global preferences dialog. */
static CalPrefsDialog *preferences_dialog = NULL;
-
-static void update_pixmaps (BonoboUIComponent *uic);
-static void set_pixmap (BonoboUIComponent *uic,
- const char *xml_path,
- char **xpm_data);
-
-
/* Callback for the new appointment command */
static void
new_appointment_cb (BonoboUIComponent *uic, gpointer data, const char *path)
@@ -360,6 +345,41 @@ static BonoboUIVerb verbs [] = {
BONOBO_UI_VERB_END
};
+static void
+set_pixmap (BonoboUIComponent *uic,
+ const char *xml_path,
+ const char *icon)
+{
+ char *path;
+ GdkPixbuf *pixbuf;
+
+ path = g_concat_dir_and_file (EVOLUTION_DATADIR "/images/evolution", icon);
+
+ pixbuf = gdk_pixbuf_new_from_file (path);
+ if (pixbuf == NULL) {
+ g_warning ("Cannot load image -- %s", path);
+ g_free (path);
+ return;
+ }
+
+ bonobo_ui_util_set_pixbuf (uic, xml_path, pixbuf);
+
+ gdk_pixbuf_unref (pixbuf);
+
+ g_free (path);
+}
+
+static void
+update_pixmaps (BonoboUIComponent *uic)
+{
+ set_pixmap (uic, "/Toolbar/New", "buttons/new_appointment.png");
+
+ set_pixmap (uic, "/Toolbar/DayView", "buttons/dayview.xpm");
+ set_pixmap (uic, "/Toolbar/WorkWeekView", "buttons/workweekview.xpm");
+ set_pixmap (uic, "/Toolbar/WeekView", "buttons/weekview.xpm");
+ set_pixmap (uic, "/Toolbar/MonthView", "buttons/monthview.xpm");
+}
+
void
calendar_control_activate (BonoboControl *control,
GnomeCalendar *cal)
@@ -404,33 +424,6 @@ calendar_control_activate (BonoboControl *control,
bonobo_ui_component_thaw (uic, NULL);
}
-
-static void
-update_pixmaps (BonoboUIComponent *uic)
-{
- set_pixmap (uic, "/Toolbar/DayView", dayview_xpm);
- set_pixmap (uic, "/Toolbar/WorkWeekView", workweekview_xpm);
- set_pixmap (uic, "/Toolbar/WeekView", weekview_xpm);
- set_pixmap (uic, "/Toolbar/MonthView", monthview_xpm);
-}
-
-
-static void
-set_pixmap (BonoboUIComponent *uic,
- const char *xml_path,
- char **xpm_data)
-{
- GdkPixbuf *pixbuf;
-
- pixbuf = gdk_pixbuf_new_from_xpm_data ((const char **) xpm_data);
- g_return_if_fail (pixbuf != NULL);
-
- bonobo_ui_util_set_pixbuf (uic, xml_path, pixbuf);
-
- gdk_pixbuf_unref (pixbuf);
-}
-
-
void
calendar_control_deactivate (BonoboControl *control)
{