diff options
Diffstat (limited to 'plugins')
69 files changed, 556 insertions, 1179 deletions
diff --git a/plugins/attachment-reminder/Makefile.am b/plugins/attachment-reminder/Makefile.am index 6d207ef839..8fb3c30ad2 100644 --- a/plugins/attachment-reminder/Makefile.am +++ b/plugins/attachment-reminder/Makefile.am @@ -22,9 +22,13 @@ plugin_LTLIBRARIES = liborg-gnome-evolution-attachment-reminder.la liborg_gnome_evolution_attachment_reminder_la_SOURCES = attachment-reminder.c liborg_gnome_evolution_attachment_reminder_la_LDFLAGS = -module -avoid-version $(NO_UNDEFINED) liborg_gnome_evolution_attachment_reminder_la_LIBADD = \ + $(top_builddir)/composer/libcomposer.la \ + $(top_builddir)/shell/libeshell.la \ + $(top_builddir)/addressbook/gui/contact-editor/libecontacteditor.la \ + $(top_builddir)/addressbook/gui/contact-list-editor/libecontactlisteditor.la \ $(top_builddir)/e-util/libeutil.la \ $(top_builddir)/widgets/misc/libemiscwidgets.la \ - $(top_builddir)/mail/libevolution-mail.la \ + $(top_builddir)/mail/libevolution-mail.la \ $(EVOLUTION_MAIL_LIBS) schemadir = $(GCONF_SCHEMA_FILE_DIR) diff --git a/plugins/audio-inline/Makefile.am b/plugins/audio-inline/Makefile.am index b9ee89f93b..785d53557a 100644 --- a/plugins/audio-inline/Makefile.am +++ b/plugins/audio-inline/Makefile.am @@ -17,10 +17,10 @@ plugin_LTLIBRARIES = liborg-gnome-audio-inline.la liborg_gnome_audio_inline_la_SOURCES = audio-inline.c liborg_gnome_audio_inline_la_LDFLAGS = -module -avoid-version $(NO_UNDEFINED) -liborg_gnome_audio_inline_la_LIBADD = \ - $(GSTREAMER_LIBS) \ - $(EVOLUTION_MAIL_LIBS) \ - $(NO_UNDEFINED_REQUIRED_LIBS) +liborg_gnome_audio_inline_la_LIBADD = \ + $(top_builddir)/mail/libevolution-mail.la \ + $(GSTREAMER_LIBS) \ + $(EVOLUTION_MAIL_LIBS) EXTRA_DIST = org-gnome-audio-inline.eplug.xml diff --git a/plugins/audio-inline/org-gnome-audio-inline.eplug.xml b/plugins/audio-inline/org-gnome-audio-inline.eplug.xml index 14ad280740..1e853df10b 100644 --- a/plugins/audio-inline/org-gnome-audio-inline.eplug.xml +++ b/plugins/audio-inline/org-gnome-audio-inline.eplug.xml @@ -4,33 +4,94 @@ type="shlib" id="org.gnome.evolution.plugin.audioInline" location="@PLUGINDIR@/liborg-gnome-audio-inline@SOEXT@" - _name="Audio Inline"> + _name="Inline Audio"> - <_description>Play audio attachments directly from Evolution.</_description> <author name="Radek Doulík" email="rodo@novell.com"/> + <_description> + Play audio attachments directly in mail messages. + </_description> <hook class="org.gnome.evolution.mail.format:1.0"> <group id="EMFormatHTMLDisplay"> - <item mime_type="audio/ac3" format="org_gnome_audio_inline_format" flags="inline_disposition"/> - <item mime_type="audio/x-ac3" format="org_gnome_audio_inline_format" flags="inline_disposition"/> - <item mime_type="audio/basic" format="org_gnome_audio_inline_format" flags="inline_disposition"/> - <item mime_type="audio/mpeg" format="org_gnome_audio_inline_format" flags="inline_disposition"/> - <item mime_type="audio/x-mpeg" format="org_gnome_audio_inline_format" flags="inline_disposition"/> - <item mime_type="audio/mpeg3" format="org_gnome_audio_inline_format" flags="inline_disposition"/> - <item mime_type="audio/x-mpeg3" format="org_gnome_audio_inline_format" flags="inline_disposition"/> - <item mime_type="audio/mp3" format="org_gnome_audio_inline_format" flags="inline_disposition"/> - <item mime_type="audio/x-mp3" format="org_gnome_audio_inline_format" flags="inline_disposition"/> - <item mime_type="audio/mp4" format="org_gnome_audio_inline_format" flags="inline_disposition"/> - <item mime_type="audio/flac" format="org_gnome_audio_inline_format" flags="inline_disposition"/> - <item mime_type="audio/x-flac" format="org_gnome_audio_inline_format" flags="inline_disposition"/> - <item mime_type="audio/mod" format="org_gnome_audio_inline_format" flags="inline_disposition"/> - <item mime_type="audio/x-mod" format="org_gnome_audio_inline_format" flags="inline_disposition"/> - <item mime_type="audio/x-wav" format="org_gnome_audio_inline_format" flags="inline_disposition"/> - <item mime_type="audio/microsoft-wav" format="org_gnome_audio_inline_format" flags="inline_disposition"/> - <item mime_type="audio/x-wma" format="org_gnome_audio_inline_format" flags="inline_disposition"/> - <item mime_type="audio/x-ms-wma" format="org_gnome_audio_inline_format" flags="inline_disposition"/> - <item mime_type="application/ogg" format="org_gnome_audio_inline_format" flags="inline_disposition"/> - <item mime_type="application/x-ogg" format="org_gnome_audio_inline_format" flags="inline_disposition"/> + <item + mime_type="audio/ac3" + format="org_gnome_audio_inline_format" + flags="inline_disposition"/> + <item + mime_type="audio/x-ac3" + format="org_gnome_audio_inline_format" + flags="inline_disposition"/> + <item + mime_type="audio/basic" + format="org_gnome_audio_inline_format" + flags="inline_disposition"/> + <item + mime_type="audio/mpeg" + format="org_gnome_audio_inline_format" + flags="inline_disposition"/> + <item + mime_type="audio/x-mpeg" + format="org_gnome_audio_inline_format" + flags="inline_disposition"/> + <item + mime_type="audio/mpeg3" + format="org_gnome_audio_inline_format" + flags="inline_disposition"/> + <item + mime_type="audio/x-mpeg3" + format="org_gnome_audio_inline_format" + flags="inline_disposition"/> + <item + mime_type="audio/mp3" + format="org_gnome_audio_inline_format" + flags="inline_disposition"/> + <item + mime_type="audio/x-mp3" + format="org_gnome_audio_inline_format" + flags="inline_disposition"/> + <item + mime_type="audio/mp4" + format="org_gnome_audio_inline_format" + flags="inline_disposition"/> + <item + mime_type="audio/flac" + format="org_gnome_audio_inline_format" + flags="inline_disposition"/> + <item + mime_type="audio/x-flac" + format="org_gnome_audio_inline_format" + flags="inline_disposition"/> + <item + mime_type="audio/mod" + format="org_gnome_audio_inline_format" + flags="inline_disposition"/> + <item + mime_type="audio/x-mod" + format="org_gnome_audio_inline_format" + flags="inline_disposition"/> + <item + mime_type="audio/x-wav" + format="org_gnome_audio_inline_format" + flags="inline_disposition"/> + <item + mime_type="audio/microsoft-wav" + format="org_gnome_audio_inline_format" + flags="inline_disposition"/> + <item + mime_type="audio/x-wma" + format="org_gnome_audio_inline_format" + flags="inline_disposition"/> + <item + mime_type="audio/x-ms-wma" + format="org_gnome_audio_inline_format" + flags="inline_disposition"/> + <item + mime_type="application/ogg" + format="org_gnome_audio_inline_format" + flags="inline_disposition"/> + <item mime_type="application/x-ogg" + format="org_gnome_audio_inline_format" + flags="inline_disposition"/> </group> </hook> diff --git a/plugins/bbdb/Makefile.am b/plugins/bbdb/Makefile.am index 182c1e808b..0a44dc0c26 100644 --- a/plugins/bbdb/Makefile.am +++ b/plugins/bbdb/Makefile.am @@ -21,8 +21,10 @@ liborg_gnome_evolution_bbdb_la_SOURCES = bbdb.c bbdb.h gaimbuddies.c liborg_gnome_evolution_bbdb_la_LDFLAGS = -module -avoid-version $(NO_UNDEFINED) liborg_gnome_evolution_bbdb_la_LIBADD = \ $(top_builddir)/e-util/libeutil.la \ - $(EVOLUTION_ADDRESSBOOK_LIBS) \ - $(NO_UNDEFINED_REQUIRED_LIBS) + $(top_builddir)/composer/libcomposer.la \ + $(top_builddir)/addressbook/gui/contact-editor/libecontacteditor.la \ + $(top_builddir)/addressbook/gui/contact-list-editor/libecontactlisteditor.la \ + $(EVOLUTION_ADDRESSBOOK_LIBS) EXTRA_DIST = org-gnome-evolution-bbdb.eplug.xml diff --git a/plugins/bogo-junk-plugin/Makefile.am b/plugins/bogo-junk-plugin/Makefile.am index f488ddf0f7..00453ef090 100644 --- a/plugins/bogo-junk-plugin/Makefile.am +++ b/plugins/bogo-junk-plugin/Makefile.am @@ -11,8 +11,10 @@ plugin_LTLIBRARIES = liborg-gnome-bogo-junk-plugin.la liborg_gnome_bogo_junk_plugin_la_SOURCES = bf-junk-filter.c liborg_gnome_bogo_junk_plugin_la_LDFLAGS = -module -avoid-version $(NO_UNDEFINED) liborg_gnome_bogo_junk_plugin_la_LIBADD = \ - $(GNOME_PLATFORM_LIBS) \ - $(top_builddir)/e-util/libeutil.la + $(top_builddir)/mail/libevolution-mail.la \ + $(top_builddir)/e-util/libeutil.la \ + $(EVOLUTION_MAIL_LIBS) \ + $(GNOME_PLATFORM_LIBS) schemadir = $(GCONF_SCHEMA_FILE_DIR) schema_in_files = bogo-junk-plugin.schemas.in diff --git a/plugins/calendar-weather/Makefile.am b/plugins/calendar-weather/Makefile.am index f90d26e7e3..8ba5fdf2cd 100644 --- a/plugins/calendar-weather/Makefile.am +++ b/plugins/calendar-weather/Makefile.am @@ -1,5 +1,4 @@ eds_datadir = `pkg-config --variable=privdatadir evolution-data-server-1.2` -weatherdatadir = $(datadir)/evolution/$(BASE_VERSION)/weather AM_CPPFLAGS = \ -I$(top_srcdir) \ @@ -12,15 +11,6 @@ AM_CPPFLAGS = \ @EVO_PLUGIN_RULE@ -weatherdata_DATA = \ - category_weather_cloudy_16.png \ - category_weather_fog_16.png \ - category_weather_partly_cloudy_16.png \ - category_weather_rain_16.png \ - category_weather_snow_16.png \ - category_weather_sun_16.png \ - category_weather_tstorm_16.png - plugin_DATA = org-gnome-calendar-weather.eplug plugin_LTLIBRARIES = liborg-gnome-calendar-weather.la diff --git a/plugins/calendar-weather/calendar-weather.c b/plugins/calendar-weather/calendar-weather.c index cacc7e00fa..22fb4946f3 100644 --- a/plugins/calendar-weather/calendar-weather.c +++ b/plugins/calendar-weather/calendar-weather.c @@ -51,8 +51,8 @@ gint e_plugin_lib_enable (EPluginLib *epl, gint enable) { GList *l; - gboolean found = FALSE; const gchar *tmp; + gint ii; static struct { const gchar *description; @@ -74,24 +74,21 @@ e_plugin_lib_enable (EPluginLib *epl, gint enable) /* Add the categories icons if we don't have them. */ for (l = e_categories_get_list (); l; l = g_list_next (l)) { - if (!strcmp ((const gchar *)l->data, tmp)) { - found = TRUE; - break; - } + if (!strcmp ((const gchar *)l->data, tmp)) + goto exit; } - if (!found) { - gint i; - - for (i = 0; categories[i].description; i++) { - gchar *filename; + for (ii = 0; categories[ii].description; ii++) { + gchar *filename; - filename = e_icon_factory_get_icon_filename (categories[i].icon_name, GTK_ICON_SIZE_MENU); - e_categories_add (_(categories[i].description), NULL, filename, FALSE); - g_free (filename); - } + filename = e_icon_factory_get_icon_filename ( + categories[ii].icon_name, GTK_ICON_SIZE_MENU); + e_categories_add ( + _(categories[ii].description), NULL, filename, FALSE); + g_free (filename); } +exit: return 0; } diff --git a/plugins/calendar-weather/category_weather_cloudy_16.png b/plugins/calendar-weather/category_weather_cloudy_16.png Binary files differdeleted file mode 100644 index ddb3ba7c59..0000000000 --- a/plugins/calendar-weather/category_weather_cloudy_16.png +++ /dev/null diff --git a/plugins/calendar-weather/category_weather_fog_16.png b/plugins/calendar-weather/category_weather_fog_16.png Binary files differdeleted file mode 100644 index 23e4e2f1d4..0000000000 --- a/plugins/calendar-weather/category_weather_fog_16.png +++ /dev/null diff --git a/plugins/calendar-weather/category_weather_partly_cloudy_16.png b/plugins/calendar-weather/category_weather_partly_cloudy_16.png Binary files differdeleted file mode 100644 index 472feaa654..0000000000 --- a/plugins/calendar-weather/category_weather_partly_cloudy_16.png +++ /dev/null diff --git a/plugins/calendar-weather/category_weather_rain_16.png b/plugins/calendar-weather/category_weather_rain_16.png Binary files differdeleted file mode 100644 index e00d5e1c82..0000000000 --- a/plugins/calendar-weather/category_weather_rain_16.png +++ /dev/null diff --git a/plugins/calendar-weather/category_weather_snow_16.png b/plugins/calendar-weather/category_weather_snow_16.png Binary files differdeleted file mode 100644 index 5e95985f5f..0000000000 --- a/plugins/calendar-weather/category_weather_snow_16.png +++ /dev/null diff --git a/plugins/calendar-weather/category_weather_sun_16.png b/plugins/calendar-weather/category_weather_sun_16.png Binary files differdeleted file mode 100644 index 780c61c23c..0000000000 --- a/plugins/calendar-weather/category_weather_sun_16.png +++ /dev/null diff --git a/plugins/calendar-weather/category_weather_tstorm_16.png b/plugins/calendar-weather/category_weather_tstorm_16.png Binary files differdeleted file mode 100644 index b2af092b53..0000000000 --- a/plugins/calendar-weather/category_weather_tstorm_16.png +++ /dev/null diff --git a/plugins/copy-tool/ChangeLog b/plugins/copy-tool/ChangeLog deleted file mode 100644 index 5fab320dc8..0000000000 --- a/plugins/copy-tool/ChangeLog +++ /dev/null @@ -1,67 +0,0 @@ -2008-08-27 Sankar P <psankar@novell.com> - -License Changes - - * copy-tool.c: - -2008-08-12 Bharath Acharya <abharath@novell.com> - - * Makefile.am: Use NO_UNDEFINED. Link with more libraries. To generate - dlls on Windows. - -2007-04-02 Sankar P <psankar@novell.com> - - * Committed on behalf of Gilles Dartiguelongue <dartigug@esiee.fr> - - * org-gnome-copy-tool.eplug.xml: - Cleanup. - Fixes part of #301149 - -2006-05-19 Hiroyuki Ikezoe <poincare@ikezoe.net> - - ** Fixes bug #322771 - * copy-tool.c: Use GtkClipboard instead of GtkInvisible. - -2005-11-30 Simon Zheng <Simon.Zheng@Sun.Com> - - Fix for 322733. - - * copy-tool.c: (ct_selection_get): Removed printf() statement - in order to avoid printing NULL point. - (org_gnome_copy_tool_copy_address): Removed printf() statement. - (ct_selection_clear_event): Removed printf() statement. - -2005-05-11 Not Zed <NotZed@Ximian.com> - - * Makefile.am: added built_sources/cleanfiles. - -2005-05-06 Not Zed <NotZed@Ximian.com> - - * Makefile.am: - * org-gnome-copy-tool.eplug.xml: s/.in/.xml/ & i18n. - -2005-02-24 Björn Torkelsson <torkel@acc.umu.se> - - * org-gnome-copy-tool.eplug.in: Added a . to the end of description. - -2004-11-03 Not Zed <NotZed@Ximian.com> - - * org-gnome-copy-tool.eplug.in: gave it a better name and fixed - the description and author tags. - -2004-11-01 JP Rosevear <jpr@novell.com> - - * Makefile.am: dist .eplug.in file - -2004-10-28 Not Zed <NotZed@Ximian.com> - - * org-gnome-copy-tool.eplug.in: fix folderview popup hook id. - -2004-10-21 JP Rosevear <jpr@novell.com> - - * org-gnome-copy-tool.eplug.in: s/image/icon/ - -2004-10-20 Not Zed <NotZed@Ximian.com> - - * implemented a copy-utils plugin. - diff --git a/plugins/copy-tool/Makefile.am b/plugins/copy-tool/Makefile.am deleted file mode 100644 index 87d1dff454..0000000000 --- a/plugins/copy-tool/Makefile.am +++ /dev/null @@ -1,20 +0,0 @@ -AM_CPPFLAGS = \ - -I$(top_srcdir) \ - $(EVOLUTION_MAIL_CFLAGS) - -@EVO_PLUGIN_RULE@ - -plugin_DATA = org-gnome-copy-tool.eplug -plugin_LTLIBRARIES = liborg-gnome-copy-tool.la - -liborg_gnome_copy_tool_la_SOURCES = copy-tool.c -liborg_gnome_copy_tool_la_LDFLAGS = -module -avoid-version $(NO_UNDEFINED) -liborg_gnome_copy_tool_la_LIBADD = \ - $(EVOLUTION_MAIL_LIBS) - -EXTRA_DIST = org-gnome-copy-tool.eplug.xml - -BUILT_SOURCES = $(plugin_DATA) -CLEANFILES = $(BUILT_SOURCES) - --include $(top_srcdir)/git.mk diff --git a/plugins/copy-tool/copy-tool.c b/plugins/copy-tool/copy-tool.c deleted file mode 100644 index 769bd00431..0000000000 --- a/plugins/copy-tool/copy-tool.c +++ /dev/null @@ -1,71 +0,0 @@ -/* - * - * This program is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 2 of the License, or (at your option) version 3. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General Public - * License along with the program; if not, see <http://www.gnu.org/licenses/> - * - * - * Authors: - * Michael Zucchi <notzed@novell.com> - * - * Copyright (C) 1999-2008 Novell, Inc. (www.novell.com) - * - */ - -/* Add 'copy to clipboard' things to various menu's. - - Uh, so far only to copy mail addresses from mail content */ - -#ifdef HAVE_CONFIG_H -#include "config.h" -#endif - -#include <glib/gi18n-lib.h> -#include <string.h> - -#include "mail/em-popup.h" - -#include <gtk/gtk.h> - -#include "camel/camel-internet-address.h" -#include "camel/camel-url.h" - -void org_gnome_copy_tool_copy_address(gpointer ep, EMPopupTargetURI *t); - -void -org_gnome_copy_tool_copy_address(gpointer ep, EMPopupTargetURI *t) -{ - if (t->uri) { - CamelInternetAddress *cia = camel_internet_address_new(); - CamelURL *curl; - GtkClipboard *clipboard; - gchar *addr; - const gchar *tmp; - - curl = camel_url_new(t->uri, NULL); - camel_address_decode((CamelAddress *)cia, curl->path); - /* should it perhaps use address format? */ - addr = camel_address_encode((CamelAddress *)cia); - tmp = addr && addr[0] ? addr : t->uri + 7; - - clipboard = gtk_clipboard_get (GDK_SELECTION_PRIMARY); - - gtk_clipboard_set_text (clipboard, tmp, strlen (tmp)); - - clipboard = gtk_clipboard_get (GDK_SELECTION_CLIPBOARD); - gtk_clipboard_set_text (clipboard, tmp, strlen (tmp)); - - g_free(addr); - camel_url_free(curl); - camel_object_unref(cia); - } -} diff --git a/plugins/copy-tool/org-gnome-copy-tool.eplug.xml b/plugins/copy-tool/org-gnome-copy-tool.eplug.xml deleted file mode 100644 index 3b6a30752d..0000000000 --- a/plugins/copy-tool/org-gnome-copy-tool.eplug.xml +++ /dev/null @@ -1,24 +0,0 @@ -<?xml version="1.0"?> -<e-plugin-list> - <e-plugin - type="shlib" - id="org.gnome.evolution.plugin.copyTool" - location="@PLUGINDIR@/liborg-gnome-copy-tool@SOEXT@" - _name="Copy Tool"> - <_description>Copy things to the clipboard.</_description> - <author name="Michael Zucchi" email="notzed@ximian.com"/> - - <!-- hook into the uri popup menu --> - <hook class="org.gnome.evolution.mail.popup:1.0"> - <menu id="org.gnome.evolution.mail.folderview.popup" target="uri"> - <item - type="item" - path="80.test" - icon="gtk-copy" - _label="Copy _Email Address" - visible="mailto" - activate="org_gnome_copy_tool_copy_address"/> - </menu> - </hook> - </e-plugin> -</e-plugin-list> diff --git a/plugins/default-mailer/Makefile.am b/plugins/default-mailer/Makefile.am index 94d3436f0e..ccb8071a99 100644 --- a/plugins/default-mailer/Makefile.am +++ b/plugins/default-mailer/Makefile.am @@ -1,6 +1,6 @@ AM_CPPFLAGS = \ -I$(top_srcdir) \ - -I$(top_builddir)/shell \ + -I$(top_srcdir)/widgets \ $(EVOLUTION_MAIL_CFLAGS) @EVO_PLUGIN_RULE@ diff --git a/plugins/email-custom-header/Makefile.am b/plugins/email-custom-header/Makefile.am index efd46a5435..2ab28fad67 100644 --- a/plugins/email-custom-header/Makefile.am +++ b/plugins/email-custom-header/Makefile.am @@ -23,8 +23,7 @@ liborg_gnome_email_custom_header_la_LIBADD = \ $(top_builddir)/e-util/libeutil.la \ $(top_builddir)/widgets/misc/libemiscwidgets.la \ $(top_builddir)/mail/libevolution-mail.la \ - $(EVOLUTION_MAIL_LIBS) \ - $(NO_UNDEFINED_REQUIRED_LIBS) + $(EVOLUTION_MAIL_LIBS) liborg_gnome_email_custom_header_la_LDFLAGS = -module -avoid-version $(NO_UNDEFINED) diff --git a/plugins/email-custom-header/email-custom-header.c b/plugins/email-custom-header/email-custom-header.c index 026a4dc5e1..e160e706c8 100644 --- a/plugins/email-custom-header/email-custom-header.c +++ b/plugins/email-custom-header/email-custom-header.c @@ -550,13 +550,13 @@ destroy_compo_data (gpointer data) static void action_email_custom_header_cb (GtkAction *action, EMsgComposer *composer) { - GtkUIManager *manager; + GtkUIManager *ui_manager; GtkWidget *menuitem; CustomHeaderOptionsDialog *dialog = NULL; EmailCustomHeaderWindow *new_email_custom_header_window = NULL; - manager = gtkhtml_editor_get_ui_manager (GTKHTML_EDITOR (composer)); - menuitem = gtk_ui_manager_get_widget (manager, "/main-menu/insert-menu/insert-menu-top/Custom Header"); + ui_manager = gtkhtml_editor_get_ui_manager (GTKHTML_EDITOR (composer)); + menuitem = gtk_ui_manager_get_widget (ui_manager, "/main-menu/insert-menu/insert-menu-top/Custom Header"); new_email_custom_header_window = g_object_get_data ((GObject *) composer, "compowindow"); diff --git a/plugins/external-editor/Makefile.am b/plugins/external-editor/Makefile.am index 05457efd17..8c47bca60c 100644 --- a/plugins/external-editor/Makefile.am +++ b/plugins/external-editor/Makefile.am @@ -35,8 +35,15 @@ liborg_gnome_external_editor_la_SOURCES = \ liborg_gnome_external_editor_la_LDFLAGS = \ -module -avoid-version $(NO_UNDEFINED) -liborg_gnome_external_editor_la_LIBADD = \ - $(NO_UNDEFINED_REQUIRED_LIBS) +liborg_gnome_external_editor_la_LIBADD = \ + $(top_builddir)/e-util/libeutil.la \ + $(top_builddir)/composer/libcomposer.la \ + $(top_builddir)/shell/libeshell.la \ + $(top_builddir)/addressbook/gui/contact-editor/libecontacteditor.la \ + $(top_builddir)/addressbook/gui/contact-list-editor/libecontactlisteditor.la \ + $(top_builddir)/mail/libevolution-mail.la \ + $(EVOLUTION_MAIL_LIBS) \ + $(GNOME_PLATFORM_LIBS) schemadir = $(GCONF_SCHEMA_FILE_DIR) schema_in_files = apps-evolution-external-editor.schemas.in diff --git a/plugins/face/Makefile.am b/plugins/face/Makefile.am index 86a522a2d0..07cbb8199d 100644 --- a/plugins/face/Makefile.am +++ b/plugins/face/Makefile.am @@ -22,8 +22,7 @@ liborg_gnome_face_la_LIBADD = \ $(top_builddir)/e-util/libeutil.la \ $(top_builddir)/widgets/misc/libemiscwidgets.la \ $(top_builddir)/mail/libevolution-mail.la \ - $(EVOLUTION_MAIL_LIBS) \ - $(NO_UNDEFINED_REQUIRED_LIBS) + $(EVOLUTION_MAIL_LIBS) liborg_gnome_face_la_LDFLAGS = -module -avoid-version $(NO_UNDEFINED) diff --git a/plugins/folder-unsubscribe/ChangeLog b/plugins/folder-unsubscribe/ChangeLog deleted file mode 100644 index fd8eb19b43..0000000000 --- a/plugins/folder-unsubscribe/ChangeLog +++ /dev/null @@ -1,58 +0,0 @@ -2008-09-23 Matthew Barnes <mbarnes@redhat.com> - - ** Fixes part of bug #552850 - - * org-gnome-mail-folder-unsubscribe.eplug.xml: - Prefer the term "side bar" over "folder tree". - -2008-08-27 Sankar P <psankar@novell.com> - -License Changes - - * folder-unsubscribe.c: - -2008-08-12 Bharath Acharya <abharath@novell.com> - - * Makefile.am: Use NO_UNDEFINED. Link with more libraries. To generate - dlls on Windows. - -2007-12-20 Matthew Barnes <mbarnes@redhat.com> - - ** Fixes part of bug #362638 - - * folder-unsubscribe.c: - Use the new MailMsg API for messages. - -2007-11-18 Gilles Dartiguelongue <gdartigu@svn.gnome.org> - - ** Fix bug #495875 - - * org-gnome-mail-folder-unsubscribe.eplug.xml: - right click menu reordering - -2007-04-02 Sankar P <psankar@novell.com> - - * Committed on behalf of Gilles Dartiguelongue <dartigug@esiee.fr> - - * org-gnome-mail-folder-unsubscribe.eplug.xml: - Cleanup. - Fixes part of #301149 - - -2005-05-06 Not Zed <NotZed@Ximian.com> - - * Makefile.am: - * org-gnome-mail-folder-unsubscribe.eplug.xml: s/.in/.xml/ & i18n. - -2005-02-24 Björn Torkelsson <torkel@acc.umu.se> - - * org-gnome-mail-folder-unsubscribe.eplug.in: Updated description. - -2004-11-01 JP Rosevear <jpr@novell.com> - - * Makefile.am: dist .eplug.in file - -2004-10-28 Not Zed <NotZed@Ximian.com> - - * org-gnome-mail-folder-unsubscribe.eplug.in: fix hook id - diff --git a/plugins/folder-unsubscribe/Makefile.am b/plugins/folder-unsubscribe/Makefile.am deleted file mode 100644 index 242d911ed0..0000000000 --- a/plugins/folder-unsubscribe/Makefile.am +++ /dev/null @@ -1,18 +0,0 @@ -AM_CPPFLAGS = \ - -I$(top_srcdir) \ - $(EVOLUTION_MAIL_CFLAGS) - -@EVO_PLUGIN_RULE@ - -plugin_DATA = org-gnome-mail-folder-unsubscribe.eplug -plugin_LTLIBRARIES = liborg-gnome-mail-folder-unsubscribe.la - -liborg_gnome_mail_folder_unsubscribe_la_SOURCES = folder-unsubscribe.c -liborg_gnome_mail_folder_unsubscribe_la_LDFLAGS = -module -avoid-version $(NO_UNDEFINED) -liborg_gnome_mail_folder_unsubscribe_la_LIBADD = \ - $(top_builddir)/mail/libevolution-mail.la \ - $(EVOLUTION_MAIL_LIBS) - -EXTRA_DIST = org-gnome-mail-folder-unsubscribe.eplug.xml - --include $(top_srcdir)/git.mk diff --git a/plugins/folder-unsubscribe/folder-unsubscribe.c b/plugins/folder-unsubscribe/folder-unsubscribe.c deleted file mode 100644 index 7005ac7feb..0000000000 --- a/plugins/folder-unsubscribe/folder-unsubscribe.c +++ /dev/null @@ -1,110 +0,0 @@ -/* - * - * This program is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 2 of the License, or (at your option) version 3. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General Public - * License along with the program; if not, see <http://www.gnu.org/licenses/> - * - * - * Authors: - * Jeffrey Stedfast <fejj@novell.com> - * - * Copyright (C) 1999-2008 Novell, Inc. (www.novell.com) - * - */ - -#ifdef HAVE_CONFIG_H -#include <config.h> -#endif - -#include <glib.h> -#include <glib/gi18n.h> - -#include <string.h> - -#include <camel/camel-session.h> -#include <camel/camel-store.h> -#include <camel/camel-url.h> - -#include "mail/em-popup.h" -#include "mail/mail-mt.h" -#include "mail/mail-ops.h" - - -void org_gnome_mail_folder_unsubscribe (EPlugin *plug, EMPopupTargetFolder *target); - - - -struct _folder_unsub_t { - MailMsg base; - - gchar *uri; -}; - -static gchar * -folder_unsubscribe_desc (struct _folder_unsub_t *msg) -{ - return g_strdup_printf ( - _("Unsubscribing from folder \"%s\""), msg->uri); -} - -extern CamelSession *session; - -static void -folder_unsubscribe_exec (struct _folder_unsub_t *msg) -{ - const gchar *path = NULL; - CamelStore *store; - CamelURL *url; - - if (!(store = camel_session_get_store (session, msg->uri, &msg->base.ex))) - return; - - url = camel_url_new (msg->uri, NULL); - if (((CamelService *) store)->provider->url_flags & CAMEL_URL_FRAGMENT_IS_PATH) - path = url->fragment; - else if (url->path && url->path[0]) - path = url->path + 1; - - if (path != NULL) - camel_store_unsubscribe_folder (store, path, &msg->base.ex); - - camel_url_free (url); -} - -static void -folder_unsubscribe_free (struct _folder_unsub_t *msg) -{ - g_free (msg->uri); -} - -static MailMsgInfo unsubscribe_info = { - sizeof (struct _folder_unsub_t), - (MailMsgDescFunc) folder_unsubscribe_desc, - (MailMsgExecFunc) folder_unsubscribe_exec, - (MailMsgDoneFunc) NULL, - (MailMsgFreeFunc) folder_unsubscribe_free -}; - - -void -org_gnome_mail_folder_unsubscribe (EPlugin *plug, EMPopupTargetFolder *target) -{ - struct _folder_unsub_t *unsub; - - if (target->uri == NULL) - return; - - unsub = mail_msg_new (&unsubscribe_info); - unsub->uri = g_strdup (target->uri); - - mail_msg_unordered_push (unsub); -} diff --git a/plugins/folder-unsubscribe/org-gnome-mail-folder-unsubscribe.eplug.xml b/plugins/folder-unsubscribe/org-gnome-mail-folder-unsubscribe.eplug.xml deleted file mode 100644 index 24271fa8af..0000000000 --- a/plugins/folder-unsubscribe/org-gnome-mail-folder-unsubscribe.eplug.xml +++ /dev/null @@ -1,20 +0,0 @@ -<?xml version="1.0"?> -<e-plugin-list> - <e-plugin - id="org.gnome.evolution.mail.folder.unsubscribe" - type="shlib" - domain="@GETTEXT_PACKAGE@" - _name="Unsubscribe Folders" - location="@PLUGINDIR@/liborg-gnome-mail-folder-unsubscribe@SOEXT@"> - <_description>Unsubscribe from an IMAP folder by right-clicking on it in the folder tree.</_description> - <author name="Jeffrey Stedfast" email="fejj@novell.com"/> - - <hook class="org.gnome.evolution.mail.popup:1.0"> - <menu id="org.gnome.evolution.mail.foldertree.popup" target="folder"> - <item type="item" path="30.emc.03" _label="_Unsubscribe" - activate="org_gnome_mail_folder_unsubscribe" - enable="delete" visible="delete"/> - </menu> - </hook> - </e-plugin> -</e-plugin-list> diff --git a/plugins/groupwise-features/Makefile.am b/plugins/groupwise-features/Makefile.am index 1af407dcd7..41b3f91170 100644 --- a/plugins/groupwise-features/Makefile.am +++ b/plugins/groupwise-features/Makefile.am @@ -45,7 +45,6 @@ liborg_gnome_groupwise_features_la_LIBADD= \ $(top_builddir)/calendar/gui/libevolution-calendar.la \ $(top_builddir)/widgets/misc/libemiscwidgets.la \ $(top_builddir)/filter/libfilter.la \ - $(NO_UNDEFINED_REQUIRED_LIBS) \ $(EVOLUTION_CALENDAR_LIBS) \ $(EVOLUTION_MAIL_LIBS) \ $(CAMEL_GROUPWISE_LIBS) diff --git a/plugins/groupwise-features/install-shared.c b/plugins/groupwise-features/install-shared.c index 67b1b5bdee..d770afa2d4 100644 --- a/plugins/groupwise-features/install-shared.c +++ b/plugins/groupwise-features/install-shared.c @@ -166,6 +166,7 @@ accept_clicked(GnomeDruidPage *page, GtkWidget *druid, CamelMimeMessage *msg) accept_data = g_new0(struct AcceptData, 1); model = mail_component_peek_tree_model (NULL); folder_tree = (EMFolderTree *) em_folder_tree_new_with_model (model); + dialog = em_folder_selector_create_new (folder_tree, 0, _("Create folder"), _("Specify where to create the folder:")); uri = em_folder_tree_get_selected_uri(folder_tree); em_folder_selector_set_selected ((EMFolderSelector *) dialog, uri); diff --git a/plugins/groupwise-features/proxy-login.c b/plugins/groupwise-features/proxy-login.c index d48afaa452..20d477a345 100644 --- a/plugins/groupwise-features/proxy-login.c +++ b/plugins/groupwise-features/proxy-login.c @@ -43,6 +43,7 @@ #include <e-util/e-error.h> #include <e-util/e-icon-factory.h> #include <e-util/e-util-private.h> +#include <e-util/e-account-utils.h> #include <e-gw-container.h> #include <e-gw-connection.h> @@ -304,7 +305,7 @@ proxy_login_cb (GtkDialog *dialog, gint state) static void proxy_soap_login (gchar *email) { - EAccountList *accounts = mail_config_get_accounts(); + EAccountList *accounts = e_get_account_list (); EAccount *srcAccount; EAccount *dstAccount; EGwConnection *proxy_cnc, *cnc; diff --git a/plugins/groupwise-features/share-folder-common.c b/plugins/groupwise-features/share-folder-common.c index 50bb6fccf3..2f50f3a0cb 100644 --- a/plugins/groupwise-features/share-folder-common.c +++ b/plugins/groupwise-features/share-folder-common.c @@ -383,6 +383,7 @@ create_shared_folder(EPopup *ep, EPopupItem *p, gpointer data) model = mail_component_peek_tree_model (mail_component_peek ()); folder_tree = (EMFolderTree *) em_folder_tree_new_with_model (model); + dialog = em_folder_selector_create_new (folder_tree, 0, _("Create folder"), _("Specify where to create the folder:")); uri = em_folder_tree_get_selected_uri(folder_tree); em_folder_selector_set_selected ((EMFolderSelector *) dialog, uri); diff --git a/plugins/imap-features/Makefile.am b/plugins/imap-features/Makefile.am index c539a70cb2..d21841f7c7 100644 --- a/plugins/imap-features/Makefile.am +++ b/plugins/imap-features/Makefile.am @@ -18,9 +18,10 @@ plugin_LTLIBRARIES = liborg-gnome-imap-features.la liborg_gnome_imap_features_la_SOURCES = \ imap-headers.c -liborg_gnome_imap_features_la_LIBADD= \ - $(NO_UNDEFINED_REQUIRED_LIBS) \ - $(EVOLUTION_MAIL_LIBS) +liborg_gnome_imap_features_la_LIBADD= \ + $(top_builddir)/e-util/libeutil.la \ + $(top_builddir)/mail/libevolution-mail.la \ + $(EVOLUTION_MAIL_LIBS) liborg_gnome_imap_features_la_LDFLAGS = -module -avoid-version $(NO_UNDEFINED) diff --git a/plugins/imap-features/imap-headers.c b/plugins/imap-features/imap-headers.c index ea969b2b3a..91ef049003 100644 --- a/plugins/imap-features/imap-headers.c +++ b/plugins/imap-features/imap-headers.c @@ -31,8 +31,7 @@ #include <gtk/gtk.h> -#include <libedataserver/e-account.h> -#include <libedataserver/e-account-list.h> +#include "e-util/e-account-utils.h" #include <camel/camel-url.h> #include <camel/camel-exception.h> @@ -84,7 +83,7 @@ imap_headers_commit (EPlugin *efp, EConfigHookItemFactoryData *data) if (g_str_has_prefix (account->source->url, "imap://") || (use_imap && g_str_has_prefix (account->source->url, "groupwise://"))) { EAccount *temp = NULL; - EAccountList *accounts = mail_config_get_accounts (); + EAccountList *accounts = e_get_account_list (); CamelURL *url = NULL; CamelException ex; GtkTreeModel *model; diff --git a/plugins/ipod-sync/Makefile.am b/plugins/ipod-sync/Makefile.am index a55fc83a4e..74522a41a3 100644 --- a/plugins/ipod-sync/Makefile.am +++ b/plugins/ipod-sync/Makefile.am @@ -17,7 +17,7 @@ liborg_gnome_ipod_sync_evolution_la_SOURCES = \ format-handler.h \ evolution-ipod-sync.h -liborg_gnome_ipod_sync_evolution_la_LDFLAGS = -module -avoid-version +liborg_gnome_ipod_sync_evolution_la_LDFLAGS = -module -avoid-version $(NO_UNDEFINED) liborg_gnome_ipod_sync_evolution_la_LIBADD = \ $(EVOLUTION_CALENDAR_LIBS) diff --git a/plugins/mail-account-disable/ChangeLog b/plugins/mail-account-disable/ChangeLog deleted file mode 100644 index 86dc9a4897..0000000000 --- a/plugins/mail-account-disable/ChangeLog +++ /dev/null @@ -1,62 +0,0 @@ -2008-10-03 Sankar P <psankar@novell.com> - -License Changes - - * mail-account-disable.c: - -2007-11-18 Gilles Dartiguelongue <gdartigu@svn.gnome.org> - - ** Fix bug #495875 - - * mail-account-disable.c: - right click menu reordering - -2007-04-02 Sankar P <psankar@novell.com> - - * Committed on behalf of Gilles Dartiguelongue <dartigug@esiee.fr> - - * org-gnome-mail-account-disable.eplug.xml: - Cleanup. - Fixes part of #301149 - -2006-08-21 Matthew Barnes <mbarnes@redhat.com> - - * mail-account-disable.c: - "Disable" did not work for "On This Computer" - fixes bug 350901. - -2006-01-06 Simon Zheng <simon.zheng@sun.com> - - * mail-account-disable.c: - use libedataserver/e-account-list.h instead of e-util/e-account-list.h. - use libedataserver/e-account.h instead of e-util/e-account.h. - -2005-12-12 Harish Krishnaswamy <kharish@novell.com> - - * Makefile.am: Fix make-clean issues. - -2005-08-23 Not Zed <NotZed@Ximian.com> - - * Makefile.am: Remove the special case for win32, its a bug on all - platforms, silly. - - * mail-account-disable.c (mail_account_disable): make signature - match usage. - -2005-07-13 Tor Lillqvist <tml@novell.com> - - * Makefile.am (INCLUDES): Remove duplicated line. - (LDFLAGS): Use NO_UNDEFINED. - (LIBADD): Link with the required libraries, but let's do it only - on Win32. - - * org-gnome-mail-account-disable.eplug.xml: Use SOEXT. - -2005-07-12 Vivek Jain <jvivek@novell.com> - - have a ChangeLog and transfer the changelog entry from the main - ChangeLog - (2005-07-10 Shreyas Srinivasan <sshreyas@novell.com>) - - * plugins/mail-account-disable/*: Plugin to add Disable/ Proxy - Logout to a store menu on right click. - diff --git a/plugins/mail-account-disable/Makefile.am b/plugins/mail-account-disable/Makefile.am deleted file mode 100644 index 7793f851d7..0000000000 --- a/plugins/mail-account-disable/Makefile.am +++ /dev/null @@ -1,24 +0,0 @@ -AM_CPPFLAGS = \ - -I$(top_srcdir) \ - -I$(top_srcdir)/widgets \ - -I$(top_builddir)/mail \ - $(EVOLUTION_MAIL_CFLAGS) \ - -DEVOLUTION_GLADEDIR=\""$(gladedir)"\" - -@EVO_PLUGIN_RULE@ - -plugin_DATA = org-gnome-mail-account-disable.eplug -plugin_LTLIBRARIES = libmail-account-disable.la - -libmail_account_disable_la_SOURCES = mail-account-disable.c -libmail_account_disable_la_LDFLAGS = -module -avoid-version $(NO_UNDEFINED) -libmail_account_disable_la_LIBADD = $(top_builddir)/e-util/libeutil.la \ - $(top_builddir)/mail/libevolution-mail.la \ - $(EVOLUTION_MAIL_LIBS) - -EXTRA_DIST = org-gnome-mail-account-disable.eplug.xml - -BUILT_SOURCES = $(plugin_DATA) -CLEANFILES = $(BUILT_SOURCES) - --include $(top_srcdir)/git.mk diff --git a/plugins/mail-account-disable/mail-account-disable.c b/plugins/mail-account-disable/mail-account-disable.c deleted file mode 100644 index aee3043682..0000000000 --- a/plugins/mail-account-disable/mail-account-disable.c +++ /dev/null @@ -1,100 +0,0 @@ -/* - * This program is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 2 of the License, or (at your option) version 3. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General Public - * License along with the program; if not, see <http://www.gnu.org/licenses/> - * - * - * Authors: - * Shreyas Srinivasan <sshreyas@novell.com> - * - * Copyright (C) 1999-2008 Novell, Inc. (www.novell.com) - * - */ - -#ifdef HAVE_CONFIG_H -#include <config.h> -#endif - -#include <glib.h> -#include <glib/gi18n.h> -#include <string.h> -#include <mail/mail-component.h> -#include <mail/em-folder-selector.h> -#include <mail/em-popup.h> -#include <mail/em-account-editor.h> -#include <mail/mail-config.h> -#include <libedataserver/e-account.h> -#include <libedataserver/e-account-list.h> - -#define ACCOUNT_DISABLE 0 -#define PROXY_LOGOUT 1 - -void mail_account_disable (EPopup *ep, EPopupItem *p, gpointer data); -void org_gnome_create_mail_account_disable (EPlugin *ep, EMPopupTargetFolder *t); - -static EPopupItem popup_items[] = { - { E_POPUP_ITEM, (gchar *) "40.emc.04", (gchar *) N_("_Disable"), mail_account_disable, NULL, NULL, 0, EM_POPUP_FOLDER_STORE }, - { E_POPUP_ITEM, (gchar *) "40.emc.04", (gchar *) N_("Proxy _Logout"), mail_account_disable, NULL, NULL, 0, EM_POPUP_FOLDER_STORE } -}; - -static void -popup_free (EPopup *ep, GSList *items, gpointer data) -{ - g_slist_free (items); -} - -void -mail_account_disable (EPopup *ep, EPopupItem *p, gpointer data) -{ - MailComponent *component; - EAccount *account = data; - - g_assert (account != NULL); - - component = mail_component_peek (); - - if (mail_config_has_proxies (account)) - mail_config_remove_account_proxies (account); - - account->enabled = !account->enabled; - e_account_list_change (mail_config_get_accounts (), account); - mail_component_remove_store_by_uri (component, account->source->url); - - if (account->parent_uid) - mail_config_remove_account (account); - - mail_config_save_accounts(); -} - -void -org_gnome_create_mail_account_disable (EPlugin *ep, EMPopupTargetFolder *t) -{ - EAccount *account; - GSList *menus = NULL; - - account = mail_config_get_account_by_source_url (t->uri); - - if (account == NULL) - return; - - if (g_strrstr (t->uri,"groupwise://") && account->parent_uid) { - popup_items[PROXY_LOGOUT].label = _(popup_items [PROXY_LOGOUT].label); - menus = g_slist_prepend (menus, &popup_items [PROXY_LOGOUT]); - } - else { - popup_items[ACCOUNT_DISABLE].label = _(popup_items [ACCOUNT_DISABLE].label); - menus = g_slist_prepend (menus, &popup_items [ACCOUNT_DISABLE]); - } - - e_popup_add_items (t->target.popup, menus, NULL, popup_free, account); -} - diff --git a/plugins/mail-account-disable/org-gnome-mail-account-disable.eplug.xml b/plugins/mail-account-disable/org-gnome-mail-account-disable.eplug.xml deleted file mode 100644 index 535a87a314..0000000000 --- a/plugins/mail-account-disable/org-gnome-mail-account-disable.eplug.xml +++ /dev/null @@ -1,18 +0,0 @@ -<?xml version="1.0"?> -<e-plugin-list> - <e-plugin - id="org.gnome.mail.account.disable" - type="shlib" - domain="@GETTEXT_PACKAGE@" - _name="Disable Account" - location="@PLUGINDIR@/libmail-account-disable@SOEXT@"> - <_description>Disable an account by right-clicking on it in the folder tree.</_description> - <author name="Shreyas Srinivasan" email="sshreyas@novell.com"/> - - <hook class="org.gnome.evolution.mail.popup:1.0"> - <menu id="org.gnome.evolution.mail.foldertree.popup" target="folder" - factory="org_gnome_create_mail_account_disable"> - </menu> - </hook> - </e-plugin> -</e-plugin-list> diff --git a/plugins/mail-notification/Makefile.am b/plugins/mail-notification/Makefile.am index ec91117eb8..f1f121f6b5 100644 --- a/plugins/mail-notification/Makefile.am +++ b/plugins/mail-notification/Makefile.am @@ -25,9 +25,11 @@ plugin_LTLIBRARIES = liborg-gnome-mail-notification.la liborg_gnome_mail_notification_la_SOURCES = mail-notification.c liborg_gnome_mail_notification_la_LDFLAGS = \ -module -avoid-version $(NO_UNDEFINED) -liborg_gnome_mail_notification_la_LIBADD = \ - $(LIBNOTIFY_LIBS) \ - $(NO_UNDEFINED_REQUIRED_LIBS) +liborg_gnome_mail_notification_la_LIBADD = \ + $(LIBNOTIFY_LIBS) \ + $(top_builddir)/e-util/libeutil.la \ + $(top_builddir)/mail/libevolution-mail.la \ + $(GNOME_PLATFORM_LIBS) if ENABLE_DBUS liborg_gnome_mail_notification_la_LDFLAGS += $(NMN_LIBS) diff --git a/plugins/mail-to-task/Makefile.am b/plugins/mail-to-task/Makefile.am index dc63da7a8c..b7eb5ed749 100644 --- a/plugins/mail-to-task/Makefile.am +++ b/plugins/mail-to-task/Makefile.am @@ -6,7 +6,7 @@ AM_CPPFLAGS = \ @EVO_PLUGIN_RULE@ -plugin_DATA = org-gnome-mail-to-task.eplug org-gnome-mail-to-task.xml +plugin_DATA = org-gnome-mail-to-task.eplug plugin_LTLIBRARIES = liborg-gnome-mail-to-task.la liborg_gnome_mail_to_task_la_SOURCES = mail-to-task.c @@ -18,8 +18,7 @@ liborg_gnome_mail_to_task_la_LIBADD = \ $(EVOLUTION_CALENDAR_LIBS) \ $(EVOLUTION_MAIL_LIBS) -EXTRA_DIST = org-gnome-mail-to-task.eplug.xml \ - org-gnome-mail-to-task.xml +EXTRA_DIST = org-gnome-mail-to-task.eplug.xml BUILT_SOURCES = org-gnome-mail-to-task.eplug CLEANFILES = $(BUILT_SOURCES) diff --git a/plugins/mail-to-task/mail-to-task.c b/plugins/mail-to-task/mail-to-task.c index e7fa727ff1..3613694985 100644 --- a/plugins/mail-to-task/mail-to-task.c +++ b/plugins/mail-to-task/mail-to-task.c @@ -32,10 +32,12 @@ #include <string.h> #include <stdio.h> +#include <gtkhtml/gtkhtml.h> #include <gconf/gconf-client.h> #include <libecal/e-cal.h> #include <libedataserver/e-account.h> #include <libedataserverui/e-source-selector-dialog.h> + #include <camel/camel-folder.h> #include <camel/camel-medium.h> #include <camel/camel-mime-message.h> @@ -43,15 +45,30 @@ #include <camel/camel-stream.h> #include <camel/camel-stream-mem.h> #include <camel/camel-utf8.h> -#include "mail/em-menu.h" -#include "mail/em-popup.h" -#include "mail/em-utils.h" -#include "mail/em-folder-view.h" -#include "mail/em-format-html.h" -#include "mail/mail-config.h" -#include "e-util/e-dialog-utils.h" -#include <gtkhtml/gtkhtml.h> + +#include <mail/em-menu.h> +#include <mail/em-popup.h> +#include <mail/em-utils.h> +#include <mail/em-format-html.h> +#include <mail/mail-config.h> +#include <e-util/e-account-utils.h> +#include <e-util/e-dialog-utils.h> #include <calendar/common/authentication.h> +#include <misc/e-popup-action.h> +#include <shell/e-shell-view.h> +#include <shell/e-shell-window-actions.h> + +#define E_SHELL_WINDOW_ACTION_CONVERT_TO_EVENT(window) \ + E_SHELL_WINDOW_ACTION ((window), "mail-convert-to-event") +#define E_SHELL_WINDOW_ACTION_CONVERT_TO_MEETING(window) \ + E_SHELL_WINDOW_ACTION ((window), "mail-convert-to-meeting") +#define E_SHELL_WINDOW_ACTION_CONVERT_TO_MEMO(window) \ + E_SHELL_WINDOW_ACTION ((window), "mail-convert-to-memo") +#define E_SHELL_WINDOW_ACTION_CONVERT_TO_TASK(window) \ + E_SHELL_WINDOW_ACTION ((window), "mail-convert-to-task") + +gboolean e_plugin_ui_init (GtkUIManager *ui_manager, + EShellView *shell_view); static gchar * clean_name(const guchar *s) @@ -214,7 +231,7 @@ set_organizer (ECalComponent *comp) ECalComponentOrganizer organizer = {NULL, NULL, NULL, NULL}; gchar *res; - account = mail_config_get_default_account (); + account = e_get_default_account (); if (!account) return NULL; @@ -476,12 +493,6 @@ do_mail_to_event (AsyncData *data) return TRUE; } -static void -copy_uids (gchar *uid, GPtrArray *uid_array) -{ - g_ptr_array_add (uid_array, g_strdup (uid)); -} - static gboolean text_contains_nonwhitespace (const gchar *text, gint len) { @@ -509,47 +520,51 @@ text_contains_nonwhitespace (const gchar *text, gint len) /* should be freed with g_free after done with it */ static gchar * -get_selected_text (EMFolderView *emfv) +get_selected_text (EMailReader *reader) { + EMFormatHTMLDisplay *html_display; + GtkHTML *html; gchar *text = NULL; gint len; - if (!emfv || !emfv->preview || !gtk_html_command (((EMFormatHTML *)emfv->preview)->html, "is-selection-active")) + html_display = e_mail_reader_get_html_display (reader); + html = EM_FORMAT_HTML (html_display)->html; + + if (!gtk_html_command (html, "is-selection-active")) return NULL; - if (gtk_html_command (((EMFormatHTML *)emfv->preview)->html, "is-selection-active") - && (text = gtk_html_get_selection_plain_text (((EMFormatHTML *)emfv->preview)->html, &len)) - && len && text && text[0] && text_contains_nonwhitespace (text, len)) { - /* selection is ok, so use it as returned from gtkhtml widget */ - } else { + text = gtk_html_get_selection_plain_text (html, &len); + + if (text == NULL || !text_contains_nonwhitespace (text, len)) { g_free (text); - text = NULL; + return NULL; } return text; } static void -mail_to_event (ECalSourceType source_type, gboolean with_attendees, GPtrArray *uids, CamelFolder *folder, EMFolderView *emfv) +mail_to_event (ECalSourceType source_type, + gboolean with_attendees, + EShellView *shell_view) { - GPtrArray *uid_array = NULL; + EShellContent *shell_content; + EMailReader *reader; + MessageList *message_list; + CamelFolder *folder; + GPtrArray *selected; ESourceList *source_list = NULL; gboolean done = FALSE; GSList *groups, *p; ESource *source = NULL; GError *error = NULL; - g_return_if_fail (uids != NULL); - g_return_if_fail (folder != NULL); - g_return_if_fail (emfv != NULL); + shell_content = e_shell_view_get_shell_content (shell_view); - if (uids->len > 0) { - uid_array = g_ptr_array_new (); - g_ptr_array_foreach (uids, (GFunc)copy_uids, (gpointer) uid_array); - } else { - /* nothing selected */ - return; - } + reader = E_MAIL_READER (shell_content); + message_list = e_mail_reader_get_message_list (reader); + selected = message_list_get_selected (message_list); + folder = message_list->folder; if (!e_cal_get_sources (&source_list, source_type, &error)) { e_notice (NULL, GTK_MESSAGE_ERROR, _("Cannot get source list. %s"), error ? error->message : _("Unknown error.")); @@ -615,11 +630,11 @@ mail_to_event (ECalSourceType source_type, gboolean with_attendees, GPtrArray *u data = g_new0 (AsyncData, 1); data->client = client; data->folder = folder; - data->uids = uid_array; + data->uids = selected; data->with_attendees = with_attendees; - if (uid_array->len == 1) - data->selected_text = get_selected_text (emfv); + if (selected->len == 1) + data->selected_text = get_selected_text (reader); else data->selected_text = NULL; @@ -633,70 +648,135 @@ mail_to_event (ECalSourceType source_type, gboolean with_attendees, GPtrArray *u g_object_unref (source_list); } -/* ************************************************************************* */ - -gint e_plugin_lib_enable (EPluginLib *ep, gint enable); -void org_gnome_mail_to_event (gpointer ep, EMPopupTargetSelect *t); -void org_gnome_mail_to_event_menu (EPlugin *ep, EMMenuTargetSelect *t); -void org_gnome_mail_to_meeting (gpointer ep, EMPopupTargetSelect *t); -void org_gnome_mail_to_meeting_menu (EPlugin *ep, EMMenuTargetSelect *t); -void org_gnome_mail_to_task (gpointer ep, EMPopupTargetSelect *t); -void org_gnome_mail_to_task_menu (EPlugin *ep, EMMenuTargetSelect *t); -void org_gnome_mail_to_memo (gpointer ep, EMPopupTargetSelect *t); -void org_gnome_mail_to_memo_menu (EPlugin *ep, EMMenuTargetSelect *t); - -gint -e_plugin_lib_enable (EPluginLib *ep, gint enable) +static void +action_mail_convert_to_event_cb (GtkAction *action, + EShellView *shell_view) { - return 0; + mail_to_event (E_CAL_SOURCE_TYPE_EVENT, FALSE, shell_view); } -void -org_gnome_mail_to_event (gpointer ep, EMPopupTargetSelect *t) +static void +action_mail_convert_to_meeting_cb (GtkAction *action, + EShellView *shell_view) { - mail_to_event (E_CAL_SOURCE_TYPE_EVENT, FALSE, t->uids, t->folder, (EMFolderView *) t->target.widget); + mail_to_event (E_CAL_SOURCE_TYPE_EVENT, TRUE, shell_view); } -void -org_gnome_mail_to_event_menu (EPlugin *ep, EMMenuTargetSelect *t) +static void +action_mail_convert_to_memo_cb (GtkAction *action, + EShellView *shell_view) { - mail_to_event (E_CAL_SOURCE_TYPE_EVENT, FALSE, t->uids, t->folder, (EMFolderView *) t->target.widget); + mail_to_event (E_CAL_SOURCE_TYPE_JOURNAL, FALSE, shell_view); } -void -org_gnome_mail_to_meeting (gpointer ep, EMPopupTargetSelect *t) +static void +action_mail_convert_to_task_cb (GtkAction *action, + EShellView *shell_view) { - mail_to_event (E_CAL_SOURCE_TYPE_EVENT, TRUE, t->uids, t->folder, (EMFolderView *) t->target.widget); + mail_to_event (E_CAL_SOURCE_TYPE_TODO, FALSE, shell_view); } -void -org_gnome_mail_to_meeting_menu (EPlugin *ep, EMMenuTargetSelect *t) -{ - mail_to_event (E_CAL_SOURCE_TYPE_EVENT, TRUE, t->uids, t->folder, (EMFolderView *) t->target.widget); -} +static GtkActionEntry entries[] = { + + { "mail-convert-to-event", + "appointment-new", + N_("Convert to an _Event"), + NULL, + N_("Convert the selected messages to an event"), + G_CALLBACK (action_mail_convert_to_event_cb) }, + + { "mail-convert-to-meeting", + "stock_new-meeting", + N_("Convert to a _Meeting"), + NULL, + N_("Convert the selected messages to a meeting"), + G_CALLBACK (action_mail_convert_to_meeting_cb) }, + + { "mail-convert-to-memo", + "stock_insert-note", + N_("Convert to a Mem_o"), + NULL, + N_("Convert the selected messages to a memo"), + G_CALLBACK (action_mail_convert_to_memo_cb) }, + + { "mail-convert-to-task", + "stock_todo", + N_("Convert to a _Task"), + NULL, + N_("Convert the selected messages to a task"), + G_CALLBACK (action_mail_convert_to_task_cb) } +}; -void -org_gnome_mail_to_task (gpointer ep, EMPopupTargetSelect *t) -{ - mail_to_event (E_CAL_SOURCE_TYPE_TODO, TRUE, t->uids, t->folder, (EMFolderView *) t->target.widget); -} +static EPopupActionEntry popup_entries[] = { -void -org_gnome_mail_to_task_menu (EPlugin *ep, EMMenuTargetSelect *t) -{ - mail_to_event (E_CAL_SOURCE_TYPE_TODO, TRUE, t->uids, t->folder, (EMFolderView *) t->target.widget); -} + { "mail-popup-convert-to-event", + NULL, + "mail-convert-to-event" }, -void -org_gnome_mail_to_memo (gpointer ep, EMPopupTargetSelect *t) + { "mail-popup-convert-to-meeting", + NULL, + "mail-convert-to-meeting" }, + + { "mail-popup-convert-to-memo", + NULL, + "mail-convert-to-memo" }, + + { "mail-popup-convert-to-task", + NULL, + "mail-convert-to-task" } +}; + +static void +update_actions_cb (EShellView *shell_view) { - /* do not set organizer and attendees for memos */ - mail_to_event (E_CAL_SOURCE_TYPE_JOURNAL, FALSE, t->uids, t->folder, (EMFolderView *) t->target.widget); + EShellContent *shell_content; + EShellWindow *shell_window; + GtkAction *action; + gboolean sensitive; + guint32 state; + + shell_content = e_shell_view_get_shell_content (shell_view); + shell_window = e_shell_view_get_shell_window (shell_view); + + state = e_mail_reader_check_state (E_MAIL_READER (shell_content)); + + sensitive = + (state & E_MAIL_READER_SELECTION_SINGLE) || + (state & E_MAIL_READER_SELECTION_MULTIPLE); + + action = E_SHELL_WINDOW_ACTION_CONVERT_TO_EVENT (shell_window); + gtk_action_set_sensitive (action, sensitive); + + action = E_SHELL_WINDOW_ACTION_CONVERT_TO_MEETING (shell_window); + gtk_action_set_sensitive (action, sensitive); + + action = E_SHELL_WINDOW_ACTION_CONVERT_TO_MEMO (shell_window); + gtk_action_set_sensitive (action, sensitive); + + action = E_SHELL_WINDOW_ACTION_CONVERT_TO_TASK (shell_window); + gtk_action_set_sensitive (action, sensitive); } -void -org_gnome_mail_to_memo_menu (EPlugin *ep, EMMenuTargetSelect *t) +gboolean +e_plugin_ui_init (GtkUIManager *ui_manager, + EShellView *shell_view) { - /* do not set organizer and attendees for memos */ - mail_to_event (E_CAL_SOURCE_TYPE_JOURNAL, FALSE, t->uids, t->folder, (EMFolderView *) t->target.widget); + EShellWindow *shell_window; + GtkActionGroup *action_group; + + shell_window = e_shell_view_get_shell_window (shell_view); + action_group = e_shell_window_get_action_group (shell_window, "mail"); + + gtk_action_group_add_actions ( + action_group, entries, + G_N_ELEMENTS (entries), shell_view); + e_action_group_add_popup_actions ( + action_group, popup_entries, + G_N_ELEMENTS (popup_entries)); + + g_signal_connect ( + shell_view, "update-actions", + G_CALLBACK (update_actions_cb), NULL); + + return TRUE; } diff --git a/plugins/mail-to-task/org-gnome-mail-to-task.eplug.xml b/plugins/mail-to-task/org-gnome-mail-to-task.eplug.xml index 65ae2f4a7b..614da8cf3b 100644 --- a/plugins/mail-to-task/org-gnome-mail-to-task.eplug.xml +++ b/plugins/mail-to-task/org-gnome-mail-to-task.eplug.xml @@ -1,80 +1,33 @@ -<?xml version="1.0"?> +<?xml version="1.0" encoding="UTF-8"?> <e-plugin-list> - <e-plugin - type="shlib" - id="org.gnome.evolution.plugin.mailToTask" - location="@PLUGINDIR@/liborg-gnome-mail-to-task@SOEXT@" - _name="Mail-to-Task"> - <_description>Convert a mail message to a task.</_description> + <e-plugin type="shlib" location="/home/mbarnes/local/lib/evolution/2.28/plugins/liborg-gnome-mail-to-task.so" id="org.gnome.evolution.plugin.mailToTask" name="Mail-to-Task"> <author name="Rodrigo Moya" email="rodrigo@novell.com"/> + <_description>Convert a mail message to a task.</_description> - <!-- hook into the uri popup menu --> - <hook class="org.gnome.evolution.mail.popup:1.0"> - <menu id="org.gnome.evolution.mail.folderview.popup" target="select"> - <item - type="item" - path="70.mail_to_event1" - icon="appointment-new" - _label="Convert to an _Event" - enable="many" - visible="many" - activate="org_gnome_mail_to_event"/> - <item - type="item" - path="70.mail_to_event2" - icon="stock_new-meeting" - _label="Convert to a _Meeting" - enable="many" - visible="many" - activate="org_gnome_mail_to_meeting"/> - <item - type="item" - path="70.mail_to_event3" - icon="stock_todo" - _label="Convert to a _Task" - enable="many" - visible="many" - activate="org_gnome_mail_to_task"/> - <item - type="item" - path="70.mail_to_event4" - icon="stock_insert-note" - _label="Convert to a Mem_o" - enable="many" - visible="many" - activate="org_gnome_mail_to_memo"/> - </menu> + <hook class="org.gnome.evolution.ui:1.0"> + <ui-manager id="org.gnome.evolution.mail"> + <menubar name='main-menu'> + <placeholder name='custom-menus'> + <menu action="mail-message-menu"> + <placeholder name="mail-message-actions"> + <menuitem action="mail-convert-to-event"/> + <menuitem action="mail-convert-to-meeting"/> + <menuitem action="mail-convert-to-task"/> + <menuitem action="mail-convert-to-memo"/> + </placeholder> + </menu> + </placeholder> + </menubar> + <popup name="mail-message-popup"> + <placeholder name="mail-message-popup-actions"> + <menuitem action="mail-popup-convert-to-event"/> + <menuitem action="mail-popup-convert-to-meeting"/> + <menuitem action="mail-popup-convert-to-task"/> + <menuitem action="mail-popup-convert-to-memo"/> + </placeholder> + </popup> + </ui-manager> </hook> - <hook class="org.gnome.evolution.mail.bonobomenu:1.0"> - <menu id="org.gnome.evolution.mail.browser" target="select"> - <!-- the path to the bonobo menu description --> - <ui file="@PLUGINDIR@/org-gnome-mail-to-task.xml"/> - <item - type="item" - verb="ConvertEvent" - path="/commands/ConvertEvent" - enable="many" - activate="org_gnome_mail_to_event_menu"/> - <item - type="item" - verb="ConvertMeeting" - path="/commands/ConvertMeeting" - enable="many" - activate="org_gnome_mail_to_meeting_menu"/> - <item - type="item" - verb="ConvertTask" - path="/commands/ConvertTask" - enable="many" - activate="org_gnome_mail_to_task_menu"/> - <item - type="item" - verb="ConvertMemo" - path="/commands/ConvertMemo" - enable="many" - activate="org_gnome_mail_to_memo_menu"/> - </menu> - </hook> - + </e-plugin> </e-plugin-list> diff --git a/plugins/mail-to-task/org-gnome-mail-to-task.xml b/plugins/mail-to-task/org-gnome-mail-to-task.xml deleted file mode 100644 index 98accf4c6c..0000000000 --- a/plugins/mail-to-task/org-gnome-mail-to-task.xml +++ /dev/null @@ -1,28 +0,0 @@ -<Root> - <commands> - <cmd name="ConvertEvent" _label="Convert to an _Event" - _tip="Convert the selected message to a new event" - pixtype="stock" pixname="appointment-new"/> - <cmd name="ConvertMeeting" _label="Convert to a _Meeting" - _tip="Convert the selected message to a new meeting" - pixtype="stock" pixname="stock_new-meeting"/> - <cmd name="ConvertTask" _label="Convert to a _Task" - _tip="Convert the selected message to a new task" - pixtype="stock" pixname="stock_todo"/> - <cmd name="ConvertMemo" _label="Convert to a Mem_o" - _tip="Convert the selected message to a new memo" - pixtype="stock" pixname="stock_insert-note"/> - </commands> - - <menu> - <placeholder name="MessagePlaceholder"> - <submenu name="Message"> - <separator f="" name="emaillist5"/> - <menuitem name="ConvertEvent" verb=""/> - <menuitem name="ConvertMeeting" verb=""/> - <menuitem name="ConvertTask" verb=""/> - <menuitem name="ConvertMemo" verb=""/> - </submenu> - </placeholder> - </menu> -</Root> diff --git a/plugins/mark-all-read/Makefile.am b/plugins/mark-all-read/Makefile.am index b653e8c1f7..c44c5dc0cb 100644 --- a/plugins/mark-all-read/Makefile.am +++ b/plugins/mark-all-read/Makefile.am @@ -12,6 +12,7 @@ liborg_gnome_mark_all_read_la_LDFLAGS = -module -avoid-version $(NO_UNDEFINED) liborg_gnome_mark_all_read_la_LIBADD = \ $(top_builddir)/e-util/libeutil.la \ $(top_builddir)/mail/libevolution-mail.la \ + $(top_builddir)/shell/libeshell.la \ $(EVOLUTION_MAIL_LIBS) EXTRA_DIST = org-gnome-mark-all-read.eplug.xml diff --git a/plugins/mark-all-read/mark-all-read.c b/plugins/mark-all-read/mark-all-read.c index 87f52183fd..662bd137c3 100644 --- a/plugins/mark-all-read/mark-all-read.c +++ b/plugins/mark-all-read/mark-all-read.c @@ -28,20 +28,26 @@ #include <glib.h> #include <gtk/gtk.h> #include <glib/gi18n.h> -#include <e-util/e-config.h> -#include <mail/em-popup.h> +#include <e-util/e-plugin-ui.h> +#include <mail/em-folder-tree.h> #include <mail/mail-ops.h> #include <mail/mail-mt.h> #include <camel/camel-vee-folder.h> #include "e-util/e-error.h" +#include <shell/e-shell-sidebar.h> +#include <shell/e-shell-view.h> +#include <shell/e-shell-window.h> + #define PRIMARY_TEXT \ N_("Also mark messages in subfolders?") #define SECONDARY_TEXT \ N_("Do you want to mark messages as read in the current folder " \ "only, or in the current folder as well as all subfolders?") -void org_gnome_mark_all_read (EPlugin *ep, EMPopupTargetFolder *target); +gboolean e_plugin_ui_init (GtkUIManager *ui_manager, + EShellView *shell_view); + static void mar_got_folder (gchar *uri, CamelFolder *folder, gpointer data); static void mar_all_sub_folders (CamelStore *store, CamelFolderInfo *fi, CamelException *ex); @@ -190,16 +196,6 @@ prompt_user (void) return response; } -void -org_gnome_mark_all_read (EPlugin *ep, EMPopupTargetFolder *t) -{ - if (t->uri == NULL) { - return; - } - - mail_get_folder(t->uri, 0, mar_got_folder, NULL, mail_msg_unordered_push); -} - static void mark_all_as_read (CamelFolder *folder) { @@ -270,3 +266,50 @@ mar_all_sub_folders (CamelStore *store, CamelFolderInfo *fi, CamelException *ex) fi = fi->next; } } + +static void +action_mail_mark_read_recursive_cb (GtkAction *action, + EShellView *shell_view) +{ + EShellSidebar *shell_sidebar; + EMFolderTree *folder_tree; + const gchar *folder_uri; + + shell_sidebar = e_shell_view_get_shell_sidebar (shell_view); + g_object_get (shell_sidebar, "folder-tree", &folder_tree, NULL); + folder_uri = em_folder_tree_get_selected_uri (folder_tree); + g_return_if_fail (folder_uri != NULL); + + mail_get_folder ( + folder_uri, 0, mar_got_folder, NULL, mail_msg_unordered_push); + + g_object_unref (folder_tree); +} + +static GtkActionEntry entries[] = { + + { "mail-mark-read-recursive", + "mail-mark-read", + N_("Mark Me_ssages as Read"), + NULL, + NULL, /* XXX Add a tooltip! */ + G_CALLBACK (action_mail_mark_read_recursive_cb) } +}; + +gboolean +e_plugin_ui_init (GtkUIManager *ui_manager, + EShellView *shell_view) +{ + EShellWindow *shell_window; + GtkActionGroup *action_group; + + shell_window = e_shell_view_get_shell_window (shell_view); + action_group = e_shell_window_get_action_group (shell_window, "mail"); + + /* Add actions to the "mail" action group. */ + gtk_action_group_add_actions ( + action_group, entries, + G_N_ELEMENTS (entries), shell_view); + + return TRUE; +} diff --git a/plugins/mark-all-read/org-gnome-mark-all-read.eplug.xml b/plugins/mark-all-read/org-gnome-mark-all-read.eplug.xml index 356b8a5793..a254e1e4db 100644 --- a/plugins/mark-all-read/org-gnome-mark-all-read.eplug.xml +++ b/plugins/mark-all-read/org-gnome-mark-all-read.eplug.xml @@ -1,18 +1,21 @@ <?xml version="1.0"?> <e-plugin-list> - <e-plugin - id="org.gnome.evolution.mail.folder.mark_all_read" - type="shlib" - domain="@GETTEXT_PACKAGE@" - _name="Mark All Read" - location="@PLUGINDIR@/liborg-gnome-mark-all-read@SOEXT@"> - <author name="Chenthill Palanisamy" email="pchenthill@novell.com"/> - <_description>Mark all messages in a folder as read.</_description> + <e-plugin id="org.gnome.evolution.mail.folder.mark_all_read" + type="shlib" + domain="@GETTEXT_PACKAGE@" + _name="Mark All Read" + location="@PLUGINDIR@/liborg-gnome-mark-all-read@SOEXT@"> + <author name="Chenthill Palanisamy" email="pchenthill@novell.com"/> + <_description>Mark all messages in a folder as read.</_description> - <hook class="org.gnome.evolution.mail.popup:1.0"> - <menu id="org.gnome.evolution.mail.foldertree.popup" target="folder"> - <item type="item" path="30.emc.01" icon="mail-mark-read" _label="Mark Me_ssages as Read" activate="org_gnome_mark_all_read" enable="folder" visible="folder"/> - </menu> - </hook> - </e-plugin> + <hook class="org.gnome.evolution.ui:1.0"> + <ui-manager id="org.gnome.evolution.mail"> + <popup name="mail-folder-popup"> + <placeholder name="mail-folder-popup-actions"> + <menuitem action="mail-mark-read-recursive"/> + </placeholder> + </popup> + </ui-manager> + </hook> + </e-plugin> </e-plugin-list> diff --git a/plugins/mono/Makefile.am b/plugins/mono/Makefile.am index 6121bd7f85..4f7a935179 100644 --- a/plugins/mono/Makefile.am +++ b/plugins/mono/Makefile.am @@ -9,7 +9,7 @@ plugin_DATA = org-gnome-evolution-mono.eplug plugin_LTLIBRARIES = liborg-gnome-evolution-mono.la liborg_gnome_evolution_mono_la_SOURCES = mono-plugin.c mono-plugin.h -liborg_gnome_evolution_mono_la_LDFLAGS = -module -avoid-version +liborg_gnome_evolution_mono_la_LDFLAGS = -module -avoid-version $(NO_UNDEFINED) liborg_gnome_evolution_mono_la_LIBADD = \ $(E_UTIL_LIBS) \ $(MONO_LIBS) diff --git a/plugins/plugin-manager/Makefile.am b/plugins/plugin-manager/Makefile.am index eb8126c398..bd284c659c 100644 --- a/plugins/plugin-manager/Makefile.am +++ b/plugins/plugin-manager/Makefile.am @@ -4,18 +4,18 @@ AM_CPPFLAGS = \ @EVO_PLUGIN_RULE@ -plugin_DATA = org-gnome-plugin-manager.eplug org-gnome-plugin-manager.xml +plugin_DATA = org-gnome-plugin-manager.eplug plugin_LTLIBRARIES = liborg-gnome-plugin-manager.la liborg_gnome_plugin_manager_la_SOURCES = plugin-manager.c liborg_gnome_plugin_manager_la_LDFLAGS = -module -avoid-version $(NO_UNDEFINED) liborg_gnome_plugin_manager_la_LIBADD = \ $(top_builddir)/e-util/libeutil.la \ + $(top_builddir)/shell/libeshell.la \ $(EVOLUTION_MAIL_LIBS) -EXTRA_DIST = \ - org-gnome-plugin-manager.eplug.xml \ - org-gnome-plugin-manager.xml +EXTRA_DIST = \ + org-gnome-plugin-manager.eplug.xml BUILT_SOURCES = org-gnome-plugin-manager.eplug diff --git a/plugins/plugin-manager/org-gnome-plugin-manager.eplug.xml b/plugins/plugin-manager/org-gnome-plugin-manager.eplug.xml index 406f19b648..da270764a0 100644 --- a/plugins/plugin-manager/org-gnome-plugin-manager.eplug.xml +++ b/plugins/plugin-manager/org-gnome-plugin-manager.eplug.xml @@ -6,18 +6,19 @@ location="@PLUGINDIR@/liborg-gnome-plugin-manager@SOEXT@" _name="Plugin Manager" system_plugin="true"> - <_description>Manage your Evolution plugins.</_description> <author name="Michael Zucchi" email="notzed@ximian.com"/> - <hook class="org.gnome.evolution.shell.bonobomenu:1.0"> - <menu id="org.gnome.evolution.shell" target="shell"> - <!-- the path to the bonobo menu description --> - <ui file="@PLUGINDIR@/org-gnome-plugin-manager.xml"/> - <item - type="item" - verb="EPluginManagerManage" - path="/commands/EPluginManagerManage" - activate="org_gnome_plugin_manager_manage"/> - </menu> + <_description>Manage your Evolution plugins.</_description> + + <hook class="org.gnome.evolution.ui:1.0"> + <ui-manager id="org.gnome.evolution.shell"> + <menubar name="main-menu"> + <menu action="edit-menu"> + <placeholder name="administrative-actions"> + <menuitem action="plugin-manager"/> + </placeholder> + </menu> + </menubar> + </ui-manager> </hook> </e-plugin> </e-plugin-list> diff --git a/plugins/plugin-manager/org-gnome-plugin-manager.xml b/plugins/plugin-manager/org-gnome-plugin-manager.xml deleted file mode 100644 index 3f74a2dd4c..0000000000 --- a/plugins/plugin-manager/org-gnome-plugin-manager.xml +++ /dev/null @@ -1,15 +0,0 @@ -<Root> - <commands> - <cmd name="EPluginManagerManage" _label="_Plugins" - _tip="Enable and disable plugins"/> - </commands> - - <menu> - <submenu name="Edit"> - <placeholder name="PluginManagerPlaceholder"> - <menuitem name="EPluginManagerManage" verb=""/> - </placeholder> - </submenu> - - </menu> -</Root> diff --git a/plugins/plugin-manager/plugin-manager.c b/plugins/plugin-manager/plugin-manager.c index 816505b662..838de0e2f3 100644 --- a/plugins/plugin-manager/plugin-manager.c +++ b/plugins/plugin-manager/plugin-manager.c @@ -32,7 +32,8 @@ #include <stdio.h> #include "e-util/e-plugin.h" -#include "shell/es-menu.h" +#include "shell/e-shell-window.h" +#include "shell/e-shell-window-actions.h" #define d(S) (S) @@ -61,7 +62,6 @@ static struct { typedef struct _Manager Manager; struct _Manager { - GtkDialog *dialog; GtkTreeView *treeview; GtkTreeModel *model; @@ -75,13 +75,13 @@ struct _Manager { }; /* for tracking if we're shown */ -static GtkDialog *dialog; static GtkWidget *notebook; static GtkWidget *configure_page; static gint last_selected_page; static gulong switch_page_handler_id; -void org_gnome_plugin_manager_manage(gpointer ep, ESMenuTargetShell *t); +gboolean e_plugin_ui_init (GtkUIManager *ui_manager, + EShellWindow *shell_window); static void eppm_set_label (GtkLabel *l, const gchar *v) @@ -221,19 +221,15 @@ eppm_free (gpointer data) } static void -eppm_response (GtkDialog *w, gint button, Manager *m) -{ - gtk_widget_destroy (GTK_WIDGET (w)); - dialog = NULL; -} - -void -org_gnome_plugin_manager_manage (gpointer ep, ESMenuTargetShell *t) +action_plugin_manager_cb (GtkAction *action, + EShellWindow *shell_window) { Manager *m; gint i; + GtkWidget *dialog; GtkWidget *hbox, *w; GtkWidget *overview_page; + GtkWidget *content_area; GtkListStore *store; GtkTreeSelection *selection; GtkCellRenderer *renderer; @@ -241,26 +237,23 @@ org_gnome_plugin_manager_manage (gpointer ep, ESMenuTargetShell *t) gchar *string; GtkWidget *subvbox; - if (dialog) { - gtk_window_present (GTK_WINDOW (dialog)); - return; - } - m = g_malloc0 (sizeof (*m)); /* Setup the ui */ - m->dialog = GTK_DIALOG (gtk_dialog_new_with_buttons (_("Plugin Manager"), - GTK_WINDOW (gtk_widget_get_toplevel (t->target.widget)), - GTK_DIALOG_DESTROY_WITH_PARENT, - GTK_STOCK_CLOSE, GTK_RESPONSE_CLOSE, - NULL)); + dialog = gtk_dialog_new_with_buttons ( + _("Plugin Manager"), + GTK_WINDOW (shell_window), + GTK_DIALOG_DESTROY_WITH_PARENT, + GTK_STOCK_CLOSE, GTK_RESPONSE_CLOSE, NULL); + + content_area = gtk_dialog_get_content_area (GTK_DIALOG (dialog)); - gtk_window_set_default_size (GTK_WINDOW (m->dialog), 640, 400); - g_object_set (G_OBJECT (m->dialog), "has_separator", FALSE, NULL); + gtk_window_set_default_size (GTK_WINDOW (dialog), 640, 400); + g_object_set (dialog, "has_separator", FALSE, NULL); hbox = gtk_hbox_new (FALSE, 0); gtk_container_set_border_width (GTK_CONTAINER (hbox), 12); - gtk_box_pack_start (GTK_BOX (m->dialog->vbox), hbox, TRUE, TRUE, 0); + gtk_box_pack_start (GTK_BOX (content_area), hbox, TRUE, TRUE, 0); string = g_strdup_printf ("<i>%s</i>", _("Note: Some changes will not take effect until restart")); @@ -272,7 +265,7 @@ org_gnome_plugin_manager_manage (gpointer ep, ESMenuTargetShell *t) gtk_widget_show (w); g_free (string); - gtk_box_pack_start (GTK_BOX (m->dialog->vbox), w, FALSE, TRUE, 6); + gtk_box_pack_start (GTK_BOX (content_area), w, FALSE, TRUE, 6); notebook = gtk_notebook_new (); gtk_notebook_set_show_tabs (GTK_NOTEBOOK (notebook), TRUE); @@ -423,24 +416,34 @@ org_gnome_plugin_manager_manage (gpointer ep, ESMenuTargetShell *t) atk_object_set_name (gtk_widget_get_accessible (GTK_WIDGET (m->treeview)), _("Plugin")); - g_object_set_data_full (G_OBJECT (m->dialog), "plugin-manager", m, eppm_free); - g_signal_connect (m->dialog, "response", G_CALLBACK (eppm_response), m); - - dialog = m->dialog; + gtk_dialog_run (GTK_DIALOG (dialog)); - gtk_widget_show (GTK_WIDGET (m->dialog)); + gtk_widget_destroy (dialog); + eppm_free (m); } -gint e_plugin_lib_enable (EPluginLib *ep, gint enable); +static GtkActionEntry entries[] = { -gint -e_plugin_lib_enable (EPluginLib *ep, gint enable) + { "plugin-manager", + NULL, + N_("_Plugins"), + NULL, + N_("Enable and disable plugins"), + G_CALLBACK (action_plugin_manager_cb) } +}; + +gboolean +e_plugin_ui_init (GtkUIManager *ui_manager, + EShellWindow *shell_window) { - if (enable) { - } else { - /* This plugin can't be disabled ... */ - return -1; - } + GtkActionGroup *action_group; + + action_group = E_SHELL_WINDOW_ACTION_GROUP_SHELL (shell_window); + + /* Add actions to the "shell" action group. */ + gtk_action_group_add_actions ( + action_group, entries, + G_N_ELEMENTS (entries), shell_window); - return 0; + return TRUE; } diff --git a/plugins/prefer-plain/prefer-plain.c b/plugins/prefer-plain/prefer-plain.c index dd7e4539b8..0a1da1f63c 100644 --- a/plugins/prefer-plain/prefer-plain.c +++ b/plugins/prefer-plain/prefer-plain.c @@ -26,16 +26,16 @@ #include <gtk/gtk.h> #include <glib/gi18n-lib.h> +#include <gconf/gconf-client.h> #include <string.h> #include <stdio.h> -#include "camel/camel-multipart.h" -#include "camel/camel-mime-part.h" -#include "mail/em-format-hook.h" -#include "mail/em-format.h" +#include <camel/camel-multipart.h> +#include <camel/camel-mime-part.h> -#include <gconf/gconf-client.h> -#include "mail/em-config.h" +#include <em-format/em-format.h> +#include <mail/em-config.h> +#include <mail/em-format-hook.h> void org_gnome_prefer_plain_multipart_alternative(gpointer ep, EMFormatHookTarget *t); void org_gnome_prefer_plain_text_html(gpointer ep, EMFormatHookTarget *t); diff --git a/plugins/profiler/Makefile.am b/plugins/profiler/Makefile.am index b276c41296..21f63af33f 100644 --- a/plugins/profiler/Makefile.am +++ b/plugins/profiler/Makefile.am @@ -10,7 +10,7 @@ plugin_DATA = org-gnome-evolution-profiler.eplug plugin_LTLIBRARIES = liborg-gnome-evolution-profiler.la liborg_gnome_evolution_profiler_la_SOURCES = profiler.c -liborg_gnome_evolution_profiler_la_LDFLAGS = -module -avoid-version +liborg_gnome_evolution_profiler_la_LDFLAGS = -module -avoid-version $(NO_UNDEFINED) EXTRA_DIST = org-gnome-evolution-profiler.eplug.xml diff --git a/plugins/profiler/profiler.c b/plugins/profiler/profiler.c index c6843d349b..1200661b51 100644 --- a/plugins/profiler/profiler.c +++ b/plugins/profiler/profiler.c @@ -40,7 +40,7 @@ org_gnome_evolution_profiler_event(EPlugin *ep, EProfileEventTarget *t) if (!fp) { gchar *name; - name = g_strdup_printf("eprofile.%ld", (glong)getpid()); + name = g_strdup_printf("eprofile.%ld", (glong) getpid()); fp = fopen(name, "w"); if (fp) fprintf(stderr, "Generating profiling data in `%s'\n", name); diff --git a/plugins/pst-import/Makefile.am b/plugins/pst-import/Makefile.am index 3cf631a4ed..a92adfbe74 100644 --- a/plugins/pst-import/Makefile.am +++ b/plugins/pst-import/Makefile.am @@ -25,7 +25,6 @@ liborg_gnome_pst_import_la_SOURCES = pst-importer.c liborg_gnome_pst_import_la_LDFLAGS = \ -module -avoid-version $(NO_UNDEFINED) liborg_gnome_pst_import_la_LIBADD = \ - $(NO_UNDEFINED_REQUIRED_LIBS) \ $(LIBPST_LIBS) EXTRA_DIST = org-gnome-pst-import.eplug.xml diff --git a/plugins/python/Makefile.am b/plugins/python/Makefile.am index f6a48ac727..6f62036a1d 100644 --- a/plugins/python/Makefile.am +++ b/plugins/python/Makefile.am @@ -9,7 +9,7 @@ plugin_DATA = org-gnome-evolution-python.eplug plugin_LTLIBRARIES = liborg-gnome-evolution-python.la liborg_gnome_evolution_python_la_SOURCES = python-plugin-loader.c python-plugin-loader.h -liborg_gnome_evolution_python_la_LDFLAGS = -module -avoid-version +liborg_gnome_evolution_python_la_LDFLAGS = -module -avoid-version $(NO_UNDEFINED) liborg_gnome_evolution_python_la_LIBADD = \ -lpthread -ldl -lutil -lm \ $(PY_LIBS) \ diff --git a/plugins/python/example/Makefile.am b/plugins/python/example/Makefile.am index 8e5ddd49fd..cc14dc94d9 100644 --- a/plugins/python/example/Makefile.am +++ b/plugins/python/example/Makefile.am @@ -9,9 +9,6 @@ plugin_DATA = \ org-gnome-hello-python-ui.xml \ org-gnome-hello-python.eplug -liborg_gnome_py_plug_test_la_LIBADD= \ - $(NO_UNDEFINED_REQUIRED_LIBS) - liborg_gnome_py_plug_test_la_LDFLAGS = -module -avoid-version $(NO_UNDEFINED) errordir = $(privdatadir)/errors diff --git a/plugins/sa-junk-plugin/Makefile.am b/plugins/sa-junk-plugin/Makefile.am index eebfdf0c26..66e31a0d6b 100644 --- a/plugins/sa-junk-plugin/Makefile.am +++ b/plugins/sa-junk-plugin/Makefile.am @@ -1,5 +1,6 @@ AM_CPPFLAGS = \ -I$(top_srcdir) \ + -I$(top_srcdir)/widgets \ $(EVOLUTION_MAIL_CFLAGS) @EVO_PLUGIN_RULE@ @@ -10,6 +11,11 @@ plugin_LTLIBRARIES = liborg-gnome-sa-junk-plugin.la liborg_gnome_sa_junk_plugin_la_SOURCES = em-junk-filter.c liborg_gnome_sa_junk_plugin_la_LDFLAGS = -module -avoid-version $(NO_UNDEFINED) +liborg_gnome_sa_junk_plugin_la_LIBADD = \ + $(top_builddir)/mail/libevolution-mail.la \ + $(top_builddir)/e-util/libeutil.la \ + $(EVOLUTION_MAIL_LIBS) \ + $(GNOME_PLATFORM_LIBS) BUILT_SOURCES = $(plugin_DATA) $(error_DATA) diff --git a/plugins/select-one-source/ChangeLog b/plugins/select-one-source/ChangeLog deleted file mode 100644 index 0534fee906..0000000000 --- a/plugins/select-one-source/ChangeLog +++ /dev/null @@ -1,64 +0,0 @@ -2008-10-13 Suman Manjunath <msuman@novell.com> - - ** Fix for bug #424818 (bugzilla.novell.com) - - * mark-calendar-offline.c: Removed this unused PoC file. The - corresponding plugin has also been integrated into the main code. - -2008-08-27 Sankar P <psankar@novell.com> - -License Changes - - * mark-calendar-offline.c: - * select-one-source.c: - -2008-08-12 Bharath Acharya <abharath@novell.com> - - * Makefile.am: Use NO_UNDEFINED. Link with more libraries. To generate - dlls on Windows. - -2007-11-11 Gilles Dartiguelongue <gdartigu@svn.gnome.org> - - ** Fix bug #495872 - - * org-gnome-select-one-source.eplug.xml: - add right-click menu item for memo component - -2007-04-02 Sankar P <psankar@novell.com> - - * Committed on behalf of Gilles Dartiguelongue <dartigug@esiee.fr> - - * org-gnome-select-one-source.eplug.xml: - Cleanup. - Fixes part of #301149 - -2006-02-13 Karsten Bräckelmann <guenther@rudersport.de> - - * org-gnome-select-one-source.eplug.xml: - Fix mnemonics to be consistent. Fixes bug #330934. - -2005-12-12 Harish Krishnaswamy <kharish@novell.com> - - * Makefile.am: Fix make-clean issues. - -2005-05-06 Not Zed <NotZed@Ximian.com> - - * Makefile.am: - * org-gnome-select-one-source.eplug.xml: s/.in/.xml/ & i18n. - -2005-02-24 Björn Torkelsson <torkel@acc.umu.se> - - * org-gnome-select-one-source.eplug.in: Fixed description and - added author. - Added xml tag. - -2004-11-01 JP Rosevear <jpr@novell.com> - - * Makefile.am: dist .eplug.in file - -2004-10-20 JP Rosevear <jpr@novell.com> - - * select-one-source.c: implement a plugin that allows the user to - limit the displayed task lists or calendars to the current - calendar or task list - diff --git a/plugins/select-one-source/Makefile.am b/plugins/select-one-source/Makefile.am deleted file mode 100644 index 3788fd30fa..0000000000 --- a/plugins/select-one-source/Makefile.am +++ /dev/null @@ -1,21 +0,0 @@ -AM_CPPFLAGS = \ - -I$(top_srcdir) \ - -I$(top_srcdir)/widgets \ - $(EVOLUTION_CALENDAR_CFLAGS) - -@EVO_PLUGIN_RULE@ - -plugin_DATA = org-gnome-select-one-source.eplug -plugin_LTLIBRARIES = liborg-gnome-select-one-source.la - -liborg_gnome_select_one_source_la_SOURCES = select-one-source.c -liborg_gnome_select_one_source_la_LDFLAGS = -module -avoid-version $(NO_UNDEFINED) -liborg_gnome_select_one_source_la_LIBADD = \ - $(EVOLUTION_CALENDAR_LIBS) - -EXTRA_DIST = org-gnome-select-one-source.eplug.xml - -BUILT_SOURCES = $(plugin_DATA) -CLEANFILES = $(BUILT_SOURCES) - --include $(top_srcdir)/git.mk diff --git a/plugins/select-one-source/org-gnome-select-one-source.eplug.xml b/plugins/select-one-source/org-gnome-select-one-source.eplug.xml deleted file mode 100644 index 12a3d03a88..0000000000 --- a/plugins/select-one-source/org-gnome-select-one-source.eplug.xml +++ /dev/null @@ -1,21 +0,0 @@ -<?xml version="1.0"?> -<e-plugin-list> - <e-plugin id="org.gnome.evolution.select_one_source" type="shlib" - _name="Select One Source" - location="@PLUGINDIR@/liborg-gnome-select-one-source@SOEXT@"> - <author name="JP Rosevear" email="jpr@novell.com"/> - <_description>Quickly select a single calendar or task list for viewing.</_description> - - <hook class="org.gnome.evolution.calendar.popup:1.0"> - <menu id="org.gnome.evolution.tasks.source.popup" target="source"> - <item type="item" path="25.select_one_source" _label="Show _only this Task List" icon="stock_check-filled" activate="org_gnome_select_one_source"/> - </menu> - <menu id="org.gnome.evolution.memos.source.popup" target="source"> - <item type="item" path="25.select_one_source" _label="Show _only this Memo List" icon="stock_check-filled" activate="org_gnome_select_one_source"/> - </menu> - <menu id="org.gnome.evolution.calendar.source.popup" target="source"> - <item type="item" path="25.select_one_source" _label="Show _only this Calendar" icon="stock_check-filled" activate="org_gnome_select_one_source"/> - </menu> - </hook> - </e-plugin> -</e-plugin-list> diff --git a/plugins/select-one-source/select-one-source.c b/plugins/select-one-source/select-one-source.c deleted file mode 100644 index c211814151..0000000000 --- a/plugins/select-one-source/select-one-source.c +++ /dev/null @@ -1,54 +0,0 @@ -/* - * - * This program is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 2 of the License, or (at your option) version 3. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General Public - * License along with the program; if not, see <http://www.gnu.org/licenses/> - * - * - * Authors: - * JP Rosevear <jpr@novell.com> - * - * Copyright (C) 1999-2008 Novell, Inc. (www.novell.com) - * - */ - -/* This is prototype code only, this may, or may not, use undocumented - * unstable or private internal function calls. */ - -#include <glib.h> -#include <glib/gi18n.h> -#include <libedataserver/e-source.h> -#include <libedataserverui/e-source-selector.h> -#include <calendar/gui/e-cal-popup.h> - -void org_gnome_select_one_source (EPlugin *ep, ECalPopupTargetSource *target); - -void -org_gnome_select_one_source (EPlugin *ep, ECalPopupTargetSource *target) -{ - GSList *selection, *l; - ESource *primary_source; - - selection = e_source_selector_get_selection (target->selector); - primary_source = e_source_selector_peek_primary_selection (target->selector); - - for (l = selection; l; l = l->next) { - ESource *source = l->data; - - if (source != primary_source) - e_source_selector_unselect_source (target->selector, source); - } - - e_source_selector_select_source (target->selector, primary_source); - - e_source_selector_free_selection (selection); -} diff --git a/plugins/startup-wizard/Makefile.am b/plugins/startup-wizard/Makefile.am index 81c75776d9..5dec1f86a5 100644 --- a/plugins/startup-wizard/Makefile.am +++ b/plugins/startup-wizard/Makefile.am @@ -16,7 +16,7 @@ liborg_gnome_evolution_startup_wizard_la_LIBADD = \ $(top_builddir)/e-util/libeutil.la \ $(top_builddir)/widgets/e-timezone-dialog/libetimezonedialog.la \ $(top_builddir)/widgets/misc/libemiscwidgets.la \ - $(top_builddir)/calendar/gui/libevolution-calendar.la \ + $(top_builddir)/calendar/gui/libcal-gui.la \ $(top_builddir)/mail/libevolution-mail.la \ $(EVOLUTION_CALENDAR_LIBS) \ $(EVOLUTION_MAIL_LIBS) diff --git a/plugins/startup-wizard/startup-wizard.c b/plugins/startup-wizard/startup-wizard.c index 7dd3f5b3e3..41a647a1b6 100644 --- a/plugins/startup-wizard/startup-wizard.c +++ b/plugins/startup-wizard/startup-wizard.c @@ -29,6 +29,7 @@ #include <libgnomeui/gnome-druid-page-standard.h> #include "e-util/e-error.h" #include "e-util/e-import.h" +#include "shell/e-shell.h" #include "shell/es-event.h" #include "mail/em-config.h" #include "mail/em-account-editor.h" @@ -47,7 +48,7 @@ static GtkWidget *import_dialog, *import_progress, *import_label; static GSList *import_iterator, *import_importers; G_GNUC_NORETURN static void -startup_wizard_delete (void) { +startup_wizard_terminate (void) { gtk_main_quit (); _exit (0); } @@ -55,10 +56,10 @@ startup_wizard_delete (void) { void startup_wizard (EPlugin *ep, ESEventTargetUpgrade *target) { - GConfClient *client; - GSList *accounts; EMAccountEditor *emae; GnomeDruidPageEdge *start_page; + GConfClient *client; + GSList *accounts; client = gconf_client_get_default (); accounts = gconf_client_get_list (client, "/apps/evolution/mail/accounts", GCONF_VALUE_STRING, NULL); @@ -79,20 +80,29 @@ startup_wizard (EPlugin *ep, ESEventTargetUpgrade *target) * * The new mail account druid. */ - emae = em_account_editor_new (NULL, EMAE_DRUID, "org.gnome.evolution.mail.config.accountWizard"); + emae = em_account_editor_new ( + NULL, EMAE_DRUID, + "org.gnome.evolution.mail.config.accountWizard"); - gtk_window_set_title (GTK_WINDOW (emae->editor), _("Evolution Setup Assistant")); + gtk_window_set_title ( + GTK_WINDOW (emae->editor), _("Evolution Setup Assistant")); - start_page = GNOME_DRUID_PAGE_EDGE (e_config_page_get ((EConfig *) emae->config, "0.start")); + start_page = GNOME_DRUID_PAGE_EDGE ( + e_config_page_get ((EConfig *) emae->config, "0.start")); gnome_druid_page_edge_set_title (start_page, _("Welcome")); - gnome_druid_page_edge_set_text (start_page, _("" - "Welcome to Evolution. The next few screens will allow Evolution to connect " - "to your email accounts, and to import files from other applications. \n" - "\n" - "Please click the \"Forward\" button to continue. ")); - g_signal_connect (emae->editor, "delete-event", G_CALLBACK (startup_wizard_delete), NULL); + gnome_druid_page_edge_set_text ( + start_page, _("" + "Welcome to Evolution. The next few screens will allow Evolution to connect " + "to your email accounts, and to import files from other applications. \n" + "\n" + "Please click the \"Forward\" button to continue. ")); + + g_signal_connect ( + emae->editor, "delete-event", + G_CALLBACK (startup_wizard_terminate), NULL); gtk_widget_show (emae->editor); + gtk_main (); } @@ -188,10 +198,16 @@ import_done(EImport *ei, gpointer d) void startup_wizard_commit (EPlugin *ep, EMConfigTargetAccount *target) { + EShell *shell; + EShellSettings *shell_settings; gchar *location; + shell = e_shell_get_default (); + shell_settings = e_shell_get_shell_settings (shell); + /* Use System Timezone by default */ - calendar_config_set_use_system_timezone (TRUE); + e_shell_settings_set_boolean ( + shell_settings, "cal-use-system-timezone", TRUE); location = e_cal_util_get_system_timezone_location (); calendar_config_set_timezone (location); g_free (location); @@ -217,6 +233,5 @@ startup_wizard_commit (EPlugin *ep, EMConfigTargetAccount *target) void startup_wizard_abort (EPlugin *ep, EMConfigTargetAccount *target) { - gtk_main_quit (); - _exit (0); + startup_wizard_terminate (); } diff --git a/plugins/templates/templates.c b/plugins/templates/templates.c index 53669ba347..ae479fb41e 100644 --- a/plugins/templates/templates.c +++ b/plugins/templates/templates.c @@ -34,10 +34,10 @@ #include <camel/camel-multipart.h> #include <camel/camel-stream-mem.h> +#include <mail/e-mail-local.h> #include <mail/em-composer-utils.h> #include <mail/em-popup.h> #include <mail/mail-session.h> -#include <mail/mail-component.h> #include <mail/mail-ops.h> #include <e-util/e-error.h> #include <e-util/e-plugin.h> @@ -506,7 +506,7 @@ reply_with_template (EPopup *ep, EPopupItem *item, gpointer data) gchar *cont; /* We get the templates folder and all the uids of the messages in there */ - templates_folder = mail_component_get_folder(NULL, MAIL_COMPONENT_FOLDER_TEMPLATES); + templates_folder = e_mail_local_get_folder (E_MAIL_FOLDER_TEMPLATES); /* Get from the currently selected folder, the currently selected message */ reply_to = camel_folder_get_message (userdata->t->folder, @@ -666,14 +666,14 @@ org_gnome_templates_popup (EPlugin *ep, EMPopupTargetSelect *t) GSList *list = NULL; /* We get the templates folder and all the uids of the messages in there */ - store = mail_component_peek_local_store (NULL); + store = e_mail_local_get_store (); - templates_folder = mail_component_get_folder(NULL, MAIL_COMPONENT_FOLDER_TEMPLATES); + templates_folder = e_mail_local_get_folder (E_MAIL_FOLDER_TEMPLATES); - templates_info = camel_store_get_folder_info (store, - templates_folder->full_name, - CAMEL_STORE_FOLDER_INFO_RECURSIVE | CAMEL_STORE_FOLDER_INFO_FAST, - NULL); + templates_info = camel_store_get_folder_info ( + store, templates_folder->full_name, + CAMEL_STORE_FOLDER_INFO_RECURSIVE | + CAMEL_STORE_FOLDER_INFO_FAST, NULL); /* Get subfolders and fill it */ list = fill_submenu (store, templates_info, list, t); @@ -692,7 +692,7 @@ action_template_cb (GtkAction *action, CamelFolder *templates_folder; /* We get the templates folder and all the uids of the messages in there */ - templates_folder = mail_component_get_folder(NULL, MAIL_COMPONENT_FOLDER_TEMPLATES); + templates_folder = e_mail_local_get_folder (E_MAIL_FOLDER_TEMPLATES); msg = e_msg_composer_get_message_draft (composer); info = camel_message_info_new (NULL); diff --git a/plugins/tnef-attachments/Makefile.am b/plugins/tnef-attachments/Makefile.am index d9447f263d..2273e6ed80 100644 --- a/plugins/tnef-attachments/Makefile.am +++ b/plugins/tnef-attachments/Makefile.am @@ -8,6 +8,7 @@ endif AM_CPPFLAGS = \ -I$(top_srcdir) \ + -I$(top_srcdir)/widgets \ -DGETTEXT_PACKAGE="\"$(GETTEXT_PACKAGE)\"" \ -DLOCALEDIR="\"$(localedir)\"" \ $(EVOLUTION_MAIL_CFLAGS) \ @@ -21,7 +22,9 @@ plugin_LTLIBRARIES = liborg-gnome-tnef-attachments.la liborg_gnome_tnef_attachments_la_SOURCES = tnef-plugin.c liborg_gnome_tnef_attachments_la_LDFLAGS = -module -avoid-version $(NO_UNDEFINED) liborg_gnome_tnef_attachments_la_LIBADD = \ - $(NO_UNDEFINED_REQUIRED_LIBS) \ + $(top_builddir)/e-util/libeutil.la \ + $(top_builddir)/em-format/libemformat.la \ + $(EVOLUTION_MAIL_LIBS) \ -lytnef EXTRA_DIST = org-gnome-tnef-attachments.eplug.xml diff --git a/plugins/tnef-attachments/tnef-plugin.c b/plugins/tnef-attachments/tnef-plugin.c index c23cfaa730..3ad583c2a7 100644 --- a/plugins/tnef-attachments/tnef-plugin.c +++ b/plugins/tnef-attachments/tnef-plugin.c @@ -46,7 +46,7 @@ #include <camel/camel-multipart.h> #include <camel/camel-stream-fs.h> -#include <mail/em-format.h> +#include <em-format/em-format.h> #include <mail/em-format-hook.h> #include <mail/em-utils.h> #include <e-util/e-error.h> @@ -160,7 +160,7 @@ org_gnome_format_tnef(gpointer ep, EMFormatHookTarget *t) camel_medium_set_content_object((CamelMedium *)part, content); camel_object_unref(content); - type = em_utils_snoop_type(part); + type = em_format_snoop_type(part); if (type) camel_data_wrapper_set_mime_type((CamelDataWrapper *)part, type); diff --git a/plugins/vcard-inline/Makefile.am b/plugins/vcard-inline/Makefile.am index 5a8ed2c88e..dd8f92fd1a 100644 --- a/plugins/vcard-inline/Makefile.am +++ b/plugins/vcard-inline/Makefile.am @@ -18,10 +18,13 @@ plugin_LTLIBRARIES = liborg-gnome-vcard-inline.la liborg_gnome_vcard_inline_la_SOURCES = vcard-inline.c liborg_gnome_vcard_inline_la_LDFLAGS = -module -avoid-version $(NO_UNDEFINED) liborg_gnome_vcard_inline_la_LIBADD = \ - $(EVOLUTION_ADDRESSBOOK_LIBS) \ - $(EVOLUTION_MAIL_LIBS) \ - $(EVOLUTION_ADDRESSBOOK_LIBS) \ - $(NO_UNDEFINED_REQUIRED_LIBS) + $(top_builddir)/mail/libevolution-mail.la \ + $(top_builddir)/addressbook/util/libeabutil.la \ + $(top_builddir)/addressbook/gui/widgets/libeabwidgets.la \ + $(top_builddir)/addressbook/gui/merging/libeabbookmerging.la \ + $(top_builddir)/addressbook/printing/libecontactprint.la \ + $(EVOLUTION_ADDRESSBOOK_LIBS) \ + $(EVOLUTION_MAIL_LIBS) EXTRA_DIST = org-gnome-vcard-inline.eplug.xml diff --git a/plugins/vcard-inline/vcard-inline.c b/plugins/vcard-inline/vcard-inline.c index 916774b4f0..7fc20b9dc1 100644 --- a/plugins/vcard-inline/vcard-inline.c +++ b/plugins/vcard-inline/vcard-inline.c @@ -29,9 +29,9 @@ #include <camel/camel-stream-mem.h> #include <gtkhtml/gtkhtml-embedded.h> -#include "addressbook/gui/component/addressbook.h" #include "addressbook/gui/merging/eab-contact-merging.h" #include "addressbook/gui/widgets/eab-contact-display.h" +#include "addressbook/util/addressbook.h" #include "addressbook/util/eab-book-util.h" #include "mail/em-format-hook.h" #include "mail/em-format-html.h" @@ -46,7 +46,6 @@ struct _VCardInlinePObject { GList *contact_list; GtkWidget *contact_display; GtkWidget *message_label; - EABContactDisplayRenderMode mode; }; static gint org_gnome_vcard_inline_classid; @@ -145,25 +144,23 @@ org_gnome_vcard_inline_toggle_cb (VCardInlinePObject *vcard_object, GtkButton *button) { EABContactDisplay *contact_display; + EABContactDisplayMode mode; const gchar *label; contact_display = EAB_CONTACT_DISPLAY (vcard_object->contact_display); + mode = eab_contact_display_get_mode (contact_display); /* Toggle between "full" and "compact" modes. */ - if (vcard_object->mode == EAB_CONTACT_DISPLAY_RENDER_NORMAL) { - vcard_object->mode = EAB_CONTACT_DISPLAY_RENDER_COMPACT; + if (mode == EAB_CONTACT_DISPLAY_RENDER_NORMAL) { + mode = EAB_CONTACT_DISPLAY_RENDER_COMPACT; label = _("Show Full vCard"); } else { - vcard_object->mode = EAB_CONTACT_DISPLAY_RENDER_NORMAL; + mode = EAB_CONTACT_DISPLAY_RENDER_NORMAL; label = _("Show Compact vCard"); } + eab_contact_display_set_mode (contact_display, mode); gtk_button_set_label (button, label); - - eab_contact_display_render ( - EAB_CONTACT_DISPLAY (vcard_object->contact_display), - E_CONTACT (vcard_object->contact_list->data), - vcard_object->mode); } static gboolean @@ -175,11 +172,16 @@ org_gnome_vcard_inline_embed (EMFormatHTML *format, GtkWidget *button_box; GtkWidget *container; GtkWidget *widget; + EContact *contact; guint length; vcard_object = (VCardInlinePObject *) object; length = g_list_length (vcard_object->contact_list); - g_return_val_if_fail (length > 0, FALSE); + + if (vcard_object->contact_list != NULL) + contact = E_CONTACT (vcard_object->contact_list->data); + else + contact = NULL; container = GTK_WIDGET (embedded); @@ -199,15 +201,15 @@ org_gnome_vcard_inline_embed (EMFormatHTML *format, button_box = widget; widget = eab_contact_display_new (); + eab_contact_display_set_contact ( + EAB_CONTACT_DISPLAY (widget), contact); + eab_contact_display_set_mode ( + EAB_CONTACT_DISPLAY (widget), + EAB_CONTACT_DISPLAY_RENDER_COMPACT); gtk_box_pack_start (GTK_BOX (container), widget, TRUE, TRUE, 0); vcard_object->contact_display = g_object_ref (widget); gtk_widget_show (widget); - eab_contact_display_render ( - EAB_CONTACT_DISPLAY (vcard_object->contact_display), - E_CONTACT (vcard_object->contact_list->data), - vcard_object->mode); - widget = gtk_label_new (NULL); gtk_box_pack_start (GTK_BOX (container), widget, TRUE, TRUE, 0); vcard_object->message_label = g_object_ref (widget); @@ -276,7 +278,6 @@ org_gnome_vcard_inline_format (gpointer ep, EMFormatHookTarget *target) camel_object_ref (target->part); - vcard_object->mode = EAB_CONTACT_DISPLAY_RENDER_COMPACT; vcard_object->object.free = org_gnome_vcard_inline_pobject_free; org_gnome_vcard_inline_decode (vcard_object, target->part); |