diff options
author | Timothy Pearson <[email protected]> | 2013-01-25 00:33:36 -0600 |
---|---|---|
committer | Timothy Pearson <[email protected]> | 2013-01-25 00:33:36 -0600 |
commit | 3c5631f74d1c75204f950140331e10f739082ee9 (patch) | |
tree | a2811ff6c81d3c771745cde47734e65b1da3d806 /ksvg | |
parent | 6adb71382c3d5277c3dcbc4ec24c5ff36b4c07ef (diff) | |
download | tdegraphics-3c5631f74d1c75204f950140331e10f739082ee9.tar.gz tdegraphics-3c5631f74d1c75204f950140331e10f739082ee9.zip |
Rename KCModule, KConfig, KIO, KServer, and KSocket to avoid conflicts with KDE4
Diffstat (limited to 'ksvg')
-rw-r--r-- | ksvg/core/KSVGLoader.cpp | 32 | ||||
-rw-r--r-- | ksvg/core/KSVGLoader.h | 12 | ||||
-rw-r--r-- | ksvg/impl/SVGColorProfileElementImpl.cc | 4 | ||||
-rw-r--r-- | ksvg/impl/SVGScriptElementImpl.cc | 10 | ||||
-rw-r--r-- | ksvg/impl/SVGScriptElementImpl.h | 6 |
5 files changed, 32 insertions, 32 deletions
diff --git a/ksvg/core/KSVGLoader.cpp b/ksvg/core/KSVGLoader.cpp index 54f569b1..3ae1d7ff 100644 --- a/ksvg/core/KSVGLoader.cpp +++ b/ksvg/core/KSVGLoader.cpp @@ -49,14 +49,14 @@ KSVGLoader::~KSVGLoader() TQString KSVGLoader::loadXML(::KURL url) { TQString tmpFile; - if(KIO::NetAccess::download(url, tmpFile, 0)) + if(TDEIO::NetAccess::download(url, tmpFile, 0)) { TQIODevice *dev = KFilterDev::deviceForFile(tmpFile, "application/x-gzip", true); TQByteArray contents; if(dev->open(IO_ReadOnly)) contents = dev->readAll(); delete dev; - KIO::NetAccess::removeTempFile(tmpFile); + TDEIO::NetAccess::removeTempFile(tmpFile); return TQString(contents); } @@ -68,12 +68,12 @@ void KSVGLoader::getSVGContent(::KURL url) if(!url.prettyURL().isEmpty()) { if(m_job == 0) - m_job = KIO::get(url, false, false); + m_job = TDEIO::get(url, false, false); m_job->setAutoErrorHandlingEnabled(true); - connect(m_job, TQT_SIGNAL(data(KIO::Job *, const TQByteArray &)), this, TQT_SLOT(slotData(KIO::Job *, const TQByteArray &))); - connect(m_job, TQT_SIGNAL(result(KIO::Job *)), this, TQT_SLOT(slotResult(KIO::Job *))); + connect(m_job, TQT_SIGNAL(data(TDEIO::Job *, const TQByteArray &)), this, TQT_SLOT(slotData(TDEIO::Job *, const TQByteArray &))); + connect(m_job, TQT_SIGNAL(result(TDEIO::Job *)), this, TQT_SLOT(slotResult(TDEIO::Job *))); } } @@ -89,14 +89,14 @@ void KSVGLoader::newImageJob(SVGImageElementImpl *image, ::KURL baseURL) map->data = new TQByteArray(); map->imageElement = image; - KIO::TransferJob *imageJob = KIO::get(::KURL(baseURL, map->imageElement->fileName()), false, false); - connect(imageJob, TQT_SIGNAL(data(KIO::Job *, const TQByteArray &)), this, TQT_SLOT(slotData(KIO::Job *, const TQByteArray &))); - connect(imageJob, TQT_SIGNAL(result(KIO::Job *)), this, TQT_SLOT(slotResult(KIO::Job *))); + TDEIO::TransferJob *imageJob = TDEIO::get(::KURL(baseURL, map->imageElement->fileName()), false, false); + connect(imageJob, TQT_SIGNAL(data(TDEIO::Job *, const TQByteArray &)), this, TQT_SLOT(slotData(TDEIO::Job *, const TQByteArray &))); + connect(imageJob, TQT_SIGNAL(result(TDEIO::Job *)), this, TQT_SLOT(slotResult(TDEIO::Job *))); m_imageJobs.insert(imageJob, map); } -void KSVGLoader::slotData(KIO::Job *job, const TQByteArray &data) +void KSVGLoader::slotData(TDEIO::Job *job, const TQByteArray &data) { if(job == m_job) { @@ -105,7 +105,7 @@ void KSVGLoader::slotData(KIO::Job *job, const TQByteArray &data) } else { - TQMap<KIO::TransferJob *, ImageStreamMap *>::Iterator it; + TQMap<TDEIO::TransferJob *, ImageStreamMap *>::Iterator it; for(it = m_imageJobs.begin(); it != m_imageJobs.end(); ++it) { if(it.key() == job) @@ -118,13 +118,13 @@ void KSVGLoader::slotData(KIO::Job *job, const TQByteArray &data) } } -void KSVGLoader::slotResult(KIO::Job *job) +void KSVGLoader::slotResult(TDEIO::Job *job) { if(job == m_job) { if(m_job->error() == 0) { - TQString check = static_cast<KIO::TransferJob *>(job)->url().prettyURL(); + TQString check = static_cast<TDEIO::TransferJob *>(job)->url().prettyURL(); if(check.contains(".svgz") || check.contains(".svg.gz")) { // decode the gzipped svg and emit it @@ -151,7 +151,7 @@ void KSVGLoader::slotResult(KIO::Job *job) } else { - TQMap<KIO::TransferJob *, ImageStreamMap *>::Iterator it; + TQMap<TDEIO::TransferJob *, ImageStreamMap *>::Iterator it; for(it = m_imageJobs.begin(); it != m_imageJobs.end(); ++it) { if(it.key() == job) @@ -184,7 +184,7 @@ void KSVGLoader::slotResult(KIO::Job *job) (streamMap->data)->resize(0); - m_imageJobs.remove(static_cast<KIO::TransferJob *>(job)); + m_imageJobs.remove(static_cast<TDEIO::TransferJob *>(job)); emit imageReady(streamMap->imageElement); break; @@ -204,7 +204,7 @@ TQString KSVGLoader::getUrl(::KURL url, bool local) void KSVGLoader::postUrl(::KURL url, const TQByteArray &data, const TQString &mimeType, KJS::ExecState *exec, KJS::Object &callBackFunction, KJS::Object &status) { - KIO::TransferJob *job = KIO::http_post(url, data, false); + TDEIO::TransferJob *job = TDEIO::http_post(url, data, false); job->addMetaData("content-type", mimeType); m_postUrlData.job = job; @@ -212,7 +212,7 @@ void KSVGLoader::postUrl(::KURL url, const TQByteArray &data, const TQString &mi m_postUrlData.status = &status; m_postUrlData.callBackFunction = &callBackFunction; - connect(job, TQT_SIGNAL(result(KIO::Job *)), TQT_SLOT(slotResult(KIO::Job *))); + connect(job, TQT_SIGNAL(result(TDEIO::Job *)), TQT_SLOT(slotResult(TDEIO::Job *))); } class CharacterDataSearcher : public TQXmlDefaultHandler diff --git a/ksvg/core/KSVGLoader.h b/ksvg/core/KSVGLoader.h index f93280bd..69d61494 100644 --- a/ksvg/core/KSVGLoader.h +++ b/ksvg/core/KSVGLoader.h @@ -25,7 +25,7 @@ class KURL; -namespace KIO +namespace TDEIO { class Job; class TransferJob; @@ -44,7 +44,7 @@ struct ImageStreamMap; typedef struct { - KIO::Job *job; + TDEIO::Job *job; KJS::ExecState *exec; KJS::Object *callBackFunction, *status; } PostUrlData; @@ -73,8 +73,8 @@ signals: void imageReady(SVGImageElementImpl *); private slots: - void slotData(KIO::Job *, const TQByteArray &); - void slotResult(KIO::Job *); + void slotData(TDEIO::Job *, const TQByteArray &); + void slotResult(TDEIO::Job *); private: static TQString loadXML(::KURL); @@ -82,8 +82,8 @@ private: PostUrlData m_postUrlData; TQByteArray m_data; - KIO::TransferJob *m_job; - TQMap<KIO::TransferJob *, ImageStreamMap *> m_imageJobs; + TDEIO::TransferJob *m_job; + TQMap<TDEIO::TransferJob *, ImageStreamMap *> m_imageJobs; }; } diff --git a/ksvg/impl/SVGColorProfileElementImpl.cc b/ksvg/impl/SVGColorProfileElementImpl.cc index 7890f07e..85e3c035 100644 --- a/ksvg/impl/SVGColorProfileElementImpl.cc +++ b/ksvg/impl/SVGColorProfileElementImpl.cc @@ -186,7 +186,7 @@ bool SVGColorProfileElementImpl::canLoad(bool remote, bool &tempFile, TQString & { if(remote) { - if(KIO::NetAccess::download(file, open, 0)) + if(TDEIO::NetAccess::download(file, open, 0)) tempFile = true; } } @@ -218,7 +218,7 @@ bool SVGColorProfileElementImpl::loadColorProfile() m_loaded = true; if(tempFile) - KIO::NetAccess::removeTempFile(open); + TDEIO::NetAccess::removeTempFile(open); return true; } diff --git a/ksvg/impl/SVGScriptElementImpl.cc b/ksvg/impl/SVGScriptElementImpl.cc index c7e6994e..b7ddf420 100644 --- a/ksvg/impl/SVGScriptElementImpl.cc +++ b/ksvg/impl/SVGScriptElementImpl.cc @@ -73,20 +73,20 @@ void SVGScriptElementImpl::setAttributes() KURL url(ownerDoc()->baseUrl(), href); if(m_job == 0) - m_job = KIO::get(url, false, false); + m_job = TDEIO::get(url, false, false); - connect(m_job, TQT_SIGNAL(data(KIO::Job *, const TQByteArray &)), this, TQT_SLOT(slotData(KIO::Job *, const TQByteArray &))); - connect(m_job, TQT_SIGNAL(result(KIO::Job *)), this, TQT_SLOT(slotResult(KIO::Job *))); + connect(m_job, TQT_SIGNAL(data(TDEIO::Job *, const TQByteArray &)), this, TQT_SLOT(slotData(TDEIO::Job *, const TQByteArray &))); + connect(m_job, TQT_SIGNAL(result(TDEIO::Job *)), this, TQT_SLOT(slotResult(TDEIO::Job *))); } } -void SVGScriptElementImpl::slotData(KIO::Job *, const TQByteArray &data) +void SVGScriptElementImpl::slotData(TDEIO::Job *, const TQByteArray &data) { TQDataStream dataStream(m_data, IO_WriteOnly | IO_Append); dataStream.writeRawBytes(data.data(), data.size()); } -void SVGScriptElementImpl::slotResult(KIO::Job *) +void SVGScriptElementImpl::slotResult(TDEIO::Job *) { m_job = 0; diff --git a/ksvg/impl/SVGScriptElementImpl.h b/ksvg/impl/SVGScriptElementImpl.h index 560873e7..72c75506 100644 --- a/ksvg/impl/SVGScriptElementImpl.h +++ b/ksvg/impl/SVGScriptElementImpl.h @@ -58,11 +58,11 @@ public: static bool executeScript(DOM::Node node, SVGDocumentImpl *document, const TQString &text); private slots: - void slotData(KIO::Job *, const TQByteArray &); - void slotResult(KIO::Job *); + void slotData(TDEIO::Job *, const TQByteArray &); + void slotResult(TDEIO::Job *); private: - KIO::TransferJob *m_job; + TDEIO::TransferJob *m_job; TQByteArray m_data; TQString m_text; bool m_added; |