2018-11-11 05:59:55 -05:00
|
|
|
/*******************************************************************************
|
|
|
|
* plugins/VOIP/VOIPPlugin.h *
|
|
|
|
* *
|
|
|
|
* Copyright 2015 by retroshare team <retroshare.project@gmail.com> *
|
|
|
|
* *
|
|
|
|
* This program is free software: you can redistribute it and/or modify *
|
|
|
|
* it under the terms of the GNU Affero 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 Affero General Public License for more details. *
|
|
|
|
* *
|
|
|
|
* You should have received a copy of the GNU Affero General Public License *
|
|
|
|
* along with this program. If not, see <https://www.gnu.org/licenses/>. *
|
|
|
|
* *
|
|
|
|
*******************************************************************************/
|
|
|
|
|
2012-02-15 16:17:18 -05:00
|
|
|
#pragma once
|
|
|
|
|
2015-05-26 11:19:57 -04:00
|
|
|
/*VOIP*/
|
|
|
|
#include "gui/VOIPToasterNotify.h"
|
2015-05-11 15:40:07 -04:00
|
|
|
#include "services/p3VOIP.h"
|
2012-02-15 16:17:18 -05:00
|
|
|
|
2015-05-26 11:19:57 -04:00
|
|
|
/*libretroshare"*/
|
|
|
|
#include <retroshare/rsplugin.h>
|
|
|
|
|
2015-05-11 15:40:07 -04:00
|
|
|
class VOIPGUIHandler ;
|
|
|
|
class VOIPNotify ;
|
2012-02-25 13:15:36 -05:00
|
|
|
|
2012-02-15 16:17:18 -05:00
|
|
|
class VOIPPlugin: public RsPlugin
|
|
|
|
{
|
|
|
|
public:
|
|
|
|
VOIPPlugin() ;
|
|
|
|
virtual ~VOIPPlugin() {}
|
|
|
|
|
2014-08-26 18:16:32 -04:00
|
|
|
virtual p3Service *p3_service() const ;
|
2015-10-05 13:15:53 -04:00
|
|
|
virtual p3Config *p3_config() const { return mVOIP; }
|
2012-02-18 15:30:10 -05:00
|
|
|
virtual uint16_t rs_service_id() const { return RS_SERVICE_TYPE_VOIP_PLUGIN ; }
|
2012-02-18 10:56:37 -05:00
|
|
|
virtual ConfigPage *qt_config_page() const ;
|
2012-09-04 17:57:10 -04:00
|
|
|
virtual QDialog *qt_about_page() const ;
|
2014-01-01 19:56:46 -05:00
|
|
|
virtual ChatWidgetHolder *qt_get_chat_widget_holder(ChatWidget *chatWidget) const ;
|
2012-08-15 09:54:00 -04:00
|
|
|
|
|
|
|
virtual QIcon *qt_icon() const;
|
2015-06-28 06:11:47 -04:00
|
|
|
virtual std::string qt_stylesheet() { return "VOIP"; }
|
2012-10-12 14:44:02 -04:00
|
|
|
virtual QTranslator *qt_translator(QApplication *app, const QString& languageCode, const QString& externalDir) const;
|
2012-10-21 17:38:55 -04:00
|
|
|
virtual void qt_sound_events(SoundEvents &events) const;
|
2012-02-15 16:17:18 -05:00
|
|
|
|
2015-01-14 18:26:51 -05:00
|
|
|
virtual void getPluginVersion(int& major, int& minor, int &build, int& svn_rev) const ;
|
2012-02-15 16:17:18 -05:00
|
|
|
virtual void setPlugInHandler(RsPluginHandler *pgHandler);
|
|
|
|
|
|
|
|
virtual std::string configurationFileName() const { return "voip.cfg" ; }
|
|
|
|
|
|
|
|
virtual std::string getShortPluginDescription() const ;
|
|
|
|
virtual std::string getPluginName() const;
|
2015-06-14 13:45:26 -04:00
|
|
|
virtual void getLibraries(std::list<RsLibraryInfo> &libraries);
|
2012-02-15 16:17:18 -05:00
|
|
|
virtual void setInterfaces(RsPlugInInterfaces& interfaces);
|
|
|
|
|
2015-05-26 11:19:57 -04:00
|
|
|
//================================== RsPlugin Notify ==================================//
|
|
|
|
virtual ToasterNotify *qt_toasterNotify();
|
|
|
|
|
2012-02-15 16:17:18 -05:00
|
|
|
private:
|
2015-05-11 15:40:07 -04:00
|
|
|
mutable p3VOIP *mVOIP ;
|
2012-02-15 16:17:18 -05:00
|
|
|
mutable RsPluginHandler *mPlugInHandler;
|
|
|
|
mutable RsPeers* mPeers;
|
2012-02-18 10:56:37 -05:00
|
|
|
mutable ConfigPage *config_page ;
|
2012-08-15 09:54:00 -04:00
|
|
|
mutable QIcon *mIcon;
|
2012-02-25 13:15:36 -05:00
|
|
|
|
2015-05-11 15:40:07 -04:00
|
|
|
VOIPNotify *mVOIPNotify ;
|
|
|
|
VOIPGUIHandler *mVOIPGUIHandler ;
|
2015-05-26 11:19:57 -04:00
|
|
|
VOIPToasterNotify *mVOIPToasterNotify ;
|
2012-02-15 16:17:18 -05:00
|
|
|
};
|
|
|
|
|