[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-commits
Subject:    KDE/kdelibs
From:       Kevin Ottens <ervin () kde ! org>
Date:       2010-11-23 10:37:55
Message-ID: 20101123103755.B2B34AC8A2 () svn ! kde ! org
[Download RAW message or body]

SVN commit 1199950 by ervin:

Get rid of scheduleJob use as it is deprecated.


 M  +1 -1      khtml/ecma/xmlhttprequest.cpp  
 M  +8 -8      kio/kio/copyjob.cpp  
 M  +4 -4      kio/kio/deletejob.cpp  
 M  +2 -2      kio/kio/job.cpp  
 M  +1 -1      kio/tests/jobtest.cpp  
 M  +1 -1      knewstuff/knewstuff2/ui/qasyncimage.cpp  
 M  +1 -1      knewstuff/knewstuff3/ui/imageloader.cpp  
 M  +1 -1      knewstuff/knewstuff3/upload/atticahelper.cpp  


--- trunk/KDE/kdelibs/khtml/ecma/xmlhttprequest.cpp #1199949:1199950
@@ -567,7 +567,7 @@
 #ifdef APPLE_CHANGES
   KWQServeRequest(khtml::Cache::loader(), doc->docLoader(), job);
 #else
-  KIO::Scheduler::scheduleJob( job );
+  KIO::Scheduler::setJobPriority( job, 1 );
 #endif
 }
 
--- trunk/KDE/kdelibs/kio/kio/copyjob.cpp #1199949:1199950
@@ -812,7 +812,7 @@
 
     KIO_ARGS << m_currentSrcURL << dest << (qint8) false /*no overwrite*/;
     SimpleJob * newJob = SimpleJobPrivate::newJobNoUi(slave_url, CMD_RENAME, packedArgs);
-    Scheduler::scheduleJob(newJob);
+    Scheduler::setJobPriority(newJob, 1);
     q->addSubjob( newJob );
     if ( m_currentSrcURL.directory() != dest.directory() ) // For the user, moving isn't renaming. Only \
renaming is.  m_bOnlyRenames = false;
@@ -954,7 +954,7 @@
                         // We need to stat the existing dir, to get its last-modification time
                         KUrl existingDest((*it).uDest);
                         SimpleJob * newJob = KIO::stat(existingDest, StatJob::DestinationSide, 2, \
                KIO::HideProgressInfo);
-                        Scheduler::scheduleJob(newJob);
+                        Scheduler::setJobPriority(newJob, 1);
                         kDebug(7007) << "KIO::stat for resolving conflict on " << existingDest;
                         state = STATE_CONFLICT_CREATING_DIRS;
                         q->addSubjob(newJob);
@@ -1140,7 +1140,7 @@
         // Create the directory - with default permissions so that we can put files into it
         // TODO : change permissions once all is finished; but for stuff coming from CDROM it sucks...
         KIO::SimpleJob *newjob = KIO::mkdir( udir, -1 );
-        Scheduler::scheduleJob(newjob);
+        Scheduler::setJobPriority(newjob, 1);
         if (shouldOverwriteFile(udir.path())) { // if we are overwriting an existing file or symlink
             newjob->addMetaData("overwrite", "true");
         }
@@ -1216,7 +1216,7 @@
                     // We need to stat the existing file, to get its last-modification time
                     KUrl existingFile((*it).uDest);
                     SimpleJob * newJob = KIO::stat(existingFile, StatJob::DestinationSide, 2, \
                KIO::HideProgressInfo);
-                    Scheduler::scheduleJob(newJob);
+                    Scheduler::setJobPriority(newJob, 1);
                     kDebug(7007) << "KIO::stat for resolving conflict on " << existingFile;
                     state = STATE_CONFLICT_COPYING_FILES;
                     q->addSubjob(newJob);
@@ -1424,7 +1424,7 @@
     {
         // This is the case of creating a real symlink
         KIO::SimpleJob *newJob = KIO::symlink( uSource.path(), uDest, flags|HideProgressInfo /*no GUI*/ \
                );
-        Scheduler::scheduleJob(newJob);
+        Scheduler::setJobPriority(newJob, 1);
         //kDebug(7007) << "Linking target=" << uSource.path() << "link=" << uDest;
         //emit linking( this, uSource.path(), uDest );
         m_bCurrentOperationIsLink = true;
@@ -1537,7 +1537,7 @@
         {
             const JobFlags flags = bOverwrite ? Overwrite : DefaultFlags;
             KIO::SimpleJob *newJob = KIO::symlink( (*it).linkDest, uDest, flags | HideProgressInfo /*no \
                GUI*/ );
-            Scheduler::scheduleJob(newJob);
+            Scheduler::setJobPriority(newJob, 1);
             newjob = newJob;
             //kDebug(7007) << "Linking target=" << (*it).linkDest << "link=" << uDest;
             m_currentSrcURL = KUrl( (*it).linkDest );
@@ -1608,7 +1608,7 @@
         // Take first dir to delete out of list - last ones first !
         KUrl::List::Iterator it = --dirsToRemove.end();
         SimpleJob *job = KIO::rmdir( *it );
-        Scheduler::scheduleJob(job);
+        Scheduler::setJobPriority(job, 1);
         dirsToRemove.erase(it);
         q->addSubjob( job );
     }
@@ -1635,7 +1635,7 @@
         ++m_directoriesCopiedIterator;
 
         KIO::SimpleJob *job = KIO::setModificationTime( url, dt );
-        Scheduler::scheduleJob(job);
+        Scheduler::setJobPriority(job, 1);
         q->addSubjob( job );
 
 
--- trunk/KDE/kdelibs/kio/kio/deletejob.cpp #1199949:1199950
@@ -243,7 +243,7 @@
             statNextSrc();
         } else {
             KIO::SimpleJob * job = KIO::stat( m_currentURL, StatJob::SourceSide, 0, \
                KIO::HideProgressInfo );
-            Scheduler::scheduleJob(job);
+            Scheduler::setJobPriority(job, 1);
             //kDebug(7007) << "stat'ing" << m_currentURL;
             q->addSubjob(job);
         }
