diff options
Diffstat (limited to 'juk/webimagefetcher.cpp')
-rw-r--r-- | juk/webimagefetcher.cpp | 44 |
1 files changed, 22 insertions, 22 deletions
diff --git a/juk/webimagefetcher.cpp b/juk/webimagefetcher.cpp index 3e806bff..1e5bec83 100644 --- a/juk/webimagefetcher.cpp +++ b/juk/webimagefetcher.cpp @@ -12,9 +12,9 @@ * * ***************************************************************************/ -#include <qhttp.h> -#include <qdom.h> -#include <qwaitcondition.h> +#include <tqhttp.h> +#include <tqdom.h> +#include <tqwaitcondition.h> #include <kapplication.h> #include <kstatusbar.h> @@ -33,22 +33,22 @@ WebImage::WebImage() { } -WebImage::WebImage(const QString &imageURL, const QString &thumbURL, +WebImage::WebImage(const TQString &imageURL, const TQString &thumbURL, int width, int height) : m_imageURL(imageURL), m_thumbURL(thumbURL), - m_size(QString("\n%1 x %2").arg(width).arg(height)) + m_size(TQString("\n%1 x %2").arg(width).arg(height)) { } -WebImageFetcher::WebImageFetcher(QObject *parent) - : QObject(parent), - m_connection(new QHttp(this)), +WebImageFetcher::WebImageFetcher(TQObject *parent) + : TQObject(parent), + m_connection(new TQHttp(this)), m_connectionId(-1), m_dialog(0) { - connect(m_connection, SIGNAL(requestFinished(int,bool)), SLOT(slotWebRequestFinished(int,bool))); + connect(m_connection, TQT_SIGNAL(requestFinished(int,bool)), TQT_SLOT(slotWebRequestFinished(int,bool))); } WebImageFetcher::~WebImageFetcher() @@ -59,7 +59,7 @@ WebImageFetcher::~WebImageFetcher() void WebImageFetcher::setFile(const FileHandle &file) { m_file = file; - m_searchString = QString(file.tag()->artist() + ' ' + file.tag()->album()); + m_searchString = TQString(file.tag()->artist() + ' ' + file.tag()->album()); if(m_dialog) m_dialog->setFile(file); @@ -103,9 +103,9 @@ void WebImageFetcher::slotWebRequestFinished(int id, bool error) return; } - QDomDocument results("ResultSet"); + TQDomDocument results("ResultSet"); - QString errorStr; + TQString errorStr; int errorCol, errorLine; if(!results.setContent(m_connection->readAll(), &errorStr, &errorLine, &errorCol)) { kdError(65432) << "Unable to create XML document from Yahoo results.\n"; @@ -113,7 +113,7 @@ void WebImageFetcher::slotWebRequestFinished(int id, bool error) return; } - QDomNode n = results.documentElement(); + TQDomNode n = results.documentElement(); bool hasNoResults = false; @@ -122,7 +122,7 @@ void WebImageFetcher::slotWebRequestFinished(int id, bool error) hasNoResults = true; } else { - QDomElement result = n.toElement(); + TQDomElement result = n.toElement(); if(result.attribute("totalResultsReturned").toInt() == 0) kdDebug(65432) << "Search returned " << result.attribute("totalResultsAvailable") << " results.\n"; @@ -144,10 +144,10 @@ void WebImageFetcher::slotWebRequestFinished(int id, bool error) n = n.firstChild(); while(!n.isNull()) { - QDomNode resultUrl = n.namedItem("Url"); - QDomNode thumbnail = n.namedItem("Thumbnail"); - QDomNode height = n.namedItem("Height"); - QDomNode width = n.namedItem("Width"); + TQDomNode resultUrl = n.namedItem("Url"); + TQDomNode thumbnail = n.namedItem("Thumbnail"); + TQDomNode height = n.namedItem("Height"); + TQDomNode width = n.namedItem("Width"); // We have the necessary info, move to next node before we forget. n = n.nextSibling(); @@ -173,8 +173,8 @@ void WebImageFetcher::slotWebRequestFinished(int id, bool error) m_dialog = new WebImageFetcherDialog(m_imageList, m_file, 0); m_dialog->setModal(true); - connect(m_dialog, SIGNAL(coverSelected()), SLOT(slotCoverChosen())); - connect(m_dialog, SIGNAL(newSearchRequested()), SLOT(slotNewSearch())); + connect(m_dialog, TQT_SIGNAL(coverSelected()), TQT_SLOT(slotCoverChosen())); + connect(m_dialog, TQT_SIGNAL(newSearchRequested()), TQT_SLOT(slotNewSearch())); } m_dialog->refreshScreen(m_imageList); @@ -183,7 +183,7 @@ void WebImageFetcher::slotWebRequestFinished(int id, bool error) void WebImageFetcher::slotCoverChosen() { - QPixmap pixmap = m_dialog->result(); + TQPixmap pixmap = m_dialog->result(); if(pixmap.isNull()) { kdError(65432) << "Selected pixmap is null for some reason.\n"; return; @@ -210,7 +210,7 @@ void WebImageFetcher::displayWaitMessage() void WebImageFetcher::requestNewSearchTerms(bool noResults) { bool ok; - QString search = KInputDialog::getText(i18n("Cover Downloader"), + TQString search = KInputDialog::getText(i18n("Cover Downloader"), noResults ? i18n("No matching images found, please enter new search terms:") : i18n("Enter new search terms:"), |