1
0
mirror of https://github.com/tomahawk-player/tomahawk.git synced 2025-03-22 16:59:58 +01:00

Add setProxy() method to SipPlugin interface

This commit is contained in:
Dominik Schmidt 2011-05-03 16:53:29 +02:00
parent 5b961e1a58
commit 117bff483d
4 changed files with 17 additions and 5 deletions

View File

@ -1,6 +1,7 @@
/* === This file is part of Tomahawk Player - <http://tomahawk-player.org> ===
*
*
* Copyright 2010-2011, Christian Muehlhaeuser <muesli@tomahawk-player.org>
* 2011, Dominik Schmidt <dev@dominik-schmidt.de>
*
* Tomahawk is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
@ -31,3 +32,9 @@ SipPlugin::configWidget()
{
return 0;
}
void
SipPlugin::setProxy( const QNetworkProxy& proxy )
{
qDebug() << Q_FUNC_INFO << "Not implemented";
}

View File

@ -1,6 +1,7 @@
/* === This file is part of Tomahawk Player - <http://tomahawk-player.org> ===
*
*
* Copyright 2010-2011, Christian Muehlhaeuser <muesli@tomahawk-player.org>
* 2011, Dominik Schmidt <dev@dominik-schmidt.de>
*
* Tomahawk is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
@ -22,6 +23,8 @@
#include <QObject>
#include <QString>
#include <QMenu>
#include <QNetworkProxy>
#include "dllmacro.h"
@ -49,6 +52,8 @@ public slots:
virtual void addContact( const QString &jid, const QString& msg = QString() ) = 0;
virtual void sendMsg( const QString& to, const QString& msg ) = 0;
void setProxy( const QNetworkProxy &proxy );
signals:
void error( int, const QString& );
void connected();

View File

@ -115,7 +115,7 @@ JabberPlugin::~JabberPlugin()
}
void
JabberPlugin::setProxy( QNetworkProxy* proxy )
JabberPlugin::setProxy( const QNetworkProxy &proxy )
{
if(m_currentServer.isEmpty() || !(m_currentPort > 0))
{
@ -130,7 +130,7 @@ JabberPlugin::setProxy( QNetworkProxy* proxy )
m_client->setConnection(new Jreen::TcpConnection(m_currentServer, m_currentPort));
}
qobject_cast<Jreen::DirectConnection*>(m_client->connection())->setProxy(*proxy);
qobject_cast<Jreen::DirectConnection*>(m_client->connection())->setProxy(proxy);
}

View File

@ -62,7 +62,6 @@ public:
virtual const QString accountName();
virtual QMenu* menu();
void setProxy( QNetworkProxy* proxy );
signals:
void jidChanged( const QString& );
@ -73,6 +72,7 @@ public slots:
void sendMsg( const QString& to, const QString& msg );
void broadcastMsg( const QString &msg );
void addContact( const QString &jid, const QString& msg = QString() );
void setProxy( const QNetworkProxy &proxy );
private slots:
void showAddFriendDialog();