--- a/ChangeLog.API Tue Sep 20 02:55:07 2022 -0500
+++ b/ChangeLog.API Tue Sep 20 03:24:25 2022 -0500
@@ -399,6 +399,9 @@
* purple_certificate_get_fingerprint_sha256
* Purple Cipher API (PurpleCipherContext and friends).
Use GLib's GHmac or GChecksum instead.
+ * purple_cmds_get_ui_ops + * purple_cmds_set_ui_ops * purple_connection_error_reason
* PURPLE_CONNECTION_FLAG_ALLOW_CUSTOM_SMILEY
--- a/libpurple/cmds.c Tue Sep 20 02:55:07 2022 -0500
+++ b/libpurple/cmds.c Tue Sep 20 03:24:25 2022 -0500
@@ -20,7 +20,6 @@
#include "purplemarkup.h"
-static PurpleCommandsUiOps *cmds_ui_ops = NULL;
static GList *cmds = NULL;
static guint next_id = 1;
@@ -49,7 +48,6 @@
- PurpleCommandsUiOps *ops;
g_return_val_if_fail(cmd != NULL && *cmd != '\0', 0);
g_return_val_if_fail(args != NULL, 0);
@@ -70,10 +68,6 @@
cmds = g_list_insert_sorted(cmds, c, (GCompareFunc)cmds_compare_func);
- ops = purple_cmds_get_ui_ops();
- if (ops && ops->register_command)
- ops->register_command(cmd, p, f, protocol_id, helpstr, c->id);
purple_signal_emit(purple_cmds_get_handle(), "cmd-added", cmd, p, f);
@@ -98,7 +92,6 @@
- PurpleCommandsUiOps *ops;
l = g_list_find_custom(cmds, GUINT_TO_POINTER(id), purple_cmd_cmp_id);
@@ -107,11 +100,6 @@
- ops = purple_cmds_get_ui_ops();
- if (ops && ops->unregister_command) {
- ops->unregister_command(c->cmd, c->protocol_id);
cmds = g_list_delete_link(cmds, l);
purple_signal_emit(purple_cmds_get_handle(), "cmd-removed", c->cmd);
@@ -388,21 +376,6 @@
-purple_cmds_set_ui_ops(PurpleCommandsUiOps *ops)
-purple_cmds_get_ui_ops(void)
- /* It is perfectly acceptable for cmds_ui_ops to be NULL; this just
- * means that the default libpurple implementation will be used.
void purple_cmds_init(void)
gpointer handle = purple_cmds_get_handle();
--- a/libpurple/cmds.h Tue Sep 20 02:55:07 2022 -0500
+++ b/libpurple/cmds.h Tue Sep 20 03:24:25 2022 -0500
@@ -141,36 +141,6 @@
PURPLE_CMD_FLAG_ALLOW_WRONG_ARGS = 0x08
- * @register_command: If implemented, the UI is responsible for handling
- * commands. See @purple_cmd_register for the argument values.
- * @unregister_command: Should be implemented if register_command is
- * implemented. @name and @prpl_id will have the same value
- * that were used for the register_command call.
- * Command UI operations; UIs should implement this if they want to handle
- * commands themselves, rather than relying on the core.
- * See <link linkend="chapter-ui-ops">List of <literal>UiOps</literal>
- void (*register_command)(const gchar *name, PurpleCmdPriority priority,
- PurpleCmdFlag flags, const gchar *prpl_id,
- const gchar *help, PurpleCmdId id);
- void (*unregister_command)(const gchar *name, const gchar *prpl_id);
- void (*_purple_reserved1)(void);
- void (*_purple_reserved2)(void);
- void (*_purple_reserved3)(void);
- void (*_purple_reserved4)(void);
/**************************************************************************/
@@ -327,26 +297,6 @@
gpointer purple_cmds_get_handle(void);
- * purple_cmds_set_ui_ops:
- * @ops: The UI operations structure.
- * Sets the UI operations structure to be used when registering and
- * unregistering commands. The UI operations need only be set if the
- * UI wants to handle the commands itself; otherwise, leave it as NULL.
-void purple_cmds_set_ui_ops(PurpleCommandsUiOps *ops);
- * purple_cmds_get_ui_ops:
- * Returns the UI operations structure to be used when registering and
- * unregistering commands.
- * Returns: (transfer none): The UI operations structure.
-PurpleCommandsUiOps *purple_cmds_get_ui_ops(void);
* Initialize the commands subsystem.