diff options
author | Sebastien Helleu <flashcode@flashtux.org> | 2008-03-22 23:36:12 +0100 |
---|---|---|
committer | Sebastien Helleu <flashcode@flashtux.org> | 2008-03-22 23:36:12 +0100 |
commit | 61ca92972886cd7a9bc301ae7e23d6dde74920bc (patch) | |
tree | 7b69905a86b095f4fe6dffaa5a86ae6a0725c125 /src/gui/gui-completion.c | |
parent | 8c4dc57d8e5a6b1f9f239bdcbf30dd07480993be (diff) | |
download | weechat-61ca92972886cd7a9bc301ae7e23d6dde74920bc.zip |
Added tags for lines and custom filtering by tags or regex (task #7674), fixed many memory leaks
Diffstat (limited to 'src/gui/gui-completion.c')
-rw-r--r-- | src/gui/gui-completion.c | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/src/gui/gui-completion.c b/src/gui/gui-completion.c index 9d8b5a974..7c41879b0 100644 --- a/src/gui/gui-completion.c +++ b/src/gui/gui-completion.c @@ -262,6 +262,27 @@ gui_completion_list_add_buffers_names (struct t_gui_completion *completion) } /* + * gui_completion_list_add_buffers_categories_names: add buffers categories + * and names to completion + * list + */ + +void +gui_completion_list_add_buffers_categories_names (struct t_gui_completion *completion) +{ + struct t_gui_buffer *ptr_buffer; + char name[256]; + + for (ptr_buffer = gui_buffers; ptr_buffer; + ptr_buffer = ptr_buffer->next_buffer) + { + snprintf (name, sizeof (name), "%s.%s", + ptr_buffer->category, ptr_buffer->name); + gui_completion_list_add (completion, name, 0, WEECHAT_LIST_POS_SORT); + } +} + +/* * gui_completion_list_add_buffers_categories: add buffers categories to * completion list */ @@ -728,6 +749,9 @@ gui_completion_build_list_template (struct t_gui_completion *completion, case 'b': /* buffers names */ gui_completion_list_add_buffers_names (completion); break; + case 'B': /* buffers categories + names */ + gui_completion_list_add_buffers_categories_names (completion); + break; case 'c': /* buffers categories */ gui_completion_list_add_buffers_categories (completion); break; |