@@ -301,7 +301,7 @@
             { // if remote - or if unlink() failed (we'll use the job's error handling in that case)
                 //kDebug(7007) << "calling file_delete on" << *it;
                 job = KIO::file_delete( *it, KIO::HideProgressInfo );
-                Scheduler::scheduleJob(job);
+                Scheduler::setJobPriority(job, 1);
                 m_currentURL=(*it);
             }
             if ( isLink )
@@ -343,7 +343,7 @@
                 // CMD_DEL will trigger the recursive deletion in the slave.
                 SimpleJob* job = KIO::rmdir( *it );
                 job->addMetaData(QString::fromLatin1("recurse"), "true");
-                Scheduler::scheduleJob(job);
+                Scheduler::setJobPriority(job, 1);
                 dirs.erase(it);
                 q->addSubjob( job );
                 return;
@@ -386,7 +386,7 @@
             ListJob *newjob = KIO::listRecursive(url, KIO::HideProgressInfo);
             newjob->addMetaData("details", "0");
             newjob->setUnrestricted(true); // No KIOSK restrictions
-            Scheduler::scheduleJob(newjob);
+            Scheduler::setJobPriority(newjob, 1);
             QObject::connect(newjob, SIGNAL(entries(KIO::Job*, const KIO::UDSEntryList&)),
                              q, SLOT(slotEntries(KIO::Job*,const KIO::UDSEntryList&)));
             q->addSubjob(newjob);
--- trunk/KDE/kdelibs/kio/kio/job.cpp #1199949:1199950
@@ -975,7 +975,7 @@
     // Send http update_cache command (2)
     KIO_ARGS << (int)2 << url << no_cache << qlonglong(expireDate);
     SimpleJob * job = SimpleJobPrivate::newJob(url, CMD_SPECIAL, packedArgs);
-    Scheduler::scheduleJob(job);
+    Scheduler::setJobPriority(job, 1);
     return job;
 }
 
@@ -2456,7 +2456,7 @@
                                                true /*recursive*/,
                                                prefix + filename + '/',
                                                includeHidden);
-                    Scheduler::scheduleJob(job);
+                    Scheduler::setJobPriority(job, 1);
                     q->connect(job, SIGNAL(entries( KIO::Job *, const KIO::UDSEntryList& )),
                                SLOT( gotEntries( KIO::Job*, const KIO::UDSEntryList& )));
                     q->addSubjob(job);
--- trunk/KDE/kdelibs/kio/tests/jobtest.cpp #1199949:1199950
@@ -1137,7 +1137,7 @@
     QVERIFY(job != 0);
     job->setUiDelegate( 0 );
 
-    KIO::Scheduler::scheduleJob(job); // shouldn't crash (#135456)
+    KIO::Scheduler::setJobPriority(job, 1); // shouldn't crash (#135456)
 
     bool ok = KIO::NetAccess::synchronousRun( job, 0 );
     QVERIFY( !ok ); // it should fail :)
--- trunk/KDE/kdelibs/knewstuff/knewstuff2/ui/qasyncimage.cpp #1199949:1199950
@@ -32,7 +32,7 @@
 {
     if (!m_url.isEmpty()) {
         KIO::TransferJob *job = KIO::get(m_url, KIO::NoReload, KIO::HideProgressInfo);
-        KIO::Scheduler::scheduleJob(job);
+        KIO::Scheduler::setJobPriority(job,1);
         connect(job, SIGNAL(result(KJob*)), SLOT(slotDownload(KJob*)));
         connect(job, SIGNAL(data(KIO::Job*, const QByteArray&)), SLOT(slotData(KIO::Job*, const \
QByteArray&)));  }
--- trunk/KDE/kdelibs/knewstuff/knewstuff3/ui/imageloader.cpp #1199949:1199950
@@ -43,7 +43,7 @@
         m_job = KIO::get(url, KIO::NoReload, KIO::HideProgressInfo);
         connect(m_job, SIGNAL(result(KJob*)), SLOT(slotDownload(KJob*)));
         connect(m_job, SIGNAL(data(KIO::Job*, const QByteArray&)), SLOT(slotData(KIO::Job*, const \
                QByteArray&)));
-        KIO::Scheduler::scheduleJob(m_job);
+        KIO::Scheduler::setJobPriority(m_job, 1);
     }
 }
 
--- trunk/KDE/kdelibs/knewstuff/knewstuff3/upload/atticahelper.cpp #1199949:1199950
@@ -200,7 +200,7 @@
             m_previewJob[previewNum-1] = KIO::get(url, KIO::NoReload, KIO::HideProgressInfo);
             connect(m_previewJob[previewNum-1], SIGNAL(result(KJob*)), \
                SLOT(slotPreviewDownload(KJob*)));
             connect(m_previewJob[previewNum-1], SIGNAL(data(KIO::Job*, const QByteArray&)), \
                SLOT(slotPreviewData(KIO::Job*, const QByteArray&)));
-            KIO::Scheduler::scheduleJob(m_previewJob[previewNum-1]);
+            KIO::Scheduler::setJobPriority(m_previewJob[previewNum-1], 1);
         }
     }
 }


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic