pidgin/purple-plugin-pack

Parents b9b3f0d8bcc6
Children 3249d7f0bf0f
Update these to translate strings at runtime in init_plugin().
--- a/autoprofile/autoprofile.c Sat Dec 04 10:49:38 2010 -0500
+++ b/autoprofile/autoprofile.c Sat Dec 04 13:50:49 2010 -0500
@@ -139,17 +139,12 @@
NULL, /* dependencies */
PURPLE_PRIORITY_DEFAULT, /* priority */
- N_("gtk-kluge-autoprofile"), /* id */
- N_("AutoProfile"), /* name */
+ "gtk-kluge-autoprofile", /* id */
+ NULL, /* name */
PP_VERSION, /* version */
- N_("User profile and status message content generator"),/* summary */
- /* description */
- N_("Allows user to place dynamic text into profiles\n"
- "and status messages, with the text automatically\n"
- "updated whenever content changes"),
- /* author */
- N_("Casey Ho <casey at hkn-berkeley-edu>"
- "\n\t\t\taim:caseyho"),
+ NULL, /* summary */
+ NULL, /* description */
+ NULL, /* author */
PP_WEBSITE, /* homepage */
plugin_load, /* load */
plugin_unload, /* unload */
@@ -855,6 +850,13 @@
*--------------------------------------------------------------------------*/
static void init_plugin (PurplePlugin *plugin)
{
+ info.name = _("AutoProfile");
+ info.summary = _("User profile and status message content generator");
+ info.description = _("Allows user to place dynamic text into profiles\n"
+ "and status messages, with the text automatically\n"
+ "updated whenever content changes");
+ info.author = _("Casey Ho <casey at hkn-berkeley-edu>\n\t\t\taim:caseyho");
+
ap_debug ("general", "Initializing AutoProfile");
ap_init_preferences ();
--- a/capsnot/capsnot.c Sat Dec 04 10:49:38 2010 -0500
+++ b/capsnot/capsnot.c Sat Dec 04 13:50:49 2010 -0500
@@ -258,27 +258,6 @@
return frame;
}
-static void
-init_plugin(PurplePlugin *plugin)
-{
-#ifdef ENABLE_NLS
- bindtextdomain(GETTEXT_PACKAGE, PP_LOCALEDIR);
- bind_textdomain_codeset(GETTEXT_PACKAGE, "UTF-8");
-#endif
-
- purple_prefs_add_none("/plugins/core/eionrobb-capsnot");
-
- purple_prefs_add_string("/plugins/core/eionrobb-capsnot/im", "always");
- purple_prefs_add_string("/plugins/core/eionrobb-capsnot/chat", "nick");
-
- purple_prefs_add_bool("/plugins/core/eionrobb-capsnot/numlock", FALSE);
- purple_prefs_add_bool("/plugins/core/eionrobb-capsnot/capslock", FALSE);
- purple_prefs_add_bool("/plugins/core/eionrobb-capsnot/scrolllock", TRUE);
-
- purple_prefs_add_int("/plugins/core/eionrobb-capsnot/flashcount", 8);
- purple_prefs_add_int("/plugins/core/eionrobb-capsnot/flashseconds", 2);
-}
-
static gboolean
plugin_load(PurplePlugin *plugin)
{
@@ -324,11 +303,11 @@
PURPLE_PRIORITY_DEFAULT,
"eionrobb-capsnot",
- N_("Caps-notification"),
+ NULL,
PP_VERSION,
- N_("Led notification on keyboards"),
- N_("Informs of new messages with the NumLock, CapsLock, or ScrollLock LEDs"),
+ NULL,
+ NULL,
"Eion Robb <eionrobb@gmail.com>",
PP_WEBSITE, /* URL */
@@ -346,4 +325,30 @@
NULL
};
+static void
+init_plugin(PurplePlugin *plugin)
+{
+#ifdef ENABLE_NLS
+ bindtextdomain(GETTEXT_PACKAGE, PP_LOCALEDIR);
+ bind_textdomain_codeset(GETTEXT_PACKAGE, "UTF-8");
+#endif
+
+ info.name = _("Caps-notification");
+ info.summary = _("Led notification on keyboards");
+ info.description = _("Informs of new messages with the NumLock, CapsLock, or ScrollLock LEDs");
+
+
+ purple_prefs_add_none("/plugins/core/eionrobb-capsnot");
+
+ purple_prefs_add_string("/plugins/core/eionrobb-capsnot/im", "always");
+ purple_prefs_add_string("/plugins/core/eionrobb-capsnot/chat", "nick");
+
+ purple_prefs_add_bool("/plugins/core/eionrobb-capsnot/numlock", FALSE);
+ purple_prefs_add_bool("/plugins/core/eionrobb-capsnot/capslock", FALSE);
+ purple_prefs_add_bool("/plugins/core/eionrobb-capsnot/scrolllock", TRUE);
+
+ purple_prefs_add_int("/plugins/core/eionrobb-capsnot/flashcount", 8);
+ purple_prefs_add_int("/plugins/core/eionrobb-capsnot/flashseconds", 2);
+}
+
PURPLE_INIT_PLUGIN(capsnot, init_plugin, info);
--- a/icon-override/icon_override.c Sat Dec 04 10:49:38 2010 -0500
+++ b/icon-override/icon_override.c Sat Dec 04 13:50:49 2010 -0500
@@ -132,15 +132,6 @@
return TRUE;
}
-static void
-plugin_init(PurplePlugin *plugin)
-{
-#ifdef ENABLE_NLS
- bindtextdomain(GETTEXT_PACKAGE, PP_LOCALEDIR);
- bind_textdomain_codeset(GETTEXT_PACKAGE, "UTF-8");
-#endif
-}
-
static PurplePluginInfo info =
{
PURPLE_PLUGIN_MAGIC,
@@ -153,10 +144,10 @@
PURPLE_PRIORITY_LOWEST,
"eionrobb-icon-override",
- N_("Protocol Icon Override"),
+ NULL,
PP_VERSION,
- N_("Customise protocol icons"),
- N_("Lets you change protocol icons per-account so that you can tell the difference between, say, a personal XMPP account and one used for work"),
+ NULL,
+ NULL,
"Eion Robb <eionrobb@gmail.com>",
PP_WEBSITE, //URL
@@ -175,4 +166,19 @@
NULL
};
+static void
+plugin_init(PurplePlugin *plugin)
+{
+#ifdef ENABLE_NLS
+ bindtextdomain(GETTEXT_PACKAGE, PP_LOCALEDIR);
+ bind_textdomain_codeset(GETTEXT_PACKAGE, "UTF-8");
+#endif
+
+ info.name = _("Protocol Icon Override");
+ info.summary = _("Customise protocol icons");
+ info.description = _("Lets you change protocol icons per-account so that "
+ "you can tell the difference between, say, a personal "
+ "XMPP account and one used for work");
+}
+
PURPLE_INIT_PLUGIN(icon_override, plugin_init, info);