Permalink
Browse files

Fixed compatibility with evolution 3.3.5

  • Loading branch information...
1 parent 0815ae4 commit 7219ac92964f3f96e2875ee5cc7e9b80ac33483b @epienbroek committed Aug 21, 2012
View
@@ -636,6 +636,7 @@ jb_package_add_resources (void)
jb_group_add_data_file(group, "org-jylefort-mail-notification.eplug", "$evolution-plugin-dir");
jb_compile_options_add_cflags(object->compile_options, "$evolution-plugin-cflags");
+ jb_compile_options_add_cflags(object->compile_options, "$libemail-engine-cflags");
jb_group_add_dbus_interface(group,
"org.freedesktop.DBus.Properties",
@@ -663,6 +664,7 @@ jb_package_add_resources (void)
jb_compile_options_add_package(plugin->compile_options, "gettext");
jb_compile_options_add_package(plugin->compile_options, "evolution-plugin");
+ jb_compile_options_add_package(plugin->compile_options, "libemail-engine");
jb_compile_options_add_package(plugin->compile_options, "dbus");
jb_group_add_dbus_interface(group,
@@ -63,5 +63,5 @@ jb_evolution_plugin_check (const char *minversion)
g_free(plugindir);
}
- return TRUE;
+ return jb_check_packages("Evolution", "libemail-engine", "libemail-engine");
}
@@ -20,11 +20,15 @@
%privateheader{
#include <gtk/gtk.h>
#include <libedataserver/eds-version.h>
-#if EDS_CHECK_VERSION(2,91,0)
-#include <mail/e-mail-session.h>
+#if EDS_CHECK_VERSION(3,3,5)
+ #include <libemail-engine/e-mail-session.h>
#else
-/* GOB2 doesn't support private members guarded with an #if */
-typedef EMailSession void;
+ #if EDS_CHECK_VERSION(2,91,0)
+ #include <mail/e-mail-session.h>
+ #else
+ /* GOB2 doesn't support private members guarded with an #if */
+ typedef EMailSession void;
+ #endif
#endif
%}
@@ -33,13 +37,17 @@ typedef EMailSession void;
#include <gtk/gtkx.h>
#include <libedataserver/eds-version.h>
#if !EDS_CHECK_VERSION(2,29,0)
-#include <mail/mail-component.h>
+ #include <mail/mail-component.h>
#endif
#if EDS_CHECK_VERSION(3,1,0)
-#include <mail/e-mail-folder-utils.h>
-#include <mail/e-mail-browser.h>
-#include <mail/e-mail-reader.h>
-#include <shell/e-shell.h>
+ #if EDS_CHECK_VERSION(3,3,5)
+ #include <libemail-engine/e-mail-folder-utils.h>
+ #else
+ #include <mail/e-mail-folder-utils.h>
+ #endif
+ #include <mail/e-mail-browser.h>
+ #include <mail/e-mail-reader.h>
+ #include <shell/e-shell.h>
#endif
#include <mail/em-folder-tree.h>
#include "mn-evolution-plugin.h"
@@ -145,7 +153,13 @@ class MN:Evolution:Folder:Tree:Server from G:Object
gpointer user_data)
{
Self *self = user_data;
+ char *uri;
+
+ if (!folder_name) return;
+
+ uri = e_mail_folder_uri_build(store, folder_name);
self_folder_selected(self, uri);
+ g_free(uri);
}
private void
@@ -27,8 +27,13 @@
#include <camel/camel.h>
#include <libedataserver/eds-version.h>
#include <mail/em-event.h>
+#if EDS_CHECK_VERSION(3,3,5)
+#include <libemail-engine/e-mail-folder-utils.h>
+#include <libemail-engine/mail-tools.h>
+#else
#include <mail/mail-tools.h>
#include <mail/e-mail-folder-utils.h>
+#endif
#include "mn-evolution.h"
#include "mn-evolution-server.h"
#include "mn-evolution-plugin.h"
@@ -28,20 +28,25 @@
#include <libedataserver/eds-version.h>
#include <camel/camel.h>
#if EDS_CHECK_VERSION(2,29,0)
-#include <shell/e-shell.h>
-#include <mail/e-mail-browser.h>
+ #include <shell/e-shell.h>
+ #include <mail/e-mail-browser.h>
#else
-#include <mail/em-folder-view.h>
-#include <mail/em-format.h>
-#include <mail/em-message-browser.h>
+ #include <mail/em-folder-view.h>
+ #include <mail/em-format.h>
+ #include <mail/em-message-browser.h>
#endif
#include <mail/em-utils.h>
-#if EDS_CHECK_VERSION(2,91,0)
-#include <mail/e-mail-session.h>
+#if EDS_CHECK_VERSION(3,3,5)
+ #include <libemail-engine/e-mail-session.h>
+ #include <libemail-engine/mail-tools.h>
#else
-#include <mail/mail-session.h>
+ #include <mail/mail-tools.h>
+ #if EDS_CHECK_VERSION(2,91,0)
+ #include <mail/e-mail-session.h>
+ #else
+ #include <mail/mail-session.h>
+ #endif
#endif
-#include <mail/mail-tools.h>
#include "mn-evolution.h"
#include "mn-evolution-folder-tree-server.h"
#include "mn-evolution-plugin.h"

0 comments on commit 7219ac9

Please sign in to comment.