summaryrefslogtreecommitdiffstats
path: root/kresources/lib/groupwareuploadjob.cpp
diff options
context:
space:
mode:
authortpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2010-07-31 19:53:50 +0000
committertpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2010-07-31 19:53:50 +0000
commit7be55ffa061c026e35e2d6a0effe1161ddb0d41f (patch)
tree8474f9b444b2756228600050f07a7ff25de532b2 /kresources/lib/groupwareuploadjob.cpp
parentf587f20a6d09f1729dd0a8c1cd8ee0110aec7451 (diff)
downloadtdepim-7be55ffa061c026e35e2d6a0effe1161ddb0d41f.tar.gz
tdepim-7be55ffa061c026e35e2d6a0effe1161ddb0d41f.zip
Trinity Qt initial conversion
git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdepim@1157655 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'kresources/lib/groupwareuploadjob.cpp')
-rw-r--r--kresources/lib/groupwareuploadjob.cpp102
1 files changed, 51 insertions, 51 deletions
diff --git a/kresources/lib/groupwareuploadjob.cpp b/kresources/lib/groupwareuploadjob.cpp
index bb3098fc2..e4d6cb131 100644
--- a/kresources/lib/groupwareuploadjob.cpp
+++ b/kresources/lib/groupwareuploadjob.cpp
@@ -33,8 +33,8 @@
#include <kurl.h>
#include <kio/job.h>
-#include <qstringlist.h>
-#include <qtimer.h>
+#include <tqstringlist.h>
+#include <tqtimer.h>
#include <klocale.h>
using namespace KPIM;
@@ -52,22 +52,22 @@ void GroupwareUploadJob::run()
KPIM::ProgressManager::getUniqueID(),
adaptor()->uploadProgressMessage() );
connect( mUploadProgress,
- SIGNAL( progressItemCanceled( KPIM::ProgressItem * ) ),
- SLOT( cancelSave() ) );
+ TQT_SIGNAL( progressItemCanceled( KPIM::ProgressItem * ) ),
+ TQT_SLOT( cancelSave() ) );
- connect( adaptor(), SIGNAL( itemDeletionError( const KURL &, const QString & ) ),
- SLOT( slotItemDeleteError( const KURL &, const QString & ) ) );
- connect( adaptor(), SIGNAL( itemUploadError( const KURL &, const QString & ) ),
- SLOT( slotItemUploadError( const KURL &, const QString & ) ) );
- connect( adaptor(), SIGNAL( itemUploadNewError( const QString &, const QString & ) ),
- SLOT( slotItemUploadNewError( const QString &, const QString & ) ) );
+ connect( adaptor(), TQT_SIGNAL( itemDeletionError( const KURL &, const TQString & ) ),
+ TQT_SLOT( slotItemDeleteError( const KURL &, const TQString & ) ) );
+ connect( adaptor(), TQT_SIGNAL( itemUploadError( const KURL &, const TQString & ) ),
+ TQT_SLOT( slotItemUploadError( const KURL &, const TQString & ) ) );
+ connect( adaptor(), TQT_SIGNAL( itemUploadNewError( const TQString &, const TQString & ) ),
+ TQT_SLOT( slotItemUploadNewError( const TQString &, const TQString & ) ) );
- connect( adaptor(), SIGNAL( itemDeleted( const QString &, const KURL & ) ),
- SLOT( slotItemDeleted( const QString &, const KURL & ) ) );
- connect( adaptor(), SIGNAL( itemUploaded( const QString &, const KURL & ) ),
- SLOT( slotItemUploaded( const QString &, const KURL & ) ) );
- connect( adaptor(), SIGNAL( itemUploadedNew( const QString &, const KURL& ) ),
- SLOT( slotItemUploadedNew( const QString &, const KURL & ) ) );
+ connect( adaptor(), TQT_SIGNAL( itemDeleted( const TQString &, const KURL & ) ),
+ TQT_SLOT( slotItemDeleted( const TQString &, const KURL & ) ) );
+ connect( adaptor(), TQT_SIGNAL( itemUploaded( const TQString &, const KURL & ) ),
+ TQT_SLOT( slotItemUploaded( const TQString &, const KURL & ) ) );
+ connect( adaptor(), TQT_SIGNAL( itemUploadedNew( const TQString &, const KURL& ) ),
+ TQT_SLOT( slotItemUploadedNew( const TQString &, const KURL & ) ) );
mUploadProgress->setTotalItems( mAddedItems.size() + mChangedItems.size() +
@@ -81,7 +81,7 @@ void GroupwareUploadJob::deleteItem()
{
kdDebug(5800)<<"GroupwareUploadJob::deleteItem()"<<endl;
if ( mDeletedItems.isEmpty() ) {
- QTimer::singleShot( 0, this, SLOT( uploadItem() ) );
+ TQTimer::singleShot( 0, this, TQT_SLOT( uploadItem() ) );
} else {
kdDebug(7000) << " Deleting " << mDeletedItems.size() << " items from the server " << endl;
@@ -101,11 +101,11 @@ kdDebug() << "Not using batch delete " << endl;
}
if ( mDeletionJob ) {
- mDeletionJobData = QString::null;
- connect( mDeletionJob, SIGNAL( result( KIO::Job* ) ),
- SLOT( slotDeletionJobResult( KIO::Job* ) ) );
-// connect( mDeletionJob, SIGNAL( data( KIO::Job *, const QByteArray & ) ),
-// SLOT( slotDeletionJobData( KIO::Job *, const QByteArray & ) ) );
+ mDeletionJobData = TQString::null;
+ connect( mDeletionJob, TQT_SIGNAL( result( KIO::Job* ) ),
+ TQT_SLOT( slotDeletionJobResult( KIO::Job* ) ) );
+// connect( mDeletionJob, TQT_SIGNAL( data( KIO::Job *, const TQByteArray & ) ),
+// TQT_SLOT( slotDeletionJobData( KIO::Job *, const TQByteArray & ) ) );
} else {
deleteItem();
}
@@ -114,7 +114,7 @@ kdDebug() << "Not using batch delete " << endl;
-void GroupwareUploadJob::slotDeletionJobData( KIO::Job *, const QByteArray &data )
+void GroupwareUploadJob::slotDeletionJobData( KIO::Job *, const TQByteArray &data )
{
kdDebug(5800) << "OpenGroupware::slotDeletionData()" << endl;
@@ -129,7 +129,7 @@ void GroupwareUploadJob::slotDeletionJobResult( KIO::Job *job )
adaptor()->interpretRemoveJob( job, mDeletionJobData );
}
mDeletionJob = 0;
- QTimer::singleShot( 0, this, SLOT( deleteItem() ) );
+ TQTimer::singleShot( 0, this, TQT_SLOT( deleteItem() ) );
}
@@ -138,7 +138,7 @@ void GroupwareUploadJob::uploadItem()
{
kdDebug(5800)<<"GroupwareUploadJob::uploadItem()"<<endl;
if ( mChangedItems.isEmpty() ) {
- QTimer::singleShot( 0, this, SLOT( uploadNewItem() ) );
+ TQTimer::singleShot( 0, this, TQT_SLOT( uploadNewItem() ) );
} else {
kdDebug(5800)<<"We still have "<<mChangedItems.count()<<" changed items to upload"<<endl;
@@ -158,11 +158,11 @@ kdDebug() << "Not using batch upload " << endl;
}
if ( mUploadJob ) {
- mUploadJobData = QString::null;
- connect( mUploadJob, SIGNAL( result( KIO::Job* ) ),
- SLOT( slotUploadJobResult( KIO::Job* ) ) );
- connect( mUploadJob, SIGNAL( data( KIO::Job *, const QByteArray & ) ),
- SLOT( slotUploadJobData( KIO::Job *, const QByteArray & ) ) );
+ mUploadJobData = TQString::null;
+ connect( mUploadJob, TQT_SIGNAL( result( KIO::Job* ) ),
+ TQT_SLOT( slotUploadJobResult( KIO::Job* ) ) );
+ connect( mUploadJob, TQT_SIGNAL( data( KIO::Job *, const TQByteArray & ) ),
+ TQT_SLOT( slotUploadJobData( KIO::Job *, const TQByteArray & ) ) );
} else {
uploadItem();
}
@@ -170,7 +170,7 @@ kdDebug() << "Not using batch upload " << endl;
}
-void GroupwareUploadJob::slotUploadJobData( KIO::Job *, const QByteArray &data )
+void GroupwareUploadJob::slotUploadJobData( KIO::Job *, const TQByteArray &data )
{
kdDebug(5800) << "OpenGroupware::slotUploadData()" << endl;
@@ -185,7 +185,7 @@ void GroupwareUploadJob::slotUploadJobResult( KIO::Job *job )
adaptor()->interpretUploadJob( job, mUploadJobData );
}
mUploadJob = 0;
- QTimer::singleShot( 0, this, SLOT( uploadItem() ) );
+ TQTimer::singleShot( 0, this, TQT_SLOT( uploadItem() ) );
}
@@ -216,11 +216,11 @@ kdDebug() << "Not using batch create to " << url.url() << " for item of type " <
}
if ( mUploadJob ) {
- mUploadNewJobData = QString::null;
- connect( mUploadJob, SIGNAL( result( KIO::Job* ) ),
- SLOT( slotUploadNewJobResult( KIO::Job* ) ) );
- connect( mUploadJob, SIGNAL( data( KIO::Job *, const QByteArray & ) ),
- SLOT( slotUploadNewJobData( KIO::Job *, const QByteArray & ) ) );
+ mUploadNewJobData = TQString::null;
+ connect( mUploadJob, TQT_SIGNAL( result( KIO::Job* ) ),
+ TQT_SLOT( slotUploadNewJobResult( KIO::Job* ) ) );
+ connect( mUploadJob, TQT_SIGNAL( data( KIO::Job *, const TQByteArray & ) ),
+ TQT_SLOT( slotUploadNewJobData( KIO::Job *, const TQByteArray & ) ) );
} else {
uploadNewItem();
}
@@ -231,7 +231,7 @@ kdDebug() << "Not using batch create to " << url.url() << " for item of type " <
}
}
-void GroupwareUploadJob::slotUploadNewJobData( KIO::Job *, const QByteArray &data )
+void GroupwareUploadJob::slotUploadNewJobData( KIO::Job *, const TQByteArray &data )
{
kdDebug(5800) << "OpenGroupware::slotUploadNewJobData()" << endl;
@@ -246,7 +246,7 @@ void GroupwareUploadJob::slotUploadNewJobResult( KIO::Job *job )
adaptor()->interpretUploadNewJob( job, mUploadNewJobData );
}
mUploadJob = 0;
- QTimer::singleShot( 0, this, SLOT( uploadNewItem() ) );
+ TQTimer::singleShot( 0, this, TQT_SLOT( uploadNewItem() ) );
}
@@ -255,12 +255,12 @@ void GroupwareUploadJob::kill()
cancelSave();
}
-void GroupwareUploadJob::slotItemDeleted( const QString &/*localId*/, const KURL &remoteURL )
+void GroupwareUploadJob::slotItemDeleted( const TQString &/*localId*/, const KURL &remoteURL )
{
kdDebug() << "GroupwareUploadJob::slotItemDeleted, removal successful: "<< remoteURL.url() << endl;
- const QString &remote = remoteURL.path();
- const QString &local = adaptor()->idMapper()->localId( remote );
+ const TQString &remote = remoteURL.path();
+ const TQString &local = adaptor()->idMapper()->localId( remote );
if ( !local.isEmpty() ) {
// TODO: Is the deleted status reset in the resource?
adaptor()->deleteItem( local );
@@ -290,12 +290,12 @@ kdDebug()<<"Found it in the list!"<<endl;
-void GroupwareUploadJob::slotItemUploaded( const QString &/*localId*/, const KURL &remoteURL )
+void GroupwareUploadJob::slotItemUploaded( const TQString &/*localId*/, const KURL &remoteURL )
{
kdDebug() << "GroupwareUploadJob::slotItemUploaded, upload successful: "<< remoteURL.url() << endl;
- const QString &remote = remoteURL.path();
- const QString &local = adaptor()->idMapper()->localId( remote );
+ const TQString &remote = remoteURL.path();
+ const TQString &local = adaptor()->idMapper()->localId( remote );
if ( !local.isEmpty() ) {
// TODO: Is the deleted status reset in the resource?
// adaptor()->itemUploaded( local, remoteURL );
@@ -327,14 +327,14 @@ kdDebug()<<"Found it in the list!"<<endl;
}
-void GroupwareUploadJob::slotItemUploadedNew( const QString &localId, const KURL &remoteURL )
+void GroupwareUploadJob::slotItemUploadedNew( const TQString &localId, const KURL &remoteURL )
{
kdDebug() << "GroupwareUploadJob::slotItemUploadedNew, upload successful: "<< remoteURL.url() << endl;
- const QString &remote = remoteURL.path();
+ const TQString &remote = remoteURL.path();
// TODO: For a new item this won't return anything, so we need to insert the
// local<=>remote id map when creating the upload job... And maybe
- const QString &local = adaptor()->idMapper()->localId( remote );
+ const TQString &local = adaptor()->idMapper()->localId( remote );
if ( !localId.isEmpty() ) {
adaptor()->deleteItem( localId );
}
@@ -367,7 +367,7 @@ kdDebug()<<"Found it in the list!"<<endl;
}
}
-void GroupwareUploadJob::slotItemDeleteError( const KURL &remoteURL, const QString &/*error*/ )
+void GroupwareUploadJob::slotItemDeleteError( const KURL &remoteURL, const TQString &/*error*/ )
{
// TODO: Add to error list, remove from uploading and toUpload list
kdDebug() << "GroupwareUploadJob::slotItemDeleteError, removal not successful: "<< remoteURL.url() << endl;
@@ -393,7 +393,7 @@ kdDebug()<<"Found it in the list!"<<endl;
}
}
-void GroupwareUploadJob::slotItemUploadError( const KURL &remoteURL, const QString &/*error*/ )
+void GroupwareUploadJob::slotItemUploadError( const KURL &remoteURL, const TQString &/*error*/ )
{
// TODO: Add to error list, remove from uploading and toUpload list
kdDebug() << "GroupwareUploadJob::slotItemUploadError, removal not successful: "<< remoteURL.url() << endl;
@@ -419,7 +419,7 @@ kdDebug()<<"Found it in the list!"<<endl;
}
}
-void GroupwareUploadJob::slotItemUploadNewError( const QString &/*localID*/, const QString &remoteURL )
+void GroupwareUploadJob::slotItemUploadNewError( const TQString &/*localID*/, const TQString &remoteURL )
{
kdDebug(5006) << "GroupwareUploadJob::slotItemUploadNewError, removal not successful: "<< remoteURL << endl;
KPIM::GroupwareUploadItem::List allit( mAddedItems );