mirror of
https://github.com/weechat/weechat.git
synced 2026-06-26 12:56:37 +02:00
Add nick completion in xfer dcc buffers, fix bug when opening xfer dcc buffer if it already exists
This commit is contained in:
@@ -239,6 +239,8 @@
|
||||
./src/plugins/xfer/xfer-chat.h
|
||||
./src/plugins/xfer/xfer-command.c
|
||||
./src/plugins/xfer/xfer-command.h
|
||||
./src/plugins/xfer/xfer-completion.c
|
||||
./src/plugins/xfer/xfer-completion.h
|
||||
./src/plugins/xfer/xfer-config.c
|
||||
./src/plugins/xfer/xfer-config.h
|
||||
./src/plugins/xfer/xfer-dcc.c
|
||||
|
||||
@@ -6,7 +6,7 @@ msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: WeeChat 0.2.7-dev\n"
|
||||
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
|
||||
"POT-Creation-Date: 2009-03-22 16:17+0100\n"
|
||||
"POT-Creation-Date: 2009-03-23 11:08+0100\n"
|
||||
"PO-Revision-Date: 2009-01-03 00:42+0100\n"
|
||||
"Last-Translator: Jiri Golembiovsky <golemj@gmail.com>\n"
|
||||
"Language-Team: weechat-dev <weechat-dev@nongnu.org>\n"
|
||||
@@ -5334,6 +5334,10 @@ msgstr "Ruším aktivní DCC: \"%s\" od %s\n"
|
||||
msgid "%s%s: error sending data to \"%s\" via xfer chat"
|
||||
msgstr "%s chyba posílání dat k \"%s\" přes DCC CHAT\n"
|
||||
|
||||
#, fuzzy, c-format
|
||||
msgid "%s%s: can't find xfer for buffer \"%s\""
|
||||
msgstr "%s nemohu vytvořít nové soukromý buffer\"%s\"\n"
|
||||
|
||||
#, fuzzy, c-format
|
||||
msgid "Connected to %s (%d.%d.%d.%d) via xfer chat"
|
||||
msgstr "Připojeno na %s%s %s(%s%d.%d.%d.%d.%s)%s přes DCC rozhovor\n"
|
||||
|
||||
@@ -9,7 +9,7 @@ msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: WeeChat 0.2.7-dev\n"
|
||||
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
|
||||
"POT-Creation-Date: 2009-03-22 16:17+0100\n"
|
||||
"POT-Creation-Date: 2009-03-23 11:08+0100\n"
|
||||
"PO-Revision-Date: 2009-01-03 00:42+0100\n"
|
||||
"Last-Translator: Thomas Schuetz <i18n@internet-villa.de>\n"
|
||||
"Language-Team: weechat-dev <weechat-dev@nongnu.org>\n"
|
||||
@@ -5272,6 +5272,10 @@ msgstr "Aktiver DCC wird abgebrochen: \"%s\" von %s\n"
|
||||
msgid "%s%s: error sending data to \"%s\" via xfer chat"
|
||||
msgstr "%s Fehler beim Senden von Daten an \"%s\" via DCC CHAT\n"
|
||||
|
||||
#, fuzzy, c-format
|
||||
msgid "%s%s: can't find xfer for buffer \"%s\""
|
||||
msgstr "%s kann kein neues privates Fenster \"%s\" erzeugen\n"
|
||||
|
||||
#, fuzzy, c-format
|
||||
msgid "Connected to %s (%d.%d.%d.%d) via xfer chat"
|
||||
msgstr "DCC Chat mit %s%s %s(%s%d.%d.%d.%d%s)%s aufgebaut\n"
|
||||
|
||||
@@ -6,7 +6,7 @@ msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: WeeChat 0.2.7-dev\n"
|
||||
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
|
||||
"POT-Creation-Date: 2009-03-22 16:17+0100\n"
|
||||
"POT-Creation-Date: 2009-03-23 11:08+0100\n"
|
||||
"PO-Revision-Date: 2009-01-03 00:42+0100\n"
|
||||
"Last-Translator: Roberto González Cardenete <robert.glez@gmail.com>\n"
|
||||
"Language-Team: weechat-dev <weechat-dev@nongnu.org>\n"
|
||||
@@ -5265,6 +5265,10 @@ msgstr "Abandonar el DCC activo: \"%s\" de %s\n"
|
||||
msgid "%s%s: error sending data to \"%s\" via xfer chat"
|
||||
msgstr "%s error enviando datos al \"%s\" con DCC CHAT\n"
|
||||
|
||||
#, fuzzy, c-format
|
||||
msgid "%s%s: can't find xfer for buffer \"%s\""
|
||||
msgstr "%s no es posible crear una nueva ventana privada \"%s\"\n"
|
||||
|
||||
#, fuzzy, c-format
|
||||
msgid "Connected to %s (%d.%d.%d.%d) via xfer chat"
|
||||
msgstr "Conectado a %s%s %s(%s%d.%d.%d.%d%s)%s a través de una charla DCC\n"
|
||||
|
||||
@@ -6,8 +6,8 @@ msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: WeeChat 0.2.7-dev\n"
|
||||
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
|
||||
"POT-Creation-Date: 2009-03-22 16:17+0100\n"
|
||||
"PO-Revision-Date: 2009-03-22 16:17+0100\n"
|
||||
"POT-Creation-Date: 2009-03-23 11:08+0100\n"
|
||||
"PO-Revision-Date: 2009-03-23 11:08+0100\n"
|
||||
"Last-Translator: FlashCode <flashcode@flashtux.org>\n"
|
||||
"Language-Team: weechat-dev <weechat-dev@nongnu.org>\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
@@ -5463,6 +5463,10 @@ msgstr "%s%s: abandon du xfer actif: \"%s\" de %s"
|
||||
msgid "%s%s: error sending data to \"%s\" via xfer chat"
|
||||
msgstr "%s%s: erreur d'envoi de données à \"%s\" via discussion xfer"
|
||||
|
||||
#, c-format
|
||||
msgid "%s%s: can't find xfer for buffer \"%s\""
|
||||
msgstr "%s%s: impossible de trouver le xfer pour le tampon \"%s\""
|
||||
|
||||
#, c-format
|
||||
msgid "Connected to %s (%d.%d.%d.%d) via xfer chat"
|
||||
msgstr "Connecté à %s (%d.%d.%d.%d) via discussion xfer"
|
||||
|
||||
@@ -12,7 +12,7 @@ msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: WeeChat 0.2.7-dev\n"
|
||||
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
|
||||
"POT-Creation-Date: 2009-03-22 16:17+0100\n"
|
||||
"POT-Creation-Date: 2009-03-23 11:08+0100\n"
|
||||
"PO-Revision-Date: 2009-01-03 00:42+0100\n"
|
||||
"Last-Translator: Andras Voroskoi <voroskoi@frugalware.org>\n"
|
||||
"Language-Team: weechat-dev <weechat-dev@nongnu.org>\n"
|
||||
@@ -5329,6 +5329,10 @@ msgstr "\"%s\" aktív DCC megszakítása a következővel: %s\n"
|
||||
msgid "%s%s: error sending data to \"%s\" via xfer chat"
|
||||
msgstr "%s hiba a(z) \"%s\" felé DCC CHAT-tel történő adatküldés közben\n"
|
||||
|
||||
#, fuzzy, c-format
|
||||
msgid "%s%s: can't find xfer for buffer \"%s\""
|
||||
msgstr "%s nem sikerült új privát ablakot nyitni \"%s\"\n"
|
||||
|
||||
#, fuzzy, c-format
|
||||
msgid "Connected to %s (%d.%d.%d.%d) via xfer chat"
|
||||
msgstr ""
|
||||
|
||||
@@ -6,7 +6,7 @@ msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: WeeChat 0.2.7-dev\n"
|
||||
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
|
||||
"POT-Creation-Date: 2009-03-22 16:17+0100\n"
|
||||
"POT-Creation-Date: 2009-03-23 11:08+0100\n"
|
||||
"PO-Revision-Date: 2009-01-03 00:42+0100\n"
|
||||
"Last-Translator: Pavel Shevchuk <stlwrt@gmail.com>\n"
|
||||
"Language-Team: weechat-dev <weechat-dev@nongnu.org>\n"
|
||||
@@ -5300,6 +5300,10 @@ msgstr "Отменяю активное DCC-сединение: \"%s\" от %s\n
|
||||
msgid "%s%s: error sending data to \"%s\" via xfer chat"
|
||||
msgstr "%s ошибка при отправке данных \"%s\" через DCC-чат\n"
|
||||
|
||||
#, fuzzy, c-format
|
||||
msgid "%s%s: can't find xfer for buffer \"%s\""
|
||||
msgstr "%s невозможно создать новый буфер привата \"%s\"\n"
|
||||
|
||||
#, fuzzy, c-format
|
||||
msgid "Connected to %s (%d.%d.%d.%d) via xfer chat"
|
||||
msgstr "Соединён с %s%s %s(%s%d.%d.%d.%d%s)%s DCC-чатом\n"
|
||||
|
||||
@@ -240,6 +240,8 @@ SET(WEECHAT_SOURCES
|
||||
./src/plugins/xfer/xfer-chat.h
|
||||
./src/plugins/xfer/xfer-command.c
|
||||
./src/plugins/xfer/xfer-command.h
|
||||
./src/plugins/xfer/xfer-completion.c
|
||||
./src/plugins/xfer/xfer-completion.h
|
||||
./src/plugins/xfer/xfer-config.c
|
||||
./src/plugins/xfer/xfer-config.h
|
||||
./src/plugins/xfer/xfer-dcc.c
|
||||
|
||||
+5
-1
@@ -7,7 +7,7 @@ msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: PACKAGE VERSION\n"
|
||||
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
|
||||
"POT-Creation-Date: 2009-03-22 16:17+0100\n"
|
||||
"POT-Creation-Date: 2009-03-23 11:08+0100\n"
|
||||
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
|
||||
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
|
||||
"Language-Team: LANGUAGE <LL@li.org>\n"
|
||||
@@ -4597,6 +4597,10 @@ msgstr ""
|
||||
msgid "%s%s: error sending data to \"%s\" via xfer chat"
|
||||
msgstr ""
|
||||
|
||||
#, c-format
|
||||
msgid "%s%s: can't find xfer for buffer \"%s\""
|
||||
msgstr ""
|
||||
|
||||
#, c-format
|
||||
msgid "Connected to %s (%d.%d.%d.%d) via xfer chat"
|
||||
msgstr ""
|
||||
|
||||
@@ -19,6 +19,7 @@ xfer.c xfer.h
|
||||
xfer-buffer.c xfer-buffer.h
|
||||
xfer-chat.c xfer-chat.h
|
||||
xfer-command.c xfer-command.h
|
||||
xfer-completion.c xfer-completion.h
|
||||
xfer-config.c xfer-config.h
|
||||
xfer-dcc.c xfer-dcc.h
|
||||
xfer-file.c xfer-file.h
|
||||
|
||||
@@ -28,6 +28,8 @@ xfer_la_SOURCES = xfer.c \
|
||||
xfer-chat.h \
|
||||
xfer-command.c \
|
||||
xfer-command.h \
|
||||
xfer-completion.c \
|
||||
xfer-completion.h \
|
||||
xfer-config.c \
|
||||
xfer-config.h \
|
||||
xfer-dcc.c \
|
||||
|
||||
@@ -136,7 +136,8 @@ xfer_chat_recv_cb (void *arg_xfer, int fd)
|
||||
|
||||
if (ptr_buf)
|
||||
{
|
||||
weechat_printf (xfer->buffer, "%s\t%s", xfer->remote_nick, ptr_buf);
|
||||
weechat_printf_tags (xfer->buffer, "notify_message", "%s\t%s",
|
||||
xfer->remote_nick, ptr_buf);
|
||||
}
|
||||
|
||||
ptr_buf = next_ptr_buf;
|
||||
@@ -163,18 +164,30 @@ int
|
||||
xfer_chat_buffer_input_cb (void *data, struct t_gui_buffer *buffer,
|
||||
const char *input_data)
|
||||
{
|
||||
struct t_xfer *xfer;
|
||||
struct t_xfer *ptr_xfer;
|
||||
|
||||
xfer = (struct t_xfer *)data;
|
||||
/* make C compiler happy */
|
||||
(void) data;
|
||||
|
||||
if (!XFER_HAS_ENDED(xfer->status))
|
||||
ptr_xfer = xfer_search_by_buffer (buffer);
|
||||
|
||||
if (!ptr_xfer)
|
||||
{
|
||||
xfer_chat_sendf (xfer, "%s\n", input_data);
|
||||
if (!XFER_HAS_ENDED(xfer->status))
|
||||
weechat_printf (NULL,
|
||||
_("%s%s: can't find xfer for buffer \"%s\""),
|
||||
weechat_prefix ("error"), XFER_PLUGIN_NAME,
|
||||
weechat_buffer_get_string (buffer, "name"));
|
||||
return WEECHAT_RC_OK;
|
||||
}
|
||||
|
||||
if (!XFER_HAS_ENDED(ptr_xfer->status))
|
||||
{
|
||||
xfer_chat_sendf (ptr_xfer, "%s\n", input_data);
|
||||
if (!XFER_HAS_ENDED(ptr_xfer->status))
|
||||
{
|
||||
weechat_printf (buffer,
|
||||
"%s\t%s",
|
||||
xfer->local_nick,
|
||||
ptr_xfer->local_nick,
|
||||
input_data);
|
||||
}
|
||||
}
|
||||
@@ -190,21 +203,25 @@ xfer_chat_buffer_input_cb (void *data, struct t_gui_buffer *buffer,
|
||||
int
|
||||
xfer_chat_buffer_close_cb (void *data, struct t_gui_buffer *buffer)
|
||||
{
|
||||
struct t_xfer *xfer;
|
||||
struct t_xfer *ptr_xfer;
|
||||
|
||||
/* make C compiler happy */
|
||||
(void) data;
|
||||
(void) buffer;
|
||||
|
||||
xfer = (struct t_xfer *)data;
|
||||
ptr_xfer = xfer_search_by_buffer (buffer);
|
||||
|
||||
if (!XFER_HAS_ENDED(xfer->status))
|
||||
{
|
||||
xfer_close (xfer, XFER_STATUS_ABORTED);
|
||||
xfer_buffer_refresh (WEECHAT_HOTLIST_MESSAGE);
|
||||
if (ptr_xfer)
|
||||
{
|
||||
if (!XFER_HAS_ENDED(ptr_xfer->status))
|
||||
{
|
||||
xfer_close (ptr_xfer, XFER_STATUS_ABORTED);
|
||||
xfer_buffer_refresh (WEECHAT_HOTLIST_MESSAGE);
|
||||
}
|
||||
|
||||
ptr_xfer->buffer = NULL;
|
||||
}
|
||||
|
||||
xfer->buffer = NULL;
|
||||
|
||||
return WEECHAT_RC_OK;
|
||||
}
|
||||
|
||||
@@ -217,28 +234,40 @@ xfer_chat_open_buffer (struct t_xfer *xfer)
|
||||
{
|
||||
char *name;
|
||||
int length;
|
||||
|
||||
length = strlen (xfer->plugin_name) + 1 + strlen (xfer->remote_nick) + 1;
|
||||
|
||||
length = strlen (xfer->plugin_name) + 8 + strlen (xfer->remote_nick) + 1;
|
||||
name = malloc (length);
|
||||
if (name)
|
||||
{
|
||||
snprintf (name, length, "%s_%s", xfer->plugin_name, xfer->remote_nick);
|
||||
xfer->buffer = weechat_buffer_new (name,
|
||||
&xfer_chat_buffer_input_cb, xfer,
|
||||
&xfer_chat_buffer_close_cb, xfer);
|
||||
if (xfer->buffer)
|
||||
snprintf (name, length, "%s_dcc_%s",
|
||||
xfer->plugin_name, xfer->remote_nick);
|
||||
xfer->buffer = weechat_buffer_search (XFER_PLUGIN_NAME, name);
|
||||
if (!xfer->buffer)
|
||||
{
|
||||
weechat_buffer_set (xfer->buffer, "title", _("xfer chat"));
|
||||
weechat_buffer_set (xfer->buffer, "localvar_set_type", "private");
|
||||
weechat_printf (xfer->buffer,
|
||||
_("Connected to %s (%d.%d.%d.%d) via "
|
||||
"xfer chat"),
|
||||
xfer->remote_nick,
|
||||
xfer->address >> 24,
|
||||
(xfer->address >> 16) & 0xff,
|
||||
(xfer->address >> 8) & 0xff,
|
||||
xfer->address & 0xff);
|
||||
xfer->buffer = weechat_buffer_new (name,
|
||||
&xfer_chat_buffer_input_cb, NULL,
|
||||
&xfer_chat_buffer_close_cb, NULL);
|
||||
|
||||
/* failed to create buffer ? then return */
|
||||
if (!xfer->buffer)
|
||||
return;
|
||||
}
|
||||
|
||||
weechat_buffer_set (xfer->buffer, "title", _("xfer chat"));
|
||||
weechat_buffer_set (xfer->buffer, "short_name", xfer->remote_nick);
|
||||
weechat_buffer_set (xfer->buffer, "localvar_set_type", "private");
|
||||
weechat_buffer_set (xfer->buffer, "localvar_set_nick", xfer->local_nick);
|
||||
weechat_buffer_set (xfer->buffer, "localvar_set_channel", xfer->remote_nick);
|
||||
weechat_buffer_set (xfer->buffer, "highlight_words", xfer->local_nick);
|
||||
weechat_printf (xfer->buffer,
|
||||
_("Connected to %s (%d.%d.%d.%d) via "
|
||||
"xfer chat"),
|
||||
xfer->remote_nick,
|
||||
xfer->address >> 24,
|
||||
(xfer->address >> 16) & 0xff,
|
||||
(xfer->address >> 8) & 0xff,
|
||||
xfer->address & 0xff);
|
||||
|
||||
free (name);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -0,0 +1,73 @@
|
||||
/*
|
||||
* Copyright (c) 2003-2009 by FlashCode <flashcode@flashtux.org>
|
||||
* See README for License detail, AUTHORS for developers list.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation; either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
/* xfer-completion.c: nick completion for xfer chats */
|
||||
|
||||
|
||||
#include <stdlib.h>
|
||||
#include <stdio.h>
|
||||
#include <string.h>
|
||||
|
||||
#include "../weechat-plugin.h"
|
||||
#include "xfer.h"
|
||||
#include "xfer-completion.h"
|
||||
|
||||
|
||||
/*
|
||||
* xfer_completion_nick_cb: callback for completion with nick
|
||||
*/
|
||||
|
||||
int
|
||||
xfer_completion_nick_cb (void *data, const char *completion_item,
|
||||
struct t_gui_buffer *buffer,
|
||||
struct t_gui_completion *completion)
|
||||
{
|
||||
struct t_xfer *ptr_xfer;
|
||||
|
||||
/* make C compiler happy */
|
||||
(void) data;
|
||||
(void) completion_item;
|
||||
|
||||
ptr_xfer = xfer_search_by_buffer (buffer);
|
||||
if (ptr_xfer)
|
||||
{
|
||||
/* remote nick */
|
||||
weechat_hook_completion_list_add (completion,
|
||||
ptr_xfer->remote_nick,
|
||||
0,
|
||||
WEECHAT_LIST_POS_SORT);
|
||||
/* add self nick at the end */
|
||||
weechat_hook_completion_list_add (completion,
|
||||
ptr_xfer->local_nick,
|
||||
1,
|
||||
WEECHAT_LIST_POS_END);
|
||||
}
|
||||
|
||||
return WEECHAT_RC_OK;
|
||||
}
|
||||
|
||||
/*
|
||||
* xfer_completion_init: init completion for xfer plugin
|
||||
*/
|
||||
|
||||
void
|
||||
xfer_completion_init ()
|
||||
{
|
||||
weechat_hook_completion ("nick",
|
||||
&xfer_completion_nick_cb, NULL);
|
||||
}
|
||||
@@ -0,0 +1,25 @@
|
||||
/*
|
||||
* Copyright (c) 2003-2009 by FlashCode <flashcode@flashtux.org>
|
||||
* See README for License detail, AUTHORS for developers list.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation; either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
|
||||
#ifndef __WEECHAT_XFER_COMPLETION_H
|
||||
#define __WEECHAT_XFER_COMPLETION_H 1
|
||||
|
||||
extern void xfer_completion_init ();
|
||||
|
||||
#endif /* xfer-completion.h */
|
||||
+28
-1
@@ -34,6 +34,7 @@
|
||||
#include "xfer.h"
|
||||
#include "xfer-buffer.h"
|
||||
#include "xfer-command.h"
|
||||
#include "xfer-completion.h"
|
||||
#include "xfer-config.h"
|
||||
#include "xfer-file.h"
|
||||
#include "xfer-info.h"
|
||||
@@ -230,6 +231,28 @@ xfer_search_by_number (int number)
|
||||
return NULL;
|
||||
}
|
||||
|
||||
/*
|
||||
* xfer_search_by_buffer: search a xfer by buffer (for chat only)
|
||||
*/
|
||||
|
||||
struct t_xfer *
|
||||
xfer_search_by_buffer (struct t_gui_buffer *buffer)
|
||||
{
|
||||
struct t_xfer *ptr_xfer;
|
||||
|
||||
if (!buffer)
|
||||
return NULL;
|
||||
|
||||
for (ptr_xfer = xfer_list; ptr_xfer; ptr_xfer = ptr_xfer->next_xfer)
|
||||
{
|
||||
if (ptr_xfer->buffer == buffer)
|
||||
return ptr_xfer;
|
||||
}
|
||||
|
||||
/* xfer not found */
|
||||
return NULL;
|
||||
}
|
||||
|
||||
/*
|
||||
* xfer_close: close a xfer
|
||||
*/
|
||||
@@ -1393,13 +1416,17 @@ weechat_plugin_init (struct t_weechat_plugin *plugin, int argc, char *argv[])
|
||||
xfer_create_directories ();
|
||||
|
||||
xfer_command_init ();
|
||||
|
||||
|
||||
/* hook some signals */
|
||||
weechat_hook_signal ("upgrade", &xfer_signal_upgrade_cb, NULL);
|
||||
weechat_hook_signal ("xfer_add", &xfer_add_cb, NULL);
|
||||
weechat_hook_signal ("xfer_start_resume", &xfer_start_resume_cb, NULL);
|
||||
weechat_hook_signal ("xfer_accept_resume", &xfer_accept_resume_cb, NULL);
|
||||
weechat_hook_signal ("debug_dump", &xfer_debug_dump_cb, NULL);
|
||||
|
||||
/* hook completions */
|
||||
xfer_completion_init ();
|
||||
|
||||
xfer_info_init ();
|
||||
|
||||
return WEECHAT_RC_OK;
|
||||
|
||||
@@ -157,6 +157,7 @@ extern int xfer_count;
|
||||
|
||||
extern int xfer_valid (struct t_xfer *xfer);
|
||||
extern struct t_xfer *xfer_search_by_number (int number);
|
||||
extern struct t_xfer *xfer_search_by_buffer (struct t_gui_buffer *buffer);
|
||||
extern void xfer_close (struct t_xfer *xfer, enum t_xfer_status status);
|
||||
extern void xfer_send_signal (struct t_xfer *xfer, const char *signal);
|
||||
extern void xfer_free (struct t_xfer *xfer);
|
||||
|
||||
Reference in New Issue
Block a user