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

List:       kde-commits
Subject:    KDE/kdelibs/plasma
From:       Marco Martin <notmart () gmail ! com>
Date:       2009-12-12 16:07:26
Message-ID: 1260634046.878057.13845.nullmailer () svn ! kde ! org
[Download RAW message or body]

SVN commit 1061657 by mart:

create a mimetype job instead of a generic transfer job, that is confised to death if \
the url is a directory instead of a file BUG:218097


 M  +5 -3      containment.cpp  


--- trunk/KDE/kdelibs/plasma/containment.cpp #1061656:1061657
@@ -1310,11 +1310,13 @@
 
                 // It may be a directory or a file, let's stat
                 KIO::JobFlags flags = KIO::HideProgressInfo;
-                KIO::TransferJob *job = KIO::get(url, KIO::NoReload, flags);
-                if (dropEvent)
+                KIO::MimetypeJob *job = KIO::mimetype(url, flags);
+                if (dropEvent) {
                     dropPoints[job] = dropEvent->pos();
-                else
+                } else {
                     dropPoints[job] = scenePos;
+                }
+
                 QObject::connect(job, SIGNAL(result(KJob*)), q, \
                SLOT(dropJobResult(KJob*)));
                 QObject::connect(job, SIGNAL(mimetype(KIO::Job *, const QString&)),
                                  q, SLOT(mimeTypeRetrieved(KIO::Job *, const \
QString&)));


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

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