diff options
author | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2011-08-10 22:19:39 +0000 |
---|---|---|
committer | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2011-08-10 22:19:39 +0000 |
commit | 36a36a5c1015aa0d03f4515c401e907ddb9d6291 (patch) | |
tree | 0212ba6d2c749043134005a41f2bd0379619d40f /kmail/imapaccountbase.cpp | |
parent | 4c6f8d69e2d1501837affb472c4eb8fec4462240 (diff) | |
download | tdepim-36a36a5c1015aa0d03f4515c401e907ddb9d6291.tar.gz tdepim-36a36a5c1015aa0d03f4515c401e907ddb9d6291.zip |
rename the following methods:
tqparent parent
tqmask mask
git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdepim@1246260 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'kmail/imapaccountbase.cpp')
-rw-r--r-- | kmail/imapaccountbase.cpp | 86 |
1 files changed, 43 insertions, 43 deletions
diff --git a/kmail/imapaccountbase.cpp b/kmail/imapaccountbase.cpp index a06163799..977090dd2 100644 --- a/kmail/imapaccountbase.cpp +++ b/kmail/imapaccountbase.cpp @@ -79,8 +79,8 @@ namespace KMail { // // - ImapAccountBase::ImapAccountBase( AccountManager * tqparent, const TQString & name, uint id ) - : NetworkAccount( tqparent, name, id ), + ImapAccountBase::ImapAccountBase( AccountManager * parent, const TQString & name, uint id ) + : NetworkAccount( parent, name, id ), mIdleTimer( 0, "mIdleTimer" ), mNoopTimer( 0, "mNoopTimer" ), mTotal( 0 ), @@ -412,19 +412,19 @@ namespace KMail { } //----------------------------------------------------------------------------- - // TODO imapPath can be removed once tqparent can be a KMFolderImapBase or whatever - void ImapAccountBase::getUserRights( KMFolder* tqparent, const TQString& imapPath ) + // TODO imapPath can be removed once parent can be a KMFolderImapBase or whatever + void ImapAccountBase::getUserRights( KMFolder* parent, const TQString& imapPath ) { // There isn't much point in asking the server about a user's rights on his own inbox, // it might not be the effective permissions (at least with Cyrus, one can admin his own inbox, // even after a SETACL that removes the admin permissions. Other imap servers apparently // don't even allow removing one's own admin permission, so this code won't hurt either). if ( imapPath == "/INBOX/" ) { - if ( tqparent->folderType() == KMFolderTypeImap ) - static_cast<KMFolderImap*>( tqparent->storage() )->setUserRights( ACLJobs::All, ACLJobs::Ok ); - else if ( tqparent->folderType() == KMFolderTypeCachedImap ) - static_cast<KMFolderCachedImap*>( tqparent->storage() )->setUserRights( ACLJobs::All, ACLJobs::Ok ); - emit receivedUserRights( tqparent ); // warning, you need to connect first to get that one + if ( parent->folderType() == KMFolderTypeImap ) + static_cast<KMFolderImap*>( parent->storage() )->setUserRights( ACLJobs::All, ACLJobs::Ok ); + else if ( parent->folderType() == KMFolderTypeCachedImap ) + static_cast<KMFolderCachedImap*>( parent->storage() )->setUserRights( ACLJobs::All, ACLJobs::Ok ); + emit receivedUserRights( parent ); // warning, you need to connect first to get that one return; } @@ -433,7 +433,7 @@ namespace KMail { ACLJobs::GetUserRightsJob* job = ACLJobs::getUserRights( mSlave, url ); - jobData jd( url.url(), tqparent ); + jobData jd( url.url(), parent ); jd.cancellable = true; insertJob(job, jd); @@ -447,7 +447,7 @@ namespace KMail { JobIterator it = findJob( job ); if ( it == jobsEnd() ) return; - KMFolder* folder = (*it).tqparent; + KMFolder* folder = (*it).parent; if ( job->error() ) { if ( job->error() == KIO::ERR_UNSUPPORTED_ACTION ) // that's when the imap server doesn't support ACLs mACLSupport = false; @@ -471,13 +471,13 @@ namespace KMail { } //----------------------------------------------------------------------------- - void ImapAccountBase::getACL( KMFolder* tqparent, const TQString& imapPath ) + void ImapAccountBase::getACL( KMFolder* parent, const TQString& imapPath ) { KURL url = getUrl(); url.setPath(imapPath); ACLJobs::GetACLJob* job = ACLJobs::getACL( mSlave, url ); - jobData jd( url.url(), tqparent ); + jobData jd( url.url(), parent ); jd.cancellable = true; insertJob(job, jd); @@ -491,21 +491,21 @@ namespace KMail { JobIterator it = findJob( job ); if ( it == jobsEnd() ) return; - KMFolder* folder = (*it).tqparent; + KMFolder* folder = (*it).parent; emit receivedACL( folder, job, job->entries() ); if (mSlave) removeJob(job); } //----------------------------------------------------------------------------- - // Do not remove imapPath, FolderDiaQuotaTab needs to call this with tqparent==0. - void ImapAccountBase::getStorageQuotaInfo( KMFolder* tqparent, const TQString& imapPath ) + // Do not remove imapPath, FolderDiaQuotaTab needs to call this with parent==0. + void ImapAccountBase::getStorageQuotaInfo( KMFolder* parent, const TQString& imapPath ) { if ( !mSlave ) return; KURL url = getUrl(); url.setPath(imapPath); QuotaJobs::GetStorageQuotaJob* job = QuotaJobs::getStorageQuota( mSlave, url ); - jobData jd( url.url(), tqparent ); + jobData jd( url.url(), parent ); jd.cancellable = true; insertJob(job, jd); @@ -521,7 +521,7 @@ namespace KMail { if ( job->error() && job->error() == KIO::ERR_UNSUPPORTED_ACTION ) setHasNoQuotaSupport(); - KMFolder* folder = (*it).tqparent; // can be 0 + KMFolder* folder = (*it).parent; // can be 0 emit receivedStorageQuotaInfo( folder, job, job->storageQuotaInfo() ); if (mSlave) removeJob(job); } @@ -900,7 +900,7 @@ namespace KMail { TQString quotaAsString( i18n("No detailed quota information available.") ); bool readOnly = false; if (it != mapJobData.end()) { - const KMFolder * const folder = (*it).tqparent; + const KMFolder * const folder = (*it).parent; if( !folder ) return _error; const KMFolderCachedImap * const imap = dynamic_cast<const KMFolderCachedImap*>( folder->storage() ); if ( imap ) { @@ -1109,7 +1109,7 @@ namespace KMail { // more than 50% of the parts have to be loaded anyway so it is faster // to load the message completely kdDebug(5006) << "Falling back to normal mode" << endl; - FolderJob *job = msg->tqparent()->createJob( + FolderJob *job = msg->parent()->createJob( msg, FolderJob::tGetMessage, 0, "TEXT" ); job->start(); return; @@ -1123,14 +1123,14 @@ namespace KMail { if ( part->loadHeaders() ) { kdDebug(5006) << "load HEADER" << endl; - FolderJob *job = msg->tqparent()->createJob( + FolderJob *job = msg->parent()->createJob( msg, FolderJob::tGetMessage, 0, part->partSpecifier()+".MIME" ); job->start(); } if ( part->loadPart() ) { kdDebug(5006) << "load Part" << endl; - FolderJob *job = msg->tqparent()->createJob( + FolderJob *job = msg->parent()->createJob( msg, FolderJob::tGetMessage, 0, part->partSpecifier() ); job->start(); } @@ -1139,7 +1139,7 @@ namespace KMail { //----------------------------------------------------------------------------- void ImapAccountBase::constructParts( TQDataStream & stream, int count, KMMessagePart* parentKMPart, - DwBodyPart * tqparent, const DwMessage * dwmsg ) + DwBodyPart * parent, const DwMessage * dwmsg ) { int tqchildren; for (int i = 0; i < count; i++) @@ -1152,12 +1152,12 @@ namespace KMail { << " of type " << part->originalContentTypeStr() << endl; DwBodyPart *dwpart = mCurrentMsg->createDWBodyPart( part ); - if ( tqparent ) + if ( parent ) { - // add to tqparent body - tqparent->Body().AddBodyPart( dwpart ); + // add to parent body + parent->Body().AddBodyPart( dwpart ); dwpart->Parse(); -// kdDebug(5006) << "constructed dwpart " << dwpart << ",dwmsg " << dwmsg << ",tqparent " << tqparent +// kdDebug(5006) << "constructed dwpart " << dwpart << ",dwmsg " << dwmsg << ",parent " << parent // << ",dwparts msg " << dwpart->Body().Message() <<",id "<<dwpart->ObjectId() << endl; } else if ( part->partSpecifier() != "0" && !part->partSpecifier().endsWith(".HEADER") ) @@ -1165,7 +1165,7 @@ namespace KMail { // add to message dwmsg->Body().AddBodyPart( dwpart ); dwpart->Parse(); -// kdDebug(5006) << "constructed dwpart " << dwpart << ",dwmsg " << dwmsg << ",tqparent " << tqparent +// kdDebug(5006) << "constructed dwpart " << dwpart << ",dwmsg " << dwmsg << ",parent " << parent // << ",dwparts msg " << dwpart->Body().Message() <<",id "<<dwpart->ObjectId() << endl; } else dwpart = 0; @@ -1175,20 +1175,20 @@ namespace KMail { if (tqchildren > 0) { - DwBodyPart* newtqparent = dwpart; + DwBodyPart* newparent = dwpart; const DwMessage* newmsg = dwmsg; if ( part->originalContentTypeStr() == "MESSAGE/RFC822" && dwpart && dwpart->Body().Message() ) { // set the encapsulated message as the new message - newtqparent = 0; + newparent = 0; newmsg = dwpart->Body().Message(); } KMMessagePart* newParentKMPart = part; - if ( part->partSpecifier().endsWith(".HEADER") ) // we don't want headers as tqparent + if ( part->partSpecifier().endsWith(".HEADER") ) // we don't want headers as parent newParentKMPart = parentKMPart; - constructParts( stream, tqchildren, newParentKMPart, newtqparent, newmsg ); + constructParts( stream, tqchildren, newParentKMPart, newparent, newmsg ); } } } @@ -1246,16 +1246,16 @@ namespace KMail { ImapAccountBase::JobIterator it = findJob(job); if ( it == jobsEnd() ) return; int errorCode = job->error(); - KMFolder * const tqparent = (*it).tqparent; + KMFolder * const parent = (*it).parent; const TQString path = (*it).path; if (errorCode && errorCode != KIO::ERR_CANNOT_OPEN_FOR_WRITING) { bool cont = handleJobError( job, i18n( "Error while uploading status of messages to server: " ) + '\n' ); - emit imapStatusChanged( tqparent, path, cont ); + emit imapStatusChanged( parent, path, cont ); } else { - emit imapStatusChanged( tqparent, path, true ); + emit imapStatusChanged( parent, path, true ); removeJob(it); } } @@ -1370,11 +1370,11 @@ namespace KMail { } //------------------------------------------------------------------------------ - TQString ImapAccountBase::createImapPath( const TQString& tqparent, + TQString ImapAccountBase::createImapPath( const TQString& parent, const TQString& folderName ) { - kdDebug(5006) << "createImapPath tqparent="<<tqparent<<", folderName="<<folderName<<endl; - TQString newName = tqparent; + kdDebug(5006) << "createImapPath parent="<<parent<<", folderName="<<folderName<<endl; + TQString newName = parent; // strip / at the end if ( newName.endsWith("/") ) { newName = newName.left( newName.length() - 1 ); @@ -1399,14 +1399,14 @@ namespace KMail { } //------------------------------------------------------------------------------ - TQString ImapAccountBase::createImapPath( FolderStorage* tqparent, + TQString ImapAccountBase::createImapPath( FolderStorage* parent, const TQString& folderName ) { TQString path; - if ( tqparent->folderType() == KMFolderTypeImap ) { - path = static_cast<KMFolderImap*>( tqparent )->imapPath(); - } else if ( tqparent->folderType() == KMFolderTypeCachedImap ) { - path = static_cast<KMFolderCachedImap*>( tqparent )->imapPath(); + if ( parent->folderType() == KMFolderTypeImap ) { + path = static_cast<KMFolderImap*>( parent )->imapPath(); + } else if ( parent->folderType() == KMFolderTypeCachedImap ) { + path = static_cast<KMFolderCachedImap*>( parent )->imapPath(); } else { // error return path; |