From 5527e01e0675fbb06b632ccdae423756fbff622b Mon Sep 17 00:00:00 2001 From: tpearson Date: Mon, 5 Jul 2010 08:45:53 +0000 Subject: Many fixes to the Yahoo protocol, courtesy of Serghei Amelian git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdenetwork@1146108 283d02a7-25f6-0310-bc7c-ecb5cbfe19da --- kopete/protocols/yahoo/libkyahoo/mailnotifiertask.cpp | 18 +++++++----------- 1 file changed, 7 insertions(+), 11 deletions(-) (limited to 'kopete/protocols/yahoo/libkyahoo/mailnotifiertask.cpp') diff --git a/kopete/protocols/yahoo/libkyahoo/mailnotifiertask.cpp b/kopete/protocols/yahoo/libkyahoo/mailnotifiertask.cpp index 7bea2c8f..1d637877 100644 --- a/kopete/protocols/yahoo/libkyahoo/mailnotifiertask.cpp +++ b/kopete/protocols/yahoo/libkyahoo/mailnotifiertask.cpp @@ -2,7 +2,7 @@ Kopete Yahoo Protocol Notifies about new mails - Copyright (c) 2005 André Duffeck + Copyright (c) 2005 André Duffeck ************************************************************************* * * @@ -21,12 +21,11 @@ #include "ymsgtransfer.h" #include "yahootypes.h" #include "client.h" -#include #include MailNotifierTask::MailNotifierTask(Task* parent) : Task(parent) { - kdDebug(YAHOO_RAW_DEBUG) << k_funcinfo << endl; + kdDebug(YAHOO_RAW_DEBUG) ; } MailNotifierTask::~MailNotifierTask() @@ -36,8 +35,6 @@ MailNotifierTask::~MailNotifierTask() bool MailNotifierTask::take( Transfer* transfer ) { - kdDebug(YAHOO_RAW_DEBUG) << k_funcinfo << endl; - if ( !forMe( transfer ) ) return false; @@ -48,11 +45,10 @@ bool MailNotifierTask::take( Transfer* transfer ) return true; } -bool MailNotifierTask::forMe( Transfer* transfer ) const +bool MailNotifierTask::forMe( const Transfer* transfer ) const { - kdDebug(YAHOO_RAW_DEBUG) << k_funcinfo << endl; - YMSGTransfer *t = 0L; - t = dynamic_cast(transfer); + const YMSGTransfer *t = 0L; + t = dynamic_cast(transfer); if (!t) return false; @@ -64,7 +60,7 @@ bool MailNotifierTask::forMe( Transfer* transfer ) const void MailNotifierTask::parseMail( YMSGTransfer *t ) { - kdDebug(YAHOO_RAW_DEBUG) << k_funcinfo << endl; + kdDebug(YAHOO_RAW_DEBUG) ; QString count = t->firstParam( 9 ); QString mail = t->firstParam( 42 ); @@ -74,7 +70,7 @@ void MailNotifierTask::parseMail( YMSGTransfer *t ) if( !mail.isEmpty() && !from.isEmpty() && !subject.isEmpty() ) emit mailNotify( QString::fromLatin1( "%1 <%2>").arg( from, mail ), subject, count.toInt() ); else - emit mailNotify( QString::null, QString::null, count.toInt()); + emit mailNotify( QString(), QString(), count.toInt()); } #include "mailnotifiertask.moc" -- cgit v1.2.1