Bump version to 4.3-4
[LibreOffice.git] / tubes / source / collaboration.cxx
bloba6e5ec09b760e223249a709df40fe8a62e4b859b
1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2 /*
3 * This file is part of the LibreOffice project.
5 * This Source Code Form is subject to the terms of the Mozilla Public
6 * License, v. 2.0. If a copy of the MPL was not distributed with this
7 * file, You can obtain one at http://mozilla.org/MPL/2.0/.
8 */
10 #include <tubes/collaboration.hxx>
12 #include <tubes/conference.hxx>
13 #include <tubes/manager.hxx>
15 Collaboration::Collaboration() :
16 mpConference( NULL ),
17 mpContacts( NULL )
19 TeleManager::registerCollaboration( this );
22 Collaboration::~Collaboration()
24 TeleManager::unregisterCollaboration( this );
25 if (mpConference)
26 mpConference->close();
29 sal_uInt64 Collaboration::GetId() const
31 return reinterpret_cast<sal_uInt64> (this);
34 void Collaboration::Invite( TpContact* pContact ) const
36 if (mpConference)
38 mpConference->invite( pContact );
39 SaveAndSendFile( pContact );
43 void Collaboration::SendFile( TpContact* pContact, const OUString& rURL ) const
45 if (mpConference)
46 mpConference->sendFile( pContact, rURL, NULL, NULL );
49 void Collaboration::SendPacket( const OString& rPacket ) const
51 if (mpConference)
52 mpConference->sendPacket( rPacket );
55 void Collaboration::SetConference( TeleConference* pConference )
57 mpConference = pConference;
58 mpConference->setCollaboration( this );
61 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */