From: Tristan Chabredier Date: Fri, 15 Dec 2006 16:41:15 +0000 (+0000) Subject: 2006-12-15 [wwp] 2.6.1cvs40 X-Git-Tag: rel_2_7_0~83 X-Git-Url: http://git.claws-mail.org/?p=claws.git;a=commitdiff_plain;h=a949999b77f5b742a59b9a29ca7ce82b5194ad15 2006-12-15 [wwp] 2.6.1cvs40 * src/wizard.c * src/common/plugin.c * src/common/plugin.h * src/gtk/about.c * src/plugins/bogofilter/bogofilter.c * src/plugins/clamav/clamav_plugin.c * src/plugins/demo/demo.c * src/plugins/dillo_viewer/dillo_viewer.c * src/plugins/pgpcore/plugin.c * src/plugins/pgpinline/plugin.c * src/plugins/pgpmime/plugin.c * src/plugins/spamassassin/spamassassin.c * src/plugins/trayicon/trayicon.c factorize some translatable strings (plugins-related), fix missing punctuation in several places, remove useless translatable \n in about.c, and factorize plugin init code w/ a new function check_plugin_version() in common/plugin.c. Patch by Fabien Vantard . --- diff --git a/ChangeLog b/ChangeLog index f33565d1c..a346c3ed9 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,25 @@ +2006-12-15 [wwp] 2.6.1cvs40 + + * src/wizard.c + * src/common/plugin.c + * src/common/plugin.h + * src/gtk/about.c + * src/plugins/bogofilter/bogofilter.c + * src/plugins/clamav/clamav_plugin.c + * src/plugins/demo/demo.c + * src/plugins/dillo_viewer/dillo_viewer.c + * src/plugins/pgpcore/plugin.c + * src/plugins/pgpinline/plugin.c + * src/plugins/pgpmime/plugin.c + * src/plugins/spamassassin/spamassassin.c + * src/plugins/trayicon/trayicon.c + factorize some translatable strings (plugins-related), + fix missing punctuation in several places, + remove useless translatable \n in about.c, + and factorize plugin init code w/ a new function + check_plugin_version() in common/plugin.c. + Patch by Fabien Vantard . + 2006-12-15 [wwp] 2.6.1cvs39 * src/plugins/bogofilter/bogofilter.c diff --git a/PATCHSETS b/PATCHSETS index 66a8a91ab..77b633ff2 100644 --- a/PATCHSETS +++ b/PATCHSETS @@ -2147,3 +2147,4 @@ ( cvs diff -u -r 1.207.2.137 -r 1.207.2.138 src/folderview.c; ) > 2.6.1cvs37.patchset ( cvs diff -u -r 1.1.2.16 -r 1.1.2.17 src/plugins/bogofilter/bogofilter.c; cvs diff -u -r 1.1.2.5 -r 1.1.2.6 src/plugins/bogofilter/bogofilter.h; cvs diff -u -r 1.1.2.9 -r 1.1.2.10 src/plugins/bogofilter/bogofilter_gtk.c; ) > 2.6.1cvs38.patchset ( cvs diff -u -r 1.1.2.17 -r 1.1.2.18 src/plugins/bogofilter/bogofilter.c; cvs diff -u -r 1.1.2.10 -r 1.1.2.11 src/plugins/bogofilter/bogofilter_gtk.c; ) > 2.6.1cvs39.patchset +( cvs diff -u -r 1.1.2.43 -r 1.1.2.44 src/wizard.c; cvs diff -u -r 1.13.2.22 -r 1.13.2.23 src/common/plugin.c; cvs diff -u -r 1.5.2.8 -r 1.5.2.9 src/common/plugin.h; cvs diff -u -r 1.4.2.43 -r 1.4.2.44 src/gtk/about.c; cvs diff -u -r 1.1.2.18 -r 1.1.2.19 src/plugins/bogofilter/bogofilter.c; cvs diff -u -r 1.13.2.27 -r 1.13.2.28 src/plugins/clamav/clamav_plugin.c; cvs diff -u -r 1.13.2.11 -r 1.13.2.12 src/plugins/demo/demo.c; cvs diff -u -r 1.12.2.17 -r 1.12.2.18 src/plugins/dillo_viewer/dillo_viewer.c; cvs diff -u -r 1.1.2.14 -r 1.1.2.15 src/plugins/pgpcore/plugin.c; cvs diff -u -r 1.1.2.12 -r 1.1.2.13 src/plugins/pgpinline/plugin.c; cvs diff -u -r 1.1.2.22 -r 1.1.2.23 src/plugins/pgpmime/plugin.c; cvs diff -u -r 1.18.2.44 -r 1.18.2.45 src/plugins/spamassassin/spamassassin.c; cvs diff -u -r 1.14.2.45 -r 1.14.2.46 src/plugins/trayicon/trayicon.c; ) > 2.6.1cvs40.patchset diff --git a/configure.ac b/configure.ac index efec99e05..bfdcb5235 100644 --- a/configure.ac +++ b/configure.ac @@ -11,7 +11,7 @@ MINOR_VERSION=6 MICRO_VERSION=1 INTERFACE_AGE=0 BINARY_AGE=0 -EXTRA_VERSION=39 +EXTRA_VERSION=40 EXTRA_RELEASE= EXTRA_GTK2_VERSION= diff --git a/src/common/plugin.c b/src/common/plugin.c index 6fb99d61c..55ad8ce3f 100644 --- a/src/common/plugin.c +++ b/src/common/plugin.c @@ -32,6 +32,7 @@ #include "utils.h" #include "plugin.h" #include "prefs.h" +#include "claws.h" struct _Plugin { @@ -520,3 +521,46 @@ const gchar *plugin_get_error(Plugin *plugin) { return plugin->error; } + +/* Generally called in plugin_init() function of each plugin. It check the + * minimal and compiled version of claws binary required by the plugin. + * If (@minimum_claws_version == 0 || @compiled_claws_version == 0), don't + * check the corresponding version. + * + * If an error occurs { + * If @error == NULL { don't allocate error string. } + * If @error != NULL { error string is allocated and must be freed after + * call function. } + * } + * Returns: FALSE if an error occurs, TRUE if all is OK. + */ +gint check_plugin_version(guint32 minimum_claws_version, + guint32 compiled_claws_version, + const gchar *plugin_name, + gchar **error) +{ + guint32 claws_version = claws_get_version(); + + if (compiled_claws_version != 0 && claws_version > compiled_claws_version) { + if (error != NULL) { + *error = (plugin_name && *plugin_name) + ? g_strdup_printf(_("Your version of Claws Mail is newer than the " + "version the '%s' plugin was built with."), + plugin_name) + : g_strdup(_("Your version of Claws Mail is newer than the " + "version the plugin was built with.")); + } + return FALSE; + } + + if (minimum_claws_version != 0 && claws_version < minimum_claws_version) { + if (error != NULL) { + *error = (plugin_name && *plugin_name) + ? g_strdup_printf(_("Your version of Claws Mail is too old for " + "the '%s' plugin."), plugin_name) + : g_strdup(_("Your version of Claws Mail is too old for the plugin.")); + } + return FALSE; + } + return TRUE; +} diff --git a/src/common/plugin.h b/src/common/plugin.h index 3fa56bd7e..7ff4b4fef 100644 --- a/src/common/plugin.h +++ b/src/common/plugin.h @@ -63,4 +63,8 @@ const gchar *plugin_get_name (Plugin *plugin); const gchar *plugin_get_desc (Plugin *plugin); const gchar *plugin_get_version (Plugin *plugin); const gchar *plugin_get_error (Plugin *plugin); +gint check_plugin_version (guint32 minimum_claws_version, + guint32 compiled_claws_version, + const gchar *plugin_name, + gchar **error); #endif diff --git a/src/gtk/about.c b/src/gtk/about.c index 853d6835d..d029ebb0e 100644 --- a/src/gtk/about.c +++ b/src/gtk/about.c @@ -306,8 +306,9 @@ static void about_create(void) "underline", PANGO_UNDERLINE_SINGLE, NULL); - gtk_text_buffer_insert_with_tags_by_name(buffer, &iter, (_("The Claws Mail Team\n")), -1, + gtk_text_buffer_insert_with_tags_by_name(buffer, &iter, (_("The Claws Mail Team")), -1, "underlined-list-title", NULL); + gtk_text_buffer_insert(buffer, &iter, "\n", 1); for (i = 0; TEAM_LIST[i] != NULL; i++) { if (g_utf8_validate(TEAM_LIST[i], -1, NULL)) @@ -323,8 +324,10 @@ static void about_create(void) gtk_text_buffer_insert(buffer, &iter, "\n", 1); } - gtk_text_buffer_insert_with_tags_by_name(buffer, &iter, (_("\nPrevious team members\n")), -1, + gtk_text_buffer_insert(buffer, &iter, "\n", 1); + gtk_text_buffer_insert_with_tags_by_name(buffer, &iter, (_("Previous team members")), -1, "underlined-list-title", NULL); + gtk_text_buffer_insert(buffer, &iter, "\n", 1); for (i = 0; EX_TEAM_LIST[i] != NULL; i++) { if (g_utf8_validate(EX_TEAM_LIST[i], -1, NULL)) @@ -340,8 +343,10 @@ static void about_create(void) gtk_text_buffer_insert(buffer, &iter, "\n", 1); } - gtk_text_buffer_insert_with_tags_by_name(buffer, &iter, (_("\nThe translation team\n")), -1, + gtk_text_buffer_insert(buffer, &iter, "\n", 1); + gtk_text_buffer_insert_with_tags_by_name(buffer, &iter, (_("The translation team")), -1, "underlined-list-title", NULL); + gtk_text_buffer_insert(buffer, &iter, "\n", 1); for (i = 0; TRANS_TEAM_LIST[i] != NULL; i++) { if (g_utf8_validate(TRANS_TEAM_LIST[i], -1, NULL)) @@ -357,8 +362,10 @@ static void about_create(void) gtk_text_buffer_insert(buffer, &iter, "\n", 1); } - gtk_text_buffer_insert_with_tags_by_name(buffer, &iter, (_("\nDocumentation team\n")), -1, + gtk_text_buffer_insert(buffer, &iter, "\n", 1); + gtk_text_buffer_insert_with_tags_by_name(buffer, &iter, (_("Documentation team")), -1, "underlined-list-title", NULL); + gtk_text_buffer_insert(buffer, &iter, "\n", 1); for (i = 0; DOC_TEAM_LIST[i] != NULL; i++) { if (g_utf8_validate(DOC_TEAM_LIST[i], -1, NULL)) @@ -374,8 +381,10 @@ static void about_create(void) gtk_text_buffer_insert(buffer, &iter, "\n", 1); } - gtk_text_buffer_insert_with_tags_by_name(buffer, &iter, (_("\nLogo\n")), -1, + gtk_text_buffer_insert(buffer, &iter, "\n", 1); + gtk_text_buffer_insert_with_tags_by_name(buffer, &iter, (_("Logo")), -1, "underlined-list-title", NULL); + gtk_text_buffer_insert(buffer, &iter, "\n", 1); for (i = 0; LOGO_LIST[i] != NULL; i++) { if (g_utf8_validate(LOGO_LIST[i], -1, NULL)) @@ -391,8 +400,10 @@ static void about_create(void) gtk_text_buffer_insert(buffer, &iter, "\n", 1); } - gtk_text_buffer_insert_with_tags_by_name(buffer, &iter, (_("\nIcons\n")), -1, + gtk_text_buffer_insert(buffer, &iter, "\n", 1); + gtk_text_buffer_insert_with_tags_by_name(buffer, &iter, (_("Icons")), -1, "underlined-list-title", NULL); + gtk_text_buffer_insert(buffer, &iter, "\n", 1); for (i = 0; ICONS_LIST[i] != NULL; i++) { if (g_utf8_validate(ICONS_LIST[i], -1, NULL)) @@ -408,8 +419,10 @@ static void about_create(void) gtk_text_buffer_insert(buffer, &iter, "\n", 1); } - gtk_text_buffer_insert_with_tags_by_name(buffer, &iter, (_("\nContributors\n")), -1, + gtk_text_buffer_insert(buffer, &iter, "\n", 1); + gtk_text_buffer_insert_with_tags_by_name(buffer, &iter, (_("Contributors")), -1, "underlined-list-title", NULL); + gtk_text_buffer_insert(buffer, &iter, "\n", 1); for (i = 0; CONTRIBS_LIST[i] != NULL; i++) { if (g_utf8_validate(CONTRIBS_LIST[i], -1, NULL)) diff --git a/src/plugins/bogofilter/bogofilter.c b/src/plugins/bogofilter/bogofilter.c index f63ea50fe..f8992ec57 100644 --- a/src/plugins/bogofilter/bogofilter.c +++ b/src/plugins/bogofilter/bogofilter.c @@ -73,6 +73,8 @@ #include #endif +#define PLUGIN_NAME (_("Bogofilter")) + static guint hook_id = -1; static MessageCallback message_callback; @@ -760,15 +762,9 @@ gint plugin_init(gchar **error) hook_id = -1; - if ((claws_get_version() > VERSION_NUMERIC)) { - *error = g_strdup(_("Your version of Claws Mail is newer than the version the Bogofilter plugin was built with")); + if (!check_plugin_version(MAKE_NUMERIC_VERSION(0, 9, 3, 86), + VERSION_NUMERIC, PLUGIN_NAME, error)) return -1; - } - - if ((claws_get_version() < MAKE_NUMERIC_VERSION(0, 9, 3, 86))) { - *error = g_strdup(_("Your version of Claws Mail is too old for the Bogofilter plugin")); - return -1; - } prefs_set_default(param); rcpath = g_strconcat(get_rc_dir(), G_DIR_SEPARATOR_S, COMMON_RC, NULL); @@ -811,7 +807,7 @@ void plugin_done(void) const gchar *plugin_name(void) { - return _("Bogofilter"); + return PLUGIN_NAME; } const gchar *plugin_desc(void) diff --git a/src/plugins/clamav/clamav_plugin.c b/src/plugins/clamav/clamav_plugin.c index 05ee9a227..71825b1fb 100644 --- a/src/plugins/clamav/clamav_plugin.c +++ b/src/plugins/clamav/clamav_plugin.c @@ -40,6 +40,8 @@ #include "clamav_plugin.h" +#define PLUGIN_NAME (_("Clam AntiVirus")) + static guint hook_id; static MessageCallback message_callback; @@ -194,15 +196,9 @@ gint plugin_init(gchar **error) int ret; unsigned int no; - if ((claws_get_version() > VERSION_NUMERIC)) { - *error = g_strdup(_("Your version of Claws Mail is newer than the version the ClamAV plugin was built with")); + if (!check_plugin_version(MAKE_NUMERIC_VERSION(0, 9, 3, 86), + VERSION_NUMERIC, PLUGIN_NAME, error)) return -1; - } - - if ((claws_get_version() < MAKE_NUMERIC_VERSION(0, 9, 3, 86))) { - *error = g_strdup(_("Your version of Claws Mail is too old for the ClamAV plugin")); - return -1; - } hook_id = hooks_register_hook(MAIL_FILTERING_HOOKLIST, mail_filtering_hook, NULL); if (hook_id == -1) { @@ -249,7 +245,7 @@ void plugin_done(void) const gchar *plugin_name(void) { - return _("Clam AntiVirus"); + return PLUGIN_NAME; } const gchar *plugin_desc(void) diff --git a/src/plugins/demo/demo.c b/src/plugins/demo/demo.c index 0aa454252..71a77c232 100644 --- a/src/plugins/demo/demo.c +++ b/src/plugins/demo/demo.c @@ -17,7 +17,7 @@ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ - #include +#include #include @@ -28,6 +28,8 @@ #include "hooks.h" #include "log.h" +#define PLUGIN_NAME (_("Demo")) + gboolean my_log_hook(gpointer source, gpointer data) { LogText *logtext = (LogText *)source; @@ -41,15 +43,9 @@ static guint hook_id; gint plugin_init(gchar **error) { - if ((claws_get_version() > VERSION_NUMERIC)) { - *error = g_strdup(_("Your claws-mail version is newer than the version the plugin was built with")); + if (!check_plugin_version(MAKE_NUMERIC_VERSION(0, 8, 11, 39), + VERSION_NUMERIC, PLUGIN_NAME, error)) return -1; - } - - if ((claws_get_version() < MAKE_NUMERIC_VERSION(0, 8, 11, 39))) { - *error = g_strdup(_("Your claws-mail version is too old")); - return -1; - } hook_id = hooks_register_hook(LOG_APPEND_TEXT_HOOKLIST, my_log_hook, NULL); if (hook_id == -1) { @@ -71,7 +67,7 @@ void plugin_done(void) const gchar *plugin_name(void) { - return _("Demo"); + return PLUGIN_NAME; } const gchar *plugin_desc(void) @@ -79,7 +75,7 @@ const gchar *plugin_desc(void) return _("This Plugin is only a demo of how to write plugins for Claws Mail. " "It installs a hook for new log output and writes it to stdout." "\n\n" - "It is not really useful"); + "It is not really useful."); } const gchar *plugin_type(void) diff --git a/src/plugins/dillo_viewer/dillo_viewer.c b/src/plugins/dillo_viewer/dillo_viewer.c index f18fa4571..d8628249f 100644 --- a/src/plugins/dillo_viewer/dillo_viewer.c +++ b/src/plugins/dillo_viewer/dillo_viewer.c @@ -36,6 +36,8 @@ #include "dillo_prefs.h" +#define PLUGIN_NAME (_("Dillo HTML Viewer")) + typedef struct _DilloViewer DilloViewer; struct _DilloViewer @@ -165,15 +167,9 @@ static MimeViewerFactory dillo_viewer_factory = gint plugin_init(gchar **error) { - if ((claws_get_version() > VERSION_NUMERIC)) { - *error = g_strdup(_("Your version of Claws Mail is newer than the version the Dillo plugin was built with")); - return -1; - } - - if ((claws_get_version() < MAKE_NUMERIC_VERSION(0, 9, 3, 86))) { - *error = g_strdup(_("Your version of Claws Mail is too old for the Dillo plugin")); - return -1; - } + if (!check_plugin_version(MAKE_NUMERIC_VERSION(0, 9, 3, 86), + VERSION_NUMERIC, PLUGIN_NAME, error)) + return -1; dillo_prefs_init(); @@ -191,7 +187,7 @@ void plugin_done(void) const gchar *plugin_name(void) { - return _("Dillo HTML Viewer"); + return PLUGIN_NAME; } const gchar *plugin_desc(void) diff --git a/src/plugins/pgpcore/plugin.c b/src/plugins/pgpcore/plugin.c index 03461e20b..6c4cdfddf 100644 --- a/src/plugins/pgpcore/plugin.c +++ b/src/plugins/pgpcore/plugin.c @@ -32,17 +32,13 @@ #include "pgp_viewer.h" #include "plugin.h" +#define PLUGIN_NAME (_("PGP/Core")) + gint plugin_init(gchar **error) { - if ((claws_get_version() > VERSION_NUMERIC)) { - *error = g_strdup(_("Your version of Claws Mail is newer than the version the PGP/Core plugin was built with")); - return -1; - } - - if ((claws_get_version() < MAKE_NUMERIC_VERSION(2, 1, 0, 1))) { - *error = g_strdup(_("Your version of Claws Mail is too old for the PGP/Core plugin")); + if (!check_plugin_version(MAKE_NUMERIC_VERSION(2, 1, 0, 1), + VERSION_NUMERIC, PLUGIN_NAME, error)) return -1; - } sgpgme_init(); prefs_gpg_init(); @@ -60,7 +56,7 @@ void plugin_done(void) const gchar *plugin_name(void) { - return _("PGP/Core"); + return PLUGIN_NAME; } const gchar *plugin_desc(void) diff --git a/src/plugins/pgpinline/plugin.c b/src/plugins/pgpinline/plugin.c index 534e78e3b..9e21b2799 100644 --- a/src/plugins/pgpinline/plugin.c +++ b/src/plugins/pgpinline/plugin.c @@ -30,17 +30,13 @@ #include "version.h" #include "pgpinline.h" +#define PLUGIN_NAME (_("PGP/inline")) + gint plugin_init(gchar **error) { - if ((claws_get_version() > VERSION_NUMERIC)) { - *error = g_strdup(_("Your version of Claws Mail is newer than the version the PGP/inline plugin was built with")); - return -1; - } - - if ((claws_get_version() < MAKE_NUMERIC_VERSION(2, 1, 0, 1))) { - *error = g_strdup(_("Your version of Claws Mail is too old for the PGP/inline plugin")); - return -1; - } + if (!check_plugin_version(MAKE_NUMERIC_VERSION(2, 1, 0, 1), + VERSION_NUMERIC, PLUGIN_NAME, error)) + return -1; pgpinline_init(); @@ -54,7 +50,7 @@ void plugin_done(void) const gchar *plugin_name(void) { - return _("PGP/inline"); + return PLUGIN_NAME; } const gchar *plugin_desc(void) diff --git a/src/plugins/pgpmime/plugin.c b/src/plugins/pgpmime/plugin.c index 1800c53a9..3f42f9f5f 100644 --- a/src/plugins/pgpmime/plugin.c +++ b/src/plugins/pgpmime/plugin.c @@ -28,18 +28,15 @@ #include "version.h" #include "common/claws.h" #include "pgpmime.h" +#include "plugin.h" + +#define PLUGIN_NAME (_("PGP/MIME")) gint plugin_init(gchar **error) { - if ((claws_get_version() > VERSION_NUMERIC)) { - *error = g_strdup(_("Your version of Claws Mail is newer than the version the PGP/MIME plugin was built with")); - return -1; - } - - if ((claws_get_version() < MAKE_NUMERIC_VERSION(2, 1, 0, 1))) { - *error = g_strdup(_("Your version of Claws Mail is too old for the PGP/MIME plugin")); + if (!check_plugin_version(MAKE_NUMERIC_VERSION(2, 1, 0, 1), + VERSION_NUMERIC, PLUGIN_NAME, error)) return -1; - } pgpmime_init(); @@ -53,7 +50,7 @@ void plugin_done(void) const gchar *plugin_name(void) { - return _("PGP/MIME"); + return PLUGIN_NAME; } const gchar *plugin_desc(void) diff --git a/src/plugins/spamassassin/spamassassin.c b/src/plugins/spamassassin/spamassassin.c index 6864e331f..7c8d3dd37 100644 --- a/src/plugins/spamassassin/spamassassin.c +++ b/src/plugins/spamassassin/spamassassin.c @@ -72,6 +72,8 @@ #include #endif +#define PLUGIN_NAME (_("SpamAssassin")) + enum { CHILD_RUNNING = 1 << 0, TIMEOUT_RUNNING = 1 << 1, @@ -465,15 +467,9 @@ gint plugin_init(gchar **error) hook_id = -1; - if ((claws_get_version() > VERSION_NUMERIC)) { - *error = g_strdup(_("Your version of Claws Mail is newer than the version the SpamAssassin plugin was built with")); + if (!check_plugin_version(MAKE_NUMERIC_VERSION(0, 9, 3, 86), + VERSION_NUMERIC, PLUGIN_NAME, error)) return -1; - } - - if ((claws_get_version() < MAKE_NUMERIC_VERSION(0, 9, 3, 86))) { - *error = g_strdup(_("Your version of Claws Mail is too old for the SpamAssassin plugin")); - return -1; - } prefs_set_default(param); rcpath = g_strconcat(get_rc_dir(), G_DIR_SEPARATOR_S, COMMON_RC, NULL); @@ -520,7 +516,7 @@ void plugin_done(void) const gchar *plugin_name(void) { - return _("SpamAssassin"); + return PLUGIN_NAME; } const gchar *plugin_desc(void) diff --git a/src/plugins/trayicon/trayicon.c b/src/plugins/trayicon/trayicon.c index 78cc4d62c..2b7a684bc 100644 --- a/src/plugins/trayicon/trayicon.c +++ b/src/plugins/trayicon/trayicon.c @@ -56,6 +56,8 @@ #include "unreadmail.offline.xpm" #include "nomail.offline.xpm" +#define PLUGIN_NAME (_("Trayicon")) + static guint item_hook_id; static guint folder_hook_id; static guint offline_hook_id; @@ -350,15 +352,9 @@ static void create_trayicon() int plugin_init(gchar **error) { - if ((claws_get_version() > VERSION_NUMERIC)) { - *error = g_strdup(_("Your version of Claws Mail is newer than the version the Trayicon plugin was built with")); + if (!check_plugin_version(MAKE_NUMERIC_VERSION(0, 9, 3, 86), + VERSION_NUMERIC, PLUGIN_NAME, error)) return -1; - } - - if ((claws_get_version() < MAKE_NUMERIC_VERSION(0, 9, 3, 86))) { - *error = g_strdup(_("Your version of Claws Mail is too old for the Trayicon plugin")); - return -1; - } item_hook_id = hooks_register_hook (FOLDER_ITEM_UPDATE_HOOKLIST, folder_item_update_hook, NULL); if (item_hook_id == -1) { @@ -411,7 +407,7 @@ void plugin_done(void) const gchar *plugin_name(void) { - return _("Trayicon"); + return PLUGIN_NAME; } const gchar *plugin_desc(void) diff --git a/src/wizard.c b/src/wizard.c index 989e74313..e38f1048a 100644 --- a/src/wizard.c +++ b/src/wizard.c @@ -458,13 +458,13 @@ static void write_welcome_email(WizardWindow *wizard) get_rfc822_date(buf_date, sizeof(buf_date)); conv_encode_header_full(enc_subject, sizeof(enc_subject), - _("Welcome to Claws Mail "), + Q_("Welcome Mail Subject|Welcome to Claws Mail"), strlen("Subject: "), FALSE, CS_INTERNAL); conv_encode_header_full(enc_to_name, sizeof(enc_to_name), gtk_entry_get_text(GTK_ENTRY(wizard->full_name)), strlen("To: "), TRUE, CS_INTERNAL); conv_encode_header_full(enc_from_name, sizeof(enc_from_name), - _("Claws Mail Team"), + _("The Claws Mail Team"), strlen("From: "), TRUE, CS_INTERNAL); head = g_strdup_printf( @@ -483,7 +483,7 @@ static void write_welcome_email(WizardWindow *wizard) body = g_strdup_printf( _("\n" "Welcome to Claws Mail\n" - "-------------------------\n" + "---------------------\n" "\n" "Now that you have set up your account you can fetch your\n" "mail by clicking the 'Get Mail' button at the left of the\n"