Mercurial > pidgin
changeset 32030:4f6b06139734
Remove deprecated plugin functions. I guess no-one asked for a
plugin-probe signal.
author | Elliott Sales de Andrade <qulogic@pidgin.im> |
---|---|
date | Fri, 02 Sep 2011 21:15:24 +0000 |
parents | 67addaf8677f |
children | cd1d9e04c587 cadc8dfafbaf |
files | ChangeLog.API libpurple/plugin.c libpurple/plugin.h |
diffstat | 3 files changed, 6 insertions(+), 127 deletions(-) [+] |
line wrap: on
line diff
--- a/ChangeLog.API Fri Sep 02 21:04:02 2011 +0000 +++ b/ChangeLog.API Fri Sep 02 21:15:24 2011 +0000 @@ -109,6 +109,12 @@ * 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
--- a/libpurple/plugin.c Fri Sep 02 21:04:02 2011 +0000 +++ b/libpurple/plugin.c Fri Sep 02 21:15:24 2011 +0000 @@ -64,13 +64,6 @@ 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 @@ 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 @@ 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 @@ (GCompareFunc)compare_prpl); } } - - if (probe_cb != NULL) - probe_cb(probe_cb_data); - #endif /* PURPLE_PLUGINS */ } @@ -1513,50 +1496,6 @@ #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) {
--- a/libpurple/plugin.h Fri Sep 02 21:04:02 2011 +0000 +++ b/libpurple/plugin.h Fri Sep 02 21:15:24 2011 +0000 @@ -566,72 +566,6 @@ */ 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. *