Members of the KDE Community are recommended to subscribe to the kde-community mailing list at https://mail.kde.org/mailman/listinfo/kde-community to allow them to participate in important discussions and receive other important announcements

Commit a096462a authored by Laurent Montel's avatar Laurent Montel 😁 Committed by Pali Rohár

Reactivate qq protocol

parent 75f2ec11
......@@ -27,6 +27,7 @@
#include <kactionmenu.h>
#include <kshortcut.h>
#include <kicon.h>
#include <kmessagebox_queued.h>
#include <kopetecontact.h>
#include <kopetecontactaction.h>
......@@ -49,7 +50,7 @@ QQChatSession::QQChatSession( const Kopete::Contact* user, Kopete::ContactPtrLis
kDebug ( 14140 ) << "New message manager for " << user->contactId();
// Needed because this is (indirectly) a KXMLGuiClient, so it can find the gui description .rc file
setComponentData( protocol->componentData() );
//setComponentData( protocol->componentData() );
// make sure Kopete knows about this instance
Kopete::ChatSessionManager::self()->registerChatSession ( this );
......@@ -290,13 +291,13 @@ void QQChatSession::slotActionInviteAboutToShow()
{
if( !members().contains( it.value() ) && it.value()->isOnline() )
{
KAction *a = new Kopete::UI::ContactAction( it.value(), actionCollection() );
QAction *a = new Kopete::UI::ContactAction( it.value(), actionCollection() );
m_actionInvite->addAction( a );
m_inviteActions.append( a ) ;
}
}
// Invite someone off-list
KAction *b=new KAction( KIcon(), i18n ("&Other..."), actionCollection() );
QAction *b=new QAction( KIcon(), i18n ("&Other..."), actionCollection() );
actionCollection()->addAction( "actionOther", b );
QObject::connect( b, SIGNAL(triggered(bool)),
this, SLOT(slotInviteOtherContact()) );
......
......@@ -13,7 +13,6 @@
#ifndef QQCHATSESSION_H
#define QQCHATSESSION_H
#include <q3ptrqueue.h>
#include <QLabel>
#include <QList>
#include <QDateTime>
......@@ -157,7 +156,7 @@ private:
QList< Kopete::Message > m_pendingOutgoingMessages; // messages queued while we wait for the server to tell us the conference is created.
Kopete::ContactPtrList m_pendingInvites; // people we wanted to invite to the conference, queued while waiting for the conference to be created.
KActionMenu *m_actionInvite;
typedef QList<KAction*> ActionList;
typedef QList<QAction*> ActionList;
ActionList m_inviteActions;
// labels showing secure and logging status
QAction *m_secure;
......
......@@ -25,7 +25,7 @@
#include <QList>
#undef KDE_NO_COMPAT
#include <kaction.h>
#include <QAction>
#include <kdebug.h>
#include <kfiledialog.h>
#include <QLineEdit>
......@@ -128,31 +128,31 @@ Kopete::ChatSession *QQContact::manager( Kopete::Contact::CanCreateFlags canCrea
return static_cast<QQAccount*>(account())->chatSession( chatMembers, guid, canCreate );
}
QList<KAction*> *QQContact::customContextMenuActions()
QList<QAction*> *QQContact::customContextMenuActions()
{
QList<KAction*> *m_actionCollection = new QList<KAction*>;
QList<QAction*> *m_actionCollection = new QList<QAction*>;
// Block/unblock Contact
QString label = isBlocked() ? i18n( "Unblock User" ) : i18n( "Block User" );
if( !actionBlock )
{
actionBlock = new KAction( KIcon("qq_blocked"), label, this );
actionBlock = new QAction( KIcon("qq_blocked"), label, this );
connect( actionBlock, SIGNAL(triggered(bool)), this, SLOT(slotBlockUser()) );
//show profile
actionShowProfile = new KAction( i18n("Show Profile"), this );
actionShowProfile = new QAction( i18n("Show Profile"), this );
connect( actionBlock, SIGNAL(triggered(bool)), this, SLOT(slotShowProfile()) );
// Send mail (only available if it is an hotmail account)
actionSendMail = new KAction( KIcon("mail-message-new"), i18n("Send Email..."), this );
actionSendMail = new QAction( KIcon("mail-message-new"), i18n("Send Email..."), this );
connect( actionSendMail, SIGNAL(triggered(bool)), this, SLOT(slotSendMail()) );
// Invite to receive webcam
actionWebcamReceive = new KAction( KIcon("webcamreceive"), i18n( "View Contact's Webcam" ), this );
actionWebcamReceive = new QAction( KIcon("webcamreceive"), i18n( "View Contact's Webcam" ), this );
connect( actionWebcamReceive, SIGNAL(triggered(bool)), this, SLOT(slotWebcamReceive()) );
//Send webcam action
actionWebcamSend = new KAction( KIcon("webcamsend"), i18n( "Send Webcam" ), this );
actionWebcamSend = new QAction( KIcon("webcamsend"), i18n( "Send Webcam" ), this );
connect( actionWebcamSend, SIGNAL(triggered(bool)), this, SLOT(slotWebcamSend()) );
}
else
......
......@@ -32,7 +32,7 @@
class QPixmap;
class KAction;
class QAction;
class KTemporaryFile;
namespace Kopete { class Protocol; }
......@@ -93,7 +93,7 @@ public:
virtual bool isReachable();
virtual QList<KAction*> *customContextMenuActions();
virtual QList<QAction*> *customContextMenuActions();
using Kopete::Contact::customContextMenuActions;
/**
......@@ -176,11 +176,11 @@ private:
QString m_phoneMobile;
KAction *actionBlock;
KAction *actionShowProfile;
KAction *actionSendMail;
KAction *actionWebcamReceive;
KAction *actionWebcamSend;
QAction *actionBlock;
QAction *actionShowProfile;
QAction *actionSendMail;
QAction *actionWebcamReceive;
QAction *actionWebcamSend;
QString m_obj; //the QQObject
QMap<const char*, QByteArray> m_contactDetail;
......
......@@ -31,7 +31,7 @@ K_EXPORT_PLUGIN( QQProtocolFactory( "kopete_qq" ) )
QQProtocol *QQProtocol::s_protocol = 0L;
QQProtocol::QQProtocol( QObject* parent, const QVariantList &/*args*/ )
: Kopete::Protocol( QQProtocolFactory::componentData(), parent ),
: Kopete::Protocol( parent ),
qqOnline( Kopete::OnlineStatus::Online, 25, this, 0, QStringList(QString()),
i18n( "Online" ), i18n( "O&nline" ) ),
qqAway( Kopete::OnlineStatus::Away, 25, this, 1, QStringList(QLatin1String("msn_away")),
......
......@@ -19,12 +19,10 @@
#include "qqeditaccountwidget.h"
#include <qcheckbox.h>
#include <q3groupbox.h>
#include <qimage.h>
#include <qlabel.h>
#include <qlayout.h>
#include <qlineedit.h>
#include <q3listbox.h>
#include <qpushbutton.h>
#include <qregexp.h>
#include <qspinbox.h>
......@@ -54,6 +52,7 @@
#include "qqnotifysocket.h"
#include "qqprotocol.h"
#include "dlgqqvcard.h"
#include <kmessagebox_queued.h>
// TODO: This was using KAutoConfig before, use KConfigXT instead.
class QQEditAccountWidgetPrivate
......
......@@ -36,7 +36,7 @@ QQWebcamDialog::QQWebcamDialog( const QString &contactId, QWidget * parent )
//setButtons( KDialog::Close );
setDefaultButton( KDialog::Close );
// showButtonSeparator( true );
setWindowFlags( Qt::WDestructiveClose );
//FIXME KF5 setWindowFlags( Qt::WDestructiveClose );
setInitialSize( QSize(320,290) );
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment