34 |
#include "weeconfig.h" |
#include "weeconfig.h" |
35 |
#include "../irc/irc.h" |
#include "../irc/irc.h" |
36 |
|
|
37 |
|
#ifdef PLUGINS |
38 |
|
#include "../plugins/plugins.h" |
39 |
|
#endif |
40 |
|
|
41 |
|
|
42 |
/* |
/* |
43 |
* completion_init: init completion |
* completion_init: init completion |
112 |
t_config_option *option; |
t_config_option *option; |
113 |
void *option_value; |
void *option_value; |
114 |
char option_string[2048]; |
char option_string[2048]; |
115 |
|
#ifdef PLUGINS |
116 |
|
t_weechat_plugin *ptr_plugin; |
117 |
|
t_plugin_cmd_handler *ptr_cmd_handler; |
118 |
|
#endif |
119 |
|
|
120 |
/* WeeChat internal commands */ |
/* WeeChat internal commands */ |
121 |
|
|
208 |
&completion->last_completion, |
&completion->last_completion, |
209 |
irc_commands[i].command_name); |
irc_commands[i].command_name); |
210 |
} |
} |
211 |
|
#ifdef PLUGINS |
212 |
|
for (ptr_plugin = weechat_plugins; ptr_plugin; |
213 |
|
ptr_plugin = ptr_plugin->next_plugin) |
214 |
|
{ |
215 |
|
for (ptr_cmd_handler = ptr_plugin->cmd_handlers; |
216 |
|
ptr_cmd_handler; |
217 |
|
ptr_cmd_handler = ptr_cmd_handler->next_handler) |
218 |
|
{ |
219 |
|
weelist_add (&completion->completion_list, |
220 |
|
&completion->last_completion, |
221 |
|
ptr_cmd_handler->command); |
222 |
|
} |
223 |
|
} |
224 |
|
#endif |
225 |
return; |
return; |
226 |
} |
} |
227 |
if (ascii_strcasecmp (completion->base_command, "ignore") == 0) |
if (ascii_strcasecmp (completion->base_command, "ignore") == 0) |
334 |
return; |
return; |
335 |
} |
} |
336 |
} |
} |
337 |
if (((ascii_strcasecmp (completion->base_command, "perl") == 0) |
if ((ascii_strcasecmp (completion->base_command, "plugin") == 0) |
|
|| (ascii_strcasecmp (completion->base_command, "python") == 0)) |
|
338 |
&& (completion->base_command_arg == 1)) |
&& (completion->base_command_arg == 1)) |
339 |
{ |
{ |
340 |
weelist_add (&completion->completion_list, |
weelist_add (&completion->completion_list, |