pidgin: 21f078cd: Remove deprecated plugin functions. I gu...
qulogic at pidgin.im
qulogic at pidgin.im
Fri Sep 2 23:05:56 EDT 2011
----------------------------------------------------------------------
Revision: 21f078cdce656c60707d6518904262ee44ac648c
Parent: b9f39d21519e68620399ba9e93122b994d25daea
Author: qulogic at pidgin.im
Date: 09/02/11 17:15:24
Branch: im.pidgin.pidgin
URL: http://d.pidgin.im/viewmtn/revision/info/21f078cdce656c60707d6518904262ee44ac648c
Changelog:
Remove deprecated plugin functions. I guess no-one asked for a
plugin-probe signal.
Changes against parent b9f39d21519e68620399ba9e93122b994d25daea
patched ChangeLog.API
patched libpurple/plugin.c
patched libpurple/plugin.h
-------------- next part --------------
============================================================
--- libpurple/plugin.c 1dea199e1aa5529847ce92d2b4a557a5d91069f2
+++ libpurple/plugin.c 35623fc392954867721d557788b110c21048e80b
@@ -64,13 +64,6 @@ static GList *plugins_to_disable = NULL;
static GList *plugins_to_disable = NULL;
#endif
-static void (*probe_cb)(void *) = NULL;
-static void *probe_cb_data = NULL;
-static void (*load_cb)(PurplePlugin *, void *) = NULL;
-static void *load_cb_data = NULL;
-static void (*unload_cb)(PurplePlugin *, void *) = NULL;
-static void *unload_cb_data = NULL;
-
#ifdef PURPLE_PLUGINS
static gboolean
@@ -615,9 +608,6 @@ purple_plugin_load(PurplePlugin *plugin)
plugin->loaded = TRUE;
- if (load_cb != NULL)
- load_cb(plugin, load_cb_data);
-
purple_signal_emit(purple_plugins_get_handle(), "plugin-load", plugin);
return TRUE;
@@ -745,9 +735,6 @@ purple_plugin_unload(PurplePlugin *plugi
g_free(plugin->error);
plugin->error = NULL;
- if (unload_cb != NULL)
- unload_cb(plugin, unload_cb_data);
-
purple_signal_emit(purple_plugins_get_handle(), "plugin-unload", plugin);
purple_prefs_disconnect_by_handle(plugin);
@@ -1439,10 +1426,6 @@ purple_plugins_probe(const char *ext)
(GCompareFunc)compare_prpl);
}
}
-
- if (probe_cb != NULL)
- probe_cb(probe_cb_data);
-
#endif /* PURPLE_PLUGINS */
}
@@ -1513,50 +1496,6 @@ purple_plugins_enabled(void)
#endif
}
-void
-purple_plugins_register_probe_notify_cb(void (*func)(void *), void *data)
-{
- probe_cb = func;
- probe_cb_data = data;
-}
-
-void
-purple_plugins_unregister_probe_notify_cb(void (*func)(void *))
-{
- probe_cb = NULL;
- probe_cb_data = NULL;
-}
-
-void
-purple_plugins_register_load_notify_cb(void (*func)(PurplePlugin *, void *),
- void *data)
-{
- load_cb = func;
- load_cb_data = data;
-}
-
-void
-purple_plugins_unregister_load_notify_cb(void (*func)(PurplePlugin *, void *))
-{
- load_cb = NULL;
- load_cb_data = NULL;
-}
-
-void
-purple_plugins_register_unload_notify_cb(void (*func)(PurplePlugin *, void *),
- void *data)
-{
- unload_cb = func;
- unload_cb_data = data;
-}
-
-void
-purple_plugins_unregister_unload_notify_cb(void (*func)(PurplePlugin *, void *))
-{
- unload_cb = NULL;
- unload_cb_data = NULL;
-}
-
PurplePlugin *
purple_plugins_find_with_name(const char *name)
{
============================================================
--- libpurple/plugin.h a9769c4b5cea898831ab255f5fa4da9632d538e0
+++ libpurple/plugin.h ba494a191bb74a7d418e34562f1382165182c00c
@@ -566,73 +566,7 @@ gboolean purple_plugins_enabled(void);
*/
gboolean purple_plugins_enabled(void);
-#if !(defined PURPLE_DISABLE_DEPRECATED) || (defined _PURPLE_PLUGIN_C_)
/**
- * Registers a function that will be called when probing is finished.
- *
- * @param func The callback function.
- * @param data Data to pass to the callback.
- * @deprecated If you need this, ask for a plugin-probe signal to be added.
- */
-void purple_plugins_register_probe_notify_cb(void (*func)(void *), void *data);
-#endif
-
-#if !(defined PURPLE_DISABLE_DEPRECATED) || (defined _PURPLE_PLUGIN_C_)
-/**
- * Unregisters a function that would be called when probing is finished.
- *
- * @param func The callback function.
- * @deprecated If you need this, ask for a plugin-probe signal to be added.
- */
-void purple_plugins_unregister_probe_notify_cb(void (*func)(void *));
-#endif
-
-#if !(defined PURPLE_DISABLE_DEPRECATED) || (defined _PURPLE_PLUGIN_C_)
-/**
- * Registers a function that will be called when a plugin is loaded.
- *
- * @param func The callback function.
- * @param data Data to pass to the callback.
- * @deprecated Use the plugin-load signal instead.
- */
-void purple_plugins_register_load_notify_cb(void (*func)(PurplePlugin *, void *),
- void *data);
-#endif
-
-#if !(defined PURPLE_DISABLE_DEPRECATED) || (defined _PURPLE_PLUGIN_C_)
-/**
- * Unregisters a function that would be called when a plugin is loaded.
- *
- * @param func The callback function.
- * @deprecated Use the plugin-load signal instead.
- */
-void purple_plugins_unregister_load_notify_cb(void (*func)(PurplePlugin *, void *));
-#endif
-
-#if !(defined PURPLE_DISABLE_DEPRECATED) || (defined _PURPLE_PLUGIN_C_)
-/**
- * Registers a function that will be called when a plugin is unloaded.
- *
- * @param func The callback function.
- * @param data Data to pass to the callback.
- * @deprecated Use the plugin-unload signal instead.
- */
-void purple_plugins_register_unload_notify_cb(void (*func)(PurplePlugin *, void *),
- void *data);
-#endif
-
-#if !(defined PURPLE_DISABLE_DEPRECATED) || (defined _PURPLE_PLUGIN_C_)
-/**
- * Unregisters a function that would be called when a plugin is unloaded.
- *
- * @param func The callback function.
- * @deprecated Use the plugin-unload signal instead.
- */
-void purple_plugins_unregister_unload_notify_cb(void (*func)(PurplePlugin *,
- void *));
-#endif
-
-/**
* Finds a plugin with the specified name.
*
* @param name The plugin name.
============================================================
--- ChangeLog.API d259bbac2e9b752031c5c099237566de39e375cc
+++ ChangeLog.API 5806fc6b00894bef87091812f47e637977a04a61
@@ -109,6 +109,12 @@ version 3.0.0 (??/??/????):
* purple_notify_searchresults_get_columns_count
* purple_notify_searchresults_get_rows_count
* purple_notify_searchresults_row_get
+ * purple_plugins_register_load_notify_cb
+ * purple_plugins_register_probe_notify_cb
+ * purple_plugins_register_unload_notify_cb
+ * purple_plugins_unregister_load_notify_cb
+ * purple_plugins_unregister_probe_notify_cb
+ * purple_plugins_unregister_unload_notify_cb
* purple_presence_add_status
* purple_presence_add_list
* purple_srv_cancel
More information about the Commits
mailing list