Statistics
| Branch: | Tag: | Revision:

root / modules / gadu_protocol / services / gadu-file-transfer-service.cpp @ f38188d2

History | View | Annotate | Download (1.6 kB)

1
/*
2
 * %kadu copyright begin%
3
 * Copyright 2009 Bartlomiej Zimon (uzi18@o2.pl)
4
 * Copyright 2009 Wojciech Treter (juzefwt@gmail.com)
5
 * Copyright 2009, 2010 RafaƂ Malinowski (rafal.przemyslaw.malinowski@gmail.com)
6
 * %kadu copyright end%
7
 *
8
 * This program is free software; you can redistribute it and/or
9
 * modify it under the terms of the GNU General Public License as
10
 * published by the Free Software Foundation; either version 2 of
11
 * the License, or (at your option) any later version.
12
 *
13
 * This program is distributed in the hope that it will be useful,
14
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
15
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16
 * GNU General Public License for more details.
17
 *
18
 * You should have received a copy of the GNU General Public License
19
 * along with this program. If not, see <http://www.gnu.org/licenses/>.
20
 */
21
22
#include "misc/misc.h"
23
24
#include "dcc/dcc-manager.h"
25
#include "file-transfer/gadu-file-transfer-handler.h"
26
#include "socket-notifiers/gadu-protocol-socket-notifiers.h"
27
#include "gadu-contact-details.h"
28
#include "gadu-protocol.h"
29
30
#include "gadu-file-transfer-service.h"
31
32
GaduFileTransferService::GaduFileTransferService(GaduProtocol *protocol) :
33
                FileTransferService(protocol), Protocol(protocol)
34
{
35
}
36
37
FileTransferHandler * GaduFileTransferService::createFileTransferHandler(FileTransfer fileTransfer)
38
{
39
        GaduFileTransferHandler *handler = new GaduFileTransferHandler(fileTransfer);
40
        fileTransfer.setHandler(handler);
41
42
        return handler;
43
}
44
45
void GaduFileTransferService::newIncomingFileTransfer(FileTransfer fileTransfer)
46
{
47
        emit incomingFileTransfer(fileTransfer);
48
}