aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--em-format/Makefile.am2
-rw-r--r--em-format/e-mail-extension-registry.c152
-rw-r--r--em-format/e-mail-extension-registry.h9
-rw-r--r--em-format/e-mail-format-extensions.c144
-rw-r--r--em-format/e-mail-format-extensions.h88
-rw-r--r--em-format/e-mail-formatter-attachment-bar.c6
-rw-r--r--em-format/e-mail-formatter-attachment.c3
-rw-r--r--em-format/e-mail-formatter-error.c3
-rw-r--r--em-format/e-mail-formatter-headers.c3
-rw-r--r--em-format/e-mail-formatter-image.c3
-rw-r--r--em-format/e-mail-formatter-message-rfc822.c3
-rw-r--r--em-format/e-mail-formatter-print-headers.c3
-rw-r--r--em-format/e-mail-formatter-print.c6
-rw-r--r--em-format/e-mail-formatter-quote-attachment.c3
-rw-r--r--em-format/e-mail-formatter-quote-headers.c3
-rw-r--r--em-format/e-mail-formatter-quote-message-rfc822.c3
-rw-r--r--em-format/e-mail-formatter-quote-text-enriched.c3
-rw-r--r--em-format/e-mail-formatter-quote-text-html.c3
-rw-r--r--em-format/e-mail-formatter-quote-text-plain.c3
-rw-r--r--em-format/e-mail-formatter-quote.c6
-rw-r--r--em-format/e-mail-formatter-secure-button.c3
-rw-r--r--em-format/e-mail-formatter-source.c3
-rw-r--r--em-format/e-mail-formatter-text-enriched.c3
-rw-r--r--em-format/e-mail-formatter-text-html.c3
-rw-r--r--em-format/e-mail-formatter-text-plain.c3
-rw-r--r--em-format/e-mail-formatter.c5
-rw-r--r--em-format/e-mail-parser-application-mbox.c3
-rw-r--r--em-format/e-mail-parser-application-smime.c3
-rw-r--r--em-format/e-mail-parser-attachment-bar.c3
-rw-r--r--em-format/e-mail-parser-headers.c3
-rw-r--r--em-format/e-mail-parser-image.c3
-rw-r--r--em-format/e-mail-parser-inlinepgp-encrypted.c3
-rw-r--r--em-format/e-mail-parser-inlinepgp-signed.c3
-rw-r--r--em-format/e-mail-parser-message-deliverystatus.c3
-rw-r--r--em-format/e-mail-parser-message-external.c3
-rw-r--r--em-format/e-mail-parser-message-rfc822.c3
-rw-r--r--em-format/e-mail-parser-message.c3
-rw-r--r--em-format/e-mail-parser-multipart-alternative.c3
-rw-r--r--em-format/e-mail-parser-multipart-appledouble.c3
-rw-r--r--em-format/e-mail-parser-multipart-digest.c3
-rw-r--r--em-format/e-mail-parser-multipart-encrypted.c3
-rw-r--r--em-format/e-mail-parser-multipart-mixed.c3
-rw-r--r--em-format/e-mail-parser-multipart-related.c3
-rw-r--r--em-format/e-mail-parser-multipart-signed.c3
-rw-r--r--em-format/e-mail-parser-secure-button.c3
-rw-r--r--em-format/e-mail-parser-source.c3
-rw-r--r--em-format/e-mail-parser-text-enriched.c3
-rw-r--r--em-format/e-mail-parser-text-html.c3
-rw-r--r--em-format/e-mail-parser-text-plain.c3
-rw-r--r--em-format/e-mail-parser.c3
-rw-r--r--modules/audio-inline/e-mail-formatter-audio-inline.c41
-rw-r--r--modules/audio-inline/e-mail-parser-audio-inline.c41
-rw-r--r--modules/itip-formatter/e-mail-formatter-itip.c43
-rw-r--r--modules/itip-formatter/e-mail-parser-itip.c41
-rw-r--r--modules/prefer-plain/e-mail-parser-prefer-plain.c41
-rw-r--r--modules/text-highlight/e-mail-formatter-text-highlight.c41
-rw-r--r--modules/text-highlight/e-mail-parser-text-highlight.c41
-rw-r--r--modules/tnef-attachment/e-mail-parser-tnef-attachment.c41
-rw-r--r--modules/vcard-inline/e-mail-formatter-vcard-inline.c41
-rw-r--r--modules/vcard-inline/e-mail-parser-vcard-inline.c41
60 files changed, 752 insertions, 201 deletions
diff --git a/em-format/Makefile.am b/em-format/Makefile.am
index f26a004d0a..51c7471cc9 100644
--- a/em-format/Makefile.am
+++ b/em-format/Makefile.am
@@ -40,6 +40,8 @@ libemformat_la_SOURCES = \
$(emformatinclude_HEADERS) \
e-mail-extension-registry.c \
e-mail-inline-filter.c \
+ e-mail-format-extensions.c \
+ e-mail-format-extensions.h \
e-mail-formatter.c \
e-mail-formatter-print.c \
e-mail-formatter-quote.c \
diff --git a/em-format/e-mail-extension-registry.c b/em-format/e-mail-extension-registry.c
index 7e5f3a9b0b..158951f813 100644
--- a/em-format/e-mail-extension-registry.c
+++ b/em-format/e-mail-extension-registry.c
@@ -22,6 +22,7 @@
#include <libebackend/libebackend.h>
+#include "e-mail-format-extensions.h"
#include "e-mail-formatter-extension.h"
#include "e-mail-parser-extension.h"
@@ -57,49 +58,6 @@ destroy_queue (GQueue *queue)
}
static void
-mail_extension_registry_add_extension (EMailExtensionRegistry *registry,
- const gchar **mime_types,
- GType extension_type)
-{
- GObject *extension;
- gint ii;
-
- if (mime_types == NULL) {
- g_critical (
- "%s does not define any MIME types",
- g_type_name (extension_type));
- return;
- }
-
- extension = g_object_new (extension_type, NULL);
-
- for (ii = 0; mime_types[ii] != NULL; ii++) {
- GQueue *queue;
-
- queue = g_hash_table_lookup (
- registry->priv->table, mime_types[ii]);
- if (queue == NULL) {
- queue = g_queue_new ();
- g_hash_table_insert (
- registry->priv->table,
- (gpointer) mime_types[ii],
- queue);
- }
-
- g_queue_push_head (queue, g_object_ref (extension));
-
- if (camel_debug ("emformat:registry")) {
- printf (
- "Added extension '%s' for type '%s'\n",
- g_type_name (extension_type),
- mime_types[ii]);
- }
- }
-
- g_object_unref (extension);
-}
-
-static void
mail_extension_registry_finalize (GObject *object)
{
EMailExtensionRegistryPrivate *priv;
@@ -138,6 +96,55 @@ e_mail_extension_registry_init (EMailExtensionRegistry *registry)
}
/**
+ * e_mail_extension_registry_add_extension:
+ * @registry: an #EMailExtensionRegistry
+ * @mime_types: a %NULL-terminated array of MIME types
+ * @extension_type: the #GType of the extension being added
+ *
+ * Creates an instance of @extension_type and registers the instance for
+ * all provided MIME types.
+ */
+void
+e_mail_extension_registry_add_extension (EMailExtensionRegistry *registry,
+ const gchar **mime_types,
+ GType extension_type)
+{
+ GObject *extension;
+ gint ii;
+
+ g_return_if_fail (E_IS_MAIL_EXTENSION_REGISTRY (registry));
+ g_return_if_fail (mime_types != NULL);
+ g_return_if_fail (extension_type != G_TYPE_INVALID);
+
+ extension = g_object_new (extension_type, NULL);
+
+ for (ii = 0; mime_types[ii] != NULL; ii++) {
+ GQueue *queue;
+
+ queue = g_hash_table_lookup (
+ registry->priv->table, mime_types[ii]);
+ if (queue == NULL) {
+ queue = g_queue_new ();
+ g_hash_table_insert (
+ registry->priv->table,
+ (gpointer) mime_types[ii],
+ queue);
+ }
+
+ g_queue_push_head (queue, g_object_ref (extension));
+
+ if (camel_debug ("emformat:registry")) {
+ printf (
+ "Added extension '%s' for type '%s'\n",
+ g_type_name (extension_type),
+ mime_types[ii]);
+ }
+ }
+
+ g_object_unref (extension);
+}
+
+/**
* e_mail_extension_registry_get_for_mime_type:
* @regstry: An #EMailExtensionRegistry
* @mime_type: A string with mime-type to look up
@@ -217,36 +224,6 @@ e_mail_parser_extension_registry_init (EMailParserExtensionRegistry *registry)
{
}
-void
-e_mail_parser_extension_registry_load (EMailParserExtensionRegistry *registry)
-{
- GType *children;
- GType base_extension_type;
- guint ii, n_children;
-
- g_return_if_fail (E_IS_MAIL_PARSER_EXTENSION_REGISTRY (registry));
-
- base_extension_type = E_TYPE_MAIL_PARSER_EXTENSION;
- children = g_type_children (base_extension_type, &n_children);
-
- for (ii = 0; ii < n_children; ii++) {
- EMailParserExtensionClass *class;
-
- if (G_TYPE_IS_ABSTRACT (children[ii]))
- continue;
-
- class = g_type_class_ref (children[ii]);
-
- mail_extension_registry_add_extension (
- E_MAIL_EXTENSION_REGISTRY (registry),
- class->mime_types, children[ii]);
-
- g_type_class_unref (class);
- }
-
- g_free (children);
-}
-
/******************************************************************************/
G_DEFINE_TYPE_WITH_CODE (
@@ -265,32 +242,3 @@ e_mail_formatter_extension_registry_init (EMailFormatterExtensionRegistry *regis
{
}
-void
-e_mail_formatter_extension_registry_load (EMailFormatterExtensionRegistry *registry,
- GType base_extension_type)
-{
- GType *children;
- guint ii, n_children;
-
- g_return_if_fail (E_IS_MAIL_FORMATTER_EXTENSION_REGISTRY (registry));
-
- children = g_type_children (base_extension_type, &n_children);
-
- for (ii = 0; ii < n_children; ii++) {
- EMailFormatterExtensionClass *class;
-
- if (G_TYPE_IS_ABSTRACT (children[ii]))
- continue;
-
- class = g_type_class_ref (children[ii]);
-
- mail_extension_registry_add_extension (
- E_MAIL_EXTENSION_REGISTRY (registry),
- class->mime_types, children[ii]);
-
- g_type_class_unref (class);
- }
-
- g_free (children);
-}
-
diff --git a/em-format/e-mail-extension-registry.h b/em-format/e-mail-extension-registry.h
index 7002eb0385..21011ef286 100644
--- a/em-format/e-mail-extension-registry.h
+++ b/em-format/e-mail-extension-registry.h
@@ -57,6 +57,10 @@ struct _EMailExtensionRegistryClass {
GType e_mail_extension_registry_get_type
(void) G_GNUC_CONST;
+void e_mail_extension_registry_add_extension
+ (EMailExtensionRegistry *registry,
+ const gchar **mime_types,
+ GType extension_type);
GQueue * e_mail_extension_registry_get_for_mime_type
(EMailExtensionRegistry *registry,
const gchar *mime_type);
@@ -104,8 +108,6 @@ struct _EMailParserExtensionRegistryClass {
GType e_mail_parser_extension_registry_get_type
(void) G_GNUC_CONST;
-void e_mail_parser_extension_registry_load
- (EMailParserExtensionRegistry *registry);
G_END_DECLS
@@ -147,9 +149,6 @@ struct _EMailFormatterExtensionRegistryClass {
GType e_mail_formatter_extension_registry_get_type
(void) G_GNUC_CONST;
-void e_mail_formatter_extension_registry_load
- (EMailFormatterExtensionRegistry *registry,
- GType base_extension_type);
G_END_DECLS
diff --git a/em-format/e-mail-format-extensions.c b/em-format/e-mail-format-extensions.c
new file mode 100644
index 0000000000..8ba36702a8
--- /dev/null
+++ b/em-format/e-mail-format-extensions.c
@@ -0,0 +1,144 @@
+/*
+ * e-mail-format-extensions.c
+ *
+ * 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/>
+ *
+ */
+
+#include "e-mail-format-extensions.h"
+
+#include "em-format/e-mail-parser-extension.h"
+#include "em-format/e-mail-formatter-extension.h"
+
+typedef GType (*TypeFunc) (void);
+
+TypeFunc parser_funcs[] = {
+ e_mail_parser_application_mbox_get_type,
+ e_mail_parser_attachment_bar_get_type,
+ e_mail_parser_headers_get_type,
+ e_mail_parser_message_get_type,
+ e_mail_parser_secure_button_get_type,
+ e_mail_parser_source_get_type,
+ e_mail_parser_image_get_type,
+ e_mail_parser_inline_pgp_encrypted_get_type,
+ e_mail_parser_inline_pgp_signed_get_type,
+ e_mail_parser_message_delivery_status_get_type,
+ e_mail_parser_message_external_get_type,
+ e_mail_parser_message_rfc822_get_type,
+ e_mail_parser_multipart_alternative_get_type,
+ e_mail_parser_multipart_apple_double_get_type,
+ e_mail_parser_multipart_digest_get_type,
+ e_mail_parser_multipart_encrypted_get_type,
+ e_mail_parser_multipart_mixed_get_type,
+ e_mail_parser_multipart_related_get_type,
+ e_mail_parser_multipart_signed_get_type,
+ e_mail_parser_text_enriched_get_type,
+ e_mail_parser_text_html_get_type,
+ e_mail_parser_text_plain_get_type,
+#ifdef ENABLE_SMIME
+ e_mail_parser_application_smime_get_type,
+#endif
+ NULL
+};
+
+TypeFunc formatter_funcs[] = {
+ e_mail_formatter_attachment_get_type,
+ e_mail_formatter_attachment_bar_get_type,
+ e_mail_formatter_error_get_type,
+ e_mail_formatter_headers_get_type,
+ e_mail_formatter_secure_button_get_type,
+ e_mail_formatter_source_get_type,
+ e_mail_formatter_image_get_type,
+ e_mail_formatter_message_rfc822_get_type,
+ e_mail_formatter_text_enriched_get_type,
+ e_mail_formatter_text_html_get_type,
+ e_mail_formatter_text_plain_get_type,
+ NULL
+};
+
+TypeFunc quote_formatter_funcs[] = {
+ e_mail_formatter_quote_attachment_get_type,
+ e_mail_formatter_quote_headers_get_type,
+ e_mail_formatter_quote_message_rfc822_get_type,
+ e_mail_formatter_quote_text_enriched_get_type,
+ e_mail_formatter_quote_text_html_get_type,
+ e_mail_formatter_quote_text_plain_get_type,
+ NULL
+};
+
+TypeFunc print_formatter_funcs[] = {
+ e_mail_formatter_print_headers_get_type,
+ NULL
+};
+
+static void
+load (EMailExtensionRegistry *ereg,
+ TypeFunc *func_array)
+{
+ gint ii;
+
+ for (ii = 0; func_array[ii] != NULL; ii++) {
+ GType extension_type;
+ GType interface_type;
+ gpointer extension_class;
+ const gchar **mime_types = NULL;
+
+ extension_type = func_array[ii]();
+ extension_class = g_type_class_ref (extension_type);
+
+ interface_type = E_TYPE_MAIL_FORMATTER_EXTENSION;
+ if (g_type_is_a (extension_type, interface_type))
+ mime_types = ((EMailFormatterExtensionClass *)
+ extension_class)->mime_types;
+
+ interface_type = E_TYPE_MAIL_PARSER_EXTENSION;
+ if (g_type_is_a (extension_type, interface_type))
+ mime_types = ((EMailParserExtensionClass *)
+ extension_class)->mime_types;
+
+ if (mime_types != NULL)
+ e_mail_extension_registry_add_extension (
+ ereg, mime_types, extension_type);
+ else
+ g_critical (
+ "%s does not define any MIME types",
+ g_type_name (extension_type));
+
+ g_type_class_unref (extension_class);
+ }
+}
+
+void
+e_mail_parser_internal_extensions_load (EMailExtensionRegistry *ereg)
+{
+ load (ereg, parser_funcs);
+}
+
+void
+e_mail_formatter_internal_extensions_load (EMailExtensionRegistry *ereg)
+{
+ load (ereg, formatter_funcs);
+}
+
+void
+e_mail_formatter_quote_internal_extensions_load (EMailExtensionRegistry *ereg)
+{
+ load (ereg, quote_formatter_funcs);
+}
+
+void
+e_mail_formatter_print_internal_extensions_load (EMailExtensionRegistry *ereg)
+{
+ load (ereg, print_formatter_funcs);
+}
diff --git a/em-format/e-mail-format-extensions.h b/em-format/e-mail-format-extensions.h
new file mode 100644
index 0000000000..1756ee2411
--- /dev/null
+++ b/em-format/e-mail-format-extensions.h
@@ -0,0 +1,88 @@
+/*
+ * e-mail-format-extensions.h
+ *
+ * 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/>
+ *
+ */
+
+#ifndef E_MAIL_FORMAT_EXTENSIONS_H
+#define E_MAIL_FORMAT_EXTENSIONS_H
+
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+
+#include <em-format/e-mail-extension-registry.h>
+#include <em-format/e-mail-part.h>
+#include <e-util/e-util.h>
+
+G_BEGIN_DECLS
+
+void e_mail_formatter_internal_extensions_load (EMailExtensionRegistry *ereg);
+void e_mail_parser_internal_extensions_load (EMailExtensionRegistry *ereg);
+void e_mail_formatter_quote_internal_extensions_load (EMailExtensionRegistry *ereg);
+void e_mail_formatter_print_internal_extensions_load (EMailExtensionRegistry *ereg);
+
+GType e_mail_formatter_attachment_get_type (void);
+GType e_mail_formatter_attachment_bar_get_type
+ (void);
+GType e_mail_formatter_error_get_type (void);
+GType e_mail_formatter_headers_get_type (void);
+GType e_mail_formatter_secure_button_get_type
+ (void);
+GType e_mail_formatter_source_get_type (void);
+GType e_mail_formatter_image_get_type (void);
+GType e_mail_formatter_message_rfc822_get_type (void);
+GType e_mail_formatter_text_enriched_get_type (void);
+GType e_mail_formatter_text_html_get_type (void);
+GType e_mail_formatter_text_plain_get_type (void);
+
+GType e_mail_parser_application_mbox_get_type (void);
+GType e_mail_parser_attachment_bar_get_type (void);
+GType e_mail_parser_headers_get_type (void);
+GType e_mail_parser_message_get_type (void);
+GType e_mail_parser_secure_button_get_type (void);
+GType e_mail_parser_source_get_type (void);
+GType e_mail_parser_image_get_type (void);
+GType e_mail_parser_inline_pgp_encrypted_get_type (void);
+GType e_mail_parser_inline_pgp_signed_get_type (void);
+GType e_mail_parser_message_delivery_status_get_type (void);
+GType e_mail_parser_message_external_get_type (void);
+GType e_mail_parser_message_rfc822_get_type (void);
+GType e_mail_parser_multipart_alternative_get_type (void);
+GType e_mail_parser_multipart_apple_double_get_type (void);
+GType e_mail_parser_multipart_digest_get_type (void);
+GType e_mail_parser_multipart_encrypted_get_type (void);
+GType e_mail_parser_multipart_mixed_get_type (void);
+GType e_mail_parser_multipart_related_get_type (void);
+GType e_mail_parser_multipart_signed_get_type (void);
+GType e_mail_parser_text_enriched_get_type (void);
+GType e_mail_parser_text_html_get_type (void);
+GType e_mail_parser_text_plain_get_type (void);
+#ifdef ENABLE_SMIME
+GType e_mail_parser_application_smime_get_type (void);
+#endif
+
+GType e_mail_formatter_quote_attachment_get_type (void);
+GType e_mail_formatter_quote_headers_get_type (void);
+GType e_mail_formatter_quote_message_rfc822_get_type (void);
+GType e_mail_formatter_quote_text_enriched_get_type (void);
+GType e_mail_formatter_quote_text_html_get_type (void);
+GType e_mail_formatter_quote_text_plain_get_type (void);
+
+GType e_mail_formatter_print_headers_get_type (void);
+
+G_END_DECLS
+
+#endif /* E_MAIL_FORMAT_EXTENSIONS_H */
diff --git a/em-format/e-mail-formatter-attachment-bar.c b/em-format/e-mail-formatter-attachment-bar.c
index 4591501331..5633f4fb33 100644
--- a/em-format/e-mail-formatter-attachment-bar.c
+++ b/em-format/e-mail-formatter-attachment-bar.c
@@ -20,17 +20,15 @@
#include <config.h>
#endif
-#include "e-mail-part-attachment-bar.h"
-
#include <glib/gi18n-lib.h>
+#include "e-mail-format-extensions.h"
#include "e-mail-formatter-extension.h"
+#include "e-mail-part-attachment-bar.h"
typedef EMailFormatterExtension EMailFormatterAttachmentBar;
typedef EMailFormatterExtensionClass EMailFormatterAttachmentBarClass;
-GType e_mail_formatter_attachment_bar_get_type (void);
-
G_DEFINE_TYPE (
EMailFormatterAttachmentBar,
e_mail_formatter_attachment_bar,
diff --git a/em-format/e-mail-formatter-attachment.c b/em-format/e-mail-formatter-attachment.c
index f800ca2994..993b261cca 100644
--- a/em-format/e-mail-formatter-attachment.c
+++ b/em-format/e-mail-formatter-attachment.c
@@ -25,6 +25,7 @@
#include <shell/e-shell.h>
#include <shell/e-shell-window.h>
+#include "e-mail-format-extensions.h"
#include "e-mail-formatter-extension.h"
#include "e-mail-inline-filter.h"
#include "e-mail-part-attachment-bar.h"
@@ -36,8 +37,6 @@
typedef EMailFormatterExtension EMailFormatterAttachment;
typedef EMailFormatterExtensionClass EMailFormatterAttachmentClass;
-GType e_mail_formatter_attachment_get_type (void);
-
G_DEFINE_TYPE (
EMailFormatterAttachment,
e_mail_formatter_attachment,
diff --git a/em-format/e-mail-formatter-error.c b/em-format/e-mail-formatter-error.c
index 3adaab90be..1535bef286 100644
--- a/em-format/e-mail-formatter-error.c
+++ b/em-format/e-mail-formatter-error.c
@@ -19,6 +19,7 @@
#ifdef HAVE_CONFIG_H
#include <config.h>
#endif
+#include "e-mail-format-extensions.h"
#include <glib/gi18n-lib.h>
@@ -29,8 +30,6 @@
typedef EMailFormatterExtension EMailFormatterError;
typedef EMailFormatterExtensionClass EMailFormatterErrorClass;
-GType e_mail_formatter_error_get_type (void);
-
G_DEFINE_TYPE (
EMailFormatterError,
e_mail_formatter_error,
diff --git a/em-format/e-mail-formatter-headers.c b/em-format/e-mail-formatter-headers.c
index 3161d88db9..f64f161571 100644
--- a/em-format/e-mail-formatter-headers.c
+++ b/em-format/e-mail-formatter-headers.c
@@ -28,6 +28,7 @@
#include <e-util/e-util.h>
#include <shell/e-shell.h>
+#include "e-mail-format-extensions.h"
#include "e-mail-formatter-extension.h"
#include "e-mail-formatter-utils.h"
#include "e-mail-inline-filter.h"
@@ -35,8 +36,6 @@
typedef EMailFormatterExtension EMailFormatterHeaders;
typedef EMailFormatterExtensionClass EMailFormatterHeadersClass;
-GType e_mail_formatter_headers_get_type (void);
-
G_DEFINE_TYPE (
EMailFormatterHeaders,
e_mail_formatter_headers,
diff --git a/em-format/e-mail-formatter-image.c b/em-format/e-mail-formatter-image.c
index 4cdd8443e6..7cfa85eb16 100644
--- a/em-format/e-mail-formatter-image.c
+++ b/em-format/e-mail-formatter-image.c
@@ -24,6 +24,7 @@
#include <e-util/e-util.h>
+#include "e-mail-format-extensions.h"
#include "e-mail-formatter-extension.h"
#include "e-mail-inline-filter.h"
#include "e-mail-parser-extension.h"
@@ -32,8 +33,6 @@
typedef EMailFormatterExtension EMailFormatterImage;
typedef EMailFormatterExtensionClass EMailFormatterImageClass;
-GType e_mail_formatter_image_get_type (void);
-
G_DEFINE_TYPE (
EMailFormatterImage,
e_mail_formatter_image,
diff --git a/em-format/e-mail-formatter-message-rfc822.c b/em-format/e-mail-formatter-message-rfc822.c
index 9e88986e98..70c3d20d5b 100644
--- a/em-format/e-mail-formatter-message-rfc822.c
+++ b/em-format/e-mail-formatter-message-rfc822.c
@@ -25,6 +25,7 @@
#include <e-util/e-util.h>
+#include "e-mail-format-extensions.h"
#include "e-mail-formatter-extension.h"
#include "e-mail-part-list.h"
#include "e-mail-part-utils.h"
@@ -32,8 +33,6 @@
typedef EMailFormatterExtension EMailFormatterMessageRFC822;
typedef EMailFormatterExtensionClass EMailFormatterMessageRFC822Class;
-GType e_mail_formatter_message_rfc822_get_type (void);
-
G_DEFINE_TYPE (
EMailFormatterMessageRFC822,
e_mail_formatter_message_rfc822,
diff --git a/em-format/e-mail-formatter-print-headers.c b/em-format/e-mail-formatter-print-headers.c
index c3f683f6b3..1499837fba 100644
--- a/em-format/e-mail-formatter-print-headers.c
+++ b/em-format/e-mail-formatter-print-headers.c
@@ -28,6 +28,7 @@
#include <e-util/e-util.h>
#include <libemail-engine/e-mail-utils.h>
+#include "e-mail-format-extensions.h"
#include "e-mail-formatter-print.h"
#include "e-mail-formatter-utils.h"
#include "e-mail-inline-filter.h"
@@ -35,8 +36,6 @@
typedef EMailFormatterExtension EMailFormatterPrintHeaders;
typedef EMailFormatterExtensionClass EMailFormatterPrintHeadersClass;
-GType e_mail_formatter_print_headers_get_type (void);
-
G_DEFINE_TYPE (
EMailFormatterPrintHeaders,
e_mail_formatter_print_headers,
diff --git a/em-format/e-mail-formatter-print.c b/em-format/e-mail-formatter-print.c
index 7e15b93e0f..6ca91484a4 100644
--- a/em-format/e-mail-formatter-print.c
+++ b/em-format/e-mail-formatter-print.c
@@ -237,9 +237,9 @@ e_mail_formatter_print_base_init (EMailFormatterPrintClass *class)
/* Register internal extensions. */
g_type_ensure (e_mail_formatter_print_headers_get_type ());
- e_mail_formatter_extension_registry_load (
- E_MAIL_FORMATTER_CLASS (class)->extension_registry,
- E_TYPE_MAIL_FORMATTER_PRINT_EXTENSION);
+ e_mail_formatter_print_internal_extensions_load (
+ E_MAIL_EXTENSION_REGISTRY (
+ E_MAIL_FORMATTER_CLASS (class)->extension_registry));
E_MAIL_FORMATTER_CLASS (class)->text_html_flags =
CAMEL_MIME_FILTER_TOHTML_CONVERT_NL |
diff --git a/em-format/e-mail-formatter-quote-attachment.c b/em-format/e-mail-formatter-quote-attachment.c
index 628ef97ab0..df2977bfa1 100644
--- a/em-format/e-mail-formatter-quote-attachment.c
+++ b/em-format/e-mail-formatter-quote-attachment.c
@@ -26,6 +26,7 @@
#include <e-util/e-util.h>
+#include "e-mail-format-extensions.h"
#include "e-mail-formatter-quote.h"
#include "e-mail-part-attachment.h"
#include "e-mail-part-utils.h"
@@ -35,8 +36,6 @@
typedef EMailFormatterExtension EMailFormatterQuoteAttachment;
typedef EMailFormatterExtensionClass EMailFormatterQuoteAttachmentClass;
-GType e_mail_formatter_quote_attachment_get_type (void);
-
G_DEFINE_TYPE (
EMailFormatterQuoteAttachment,
e_mail_formatter_quote_attachment,
diff --git a/em-format/e-mail-formatter-quote-headers.c b/em-format/e-mail-formatter-quote-headers.c
index 8fed82d480..6a6a8b8cce 100644
--- a/em-format/e-mail-formatter-quote-headers.c
+++ b/em-format/e-mail-formatter-quote-headers.c
@@ -28,6 +28,7 @@
#include <e-util/e-util.h>
#include <libemail-engine/e-mail-utils.h>
+#include "e-mail-format-extensions.h"
#include "e-mail-formatter-quote.h"
#include "e-mail-formatter-utils.h"
#include "e-mail-inline-filter.h"
@@ -35,8 +36,6 @@
typedef EMailFormatterExtension EMailFormatterQuoteHeaders;
typedef EMailFormatterExtensionClass EMailFormatterQuoteHeadersClass;
-GType e_mail_formatter_quote_headers_get_type (void);
-
G_DEFINE_TYPE (
EMailFormatterQuoteHeaders,
e_mail_formatter_quote_headers,
diff --git a/em-format/e-mail-formatter-quote-message-rfc822.c b/em-format/e-mail-formatter-quote-message-rfc822.c
index 42b3ba5af8..2e885d5f81 100644
--- a/em-format/e-mail-formatter-quote-message-rfc822.c
+++ b/em-format/e-mail-formatter-quote-message-rfc822.c
@@ -27,6 +27,7 @@
#include <e-util/e-util.h>
+#include "e-mail-format-extensions.h"
#include "e-mail-formatter-quote.h"
#include "e-mail-part-list.h"
#include "e-mail-part-utils.h"
@@ -34,8 +35,6 @@
typedef EMailFormatterExtension EMailFormatterQuoteMessageRFC822;
typedef EMailFormatterExtensionClass EMailFormatterQuoteMessageRFC822Class;
-GType e_mail_formatter_quote_message_rfc822_get_type (void);
-
G_DEFINE_TYPE (
EMailFormatterQuoteMessageRFC822,
e_mail_formatter_quote_message_rfc822,
diff --git a/em-format/e-mail-formatter-quote-text-enriched.c b/em-format/e-mail-formatter-quote-text-enriched.c
index 031cc664db..ce5170e1d5 100644
--- a/em-format/e-mail-formatter-quote-text-enriched.c
+++ b/em-format/e-mail-formatter-quote-text-enriched.c
@@ -26,14 +26,13 @@
#include <e-util/e-util.h>
+#include "e-mail-format-extensions.h"
#include "e-mail-formatter-quote.h"
#include "e-mail-inline-filter.h"
typedef EMailFormatterExtension EMailFormatterQuoteTextEnriched;
typedef EMailFormatterExtensionClass EMailFormatterQuoteTextEnrichedClass;
-GType e_mail_formatter_quote_text_enriched_get_type (void);
-
G_DEFINE_TYPE (
EMailFormatterQuoteTextEnriched,
e_mail_formatter_quote_text_enriched,
diff --git a/em-format/e-mail-formatter-quote-text-html.c b/em-format/e-mail-formatter-quote-text-html.c
index 71c7d63554..c4559a0d51 100644
--- a/em-format/e-mail-formatter-quote-text-html.c
+++ b/em-format/e-mail-formatter-quote-text-html.c
@@ -27,6 +27,7 @@
#include <e-util/e-util.h>
+#include "e-mail-format-extensions.h"
#include "e-mail-formatter-quote.h"
#include "e-mail-part-utils.h"
#include "e-mail-stripsig-filter.h"
@@ -34,8 +35,6 @@
typedef EMailFormatterExtension EMailFormatterQuoteTextHTML;
typedef EMailFormatterExtensionClass EMailFormatterQuoteTextHTMLClass;
-GType e_mail_formatter_quote_text_html_get_type (void);
-
G_DEFINE_TYPE (
EMailFormatterQuoteTextHTML,
e_mail_formatter_quote_text_html,
diff --git a/em-format/e-mail-formatter-quote-text-plain.c b/em-format/e-mail-formatter-quote-text-plain.c
index 71f1762991..e9383d49f1 100644
--- a/em-format/e-mail-formatter-quote-text-plain.c
+++ b/em-format/e-mail-formatter-quote-text-plain.c
@@ -26,6 +26,7 @@
#include <e-util/e-util.h>
+#include "e-mail-format-extensions.h"
#include "e-mail-formatter-quote.h"
#include "e-mail-part-utils.h"
#include "e-mail-stripsig-filter.h"
@@ -33,8 +34,6 @@
typedef EMailFormatterExtension EMailFormatterQuoteTextPlain;
typedef EMailFormatterExtensionClass EMailFormatterQuoteTextPlainClass;
-GType e_mail_formatter_quote_text_plain_get_type (void);
-
G_DEFINE_TYPE (
EMailFormatterQuoteTextPlain,
e_mail_formatter_quote_text_plain,
diff --git a/em-format/e-mail-formatter-quote.c b/em-format/e-mail-formatter-quote.c
index 1a2d84deba..a8833eef9d 100644
--- a/em-format/e-mail-formatter-quote.c
+++ b/em-format/e-mail-formatter-quote.c
@@ -170,9 +170,9 @@ e_mail_formatter_quote_base_init (EMailFormatterQuoteClass *class)
g_type_ensure (e_mail_formatter_quote_text_html_get_type ());
g_type_ensure (e_mail_formatter_quote_text_plain_get_type ());
- e_mail_formatter_extension_registry_load (
- E_MAIL_FORMATTER_CLASS (class)->extension_registry,
- E_TYPE_MAIL_FORMATTER_QUOTE_EXTENSION);
+ e_mail_formatter_quote_internal_extensions_load (
+ E_MAIL_EXTENSION_REGISTRY (
+ E_MAIL_FORMATTER_CLASS (class)->extension_registry));
E_MAIL_FORMATTER_CLASS (class)->text_html_flags =
CAMEL_MIME_FILTER_TOHTML_PRE |
diff --git a/em-format/e-mail-formatter-secure-button.c b/em-format/e-mail-formatter-secure-button.c
index 8f66b2ee42..a3efbb28f7 100644
--- a/em-format/e-mail-formatter-secure-button.c
+++ b/em-format/e-mail-formatter-secure-button.c
@@ -19,6 +19,7 @@
#ifdef HAVE_CONFIG_H
#include <config.h>
#endif
+#include "e-mail-format-extensions.h"
#include <glib/gi18n-lib.h>
@@ -34,8 +35,6 @@
typedef EMailFormatterExtension EMailFormatterSecureButton;
typedef EMailFormatterExtensionClass EMailFormatterSecureButtonClass;
-GType e_mail_formatter_secure_button_get_type (void);
-
G_DEFINE_TYPE (
EMailFormatterSecureButton,
e_mail_formatter_secure_button,
diff --git a/em-format/e-mail-formatter-source.c b/em-format/e-mail-formatter-source.c
index e4ee288261..0753b4836e 100644
--- a/em-format/e-mail-formatter-source.c
+++ b/em-format/e-mail-formatter-source.c
@@ -24,14 +24,13 @@
#include <e-util/e-util.h>
+#include "e-mail-format-extensions.h"
#include "e-mail-formatter-extension.h"
#include "e-mail-inline-filter.h"
typedef EMailFormatterExtension EMailFormatterSource;
typedef EMailFormatterExtensionClass EMailFormatterSourceClass;
-GType e_mail_formatter_source_get_type (void);
-
G_DEFINE_TYPE (
EMailFormatterSource,
e_mail_formatter_source,
diff --git a/em-format/e-mail-formatter-text-enriched.c b/em-format/e-mail-formatter-text-enriched.c
index 1ea46e8138..86ee917a9f 100644
--- a/em-format/e-mail-formatter-text-enriched.c
+++ b/em-format/e-mail-formatter-text-enriched.c
@@ -24,14 +24,13 @@
#include <e-util/e-util.h>
+#include "e-mail-format-extensions.h"
#include "e-mail-formatter-extension.h"
#include "e-mail-inline-filter.h"
typedef EMailFormatterExtension EMailFormatterTextEnriched;
typedef EMailFormatterExtensionClass EMailFormatterTextEnrichedClass;
-GType e_mail_formatter_text_enriched_get_type (void);
-
G_DEFINE_TYPE (
EMailFormatterTextEnriched,
e_mail_formatter_text_enriched,
diff --git a/em-format/e-mail-formatter-text-html.c b/em-format/e-mail-formatter-text-html.c
index a70ec2b2f2..b7a0175ed6 100644
--- a/em-format/e-mail-formatter-text-html.c
+++ b/em-format/e-mail-formatter-text-html.c
@@ -26,6 +26,7 @@
#include <e-util/e-util.h>
+#include "e-mail-format-extensions.h"
#include "e-mail-formatter-extension.h"
#include "e-mail-inline-filter.h"
#include "e-mail-part-utils.h"
@@ -33,8 +34,6 @@
typedef EMailFormatterExtension EMailFormatterTextHTML;
typedef EMailFormatterExtensionClass EMailFormatterTextHTMLClass;
-GType e_mail_formatter_text_html_get_type (void);
-
G_DEFINE_TYPE (
EMailFormatterTextHTML,
e_mail_formatter_text_html,
diff --git a/em-format/e-mail-formatter-text-plain.c b/em-format/e-mail-formatter-text-plain.c
index 278353b40b..bda6e53ba1 100644
--- a/em-format/e-mail-formatter-text-plain.c
+++ b/em-format/e-mail-formatter-text-plain.c
@@ -24,6 +24,7 @@
#include <e-util/e-util.h>
+#include "e-mail-format-extensions.h"
#include "e-mail-formatter-extension.h"
#include "e-mail-inline-filter.h"
#include "e-mail-part-utils.h"
@@ -31,8 +32,6 @@
typedef EMailFormatterExtension EMailFormatterTextPlain;
typedef EMailFormatterExtensionClass EMailFormatterTextPlainClass;
-GType e_mail_formatter_text_plain_get_type (void);
-
G_DEFINE_TYPE (
EMailFormatterTextPlain,
e_mail_formatter_text_plain,
diff --git a/em-format/e-mail-formatter.c b/em-format/e-mail-formatter.c
index dcea08133e..83ba48d460 100644
--- a/em-format/e-mail-formatter.c
+++ b/em-format/e-mail-formatter.c
@@ -526,9 +526,8 @@ e_mail_formatter_base_init (EMailFormatterClass *class)
class->extension_registry = g_object_new (
E_TYPE_MAIL_FORMATTER_EXTENSION_REGISTRY, NULL);
- e_mail_formatter_extension_registry_load (
- class->extension_registry,
- E_TYPE_MAIL_FORMATTER_EXTENSION);
+ e_mail_formatter_internal_extensions_load (
+ E_MAIL_EXTENSION_REGISTRY (class->extension_registry));
e_extensible_load_extensions (
E_EXTENSIBLE (class->extension_registry));
diff --git a/em-format/e-mail-parser-application-mbox.c b/em-format/e-mail-parser-application-mbox.c
index b0fde83b2e..c928debeb6 100644
--- a/em-format/e-mail-parser-application-mbox.c
+++ b/em-format/e-mail-parser-application-mbox.c
@@ -25,14 +25,13 @@
#include <e-util/e-util.h>
+#include "e-mail-format-extensions.h"
#include "e-mail-parser-extension.h"
#include "e-mail-part-utils.h"
typedef EMailParserExtension EMailParserApplicationMBox;
typedef EMailParserExtensionClass EMailParserApplicationMBoxClass;
-GType e_mail_parser_application_mbox_get_type (void);
-
G_DEFINE_TYPE (
EMailParserApplicationMBox,
e_mail_parser_application_mbox,
diff --git a/em-format/e-mail-parser-application-smime.c b/em-format/e-mail-parser-application-smime.c
index 13c3d739c1..a5ab0479c6 100644
--- a/em-format/e-mail-parser-application-smime.c
+++ b/em-format/e-mail-parser-application-smime.c
@@ -25,14 +25,13 @@
#include <e-util/e-util.h>
+#include "e-mail-format-extensions.h"
#include "e-mail-parser-extension.h"
#include "e-mail-part-utils.h"
typedef EMailParserExtension EMailParserApplicationSMIME;
typedef EMailParserExtensionClass EMailParserApplicationSMIMEClass;
-GType e_mail_parser_application_smime_get_type (void);
-
G_DEFINE_TYPE (
EMailParserApplicationSMIME,
e_mail_parser_application_smime,
diff --git a/em-format/e-mail-parser-attachment-bar.c b/em-format/e-mail-parser-attachment-bar.c
index 44fbb9cc82..ecc6be677d 100644
--- a/em-format/e-mail-parser-attachment-bar.c
+++ b/em-format/e-mail-parser-attachment-bar.c
@@ -19,6 +19,7 @@
#ifdef HAVE_CONFIG_H
#include <config.h>
#endif
+#include "e-mail-format-extensions.h"
#include "e-mail-part-attachment-bar.h"
@@ -41,8 +42,6 @@ mail_part_attachment_bar_free (EMailPart *part)
typedef EMailParserExtension EMailParserAttachmentBar;
typedef EMailParserExtensionClass EMailParserAttachmentBarClass;
-GType e_mail_parser_attachment_bar_get_type (void);
-
G_DEFINE_TYPE (
EMailParserAttachmentBar,
e_mail_parser_attachment_bar,
diff --git a/em-format/e-mail-parser-headers.c b/em-format/e-mail-parser-headers.c
index f2900945d1..009371fa1a 100644
--- a/em-format/e-mail-parser-headers.c
+++ b/em-format/e-mail-parser-headers.c
@@ -26,13 +26,12 @@
#include <e-util/e-util.h>
#include <libemail-engine/e-mail-utils.h>
+#include "e-mail-format-extensions.h"
#include "e-mail-parser-extension.h"
typedef EMailParserExtension EMailParserHeaders;
typedef EMailParserExtensionClass EMailParserHeadersClass;
-GType e_mail_parser_headers_get_type (void);
-
G_DEFINE_TYPE (
EMailParserHeaders,
e_mail_parser_headers,
diff --git a/em-format/e-mail-parser-image.c b/em-format/e-mail-parser-image.c
index 741daa7454..5360bdb176 100644
--- a/em-format/e-mail-parser-image.c
+++ b/em-format/e-mail-parser-image.c
@@ -24,14 +24,13 @@
#include <e-util/e-util.h>
+#include "e-mail-format-extensions.h"
#include "e-mail-parser-extension.h"
#include "e-mail-part-utils.h"
typedef EMailParserExtension EMailParserImage;
typedef EMailParserExtensionClass EMailParserImageClass;
-GType e_mail_parser_image_get_type (void);
-
G_DEFINE_TYPE (
EMailParserImage,
e_mail_parser_image,
diff --git a/em-format/e-mail-parser-inlinepgp-encrypted.c b/em-format/e-mail-parser-inlinepgp-encrypted.c
index 624452c8b0..99c787199f 100644
--- a/em-format/e-mail-parser-inlinepgp-encrypted.c
+++ b/em-format/e-mail-parser-inlinepgp-encrypted.c
@@ -25,14 +25,13 @@
#include <e-util/e-util.h>
+#include "e-mail-format-extensions.h"
#include "e-mail-parser-extension.h"
#include "e-mail-part-utils.h"
typedef EMailParserExtension EMailParserInlinePGPEncrypted;
typedef EMailParserExtensionClass EMailParserInlinePGPEncryptedClass;
-GType e_mail_parser_inline_pgp_encrypted_get_type (void);
-
G_DEFINE_TYPE (
EMailParserInlinePGPEncrypted,
e_mail_parser_inline_pgp_encrypted,
diff --git a/em-format/e-mail-parser-inlinepgp-signed.c b/em-format/e-mail-parser-inlinepgp-signed.c
index fb65e5c447..faf7be6e22 100644
--- a/em-format/e-mail-parser-inlinepgp-signed.c
+++ b/em-format/e-mail-parser-inlinepgp-signed.c
@@ -25,14 +25,13 @@
#include <e-util/e-util.h>
+#include "e-mail-format-extensions.h"
#include "e-mail-parser-extension.h"
#include "e-mail-part-utils.h"
typedef EMailParserExtension EMailParserInlinePGPSigned;
typedef EMailParserExtensionClass EMailParserInlinePGPSignedClass;
-GType e_mail_parser_inline_pgp_signed_get_type (void);
-
G_DEFINE_TYPE (
EMailParserInlinePGPSigned,
e_mail_parser_inline_pgp_signed,
diff --git a/em-format/e-mail-parser-message-deliverystatus.c b/em-format/e-mail-parser-message-deliverystatus.c
index d02bbf9149..88fa8ce448 100644
--- a/em-format/e-mail-parser-message-deliverystatus.c
+++ b/em-format/e-mail-parser-message-deliverystatus.c
@@ -24,13 +24,12 @@
#include <e-util/e-util.h>
+#include "e-mail-format-extensions.h"
#include "e-mail-parser-extension.h"
typedef EMailParserExtension EMailParserMessageDeliveryStatus;
typedef EMailParserExtensionClass EMailParserMessageDeliveryStatusClass;
-GType e_mail_parser_message_delivery_status_get_type (void);
-
G_DEFINE_TYPE (
EMailParserMessageDeliveryStatus,
e_mail_parser_message_delivery_status,
diff --git a/em-format/e-mail-parser-message-external.c b/em-format/e-mail-parser-message-external.c
index d24bb657e1..c6b6de13a7 100644
--- a/em-format/e-mail-parser-message-external.c
+++ b/em-format/e-mail-parser-message-external.c
@@ -26,13 +26,12 @@
#include <e-util/e-util.h>
+#include "e-mail-format-extensions.h"
#include "e-mail-parser-extension.h"
typedef EMailParserExtension EMailParserMessageExternal;
typedef EMailParserExtensionClass EMailParserMessageExternalClass;
-GType e_mail_parser_message_external_get_type (void);
-
G_DEFINE_TYPE (
EMailParserMessageExternal,
e_mail_parser_message_external,
diff --git a/em-format/e-mail-parser-message-rfc822.c b/em-format/e-mail-parser-message-rfc822.c
index ca9dd67df9..bafdd62286 100644
--- a/em-format/e-mail-parser-message-rfc822.c
+++ b/em-format/e-mail-parser-message-rfc822.c
@@ -25,6 +25,7 @@
#include <e-util/e-util.h>
+#include "e-mail-format-extensions.h"
#include "e-mail-parser-extension.h"
#include "e-mail-part-list.h"
#include "e-mail-part-utils.h"
@@ -32,8 +33,6 @@
typedef EMailParserExtension EMailParserMessageRFC822;
typedef EMailParserExtensionClass EMailParserMessageRFC822Class;
-GType e_mail_parser_message_rfc822_get_type (void);
-
G_DEFINE_TYPE (
EMailParserMessageRFC822,
e_mail_parser_message_rfc822,
diff --git a/em-format/e-mail-parser-message.c b/em-format/e-mail-parser-message.c
index 9cd0a2d76c..696c230876 100644
--- a/em-format/e-mail-parser-message.c
+++ b/em-format/e-mail-parser-message.c
@@ -26,14 +26,13 @@
#include <e-util/e-util.h>
#include <libemail-engine/e-mail-utils.h>
+#include "e-mail-format-extensions.h"
#include "e-mail-parser-extension.h"
#include "e-mail-part-utils.h"
typedef EMailParserExtension EMailParserMessage;
typedef EMailParserExtensionClass EMailParserMessageClass;
-GType e_mail_parser_message_get_type (void);
-
G_DEFINE_TYPE (
EMailParserMessage,
e_mail_parser_message,
diff --git a/em-format/e-mail-parser-multipart-alternative.c b/em-format/e-mail-parser-multipart-alternative.c
index cc1c8724db..2e78d0667c 100644
--- a/em-format/e-mail-parser-multipart-alternative.c
+++ b/em-format/e-mail-parser-multipart-alternative.c
@@ -24,14 +24,13 @@
#include <e-util/e-util.h>
+#include "e-mail-format-extensions.h"
#include "e-mail-parser-extension.h"
#include "e-mail-part-utils.h"
typedef EMailParserExtension EMailParserMultipartAlternative;
typedef EMailParserExtensionClass EMailParserMultipartAlternativeClass;
-GType e_mail_parser_multipart_alternative_get_type (void);
-
G_DEFINE_TYPE (
EMailParserMultipartAlternative,
e_mail_parser_multipart_alternative,
diff --git a/em-format/e-mail-parser-multipart-appledouble.c b/em-format/e-mail-parser-multipart-appledouble.c
index a866363717..e27bb78039 100644
--- a/em-format/e-mail-parser-multipart-appledouble.c
+++ b/em-format/e-mail-parser-multipart-appledouble.c
@@ -20,13 +20,12 @@
#include <config.h>
#endif
+#include "e-mail-format-extensions.h"
#include "e-mail-parser-extension.h"
typedef EMailParserExtension EMailParserMultipartAppleDouble;
typedef EMailParserExtensionClass EMailParserMultipartAppleDoubleClass;
-GType e_mail_parser_multipart_apple_double_get_type (void);
-
G_DEFINE_TYPE (
EMailParserMultipartAppleDouble,
e_mail_parser_multipart_apple_double,
diff --git a/em-format/e-mail-parser-multipart-digest.c b/em-format/e-mail-parser-multipart-digest.c
index 64d4882a8c..df1b680860 100644
--- a/em-format/e-mail-parser-multipart-digest.c
+++ b/em-format/e-mail-parser-multipart-digest.c
@@ -24,13 +24,12 @@
#include <e-util/e-util.h>
+#include "e-mail-format-extensions.h"
#include "e-mail-parser-extension.h"
typedef EMailParserExtension EMailParserMultipartDigest;
typedef EMailParserExtensionClass EMailParserMultipartDigestClass;
-GType e_mail_parser_multipart_digest_get_type (void);
-
G_DEFINE_TYPE (
EMailParserMultipartDigest,
e_mail_parser_multipart_digest,
diff --git a/em-format/e-mail-parser-multipart-encrypted.c b/em-format/e-mail-parser-multipart-encrypted.c
index c815ab543c..f0e2e94b0b 100644
--- a/em-format/e-mail-parser-multipart-encrypted.c
+++ b/em-format/e-mail-parser-multipart-encrypted.c
@@ -24,14 +24,13 @@
#include <libedataserver/libedataserver.h>
+#include "e-mail-format-extensions.h"
#include "e-mail-parser-extension.h"
#include "e-mail-part-utils.h"
typedef EMailParserExtension EMailParserMultipartEncrypted;
typedef EMailParserExtensionClass EMailParserMultipartEncryptedClass;
-GType e_mail_parser_multipart_encrypted_get_type (void);
-
G_DEFINE_TYPE (
EMailParserMultipartEncrypted,
e_mail_parser_multipart_encrypted,
diff --git a/em-format/e-mail-parser-multipart-mixed.c b/em-format/e-mail-parser-multipart-mixed.c
index 9e876eef4e..8fbd55febe 100644
--- a/em-format/e-mail-parser-multipart-mixed.c
+++ b/em-format/e-mail-parser-multipart-mixed.c
@@ -24,14 +24,13 @@
#include <e-util/e-util.h>
+#include "e-mail-format-extensions.h"
#include "e-mail-parser-extension.h"
#include "e-mail-part-utils.h"
typedef EMailParserExtension EMailParserMultipartMixed;
typedef EMailParserExtensionClass EMailParserMultipartMixedClass;
-GType e_mail_parser_multipart_mixed_get_type (void);
-
G_DEFINE_TYPE (
EMailParserMultipartMixed,
e_mail_parser_multipart_mixed,
diff --git a/em-format/e-mail-parser-multipart-related.c b/em-format/e-mail-parser-multipart-related.c
index a1cbbf7a41..5d94f656a1 100644
--- a/em-format/e-mail-parser-multipart-related.c
+++ b/em-format/e-mail-parser-multipart-related.c
@@ -24,14 +24,13 @@
#include <e-util/e-util.h>
+#include "e-mail-format-extensions.h"
#include "e-mail-parser-extension.h"
#include "e-mail-part-utils.h"
typedef EMailParserExtension EMailParserMultipartRelated;
typedef EMailParserExtensionClass EMailParserMultipartRelatedClass;
-GType e_mail_parser_multipart_related_get_type (void);
-
G_DEFINE_TYPE (
EMailParserMultipartRelated,
e_mail_parser_multipart_related,
diff --git a/em-format/e-mail-parser-multipart-signed.c b/em-format/e-mail-parser-multipart-signed.c
index 514d40fafb..dc3262df34 100644
--- a/em-format/e-mail-parser-multipart-signed.c
+++ b/em-format/e-mail-parser-multipart-signed.c
@@ -24,14 +24,13 @@
#include <libedataserver/libedataserver.h>
+#include "e-mail-format-extensions.h"
#include "e-mail-parser-extension.h"
#include "e-mail-part-utils.h"
typedef EMailParserExtension EMailParserMultipartSigned;
typedef EMailParserExtensionClass EMailParserMultipartSignedClass;
-GType e_mail_parser_multipart_signed_get_type (void);
-
G_DEFINE_TYPE (
EMailParserMultipartSigned,
e_mail_parser_multipart_signed,
diff --git a/em-format/e-mail-parser-secure-button.c b/em-format/e-mail-parser-secure-button.c
index 38368592c7..59d573ce9a 100644
--- a/em-format/e-mail-parser-secure-button.c
+++ b/em-format/e-mail-parser-secure-button.c
@@ -19,6 +19,7 @@
#ifdef HAVE_CONFIG_H
#include <config.h>
#endif
+#include "e-mail-format-extensions.h"
#include <glib/gi18n-lib.h>
@@ -29,8 +30,6 @@
typedef EMailParserExtension EMailParserSecureButton;
typedef EMailParserExtensionClass EMailParserSecureButtonClass;
-GType e_mail_parser_secure_button_get_type (void);
-
G_DEFINE_TYPE (
EMailParserSecureButton,
e_mail_parser_secure_button,
diff --git a/em-format/e-mail-parser-source.c b/em-format/e-mail-parser-source.c
index ff8355db15..d20051d9f3 100644
--- a/em-format/e-mail-parser-source.c
+++ b/em-format/e-mail-parser-source.c
@@ -24,13 +24,12 @@
#include <e-util/e-util.h>
+#include "e-mail-format-extensions.h"
#include "e-mail-parser-extension.h"
typedef EMailParserExtension EMailParserSource;
typedef EMailParserExtensionClass EMailParserSourceClass;
-GType e_mail_parser_source_get_type (void);
-
G_DEFINE_TYPE (
EMailParserSource,
e_mail_parser_source,
diff --git a/em-format/e-mail-parser-text-enriched.c b/em-format/e-mail-parser-text-enriched.c
index 024d160196..2c4edaa612 100644
--- a/em-format/e-mail-parser-text-enriched.c
+++ b/em-format/e-mail-parser-text-enriched.c
@@ -24,14 +24,13 @@
#include <e-util/e-util.h>
+#include "e-mail-format-extensions.h"
#include "e-mail-parser-extension.h"
#include "e-mail-part-utils.h"
typedef EMailParserExtension EMailParserTextEnriched;
typedef EMailParserExtensionClass EMailParserTextEnrichedClass;
-GType e_mail_parser_text_enriched_get_type (void);
-
G_DEFINE_TYPE (
EMailParserTextEnriched,
e_mail_parser_text_enriched,
diff --git a/em-format/e-mail-parser-text-html.c b/em-format/e-mail-parser-text-html.c
index ccfc5d6eb3..3fa17acfc1 100644
--- a/em-format/e-mail-parser-text-html.c
+++ b/em-format/e-mail-parser-text-html.c
@@ -25,14 +25,13 @@
#include <e-util/e-util.h>
+#include "e-mail-format-extensions.h"
#include "e-mail-parser-extension.h"
#include "e-mail-part-utils.h"
typedef EMailParserExtension EMailParserTextHTML;
typedef EMailParserExtensionClass EMailParserTextHTMLClass;
-GType e_mail_parser_text_html_get_type (void);
-
G_DEFINE_TYPE (
EMailParserTextHTML,
e_mail_parser_text_html,
diff --git a/em-format/e-mail-parser-text-plain.c b/em-format/e-mail-parser-text-plain.c
index f0b34e4b2c..bbe7e6e5e3 100644
--- a/em-format/e-mail-parser-text-plain.c
+++ b/em-format/e-mail-parser-text-plain.c
@@ -25,6 +25,7 @@
#include <e-util/e-util.h>
+#include "e-mail-format-extensions.h"
#include "e-mail-inline-filter.h"
#include "e-mail-parser-extension.h"
#include "e-mail-part-utils.h"
@@ -32,8 +33,6 @@
typedef EMailParserExtension EMailParserTextPlain;
typedef EMailParserExtensionClass EMailParserTextPlainClass;
-GType e_mail_parser_text_plain_get_type (void);
-
G_DEFINE_TYPE (
EMailParserTextPlain,
e_mail_parser_text_plain,
diff --git a/em-format/e-mail-parser.c b/em-format/e-mail-parser.c
index 359efe7d9b..762302ba80 100644
--- a/em-format/e-mail-parser.c
+++ b/em-format/e-mail-parser.c
@@ -233,7 +233,8 @@ e_mail_parser_base_init (EMailParserClass *class)
class->extension_registry = g_object_new (
E_TYPE_MAIL_PARSER_EXTENSION_REGISTRY, NULL);
- e_mail_parser_extension_registry_load (class->extension_registry);
+ e_mail_parser_internal_extensions_load (
+ E_MAIL_EXTENSION_REGISTRY (class->extension_registry));
e_extensible_load_extensions (E_EXTENSIBLE (class->extension_registry));
}
diff --git a/modules/audio-inline/e-mail-formatter-audio-inline.c b/modules/audio-inline/e-mail-formatter-audio-inline.c
index 7abcf934fa..235315a64d 100644
--- a/modules/audio-inline/e-mail-formatter-audio-inline.c
+++ b/modules/audio-inline/e-mail-formatter-audio-inline.c
@@ -43,12 +43,18 @@ typedef EExtension EMailFormatterAudioInlineLoader;
typedef EExtensionClass EMailFormatterAudioInlineLoaderClass;
GType e_mail_formatter_audio_inline_get_type (void);
+GType e_mail_formatter_audio_inline_loader_get_type (void);
G_DEFINE_DYNAMIC_TYPE (
EMailFormatterAudioInline,
e_mail_formatter_audio_inline,
E_TYPE_MAIL_FORMATTER_EXTENSION)
+G_DEFINE_DYNAMIC_TYPE (
+ EMailFormatterAudioInlineLoader,
+ e_mail_formatter_audio_inline_loader,
+ E_TYPE_EXTENSION)
+
static const gchar *formatter_mime_types[] = {
"application/vnd.evolution.widget.audio-inline",
"audio/ac3",
@@ -323,9 +329,44 @@ e_mail_formatter_audio_inline_init (EMailFormatterExtension *extension)
{
}
+static void
+mail_formatter_audio_inline_loader_constructed (GObject *object)
+{
+ EExtensible *extensible;
+
+ extensible = e_extension_get_extensible (E_EXTENSION (object));
+
+ e_mail_extension_registry_add_extension (
+ E_MAIL_EXTENSION_REGISTRY (extensible),
+ formatter_mime_types,
+ e_mail_formatter_audio_inline_get_type ());
+}
+
+static void
+e_mail_formatter_audio_inline_loader_class_init (EExtensionClass *class)
+{
+ GObjectClass *object_class;
+
+ object_class = G_OBJECT_CLASS (class);
+ object_class->constructed = mail_formatter_audio_inline_loader_constructed;
+
+ class->extensible_type = E_TYPE_MAIL_FORMATTER_EXTENSION_REGISTRY;
+}
+
+static void
+e_mail_formatter_audio_inline_loader_class_finalize (EExtensionClass *class)
+{
+}
+
+static void
+e_mail_formatter_audio_inline_loader_init (EExtension *extension)
+{
+}
+
void
e_mail_formatter_audio_inline_type_register (GTypeModule *type_module)
{
e_mail_formatter_audio_inline_register_type (type_module);
+ e_mail_formatter_audio_inline_loader_register_type (type_module);
}
diff --git a/modules/audio-inline/e-mail-parser-audio-inline.c b/modules/audio-inline/e-mail-parser-audio-inline.c
index 1ebbf905ba..a4ef834e1e 100644
--- a/modules/audio-inline/e-mail-parser-audio-inline.c
+++ b/modules/audio-inline/e-mail-parser-audio-inline.c
@@ -45,12 +45,18 @@ typedef EExtension EMailParserAudioInlineLoader;
typedef EExtensionClass EMailParserAudioInlineLoaderClass;
GType e_mail_parser_audio_inline_get_type (void);
+GType e_mail_parser_audio_inline_loader_get_type (void);
G_DEFINE_DYNAMIC_TYPE (
EMailParserAudioInline,
e_mail_parser_audio_inline,
E_TYPE_MAIL_PARSER_EXTENSION)
+G_DEFINE_DYNAMIC_TYPE (
+ EMailParserAudioInlineLoader,
+ e_mail_parser_audio_inline_loader,
+ E_TYPE_EXTENSION)
+
static const gchar *parser_mime_types[] = {
"audio/ac3",
"audio/x-ac3",
@@ -158,9 +164,44 @@ e_mail_parser_audio_inline_init (EMailParserExtension *extension)
{
}
+static void
+mail_parser_audio_inline_loader_constructed (GObject *object)
+{
+ EExtensible *extensible;
+
+ extensible = e_extension_get_extensible (E_EXTENSION (object));
+
+ e_mail_extension_registry_add_extension (
+ E_MAIL_EXTENSION_REGISTRY (extensible),
+ parser_mime_types,
+ e_mail_parser_audio_inline_get_type ());
+}
+
+static void
+e_mail_parser_audio_inline_loader_class_init (EExtensionClass *class)
+{
+ GObjectClass *object_class;
+
+ object_class = G_OBJECT_CLASS (class);
+ object_class->constructed = mail_parser_audio_inline_loader_constructed;
+
+ class->extensible_type = E_TYPE_MAIL_PARSER_EXTENSION_REGISTRY;
+}
+
+static void
+e_mail_parser_audio_inline_loader_class_finalize (EExtensionClass *class)
+{
+}
+
+static void
+e_mail_parser_audio_inline_loader_init (EExtension *extension)
+{
+}
+
void
e_mail_parser_audio_inline_type_register (GTypeModule *type_module)
{
e_mail_parser_audio_inline_register_type (type_module);
+ e_mail_parser_audio_inline_loader_register_type (type_module);
}
diff --git a/modules/itip-formatter/e-mail-formatter-itip.c b/modules/itip-formatter/e-mail-formatter-itip.c
index 500810b639..6d5a3f1ac1 100644
--- a/modules/itip-formatter/e-mail-formatter-itip.c
+++ b/modules/itip-formatter/e-mail-formatter-itip.c
@@ -37,6 +37,9 @@
typedef EMailFormatterExtension EMailFormatterItip;
typedef EMailFormatterExtensionClass EMailFormatterItipClass;
+typedef EExtension EMailFormatterItipLoader;
+typedef EExtensionClass EMailFormatterItipLoaderClass;
+
GType e_mail_formatter_itip_get_type (void);
GType e_mail_formatter_itip_loader_get_type (void);
@@ -45,6 +48,11 @@ G_DEFINE_DYNAMIC_TYPE (
e_mail_formatter_itip,
E_TYPE_MAIL_FORMATTER_EXTENSION)
+G_DEFINE_DYNAMIC_TYPE (
+ EMailFormatterItipLoader,
+ e_mail_formatter_itip_loader,
+ E_TYPE_EXTENSION)
+
static const gchar *formatter_mime_types[] = {
"text/calendar",
"application/ics",
@@ -158,8 +166,43 @@ e_mail_formatter_itip_init (EMailFormatterExtension *extension)
{
}
+static void
+mail_formatter_itip_loader_constructed (GObject *object)
+{
+ EExtensible *extensible;
+
+ extensible = e_extension_get_extensible (E_EXTENSION (object));
+
+ e_mail_extension_registry_add_extension (
+ E_MAIL_EXTENSION_REGISTRY (extensible),
+ formatter_mime_types,
+ e_mail_formatter_itip_get_type ());
+}
+
+static void
+e_mail_formatter_itip_loader_class_init (EExtensionClass *class)
+{
+ GObjectClass *object_class;
+
+ object_class = G_OBJECT_CLASS (class);
+ object_class->constructed = mail_formatter_itip_loader_constructed;
+
+ class->extensible_type = E_TYPE_MAIL_FORMATTER_EXTENSION_REGISTRY;
+}
+
+static void
+e_mail_formatter_itip_loader_class_finalize (EExtensionClass *class)
+{
+}
+
+static void
+e_mail_formatter_itip_loader_init (EExtension *extension)
+{
+}
+
void
e_mail_formatter_itip_type_register (GTypeModule *type_module)
{
e_mail_formatter_itip_register_type (type_module);
+ e_mail_formatter_itip_loader_register_type (type_module);
}
diff --git a/modules/itip-formatter/e-mail-parser-itip.c b/modules/itip-formatter/e-mail-parser-itip.c
index 9e5ff46e45..5d2cb458f1 100644
--- a/modules/itip-formatter/e-mail-parser-itip.c
+++ b/modules/itip-formatter/e-mail-parser-itip.c
@@ -50,12 +50,18 @@ typedef EExtension EMailParserItipLoader;
typedef EExtensionClass EMailParserItipLoaderClass;
GType e_mail_parser_itip_get_type (void);
+GType e_mail_parser_itip_loader_get_type (void);
G_DEFINE_DYNAMIC_TYPE (
EMailParserItip,
e_mail_parser_itip,
E_TYPE_MAIL_PARSER_EXTENSION)
+G_DEFINE_DYNAMIC_TYPE (
+ EMailParserItipLoader,
+ e_mail_parser_itip_loader,
+ E_TYPE_EXTENSION)
+
static const gchar *parser_mime_types[] = {
"text/calendar",
"application/ics",
@@ -259,9 +265,44 @@ e_mail_parser_itip_init (EMailParserExtension *class)
{
}
+static void
+mail_parser_itip_loader_constructed (GObject *object)
+{
+ EExtensible *extensible;
+
+ extensible = e_extension_get_extensible (E_EXTENSION (object));
+
+ e_mail_extension_registry_add_extension (
+ E_MAIL_EXTENSION_REGISTRY (extensible),
+ parser_mime_types,
+ e_mail_parser_itip_get_type ());
+}
+
+static void
+e_mail_parser_itip_loader_class_init (EExtensionClass *class)
+{
+ GObjectClass *object_class;
+
+ object_class = G_OBJECT_CLASS (class);
+ object_class->constructed = mail_parser_itip_loader_constructed;
+
+ class->extensible_type = E_TYPE_MAIL_PARSER_EXTENSION_REGISTRY;
+}
+
+static void
+e_mail_parser_itip_loader_class_finalize (EExtensionClass *class)
+{
+}
+
+static void
+e_mail_parser_itip_loader_init (EExtension *extension)
+{
+}
+
void
e_mail_parser_itip_type_register (GTypeModule *type_module)
{
e_mail_parser_itip_register_type (type_module);
+ e_mail_parser_itip_loader_register_type (type_module);
}
diff --git a/modules/prefer-plain/e-mail-parser-prefer-plain.c b/modules/prefer-plain/e-mail-parser-prefer-plain.c
index 914b96952d..dfe4b22092 100644
--- a/modules/prefer-plain/e-mail-parser-prefer-plain.c
+++ b/modules/prefer-plain/e-mail-parser-prefer-plain.c
@@ -51,6 +51,7 @@ struct _EMailParserPreferPlainClass {
};
GType e_mail_parser_prefer_plain_get_type (void);
+GType e_mail_parser_prefer_plain_loader_get_type (void);
enum {
PREFER_HTML,
@@ -63,6 +64,11 @@ G_DEFINE_DYNAMIC_TYPE (
e_mail_parser_prefer_plain,
E_TYPE_MAIL_PARSER_EXTENSION)
+G_DEFINE_DYNAMIC_TYPE (
+ EMailParserPreferPlainLoader,
+ e_mail_parser_prefer_plain_loader,
+ E_TYPE_EXTENSION)
+
static const gchar *parser_mime_types[] = {
"multipart/alternative",
"text/html",
@@ -499,9 +505,44 @@ e_mail_parser_prefer_plain_init (EMailParserPreferPlain *parser)
parser->show_suppressed = g_settings_get_boolean (parser->settings, "show-suppressed");
}
+static void
+mail_parser_prefer_plain_loader_constructed (GObject *object)
+{
+ EExtensible *extensible;
+
+ extensible = e_extension_get_extensible (E_EXTENSION (object));
+
+ e_mail_extension_registry_add_extension (
+ E_MAIL_EXTENSION_REGISTRY (extensible),
+ parser_mime_types,
+ e_mail_parser_prefer_plain_get_type ());
+}
+
+static void
+e_mail_parser_prefer_plain_loader_class_init (EExtensionClass *class)
+{
+ GObjectClass *object_class;
+
+ object_class = G_OBJECT_CLASS (class);
+ object_class->constructed = mail_parser_prefer_plain_loader_constructed;
+
+ class->extensible_type = E_TYPE_MAIL_PARSER_EXTENSION_REGISTRY;
+}
+
+static void
+e_mail_parser_prefer_plain_loader_class_finalize (EExtensionClass *class)
+{
+}
+
+static void
+e_mail_parser_prefer_plain_loader_init (EExtension *extension)
+{
+}
+
void
e_mail_parser_prefer_plain_type_register (GTypeModule *type_module)
{
e_mail_parser_prefer_plain_register_type (type_module);
+ e_mail_parser_prefer_plain_loader_register_type (type_module);
}
diff --git a/modules/text-highlight/e-mail-formatter-text-highlight.c b/modules/text-highlight/e-mail-formatter-text-highlight.c
index 5e8c15c16c..ea4cb6c839 100644
--- a/modules/text-highlight/e-mail-formatter-text-highlight.c
+++ b/modules/text-highlight/e-mail-formatter-text-highlight.c
@@ -45,12 +45,18 @@ typedef EExtension EMailFormatterTextHighlightLoader;
typedef EExtensionClass EMailFormatterTextHighlightLoaderClass;
GType e_mail_formatter_text_highlight_get_type (void);
+GType e_mail_formatter_text_highlight_loader_get_type (void);
G_DEFINE_DYNAMIC_TYPE (
EMailFormatterTextHighlight,
e_mail_formatter_text_highlight,
E_TYPE_MAIL_FORMATTER_EXTENSION)
+G_DEFINE_DYNAMIC_TYPE (
+ EMailFormatterTextHighlightLoader,
+ e_mail_formatter_text_highlight_loader,
+ E_TYPE_EXTENSION)
+
static gchar *
get_default_font (void)
{
@@ -384,9 +390,44 @@ e_mail_formatter_text_highlight_init (EMailFormatterExtension *extension)
{
}
+static void
+mail_formatter_text_highlight_loader_constructed (GObject *object)
+{
+ EExtensible *extensible;
+
+ extensible = e_extension_get_extensible (E_EXTENSION (object));
+
+ e_mail_extension_registry_add_extension (
+ E_MAIL_EXTENSION_REGISTRY (extensible),
+ get_mime_types (),
+ e_mail_formatter_text_highlight_get_type ());
+}
+
+static void
+e_mail_formatter_text_highlight_loader_class_init (EExtensionClass *class)
+{
+ GObjectClass *object_class;
+
+ object_class = G_OBJECT_CLASS (class);
+ object_class->constructed = mail_formatter_text_highlight_loader_constructed;
+
+ class->extensible_type = E_TYPE_MAIL_FORMATTER_EXTENSION_REGISTRY;
+}
+
+static void
+e_mail_formatter_text_highlight_loader_class_finalize (EExtensionClass *class)
+{
+}
+
+static void
+e_mail_formatter_text_highlight_loader_init (EExtension *extension)
+{
+}
+
void
e_mail_formatter_text_highlight_type_register (GTypeModule *type_module)
{
e_mail_formatter_text_highlight_register_type (type_module);
+ e_mail_formatter_text_highlight_loader_register_type (type_module);
}
diff --git a/modules/text-highlight/e-mail-parser-text-highlight.c b/modules/text-highlight/e-mail-parser-text-highlight.c
index 28d10409b1..99d920fe0b 100644
--- a/modules/text-highlight/e-mail-parser-text-highlight.c
+++ b/modules/text-highlight/e-mail-parser-text-highlight.c
@@ -41,12 +41,18 @@ typedef EExtension EMailParserTextHighlightLoader;
typedef EExtensionClass EMailParserTextHighlightLoaderClass;
GType e_mail_parser_text_highlight_get_type (void);
+GType e_mail_parser_text_highlight_loader_get_type (void);
G_DEFINE_DYNAMIC_TYPE (
EMailParserTextHighlight,
e_mail_parser_text_highlight,
E_TYPE_MAIL_PARSER_EXTENSION)
+G_DEFINE_DYNAMIC_TYPE (
+ EMailParserTextHighlightLoader,
+ e_mail_parser_text_highlight_loader,
+ E_TYPE_EXTENSION)
+
static gboolean
empe_text_highlight_parse (EMailParserExtension *extension,
EMailParser *parser,
@@ -104,9 +110,44 @@ e_mail_parser_text_highlight_init (EMailParserExtension *extension)
{
}
+static void
+mail_parser_text_highlight_loader_constructed (GObject *object)
+{
+ EExtensible *extensible;
+
+ extensible = e_extension_get_extensible (E_EXTENSION (object));
+
+ e_mail_extension_registry_add_extension (
+ E_MAIL_EXTENSION_REGISTRY (extensible),
+ get_mime_types (),
+ e_mail_parser_text_highlight_get_type ());
+}
+
+static void
+e_mail_parser_text_highlight_loader_class_init (EExtensionClass *class)
+{
+ GObjectClass *object_class;
+
+ object_class = G_OBJECT_CLASS (class);
+ object_class->constructed = mail_parser_text_highlight_loader_constructed;
+
+ class->extensible_type = E_TYPE_MAIL_PARSER_EXTENSION_REGISTRY;
+}
+
+static void
+e_mail_parser_text_highlight_loader_class_finalize (EExtensionClass *class)
+{
+}
+
+static void
+e_mail_parser_text_highlight_loader_init (EExtension *extension)
+{
+}
+
void
e_mail_parser_text_highlight_type_register (GTypeModule *type_module)
{
e_mail_parser_text_highlight_register_type (type_module);
+ e_mail_parser_text_highlight_loader_register_type (type_module);
}
diff --git a/modules/tnef-attachment/e-mail-parser-tnef-attachment.c b/modules/tnef-attachment/e-mail-parser-tnef-attachment.c
index dc93b91955..cc9d024349 100644
--- a/modules/tnef-attachment/e-mail-parser-tnef-attachment.c
+++ b/modules/tnef-attachment/e-mail-parser-tnef-attachment.c
@@ -64,12 +64,18 @@ typedef EExtension EMailParserTnefAttachmentLoader;
typedef EExtensionClass EMailParserTnefAttachmentLoaderClass;
GType e_mail_parser_tnef_attachment_get_type (void);
+GType e_mail_parser_tnef_attachment_loader_get_type (void);
G_DEFINE_DYNAMIC_TYPE (
EMailParserTnefAttachment,
e_mail_parser_tnef_attachment,
E_TYPE_MAIL_PARSER_EXTENSION)
+G_DEFINE_DYNAMIC_TYPE (
+ EMailParserTnefAttachmentLoader,
+ e_mail_parser_tnef_attachment_loader,
+ E_TYPE_EXTENSION)
+
static const gchar *parser_mime_types[] = {
"application/vnd.ms-tnef",
"application/ms-tnefl",
@@ -274,10 +280,45 @@ e_mail_parser_tnef_attachment_init (EMailParserTnefAttachment *extension)
{
}
+static void
+mail_parser_tnef_attachment_loader_constructed (GObject *object)
+{
+ EExtensible *extensible;
+
+ extensible = e_extension_get_extensible (E_EXTENSION (object));
+
+ e_mail_extension_registry_add_extension (
+ E_MAIL_EXTENSION_REGISTRY (extensible),
+ parser_mime_types,
+ e_mail_parser_tnef_attachment_get_type ());
+}
+
+static void
+e_mail_parser_tnef_attachment_loader_class_init (EExtensionClass *class)
+{
+ GObjectClass *object_class;
+
+ object_class = G_OBJECT_CLASS (class);
+ object_class->constructed = mail_parser_tnef_attachment_loader_constructed;
+
+ class->extensible_type = E_TYPE_MAIL_PARSER_EXTENSION_REGISTRY;
+}
+
+static void
+e_mail_parser_tnef_attachment_loader_class_finalize (EExtensionClass *class)
+{
+}
+
+static void
+e_mail_parser_tnef_attachment_loader_init (EExtension *extension)
+{
+}
+
void
e_mail_parser_tnef_attachment_type_register (GTypeModule *type_module)
{
e_mail_parser_tnef_attachment_register_type (type_module);
+ e_mail_parser_tnef_attachment_loader_register_type (type_module);
}
void
diff --git a/modules/vcard-inline/e-mail-formatter-vcard-inline.c b/modules/vcard-inline/e-mail-formatter-vcard-inline.c
index bcced23351..3032f23560 100644
--- a/modules/vcard-inline/e-mail-formatter-vcard-inline.c
+++ b/modules/vcard-inline/e-mail-formatter-vcard-inline.c
@@ -43,12 +43,18 @@ typedef EExtension EMailFormatterVCardInlineLoader;
typedef EExtensionClass EMailFormatterVCardInlineLoaderClass;
GType e_mail_formatter_vcard_inline_get_type (void);
+GType e_mail_formatter_vcard_inline_loader_get_type (void);
G_DEFINE_DYNAMIC_TYPE (
EMailFormatterVCardInline,
e_mail_formatter_vcard_inline,
E_TYPE_MAIL_FORMATTER_EXTENSION)
+G_DEFINE_DYNAMIC_TYPE (
+ EMailFormatterVCardInlineLoader,
+ e_mail_formatter_vcard_inline_loader,
+ E_TYPE_EXTENSION)
+
static const gchar *formatter_mime_types[] = {
"text/vcard",
"text/x-vcard",
@@ -217,9 +223,44 @@ e_mail_formatter_vcard_inline_init (EMailFormatterExtension *extension)
{
}
+static void
+mail_formatter_vcard_inline_loader_constructed (GObject *object)
+{
+ EExtensible *extensible;
+
+ extensible = e_extension_get_extensible (E_EXTENSION (object));
+
+ e_mail_extension_registry_add_extension (
+ E_MAIL_EXTENSION_REGISTRY (extensible),
+ formatter_mime_types,
+ e_mail_formatter_vcard_inline_get_type ());
+}
+
+static void
+e_mail_formatter_vcard_inline_loader_class_init (EExtensionClass *class)
+{
+ GObjectClass *object_class;
+
+ object_class = G_OBJECT_CLASS (class);
+ object_class->constructed = mail_formatter_vcard_inline_loader_constructed;
+
+ class->extensible_type = E_TYPE_MAIL_FORMATTER_EXTENSION_REGISTRY;
+}
+
+static void
+e_mail_formatter_vcard_inline_loader_class_finalize (EExtensionClass *class)
+{
+}
+
+static void
+e_mail_formatter_vcard_inline_loader_init (EExtension *extension)
+{
+}
+
void
e_mail_formatter_vcard_inline_type_register (GTypeModule *type_module)
{
e_mail_formatter_vcard_inline_register_type (type_module);
+ e_mail_formatter_vcard_inline_loader_register_type (type_module);
}
diff --git a/modules/vcard-inline/e-mail-parser-vcard-inline.c b/modules/vcard-inline/e-mail-parser-vcard-inline.c
index b871351d0a..c1064dd28f 100644
--- a/modules/vcard-inline/e-mail-parser-vcard-inline.c
+++ b/modules/vcard-inline/e-mail-parser-vcard-inline.c
@@ -54,12 +54,18 @@ typedef EExtension EMailParserVCardInlineLoader;
typedef EExtensionClass EMailParserVCardInlineLoaderClass;
GType e_mail_parser_vcard_inline_get_type (void);
+GType e_mail_parser_vcard_inline_loader_get_type (void);
G_DEFINE_DYNAMIC_TYPE (
EMailParserVCardInline,
e_mail_parser_vcard_inline,
E_TYPE_MAIL_PARSER_EXTENSION)
+G_DEFINE_DYNAMIC_TYPE (
+ EMailParserVCardInlineLoader,
+ e_mail_parser_vcard_inline_loader,
+ E_TYPE_EXTENSION)
+
static const gchar *parser_mime_types[] = {
"text/vcard",
"text/x-vcard",
@@ -382,9 +388,44 @@ e_mail_parser_vcard_inline_init (EMailParserExtension *extension)
{
}
+static void
+mail_parser_vcard_inline_loader_constructed (GObject *object)
+{
+ EExtensible *extensible;
+
+ extensible = e_extension_get_extensible (E_EXTENSION (object));
+
+ e_mail_extension_registry_add_extension (
+ E_MAIL_EXTENSION_REGISTRY (extensible),
+ parser_mime_types,
+ e_mail_parser_vcard_inline_get_type ());
+}
+
+static void
+e_mail_parser_vcard_inline_loader_class_init (EExtensionClass *class)
+{
+ GObjectClass *object_class;
+
+ object_class = G_OBJECT_CLASS (class);
+ object_class->constructed = mail_parser_vcard_inline_loader_constructed;
+
+ class->extensible_type = E_TYPE_MAIL_PARSER_EXTENSION_REGISTRY;
+}
+
+static void
+e_mail_parser_vcard_inline_loader_class_finalize (EExtensionClass *class)
+{
+}
+
+static void
+e_mail_parser_vcard_inline_loader_init (EExtension *extension)
+{
+}
+
void
e_mail_parser_vcard_inline_type_register (GTypeModule *type_module)
{
e_mail_parser_vcard_inline_register_type (type_module);
+ e_mail_parser_vcard_inline_loader_register_type (type_module);
}