diff --git a/accountwizard.cpp b/accountwizard.cpp index 09166839b..5c96d776f 100644 --- a/accountwizard.cpp +++ b/accountwizard.cpp @@ -414,7 +414,7 @@ void AccountWizard::createTransport() if ( pathToSendmail.isEmpty() ) { pathToSendmail = KStandardDirs::findExe( "sendmail", "/usr/sbin" ); if ( pathToSendmail.isEmpty() ) { - kWarning() <<"Could not find the sendmail binary for local delivery"; + kWarning(5006) <<"Could not find the sendmail binary for local delivery"; // setting the path to the most likely location pathToSendmail = "/usr/sbin/sendmail"; } diff --git a/configuredialog.cpp b/configuredialog.cpp index 883faff06..db3de0a7e 100644 --- a/configuredialog.cpp +++ b/configuredialog.cpp @@ -508,7 +508,7 @@ void IdentityPage::slotRemoveIdentity() Q_ASSERT( !mIdentityDialog ); KPIMIdentities::IdentityManager *im = kmkernel->identityManager(); - kFatal( im->shadowIdentities().count() < 2 ) + kFatal( im->shadowIdentities().count() < 2, 5006 ) << "Attempted to remove the last identity!"; IdentityListViewItem *item = 0; diff --git a/keyresolver.cpp b/keyresolver.cpp index b7309689a..1ca01806a 100644 --- a/keyresolver.cpp +++ b/keyresolver.cpp @@ -101,13 +101,13 @@ static bool ValidTrustedOpenPGPEncryptionKey( const GpgME::Key & key ) { } #if 0 if ( key.isRevoked() ) - kWarning() <<" is revoked"; + kWarning(5006) <<" is revoked"; if ( key.isExpired() ) - kWarning() <<" is expired"; + kWarning(5006) <<" is expired"; if ( key.isDisabled() ) - kWarning() <<" is disabled"; + kWarning(5006) <<" is disabled"; if ( !key.canEncrypt() ) - kWarning() <<" can't encrypt"; + kWarning(5006) <<" can't encrypt"; #endif if ( key.isRevoked() || key.isExpired() || key.isDisabled() || !key.canEncrypt() ) return false; @@ -118,9 +118,9 @@ static bool ValidTrustedOpenPGPEncryptionKey( const GpgME::Key & key ) { #if 0 else if ( it->isRevoked() ) - kWarning() <<"a userid is revoked"; + kWarning(5006) <<"a userid is revoked"; else - kWarning() <<"bad validity" << it->validity(); + kWarning(5006) <<"bad validity" << it->validity(); #endif } return false; @@ -1436,7 +1436,7 @@ void Kleo::KeyResolver::addKeys( const std::vector & items ) { } } if ( f == AutoFormat ) - kWarning() <<"Kleo::KeyResolver::addKeys(): Something went wrong. Didn't find a format for \"" + kWarning(5006) <<"Kleo::KeyResolver::addKeys(): Something went wrong. Didn't find a format for \"" << it->address << "\""; else std::remove_copy_if( it->keys.begin(), it->keys.end(), diff --git a/kmailicalifaceimpl.cpp b/kmailicalifaceimpl.cpp index bf3ff2238..da27d38c8 100644 --- a/kmailicalifaceimpl.cpp +++ b/kmailicalifaceimpl.cpp @@ -1464,7 +1464,7 @@ void KMailICalIfaceImpl::triggerKolabFreeBusy( const KUrl& folderURL ) Q_ASSERT( path.startsWith( '/' ) ); int secondSlash = path.indexOf( '/', 1 ); if ( secondSlash == -1 ) { - kWarning() <<"KCal::ResourceKolab::fromKMailFolderSynced path is too short:" << path; + kWarning(5006) <<"KCal::ResourceKolab::fromKMailFolderSynced path is too short:" << path; return; } if ( path.startsWith( "/INBOX/", Qt::CaseInsensitive ) ) { diff --git a/kmcommands.cpp b/kmcommands.cpp index 350620cf3..999aca65c 100644 --- a/kmcommands.cpp +++ b/kmcommands.cpp @@ -3445,7 +3445,7 @@ KMCommand::Result CreateTodoCommand::execute() kDebug() <<"Loaded" << dcopService <<" successfully"; Q_ASSERT( kapp->dcopClient()->findObject( dcopService, dcopObjectId, "", QByteArray(), dummy, dummy ) ); } else - kWarning() <<"Error loading" << dcopService; + kWarning(5006) <<"Error loading" << dcopService; } #endif } diff --git a/kmcomposewin.cpp b/kmcomposewin.cpp index 9f9efd09b..bc3992dec 100644 --- a/kmcomposewin.cpp +++ b/kmcomposewin.cpp @@ -2372,7 +2372,7 @@ QString KMComposeWin::prettyMimeType( const QString &type ) const KMimeType::Ptr st = KMimeType::mimeType( t ); if ( !st ) { - kWarning() <<"unknown mimetype" << t; + kWarning(5006) <<"unknown mimetype" << t; return QString(); } @@ -2458,7 +2458,7 @@ void KMComposeWin::addrBookSelInto() addrBookSelIntoOld(); } } else { - kWarning() <<"To be implemented: call recipients picker."; + kWarning(5006) <<"To be implemented: call recipients picker."; } } diff --git a/kmfolderimap.cpp b/kmfolderimap.cpp index 0708e09da..7cf2f00d3 100644 --- a/kmfolderimap.cpp +++ b/kmfolderimap.cpp @@ -178,12 +178,12 @@ KMAcctImap* KMFolderImap::account() const if ( !mAccount ) { KMFolderDir *parentFolderDir = dynamic_cast( folder()->parent() ); if ( !parentFolderDir ) { - kWarning() <<"No parent folder dir found for" << folder()->prettyUrl(); + kWarning(5006) <<"No parent folder dir found for" << folder()->prettyUrl(); return 0; } KMFolder *parentFolder = parentFolderDir->owner(); if ( !parentFolder ) { - kWarning() <<"No parent folder found for" << folder()->prettyUrl(); + kWarning(5006) <<"No parent folder found for" << folder()->prettyUrl(); return 0; } KMFolderImap *parentStorage = dynamic_cast( parentFolder->storage() ); diff --git a/kmfoldertree.cpp b/kmfoldertree.cpp index d5d153737..53bb6663c 100644 --- a/kmfoldertree.cpp +++ b/kmfoldertree.cpp @@ -1552,7 +1552,7 @@ void KMFolderTree::contentsDropEvent( QDropEvent *e ) emit folderDropCopy( fti->folder() ); } else if ( action == DRAG_COPY || action == DRAG_MOVE ) { if ( !MailList::canDecode( e->mimeData() ) ) { - kWarning() <<"Could not decode drag data!"; + kWarning(5006) <<"Could not decode drag data!"; } else { MailList list = MailList::fromMimeData( e->mimeData() ); QList serNums = MessageCopyHelper::serNumListFromMailList( list ); diff --git a/kmkernel.cpp b/kmkernel.cpp index 4e1f2d85b..d77f7aad4 100644 --- a/kmkernel.cpp +++ b/kmkernel.cpp @@ -543,7 +543,7 @@ void KMKernel::setDefaultTransport( const QString & transport ) { MailTransport::Transport *t = MailTransport::TransportManager::self()->transportByName( transport, false ); if ( !t ) { - kWarning() <<"The transport you entered is not available"; + kWarning(5006) <<"The transport you entered is not available"; return; } MailTransport::TransportManager::self()->setDefaultTransport( t->id() ); @@ -1907,7 +1907,7 @@ void KMKernel::emergencyExit( const QString& reason ) "terminate now.\nThe error was:\n%1", reason ); } - kWarning() << mesg; + kWarning(5006) << mesg; KNotification::event(KNotification::Catastrophe, mesg); ::exit(1); diff --git a/kmmsgpart.cpp b/kmmsgpart.cpp index 35bddc70b..8fa0a4eb9 100644 --- a/kmmsgpart.cpp +++ b/kmmsgpart.cpp @@ -148,7 +148,7 @@ QString KMMessagePart::bodyToUnicode(const QTextCodec* codec) const { void KMMessagePart::setCharset( const QByteArray & c ) { if ( type() != DwMime::kTypeText ) - kWarning() + kWarning(5006) << "KMMessagePart::setCharset(): trying to set a charset for a non-textual mimetype." << endl << "Fix this caller:" << endl << "====================================================================" << endl @@ -316,7 +316,7 @@ QString KMMessagePart::iconName() const if (mime) { fileName = mime->iconName(); } else { - kWarning() <<"unknown mimetype" << mimeType; + kWarning(5006) <<"unknown mimetype" << mimeType; } if ( fileName.isEmpty() ) diff --git a/kmreaderwin.cpp b/kmreaderwin.cpp index 50fc85492..0d3bdacf7 100644 --- a/kmreaderwin.cpp +++ b/kmreaderwin.cpp @@ -1501,7 +1501,7 @@ void KMReaderWin::parseMsg(KMMessage* aMsg) aMsg->setIsBeingParsed( true ); if ( mRootNode && !mRootNode->processed() ) { - kWarning() <<"The root node is not yet processed! Danger!"; + kWarning(5006) <<"The root node is not yet processed! Danger!"; return; } else { delete mRootNode; diff --git a/partNode.cpp b/partNode.cpp index a85c3fb87..80bbdfb4f 100644 --- a/partNode.cpp +++ b/partNode.cpp @@ -586,7 +586,7 @@ bool partNode::isFirstTextPart() const { for ( const partNode * n = root ; n ; n = n->next() ) if ( n->type() == DwMime::kTypeText ) return n == this; - kFatal() <<"partNode::isFirstTextPart(): Didn't expect to end up here..."; + kFatal(5006) <<"partNode::isFirstTextPart(): Didn't expect to end up here..."; return false; // make comiler happy }