aboutsummaryrefslogtreecommitdiffstats
path: root/protocols/bee_ft.c
blob: 1026eab3119d23c02166b38f863ae17b02ec6302 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
/********************************************************************\
* BitlBee -- An IRC to other IM-networks gateway                     *
*                                                                    *
* Copyright 2010 Wilmer van der Gaast <wilmer@gaast.net>             *
\********************************************************************/

/*
  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 2 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 with
  the Debian GNU/Linux distribution in /usr/share/common-licenses/GPL;
  if not, write to the Free Software Foundation, Inc., 59 Temple Place,
  Suite 330, Boston, MA  02111-1307  USA
*/

#define BITLBEE_CORE
#include "bitlbee.h"
#include "ft.h"

file_transfer_t *imcb_file_send_start( struct im_connection *ic, char *handle, char *file_name, size_t file_size )
{
	bee_t *bee = ic->bee; 
	bee_user_t *bu = bee_user_by_handle( bee, ic, handle );
	
	if( bee->ui->ft_in_start )
		return bee->ui->ft_in_start( bee, bu, file_name, file_size );
	else
		return NULL;
}

gboolean imcb_file_recv_start( struct im_connection *ic, file_transfer_t *ft )
{
	bee_t *bee = ic->bee;
	
	if( bee->ui->ft_out_start )
		return bee->ui->ft_out_start( ic, ft );
	else
		return FALSE;
}

void imcb_file_canceled( struct im_connection *ic, file_transfer_t *file, char *reason )
{
	bee_t *bee = ic->bee;
	
	if( file->canceled )
		file->canceled( file, reason );
	
	if( bee->ui->ft_close )
		bee->ui->ft_close( ic, file );
}

void imcb_file_finished( struct im_connection *ic, file_transfer_t *file )
{
	bee_t *bee = ic->bee;
	
	if( bee->ui->ft_finished )
		bee->ui->ft_finished( ic, file );
}
color: #bb0066; font-weight: bold } /* Name.Class */ .highlight .no { color: #003366; font-weight: bold } /* Name.Constant */ .highlight .nd { color: #555555 } /* Name.Decorator */ .highlight .ne { color: #bb0066; font-weight: bold } /* Name.Exception */ .highlight .nf { color: #0066bb; font-weight: bold } /* Name.Function */ .highlight .nl { color: #336699; font-style: italic } /* Name.Label */ .highlight .nn { color: #bb0066; font-weight: bold } /* Name.Namespace */ .highlight .py { color: #336699; font-weight: bold } /* Name.Property */ .highlight .nt { color: #bb0066; font-weight: bold } /* Name.Tag */ .highlight .nv { color: #336699 } /* Name.Variable */ .highlight .ow { color: #008800 } /* Operator.Word */ .highlight .w { color: #bbbbbb } /* Text.Whitespace */ .highlight .mb { color: #0000DD; font-weight: bold } /* Literal.Number.Bin */ .highlight .mf { color: #0000DD; font-weight: bold } /* Literal.Number.Float */ .highlight .mh { color: #0000DD; font-weight: bold } /* Literal.Number.Hex */ .highlight .mi { color: #0000DD; font-weight: bold } /* Literal.Number.Integer */ .highlight .mo { color: #0000DD; font-weight: bold } /* Literal.Number.Oct */ .highlight .sa { color: #dd2200; background-color: #fff0f0 } /* Literal.String.Affix */ .highlight .sb { color: #dd2200; background-color: #fff0f0 } /* Literal.String.Backtick */ .highlight .sc { color: #dd2200; background-color: #fff0f0 } /* Literal.String.Char */ .highlight .dl { color: #dd2200; background-color: #fff0f0 } /* Literal.String.Delimiter */ .highlight .sd { color: #dd2200; background-color: #fff0f0 } /* Literal.String.Doc */ .highlight .s2 { color: #dd2200; background-color: #fff0f0 } /* Literal.String.Double */ .highlight .se { color: #0044dd; background-color: #fff0f0 } /* Literal.String.Escape */ .highlight .sh { color: #dd2200; background-color: #fff0f0 } /* Literal.String.Heredoc */ .highlight .si { color: #3333bb; background-color: #fff0f0 } /* Literal.String.Interpol */ .highlight .sx { color: #22bb22; background-color: #f0fff0 } /* Literal.String.Other */ .highlight .sr { color: #008800; background-color: #fff0ff } /* Literal.String.Regex */ .highlight .s1 { color: #dd2200; background-color: #fff0f0 } /* Literal.String.Single */ .highlight .ss { color: #aa6600; background-color: #fff0f0 } /* Literal.String.Symbol */ .highlight .bp { color: #003388 } /* Name.Builtin.Pseudo */ .highlight .fm { color: #0066bb; font-weight: bold } /* Name.Function.Magic */ .highlight .vc { color: #336699 } /* Name.Variable.Class */ .highlight .vg { color: #dd7700 } /* Name.Variable.Global */ .highlight .vi { color: #3333bb } /* Name.Variable.Instance */ .highlight .vm { color: #336699 } /* Name.Variable.Magic */ .highlight .il { color: #0000DD; font-weight: bold } /* Literal.Number.Integer.Long */
# CGI/ERB sample for Ruby-GetText-Package.
#
# Copyright (C) 2005,2006 Masao Mutoh
#
# This file is distributed under the same license as the Ruby-GetText-Package.
#
# Ngoc DAO Thanh <ngocdaothanh at gmail.com>, 2007.
#
msgid ""
msgstr ""
"Project-Id-Version: cgi-sample 1.1.1\n"
"POT-Creation-Date: 2006-01-07 14:48+0900\n"
"PO-Revision-Date: 2007-03-21 10:40+0900\n"
"Last-Translator: Ngoc DAO Thanh <ngocdaothanh at gmail.com>\n"
"Language-Team: Vietnamese\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"

#: helloerb1.cgi:32
msgid "Sample script for CGI/ERB (UTF-8)."
msgstr "Script ví dụ mẫu về CGI/ERB (UTF-8)."

#: helloerb.rhtml:5
#: other.rhtml:5
msgid "Sample script for CGI/ERB and Ruby-GetText-Package"
msgstr "Script ví dụ mẫu về CGI/ERB và gói Ruby-GetText"

#: helloerb.rhtml:12
msgid "Hello World"
msgstr "Xin chào cả Thế Giới"

#: helloerb.rhtml:15
#: other.rhtml:11
msgid "locale"
msgstr "ngông ngữ"

#: helloerb.rhtml:16
#: other.rhtml:12
msgid "output_charset"
msgstr "output_charset"

#: helloerb.rhtml:17
#: other.rhtml:13
msgid "QUERY_STRING"
msgstr "QUERY_STRING"

#: helloerb.rhtml:19
msgid "Call a library method which has another textdomain."
msgstr "Gọi phương thức trong thư viện có textdomain khác."

#: helloerb.rhtml:21
#: other.rhtml:15
msgid "Back"
msgstr "Quay lui"

#: other.rhtml:8
msgid "Another sample"
msgstr "Ví dụ mẫu khác"

#: other.rhtml:9
msgid "This sample(other.rhtml) is the another ERB file of helloerb1.cgi."
msgstr "Ví dụ mẫu này (other.rhtml) là tập tin ERB khác của helloerb1.cgi."