1
0
mirror of https://github.com/profanity-im/profanity.git synced 2024-06-23 21:45:30 +00:00

Revert "Move adding plugins commands to autocompleters"

This reverts commit 97f7997025.
This commit is contained in:
James Booth 2016-07-05 22:11:58 +01:00
parent 97f7997025
commit 82458c9d96
2 changed files with 3 additions and 4 deletions

View File

@ -52,7 +52,6 @@
#include "command/cmd_defs.h"
#include "window_list.h"
#include "common.h"
#include "command/cmd_ac.h"
void
api_cons_alert(void)
@ -145,9 +144,6 @@ api_register_command(const char *const plugin_name, const char *command_name, in
command->help = help;
callbacks_add_command(plugin_name, command);
cmd_ac_add(command->command_name);
cmd_ac_add_help(&command->command_name[1]);
}
void

View File

@ -36,6 +36,7 @@
#include <stdlib.h>
#include "command/cmd_defs.h"
#include "command/cmd_ac.h"
#include "plugins/callbacks.h"
#include "plugins/plugins.h"
#include "tools/autocomplete.h"
@ -165,6 +166,8 @@ callbacks_add_command(const char *const plugin_name, PluginCommand *command)
g_hash_table_insert(command_hash, strdup(command->command_name), command);
g_hash_table_insert(p_commands, strdup(plugin_name), command_hash);
}
cmd_ac_add(command->command_name);
cmd_ac_add_help(&command->command_name[1]);
}
void