------- You are receiving this mail because: ------- You are on the CC list for the bug, or are watching someone who is. http://bugs.kde.org/show_bug.cgi?id=99028 ------- Additional Comments From mart.kde hccnet nl 2005-07-31 22:27 ------- SVN commit 441746 by mkelder: This shows a passive popup if an error occured during checking and passive popup's are enabled. The passive popup contains an error description. CCBUG: 99028 M +2 -0 accountmanager.cpp M +6 -0 dockeditem.cpp M +2 -0 dockeditem.h M +6 -0 hvitem.cpp M +6 -0 hvitem.h M +3 -1 kio.cpp M +2 -0 kio.h M +2 -0 kio_count.cpp M +1 -0 kio_subjects.cpp M +8 -0 maildrop.h --- branches/KDE/3.5/kdepim/korn/accountmanager.cpp #441745:441746 @ -86,6 +86,8 @ connect( kiodrop, SIGNAL( changed( int, KMailDrop* ) ), this, SLOT( slotChanged( int, KMailDrop* ) ) ); connect( kiodrop, SIGNAL( showPassivePopup( QPtrList< KornMailSubject >*, int, bool, const QString& ) ), this, SLOT( slotShowPassivePopup( QPtrList< KornMailSubject >*, int, bool, const QString& ) ) ); + connect( kiodrop, SIGNAL( showPassivePopup( const QString&, const QString& ) ), + this, SLOT( slotShowPassivePopup( const QString&, const QString& ) ) ); connect( kiodrop, SIGNAL( validChanged( bool ) ), this, SLOT( slotValidChanged( bool ) ) ); kiodrop->readGeneralConfigGroup( *masterGroup ); --- branches/KDE/3.5/kdepim/korn/dockeditem.cpp #441745:441746 @ -25,6 +25,7 @ #include #include #include +#include #include #include @ -77,6 +78,11 @ showPassivePopup( _systemtray, list, total, name, date ); } +void DockedItem::slotShowPassivePopup( const QString& message, const QString& name ) +{ + KPassivePopup::message( QString( "Korn - %1/%2" ).arg( objId() ).arg( name ), message, _systemtray, "Passive error message" ); +} + void DockedItem::doPopup() { _systemtray->contextMenu()->popup( QCursor::pos() ); --- branches/KDE/3.5/kdepim/korn/dockeditem.h #441745:441746 @ -77,6 +77,8 @ virtual void setTooltip( const QString& string ); void slotShowPassivePopup( QPtrList< KornMailSubject >* list, int total, bool date, const QString& ); + + void slotShowPassivePopup( const QString& error, const QString& ); protected: /** --- branches/KDE/3.5/kdepim/korn/hvitem.cpp #441745:441746 @ -23,6 +23,7 @ #include #include #include +#include #include #include @ -67,6 +68,11 @ { showPassivePopup( _label, list, total, name, date ); } + +void HVItem::slotShowPassivePopup( const QString& errorMessage, const QString& name ) +{ + KPassivePopup::message( QString( "korn-%1-%2" ).arg( objId() ).arg( name ), errorMessage, _label, "Passive error message" ); +} void HVItem::doPopup() { --- branches/KDE/3.5/kdepim/korn/hvitem.h #441745:441746 @ -62,6 +62,12 @ void slotShowPassivePopup( QPtrList< KornMailSubject >* list, int total, bool date, const QString& ); /** + * This slot triggered when the passive popup is to be shown. It is transported + * to BoxContainerItem, but so it is possible to change the arguments. + */ + void slotShowPassivePopup( const QString& errorMessage, const QString& name ); + + /** * Trigered if the popup-menu is to be shown */ virtual void doPopup(); --- branches/KDE/3.5/kdepim/korn/kio.cpp #441745:441746 @ -264,7 +264,7 @ bool KKioDrop::valid() { - return _valid && _count->valid( ) && _subjects->valid(); + return _valid && _count->valid() && _subjects->valid(); } KKioDrop::~KKioDrop() @ -425,6 +425,8 @ void KKioDrop::slotConnectionError( int number, const QString& arg ) { kdError() << KIO::buildErrorString( number, arg ) << endl; +// if( passivePopup() ) + emitShowPassivePopup( KIO::buildErrorString( number, arg ) ); } void KKioDrop::slotConnectionWarning( const QString& msg ) --- branches/KDE/3.5/kdepim/korn/kio.h #441745:441746 @ -179,6 +179,8 @ void emitShowPassivePopup( QPtrList< KornMailSubject > *subject, int total ) { emit showPassivePopup( subject, total, passiveDate(), this->realName() ); } + void emitShowPassivePopup( const QString& error ) + { if( passivePopup() ) { emit showPassivePopup( error, this->realName() ); } } void emitValidChanged() { emit validChanged( valid() ); } private slots: --- branches/KDE/3.5/kdepim/korn/kio_count.cpp #441745:441746 @ -87,6 +87,7 @ if( ! ( _slave = KIO::Scheduler::getConnectedSlave( kurl, metadata ) ) ) //Forcing reload { kdWarning() << i18n( "Not able to open a kio slave for %1." ).arg( _protocol->configName() ) << endl; + _kio->emitShowPassivePopup( i18n( "Not able to open a kio slave for %1." ).arg( _protocol->configName() ) ); _valid = false; _kio->emitValidChanged(); _slave = 0; @ -207,6 +208,7 @ if( job->error() ) { kdError() << i18n( "The next KIO-error occurred by counting: %1" ).arg( job->errorString() ) << endl; + _kio->emitShowPassivePopup( i18n( "The next KIO-error occurred by counting: %1" ).arg( job->errorString() ) ); _valid = false; _kio->emitValidChanged(); } --- branches/KDE/3.5/kdepim/korn/kio_subjects.cpp #441745:441746 @ -102,6 +102,7 @ if( ! ( _slave = KIO::Scheduler::getConnectedSlave( kurl, metadata ) ) ) { kdWarning() << i18n( "Not able to open a kio-slave for %1." ).arg( _protocol->configName() ); + _kio->emitShowPassivePopup( i18n( "Not able to open a kio-slave for %1." ).arg( _protocol->configName() ) ); _valid = false; _kio->emitValidChanged(); _slave = 0; --- branches/KDE/3.5/kdepim/korn/maildrop.h #441745:441746 @ -362,6 +362,14 @ * some more info that could be used with the popup. */ void showPassivePopup( QPtrList< KornMailSubject >*, int, bool, const QString& realname ); + + /** + * This signal is emitted when a passive error message should be displayed. + * + * param error The error message + * param realName The real name of this object. + */ + void showPassivePopup( const QString& error, const QString& realname ); /** * readSubjects() might signal readSubject() if